Commit Graph

24839 Commits

Author SHA1 Message Date
Colin Cross a018b3df16 Merge "Use alias for test_per_src apex dependencies" 2020-09-12 20:21:36 +00:00
Colin Cross 2c033610e2 Make generated library SDK snapshots determinstic
Sort the include dir properties before printing them out of a map.

Test: m checkbuild
Change-Id: Ia924158755983631259ef0b53c369666de4e1d23
2020-09-11 23:10:39 +00:00
Colin Cross 90dab3498d Use alias for test_per_src apex dependencies
AddFarVariationDependencies was broken, which allowed apex to add
dependencies on tests by requesting an empty test_per_src variation
even though some test dependencies did not have a test_per_src
variation.  Add an alias from the pre-test_per_src variation
variant to the empty test_per_src variation, and drop the
test_per_src variation when requesting the depencency.

Test: TestApexWithTests
Change-Id: I2ed7bdd761027956141e25d4d81f9074afe628b6
2020-09-11 16:02:24 -07:00
Treehugger Robot 05175c405b Merge "Propagate recovery_available property through to sdk snapshot" 2020-09-11 21:16:07 +00:00
Treehugger Robot 570b81ab01 Merge "Remove framework-modules naming scheme" 2020-09-11 19:58:16 +00:00
Paul Duffin d6abaa71f8 Propagate recovery_available property through to sdk snapshot
Needed for jni_headers which is marked as recovery_available because libchrome
is also marked and that library is used by others that are the recovery
partition. There may be other dependency paths that require jni_headers to be
recovery_available that was just the first one found.

Bug: 168301990
Test: m nothing
Change-Id: I916ecfe7700b9c153b29115e849da148fc7e7a76
2020-09-11 16:09:28 +01:00
Paul Duffin ee9ad5d526 Remove framework-modules naming scheme
The naming_scheme property was not removed as it may be useful for
future when migrating to java_sdk_library.

Bug: 168301990
Test: m nothing
Change-Id: Ie97dd60355a207f1312a2dd910f1fb25b46fd737
2020-09-11 16:09:15 +01:00
Jooyung Han 07931c73a3 apex: pass init_rc/vintf_fragments to make
For "non-updatable" devices, apex_manifest.pb is a module representing
the apex, so we need to pass common properties like init_rc and
vintf_fragments to the Make module of apex_manifest.pb so that those
files are copied when the apex is installed as flattened.

Bug: 159211312
Bug: 167383491
Test: lunch aosp_sunfish-userdebug
      OVERRIDE_TARGET_FLATTEN_APEX=true m com.android.vibrator.sunfish
      check $OUT/vendor/etc for init_rc/vintf_fragmemts
Change-Id: I5d5ce5acb9b837da2fb4e6ee8f3813707c6c3bd4
2020-09-11 17:33:19 +09:00
Yifan Hong c2c2d4e716 Merge "Sanitize APEX module name properly." 2020-09-11 00:25:29 +00:00
Treehugger Robot b900066dab Merge "Add support for building with R8 full mode" 2020-09-10 22:41:42 +00:00
Treehugger Robot f793d7deb4 Merge "Create os and arch variants for bootstrap Go modules" 2020-09-10 21:08:57 +00:00
Treehugger Robot b8e35ca4a4 Merge "Revert "Revert "Remove create_stubs and checkapi from droiddoc""" 2020-09-10 20:52:55 +00:00
Pirama Arumuga Nainar 0710d8e1cc Merge "Set -fsjlj-exceptions for all 32-bit Windows compiles" 2020-09-10 20:41:41 +00:00
Christoffer Quist Adamsen f2d7b16dd6 Add support for building with R8 full mode
Change-Id: Ibb6fd64e8901cb4311b29b3bbb266ec8fd1835c9
Test: make external/libtextclassifier
2020-09-10 21:24:57 +02:00
Xin Li 80dc4f137a Merge "Merge Android R" 2020-09-10 17:22:09 +00:00
Pirama Arumuga Nainar af68337d36 Set -fsjlj-exceptions for all 32-bit Windows compiles
Bug: http://b/116784799

Previously this was set only when stl was requested.  We can now pass
this for all C++ compilations.

Test: go/android-llvm-windows-testing
Change-Id: I43e635ff50d0f1a5e000f13021506aeece368b4a
2020-09-10 09:33:22 -07:00
Liz Kammer e1ab250ec8 Revert "Revert "Remove create_stubs and checkapi from droiddoc""
This reverts commit 3666c7023f.

Reason for revert: This was originally reverted because it caused a breakage (b/167405890) in a branch that is no longer relevant.

