Commit graph

32 commits

Author SHA1 Message Date
Dan Willemsen
f2649570c5 Pass userdebug/eng variant to Soong
Test: Run build with eng/userdebug/user and check the soong.variables
Change-Id: I7cd71a94e92526b6cc61303b13b7bc593cbbfc3a
2016-09-22 15:22:48 -07:00
Colin Cross
70e0ac6bc1 Remove HOST_PREFER_32_BIT
HOST_PREFER_32_BIT was used during the switch to 64-bit host tools to
keep the SDK building as 32-bit, but is never set any more.

Change-Id: I874f89c7d1e9cd8c9d4c879048d81a4362ce4dce
2016-09-02 13:20:52 -07:00
Colin Cross
5a5befb7c0 Enable goma in soong
Pass the USE_GOMA flag to soong, and export the CC_WRAPPER environment
variable after adding gomacc to it.

Bug: 31142427
Change-Id: I6de698a40817c0615b03fa17bd27075465d79ffd
2016-08-31 09:48:21 -07:00
Dan Willemsen
0533e4df40 Simplify Soong bootstrapping
Now we only run the "main" stage from Soong once, and only when combined
with the Kati ninja file. So we can now depend on pools or rules defined
by Kati in Soong.

Change-Id: I7a8fd699ddc0d41bbcbbf3c6f2edb9e26ccfc4c9
2016-08-31 00:58:12 -07:00
Colin Cross
76c4533899 Export TARGET_PREFER_32_BIT_EXECUTABLES to soong
Change-Id: I1427d88c7539c5ed0c4c238bad4a28f73d29ef0f
2016-08-25 14:49:17 -07:00
Colin Cross
0d86fc57cd Merge "Fix discrepancy in SANITIZE_TARGET format with soong." 2016-08-11 23:53:29 +00:00
Dan Willemsen
369b7df35c Pass binder ABI to Soong
Change-Id: I7a7f197a114c39ab3a4233d430d9c677f581b1f9
2016-07-26 15:55:16 -07:00
Dan Willemsen
913892fada Pass ENABLE_CPUSETS and ENABLE_SCHEDBOOST to Soong
Change-Id: I75c0d60854f2ea3d2e4e4d6dcbc6845e3b0336ad
2016-07-12 15:00:46 -07:00
Tim Becker
f7bc2e8f22 Fix discrepancy in SANITIZE_TARGET format with soong.
core/soong.mk expected SANITIZE_TARGET to be comma separated,
while the rest of the build files expected it to be space
separated.

Change-Id: I179054118ed5c422f9ae2d69afb2f4ad3a71cb7b
2016-07-06 16:32:01 -07:00
Dan Willemsen
60d9c673d7 Add Soong tools to PATH
Change-Id: I8f8649106df4ba7cefbfa37a724ebe0635d90b76
2016-05-31 18:32:35 -07:00
Colin Cross
a61d672529 Remove USE_SOONG=false option
Soong is always required to build now.

Change-Id: I4e310e98e912b370ebf980bf609f04212a7e9a50
2016-05-25 12:55:43 -07:00
Dan Willemsen
cba1557476 Pass BUILD_HOST_static to Soong
Change-Id: I0ac43a1dedf20e5251e05f12d120d0e6e2e1b1ee
2016-05-17 16:40:03 -07:00
Evgenii Stepanov
7f13ab998a Pass USE_SAFESTACK to Soong.
Change-Id: I51a94da0942aa1a1e003c134a30e8da82e1270b8
2016-05-13 14:40:58 -07:00
Dan Willemsen
8b999ac63d Read Soong-exported configuration
This is to ensure that Make and Soong agree on configuration variables
like TARGET_GLOBAL_CFLAGS. Only a few variables are actually checked
currently until we make more actually the same.

Bug: 23566674
Change-Id: Ibede43d933ede4d470e182f9490ea6ec4ef52fbc
2016-05-12 13:36:33 -07:00
Dan Willemsen
57aa920ddb Use product-specific Soong outputs
This way, when switching between two products, we don't need to re-run
kati.

Change-Id: I0a8b3b49f1b76d9e120ea93bb5d2aa06cd189679
2016-05-11 00:40:43 -07:00
Dan Willemsen
9a97ba700b Only pass NINJA_ARGS to the main ninja compile
This way commands like "-t query <target>" will work against the main
build, instead of failing to find the target during the initial soong
build and stopping.

Change-Id: I9b6bd6ac431b95e12db69ec7f272669b9d292761
2016-05-05 16:55:21 -07:00
Colin Cross
c9778e339d Merge "Pass SANTIIZE_HOST and SANITIZE_TARGET to soong" 2016-05-04 23:34:54 +00:00
Colin Cross
367ab2989a Update path to reverse_path.py
Change-Id: I98902e94a99fae7f9e738a872a83acb98d32c781
2016-05-02 15:31:17 -07:00
Colin Cross
4e2c57ab0a Pass SANTIIZE_HOST and SANITIZE_TARGET to soong
Change-Id: I80e2e386db3367383454adb1b0785b10e13a4c58
2016-04-07 13:33:06 -07:00
Dan Willemsen
cc60f01357 Handle symlinked OUT_DIRs (again)
My previous attempt at properly handling symlinked OUT_DIRs only worked
if the symlink was to a different directory, not one in the same
directory.

