unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Android build-tools / prebuild / soong
@ 2017-10-16 18:39 Hartmut Goebel
  2017-10-18  2:36 ` Maxim Cournoyer
  0 siblings, 1 reply; 3+ messages in thread
From: Hartmut Goebel @ 2017-10-16 18:39 UTC (permalink / raw)
  To: guix-devel

Hi,

maybe somebody want to work in this puzzle :-)

Last week I played around upgrading the android libs and tools to the
current release 8.0.0_r17, when I realized that the build-system has
switched from a Makefile-base to one based on "Android.mk" files. These
are meant to be processed by a tool called "soong" (with two `o`).

soong is based on "ninja" an "Blueprint". There are no
build-instructions and no usage examples. So I asked on the
android-building mailinglist how to build and use soong stand-alone. I
got the answer that this is not indented but to be build like this
(fixed by my):

guix environment --ad-hoc repo
repo init -u https://android.googlesource.com/platform/manifest -b
build-tools
repo sync -j32
mkdir OUT
OUT_DIR=OUT prebuilts/build-tools/build-prebuilts.sh

So the script in the last line is the key. It looks acceptable, but I
have no clue about how go programs are build normally. So for me solving
this puzzle is quite time-consuming and I may not be able to work on it
for quite some time. Anybody to take over?

-- 
Regards
Hartmut Goebel

| Hartmut Goebel          | h.goebel@crazy-compilers.com               |
| www.crazy-compilers.com | compilers which you thought are impossible |

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Android build-tools / prebuild / soong
  2017-10-16 18:39 Android build-tools / prebuild / soong Hartmut Goebel
@ 2017-10-18  2:36 ` Maxim Cournoyer
  2017-10-18  8:33   ` Hartmut Goebel
  0 siblings, 1 reply; 3+ messages in thread
From: Maxim Cournoyer @ 2017-10-18  2:36 UTC (permalink / raw)
  To: Hartmut Goebel; +Cc: guix-devel

Hello Hartmut!

Hartmut Goebel <h.goebel@crazy-compilers.com> writes:

> Hi,
>
> maybe somebody want to work in this puzzle :-)
>
> Last week I played around upgrading the android libs and tools to the
> current release 8.0.0_r17, when I realized that the build-system has
> switched from a Makefile-base to one based on "Android.mk" files. These
> are meant to be processed by a tool called "soong" (with two `o`).
>
> soong is based on "ninja" an "Blueprint". There are no
> build-instructions and no usage examples. So I asked on the
> android-building mailinglist how to build and use soong stand-alone. I
> got the answer that this is not indented but to be build like this
> (fixed by my):
>
> guix environment --ad-hoc repo
> repo init -u https://android.googlesource.com/platform/manifest -b
> build-tools
> repo sync -j32
> mkdir OUT
> OUT_DIR=OUT prebuilts/build-tools/build-prebuilts.sh
>
> So the script in the last line is the key. It looks acceptable, but I
> have no clue about how go programs are build normally. So for me solving
> this puzzle is quite time-consuming and I may not be able to work on it
> for quite some time. Anybody to take over?

Interesting findings! I took a look at those Android.mk files when I
studied our package of adb (in which we are currently using our own
independent makefile instead of the Android.mk), but couldn't make sense
of them.

It seems that Soong is not meant to work with those .mk files though;
its page talks about newer JSON-like "Android.bp" files that supersede
the older make-based Android.mk files[1].

It would be nice to have an Android build system which could take those
already made makefiles and build the packages with them; it would remove
the burden of maintaining our own set and enable packaging more Android
stuff (I have fastboot on my todo).

[1]  https://android.googlesource.com/platform/build/soong/

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Android build-tools / prebuild / soong
  2017-10-18  2:36 ` Maxim Cournoyer
@ 2017-10-18  8:33   ` Hartmut Goebel
  0 siblings, 0 replies; 3+ messages in thread
From: Hartmut Goebel @ 2017-10-18  8:33 UTC (permalink / raw)
  To: Maxim Cournoyer; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 2148 bytes --]

Am 18.10.2017 um 04:36 schrieb Maxim Cournoyer:
> It seems that Soong is not meant to work with those .mk files though;
> its page talks about newer JSON-like "Android.bp" files that supersede
> the older make-based Android.mk files[1].

The documentation is terrible, it totally unclear whether .bp or .mk
files are used. Maybe .bp file are transistional files only. Who knows?

For platform/system/core [1] there is a .bp file (and a .mk file), but
for e.g. fastboot (which is part of system/core) [2] there is only a .mk
file, while for soong there is a .bp file again [3]

Interesting (just discovered):

After running "repo sync" the directory .repo/projects/build contains
blueprint.git, kati.git, make.git and soong.git. So I assume there are
the tools to start with.

  * kati – https://android.googlesource.com/platform/build/kati

    based on Makefile (two others will be ncluded), implemented in C and Go
    .travis.yml available, is building the C implementation
    build seems to require ninja (according to travis.yml), but makefile
    does not use it
    tests require ruby
    .rravix.yml seems to run more tests than test-target

  * blueprint – https://android.googlesource.com/platform/build/blueprint

    .travis.yml available
    build seems to require ninja and go (according to travis.yml)

  * make – https://android.googlesource.com/platform/build

    Seems to include a lot if Makefiles to be included by Makefiles.
    There is a README. Scanning ofer this I assume, that this is the
    "meta-make" for building the android platform (commands m, mm, mmm).

  * soong – https://android.googlesource.com/platform/build/soong/


[1]
https://android.googlesource.com/platform/system/core/+/android-cts-8.0_r2
[2]
https://android.googlesource.com/platform/system/core/+/android-cts-8.0_r2/fastboot/
[3]
https://android.googlesource.com/platform/build/soong/+/android-cts-8.0_r2


-- 
Regards
Hartmut Goebel

| Hartmut Goebel          | h.goebel@crazy-compilers.com               |
| www.crazy-compilers.com | compilers which you thought are impossible |


[-- Attachment #2: Type: text/html, Size: 3928 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-10-18  8:33 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-10-16 18:39 Android build-tools / prebuild / soong Hartmut Goebel
2017-10-18  2:36 ` Maxim Cournoyer
2017-10-18  8:33   ` Hartmut Goebel

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).