Change-Id: I81063cd47b816b5b3c0ab8427432730d6b881a3f
2020-09-10 15:29:25 +00:00
Ulyana Trafimovich 79a94a27b6 Merge "Replace `is_uses_lib` property with `provides_uses_lib`." 2020-09-10 14:34:20 +00:00
Ulya Trafimovich 54027b572e Replace `is_uses_lib` property with `provides_uses_lib`.
The previous property was boolean-valued and provided only the
information whether the library should be treated as <uses-library>
by Soong. The new property is an optional string, which is the name of
the <uses-library>. The name can be different from the module name, as
in the case of "qcrilhook" module which provides <uses-library>
"com.qualcomm.qcrilhook".

Test: lunch aosp_cf_x86_phone-userdebug && m
Bug: 132357300
Change-Id: I65b68e6f7c420ab9c443a76de4c917d31fcd8c8f
2020-09-10 10:47:41 +01:00
Kousik Kumar 3e0b9c031c Merge "Check UseRBE is set before replacing any template with the RE version." 2020-09-10 09:24:17 +00:00
Xin Li 429c23c1fa Merge Android R
Bug: 168057903
Merged-In: I9d5d0da0f409bd6b131f7e0f6363be061d3045c1
Change-Id: Ie7feaf6a3d0787c750de17540969b876a4306b0a
2020-09-09 20:21:02 -07:00
Yifan Hong f2ede7a137 Sanitize APEX module name properly.
An APEX module name, unlike the APEX package name, can contain
characters like '-', which are not allowed as C define strings.
Sanitize it properly.

Test: build GKI APEX
Change-Id: I8257d43c55862da8fab7f1e342c2d14369d1211e
2020-09-09 18:49:24 -07:00
Treehugger Robot 4f35976c87 Merge "Notice files for prebuilt_etc are included in APEX" 2020-09-10 00:06:13 +00:00
Ivan Lozano fbd7372401 Merge "rust: Fix rust_bindgen implicits" am: 74fe471e7a
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1414831

Change-Id: I9d5d0da0f409bd6b131f7e0f6363be061d3045c1
2020-09-09 22:33:23 +00:00
Ivan Lozano e9505a11dc Merge "rust: Pass lld flags from cc to rust linker args." am: 0eef27a556
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1423408

Change-Id: Ifd87a8b20d6613b5f38287dfebb9d45f353a5646
2020-09-09 22:32:03 +00:00
Ivan Lozano 74fe471e7a Merge "rust: Fix rust_bindgen implicits" 2020-09-09 22:04:38 +00:00
Ivan Lozano 0eef27a556 Merge "rust: Pass lld flags from cc to rust linker args." 2020-09-09 22:03:23 +00:00
Colin Cross 617b88a288 Create os and arch variants for bootstrap Go modules
AddFarVariationDependencies was broken, which allowed modules to add
dependencies on bootstrap Go modules using os and arch variations
even though boostrap Go modules did not have any variations.  Mutate
bootstrap Go modules in the os and arch mutators so that they have the
expected os and arch variations.

This relands Ida7bc75a51ab1d2d38a6be11f574399097380cc9 with fixes
to also mutate *bootstrap.goPackage modules so that they can find a
matching *bootstrap.goBinary module when creating their pluginFor
dependency, and to create a variation for linux_bionic when it is
enabled so that linux_bionic builds can package Go binaries.

Also requries https://github.com/google/blueprint/pull/320 to
support multiple variants of bootstrap Go modules.

Test: all soong tests
Change-Id: Ibc627aa262c298a076d171a4c21b0b9c2a7b0ada
2020-09-09 14:44:57 -07:00
Ivan Lozano 6d45a9863a rust: Pass lld flags from cc to rust linker args.
Rust is not passing the sysroot flag to Clang when invoking it as the
linker. This means files from the host may leak in, and host targets
may fail if sysroot files are not available from the host.

This patch prepends the lld flags from cc into rust linkargs. This
pulls in the sysroots flag, and also ensures that we remain in sync
with linkage flags used in cc.

The '-Wl,--no-undefined-version' from cc is overridden to avoid
missing version assignment errors for rust's generated alloc
functions.

Bug: 167690054
Test: cd external/rust; mma
Test: strace -f -e %file <host libstd.dylib.so build command> pulls
      from correct sysroots.
Change-Id: Ic40597f546f3b112012155614056afed487c6ca1
2020-09-09 14:20:00 -04:00
Ivan Lozano 4fa4c9ef84 Merge "[rust] Fix missing libclang for bindgen on darwin." am: 29139f9c02
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1421828

Change-Id: Ic3a90644291856a0b4b89f72ea8886161109ed92
2020-09-09 12:53:51 +00:00
Ivan Lozano 29139f9c02 Merge "[rust] Fix missing libclang for bindgen on darwin." 2020-09-09 12:27:34 +00:00
kellyhung af286f3312 Add test_mainline_module option. am: 74b00521f8
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1402513

Change-Id: I4824247226e786363cf94815576a93da3deb73da
2020-09-09 08:06:35 +00:00
Jiyong Park 41f637d653 Notice files for prebuilt_etc are included in APEX
This change fixes a bug that notice files for some module type (e.g.
prebuilt_etc) were not included in APEX. This happened because we relied
on WalkPayloadDeps which actually doesn't traverse module types that
don't implement ApexModule interface. prebuilt_etc is one such module
type. Fixing the problem by also iterating the filesInfo array which
has info about all modules that are included in the APEX.