This time, make sure that both make and soong use the same
representation of the output directory by passing BUILDDIR to
bootstrap.bash. Soong has been updated to pick whether to use a relative
or absolute path back to the source tree depending on what makes sense.
If the BUILDDIR or the path back to the source tree change, re-run the
bootstrap.

Also, move the $OUT_DIR/Android.mk and $OUT_DIR/CleanSpec.mk generation
to before Kati runs. In the case that $TOP/out was symlinked to
$TOP/out.angler:

 1) Soong generates out.angler/soong/Android.mk
 2) Kati's find generator produces in-memory tree of the filesystem
 3) $(shell ) creates out.angler/Android.mk
 4) The emulated findleaves Android.mk search finds
    out.angler/soong/Android.mk since the in-memory tree is never updated.

This doesn't happen in the normal case, because we pass --prune=$OUT_DIR
to findleaves.

Change-Id: Ib0fdae2e80f75ddcf33a3c8c5ea0978f5308b437
2016-03-22 20:02:18 -07:00
Dan Willemsen
a800b9a83a Merge "Always run Soong" 2016-03-21 21:09:40 +00:00
Dan Willemsen
721f9bd316 Add SOONG_ALLOW_MISSING_DEPENDENCIES
Split out Soong's missing dependency option from Unbundled_build. There
are builds other than unbundled builds that don't have a full platform
tree (AOSP llvm branch is one example).

When this is set to true, Soong will defer the error for missing
dependencies until a module is attempted to be built, instead of when
it is reading and generating the build rules. So for platform builds it
will still fail early if something is missing.

Change-Id: I56cb881ff55f5928b77cddc0d67086c3d37e43d7
2016-03-16 12:41:20 -07:00
Dan Willemsen
2d12ce1d88 Always run Soong
Without switching on USE_SOONG, this lets us verify that all builds have
blueprint/soong/go, and can generate a build.ninja file without
producing errors.

Change-Id: I79451ce24c8b5b6745e41d951153265441c33e8a
2016-03-15 00:36:07 +00:00
Dan Willemsen
d53c0c7b45 Handle out being a symlink
Soong needs to be able to reverse the relative path to out. Switch to
absolute paths if .. won't work because of out being a symlink to
somewhere else.

Bug: 27612837
Change-Id: Ib8b9e0f80523148cfd4b69a03d164578916d8fd5
2016-03-11 16:29:23 -08:00
Dan Willemsen
1487f31d83 Use hermetic ckati/makeparallel prebuilts
Currently, we're building against the native host version of libc++ and
other headers. Instead, use prebuilts of ckati/makeparallel built with
Soong against the included libc++ and sysroot. Building ckati /
makeparallel doesn't work well in unbundled branches that don't have all
of the libc++ dependencies to do successful host builds.

KATI is default variable defined when running under Kati, don't use it
for other purposes. Use CKATI instead.

Bug: 27533820
Change-Id: I82d66f5e34e3341a3cee4c5c83cd1d9a54d057ff
2016-03-09 17:19:30 -08:00
Dan Willemsen
60899eddd7 Tell soong about MALLOC_SVELTE
Change-Id: I50ce6c0767db8963a7a633bdb349db1c96427cd8
2016-03-01 21:00:26 -08:00
Dan Willemsen
d6e3b84185 Tell Soong about HOST_CROSS_*
This configures Soong to build windows binaries, which requires support
for 64-bit windows binaries in BUILD_PREBUILT for USE_SOONG=true.

module_arch_supported.mk did not support 64-bit being the secondary
architecture when evaluating multilib conditionals. All other uses of
HOST_*_IS_64_BIT already check the proper version.

Change-Id: Iff664733e6991f4adbe8ddd620b091bbb55d1d86
2016-02-09 16:00:14 -08:00
Dan Willemsen
3f60c4b6c0 Allow building kati & makeparallel with soong
This uses far fewer hacks in order to build these host tools, but will
require more libraries(libc++,etc) from unbundled and stripped down
branches.

Once this becomes the only option, all builds will happen after soong
runs. Then the toolchain / global cflags information will be able to be
moved from make to soong (and exported back to make).

Change-Id: I270b1d92bcef28a96fbc3ec9910d9bd0c101ac0f
2016-01-13 13:08:29 -08:00
Josh Gao
b1171e4a31 Kill BOARD_MALLOC_ALIGNMENT.
Bug: http://b/26403338
Change-Id: I55d2c417d972f78caddc5fb28a065807feb86b0a
2016-01-06 14:15:46 -08:00
Josh Gao
a4f00d74fc Replace MALLOC_IMPL with MALLOC_SVELTE.
Bug: http://b/26390299
Change-Id: Ib1bef4aa272033412bea57a9bccf1d67793d2bda
2016-01-05 13:08:45 -08:00
Dan Willemsen
5f38f9be22 Tell soong that it is embedded in a make build
So that it can munge its ninja targets to not conflict with make.

Change-Id: I0c2273c0ca2fdfced1fa1590f2ea3eac8cddb905
2015-12-16 01:47:02 +00:00
Colin Cross
3ebb2f7326 Combine soong builds into make builds
Bootstrap soong if necessary, and wrap the kati and soong ninja files
into a single ninja file.

Change-Id: I0000c7eaa1adda763189681c57ec27a97a12ee1f
2015-12-15 16:05:57 -08:00