Bug: 166575301
Test: m com.android.tzdata and inspect the built artifact.
NOTICE.html.gz is there.

Change-Id: Iceb055b60184aef2a3e65e44680304853eb79a53
2020-09-09 13:19:56 +09:00
kellyhung 74b00521f8 Add test_mainline_module option.
Bug: 165425972

Test: m HelloWorldTests
Change-Id: I6e60b3895328c4f7aef0bfb30dcdefc30ee1d8ed
2020-09-09 02:15:39 +00:00
Treehugger Robot 9ef1f7d96a Merge "Don't assume host arch is always x86" am: daf735287b
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1415953

Change-Id: I049556891890833c1e7db6483e5ee6446714583e
2020-09-09 00:32:18 +00:00
Treehugger Robot daf735287b Merge "Don't assume host arch is always x86" 2020-09-09 00:13:50 +00:00
Treehugger Robot 9e1ba22f14 Merge "Add vendor snapshot usage test" am: f8123919aa
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1420809

Change-Id: I9b22b04a02f6b0e0fd6e76bd58a9e520e9c4d064
2020-09-09 00:05:23 +00:00
Treehugger Robot f8123919aa Merge "Add vendor snapshot usage test" 2020-09-08 23:48:06 +00:00
Ivan Lozano 54a8ee12fe [rust] Fix missing libclang for bindgen on darwin.
The LIBCLANG_PATH provided to bindgen should point to the directory
containing libclang, not the file itself.

Bug: 167977778
Test: m profcollectd
Change-Id: Iabd9970a763c192249b401a618a2d6990b02eab0
2020-09-08 13:13:07 -04:00
Ulyana Trafimovich 0f13eff149 Merge "Be more strict about unknown install <uses-library> paths." am: 117a5ef307
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1418529

Change-Id: Ib28e902e7f8ec57a15ef50692024cd37a96696bc
2020-09-08 15:34:50 +00:00
Ulyana Trafimovich 117a5ef307 Merge "Be more strict about unknown install <uses-library> paths." 2020-09-08 15:21:30 +00:00
Jiyong Park 87788b5247 Don't assume host arch is always x86
This change fixes some places where host arch is assumed to be x86 to
form a path element like linux-x86. In preparation for non-x86 host
targets, the host arch part is derived from the context.

In addition, InstallForceOS() is refactored so that it can override not
only OsType, but also ArchType. Without this, the paths for the
robolectic modules will be changed from linux-x86 to linux-common, which
breaks several other places where the old paths are expected.

Bug: 134795810
Test: m
Change-Id: Ib38c715948ae546e55021ece82bac1d82e9e5da0
2020-09-08 15:12:10 +09:00
Paul Duffin 4d38789695 Merge "Propagate vendor_available property through to sdk snapshot" am: 4964a5e000
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1398472

Change-Id: I913a8e3cfd7eebb0a53ecd591b1bf12f69fa00b2
2020-09-07 15:20:07 +00:00
Paul Duffin 4964a5e000 Merge "Propagate vendor_available property through to sdk snapshot" 2020-09-07 14:58:20 +00:00
Ulya Trafimovich 045e11ad0d Be more strict about unknown install <uses-library> paths.
Allow default install paths only for compatibility libraries. For other
libraries that are explicitly specified in `uses_libs` and
`optional_uses_libs` unknown install path should be an error.

Bug: 132357300
Test: lunch cf_x86_phone-userdebug && m
Change-Id: I2209c90a939a8aa46c42e13bb42d09c07e4d0895
2020-09-07 13:58:51 +01:00
Inseob Kim 5f58ff7839 Add vendor snapshot usage test
In addition to capture test, this adds vendor snapshot usage test to
ensure the snapshots of BOARD_VNDK_VERSION are used correctly.

Bug: 167642944
Test: m nothing
Change-Id: I200c95626479a2b2d982edd7488d816e01376734
2020-09-07 19:56:43 +09:00
Ulyana Trafimovich 99bd329274 Merge "Allow non-SDK Java libraries to masquerade as <uses-library>." am: bb3467d297
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1417188

Change-Id: If25aaa0174091e966cc5c6b16063b6486a7b4ab6
2020-09-07 10:23:53 +00:00
Ulyana Trafimovich bb3467d297 Merge "Allow non-SDK Java libraries to masquerade as <uses-library>." 2020-09-07 09:49:07 +00:00
Mark Chien 288f40ba51 Merge "Include bpf program in APEXes" am: 66a0ae60f8
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1418308

Change-Id: I86983c1012615e95d1d9aac875a52e92248a17b8
2020-09-04 09:11:22 +00:00
Mark Chien 66a0ae60f8 Merge "Include bpf program in APEXes" 2020-09-04 08:58:21 +00:00