Commit graph

48847 commits

Author SHA1 Message Date
Anton Hansson
08231e1786 Refactor generate_enforce_rro
A few tweaks to make it easier to extend to generating RROs in
multiple partitions:
- deduce the module name inside generate_enforce_rro
- dedup rule definition
- tweak framework-res check to use source module name instead

Bug: 127758779
Test: verify noop on presubmit targets
Change-Id: I2f0d6270b21f5427c372c04a5c6e7fb712e72a9a
2019-03-18 14:21:09 +00:00
Anton Hansson
b7ee86ff85 Refactor and further simplify the RRO logic
Make the runtime vs static resource overlays a little clearer.
This will help adding more logic around determining if an RRO
needs to be generated in /vendor, /product or both.

Bug: 127758779
Test: verify noop on presubmit targets
Change-Id: I43111a1d9bb3405c559faaef56a75a5ad7672ba0
2019-03-16 15:52:30 +00:00
Anton Hansson
fd06b02b30 Add comments and slight refactor auto-RRO logic
Make it a bit clearer what this code is intended to do.

Bug: 127758779
Test: verify noop on presubmit targets
Change-Id: Ic405fc5d4601b9f0a91b4d24caa06f279267c51a
2019-03-15 17:03:53 +00:00
Remi NGUYEN VAN
c6bf520424 Merge "Move NetworkStack in-process from lib to APK" 2019-03-12 01:37:26 +00:00
Treehugger Robot
8924400a8a Merge "Revert "Build System: Solve dependency problem for test"" 2019-03-11 20:45:17 +00:00
Treehugger Robot
b6f2f8b2d9 Merge "releasetools: Add compatibility for custom out directory." 2019-03-11 19:51:14 +00:00
Nelson Li
6fe7f194b9 Revert "Build System: Solve dependency problem for test"
This reverts commit 224e103308.

Reason for revert: Build Breakage in git_pi-dev-plus-aosp/docs @5366136
make -j110 docs showcommands dist DIST_DIR=/buildbot/dist_dirs/git_pi-dev-plus-aosp-linux-docs/5366136 checkbuild
FAILED:
 Dependencies in out found with no rule to create them:
 out/target/product/generic/data/app/CtsVerifierTester/CtsVerifierTester.apk
 out/target/product/generic/data/app/TradeFedTestApp/TradeFedTestApp.apk
 out/target/product/generic/data/app/TradeFedUiTestApp/TradeFedUiTestApp.apk
 15:53:46 stopping
and
make -j50 showcommands dist TARGET_PRODUCT=cf_x86_phone DIST_DIR=/buildbot/dist_dirs/git_master-linux-ndk_translation_all/5366149 ndk_translation_all
FAILED: ninja: 'out/target/product/vsoc_x86/data/nativetest/arm/arm_insn_tests_arm_static/arm_insn_tests_arm_static', needed by 'out/target/product/vsoc_x86/obj/PACKAGING/ndk_translation_tests_intermediates/arm_insn_tests_arm_static_result.xml', missing and no known rule to make it
15:55:38 ninja failed with: exit status 1
make: *** [run_soong_ui] Error 1
Return Code: 2

Change-Id: Idf95ef2e06526a0a31690420c923207db627605f
2019-03-11 16:48:29 +00:00
Pavel Salomatov
3267655004 releasetools: Add compatibility for custom out directory.
sign_target_files_apks script looks for the signapk.jar inside the out dir.
If the our dir is set to a different directory via OUT_DIR_COMMON_BASE the script does not work properly.

From now script checks if the OUT_DIR_COMMON_BASE is set, then searches the jar in the proper path.
If OUT_DIR_COMMON_BASE is unset, searches in "out" like it did before.

Test: Build with OUT_DIR_COMMON_BASE set and unset and verify that sign_target_files_apks works in both cases

Change-Id: I9218b98ff79526184f8353705640193405afac9e
2019-03-11 19:22:29 +03:00
Treehugger Robot
bc1e820f25 Merge "Fix some system property missing problem on aosp_* targets" 2019-03-11 16:10:22 +00:00
Treehugger Robot
15e76e3848 Merge "Build System: Solve dependency problem for test" 2019-03-11 15:18:12 +00:00
Treehugger Robot
b82b26456b Merge "Add a flag to select the apex boot image for preopt." 2019-03-08 17:33:51 +00:00
Nicolas Geoffray
19abe716f8 Add a flag to select the apex boot image for preopt.
Test: m && check that odex files are preopted with the apex image
Bug: 119800099
Change-Id: I5b64261cd765b511ad7e1ff513b85c0579023f6e
2019-03-08 14:41:14 +00:00
SzuWei Lin
ace19f63fe Fix some system property missing problem on aosp_* targets
Some PRODUCT_PROPERTY_OVERRIDES has no effect, ex.
ro.dalvik.vm.native.bridge=0 in runtime_libart.mk,
because gsi_common.mk uses ':=', not '+='.

Bug: 125829345
Test: build aosp_arm64-userdebug
Test: check the properties in /vendor/build.prop
Change-Id: Ib5e026069e7919fed8a00f905f3dbaa15042107f
2019-03-08 18:16:54 +08:00
Remi NGUYEN VAN
e6fcb468d8 Move NetworkStack in-process from lib to APK
This makes the in-process configuration closer to the "standard" module
configuration, by using an APK in both cases, but making sure that
svelte builds use an in-process service to avoid the memory impact.

Bug: 127908503
Test: svelte build boots and has functional WiFi
Change-Id: I59f44df7c23a24429e9fe6be034260373e33a994
2019-03-08 17:42:59 +09:00
Treehugger Robot
04f2896c88 Merge "Fix m snod" 2019-03-08 07:59:33 +00:00
Dan Willemsen
c478ea3dac Fix m snod
Whenever we're not loading all makefiles, we shouldn't be checking that
all the host packages exist.

Test: m snod
Change-Id: If1f817d855cbe329b83caee9fdd68c2cce55f02b
2019-03-07 17:18:15 -08:00
Dan Willemsen
066da0c58b Merge changes from topic "HOST_PACKAGES"
* changes:
  Build everything in PRODUCT_HOST_PACKAGES
  Reland "First pass at creating PRODUCT_HOST_PACKAGES"
2019-03-08 00:21:01 +00:00
Tri Vo
9f18c64d07 Merge "recovery: install product_file_contexts and product_property_contexts" 2019-03-07 18:32:48 +00:00
Tao Bao
28a11ef040 Merge "releasetools: Include retrofit info into package metadata." 2019-03-07 18:11:30 +00:00
nelsonli
224e103308 Build System: Solve dependency problem for test
1. A test can add a runtime dependent test module by just setting
   LOCAL_REQUIRED_MODULES or LOCAL_TARGET_REQUIRED_MODULES. Then the dependent test
   module will be copied to testcase folder.
2. Do not install to $(TARGET_OUT_DATA) for testcase

BUG: 117224272

Test: 1. (a) vi cts/tests/tests/text/Android.mk
         (b) add LOCAL_REQUIRED_MODULES := CtsPrintTestCases
         (c) m -j CtsTextTestCases
         (d) Then, CtsPrintTestCases should also be built to testcase folder like below.
             ./target/product/generic_arm64/testcases/CtsPrintTestCases

Change-Id: I24ea3783486c54a05cfa9d3d0375b977afc230f8
2019-03-07 14:08:35 +08:00
Treehugger Robot
fa2e796ce2 Merge "Remove logical partitions from ab_partitions.txt in retrofit package." 2019-03-07 01:06:42 +00:00
Tao Bao
393eeb4918 releasetools: Include retrofit info into package metadata.
Fixes: 126754990
Test: Generate retrofit and non-retrofit OTAs. Check the package
      metadata entry.
Test: python -m unittest test_ota_from_target_files
Change-Id: I076a013a6224a2ffea8e0b8581890b66f847f165
2019-03-06 16:19:11 -08:00
Dan Willemsen
b952b5e4c3 Build everything in PRODUCT_HOST_PACKAGES
This should only add extra host packages that were in
PRODUCT_HOST_PACKAGES and not PRODUCT_PACKAGES.

That shouldn't be very many things -- user builds will build a few more
host tools that used to be in PRODUCT_PACKAGES_DEBUG, etc.

Test: treehugger
Change-Id: I6768b76db74ea049de90eef326d1e314eb4ef848
Merged-In: I6768b76db74ea049de90eef326d1e314eb4ef848
2019-03-06 15:41:19 -08:00
Dan Willemsen
3d05a08a6f Reland "First pass at creating PRODUCT_HOST_PACKAGES"
Adds icu-data_host_runtime_apex to fix unbundled builds which pull it in
via PRODUCT_PACKAGES, but are missing packages that would pull it in via
PRODUCT_HOST_PACKAGES.

Test: build/soong/build_test.bash
Test: in ub-timezonedata-master; tapas TimeZoneData; m
Change-Id: I1583c7582b386c3e8478711cb1df340518d763c1
Merged-In: I1583c7582b386c3e8478711cb1df340518d763c1
2019-03-06 14:46:06 -08:00
Yifan Hong
b433eba6a6 Remove logical partitions from ab_partitions.txt in retrofit package.
For retrofit updates:
ab_partitions -= dynamic_partition_list
ab_partitions += super_block_devices

For example,
if super_block_devices == ["system", "vendor", "odm"] and
   dynamic_partition_list == ["system", "vendor", "product"],
product partition needs to be removed from ab_partitions.txt
otherwise brillo_update_payload will generate a payload with
product partition in it.

Test: retrofit update that adds a partition
Fixes: 127425410

Change-Id: Id79a410cee3c611ac50d27f14282916aea34f938
2019-03-06 13:35:20 -08:00
Colin Cross
e34ff5ca5d Merge "Update manifest merger to use binary" 2019-03-04 22:02:09 +00:00
Nicolas Geoffray
53cfd9275b Merge "Pass the --api-flags to appcompat explicitly." 2019-03-04 14:14:39 +00:00
Julien Desprez
20a50f75a3 Merge "Add a placeholder EXTRA_OPTIONS to inject more tradefed options" 2019-03-02 00:44:54 +00:00
Treehugger Robot
9da3b4c6f3 Merge "Clean up libjdwp.so and possibly other dependencies that might have crept in between http://r.android.com/890494 and http://r.android.com/913898." 2019-03-01 22:59:08 +00:00
Martin Stjernholm
6fd16926b1 Clean up libjdwp.so and possibly other dependencies that might have crept in
between http://r.android.com/890494 and http://r.android.com/913898.

(Repopulating libs from intermediates is quick, so not wasting effort trying
to be precise.)

Test: Don't have a suitably old build tree to test with.
Bug: 124498388
Change-Id: Ice35606e4c301d5b01837963137421f9d23a9733
2019-03-01 20:41:52 +00:00
Julien Desprez
4e9a9485f4 Add a placeholder EXTRA_OPTIONS to inject more tradefed options
Simply remove the placeholder in makefiles, for now I am
not sure we need to support this in makefiles at all.

Test: call the sed method
Bug: 124024827
Change-Id: Iae78ae86c20c5da6b7314b749f54983a312c4a7d
2019-03-01 11:36:36 -08:00
Yifan Hong
5a4696e460 Merge "Build ODM manifests and fragments for each SKU." 2019-03-01 18:32:32 +00:00
Anton Hansson
e0ce6ca8a5 Merge "Move BoardConfig strip / READONLY marking" 2019-03-01 15:34:36 +00:00
Anton Hansson
451951c139 Merge "Move combo makefile parsing" 2019-03-01 15:34:19 +00:00
Colin Cross
5852c93585 Merge "Use flags from Soong for d8 and r8" 2019-03-01 15:28:29 +00:00
Anton Hansson
d488d2d7d7 Move BoardConfig strip / READONLY marking
This moves the BoardConfig READONLY marking being product.mk's
responsibility to board_config.mk.

Also unify it with the BUILD_BROKEN_* setting handling, and
READONLY a few additional variables.

Test: build_test
Change-Id: Ifcfef588aa459223d6d7f017413d1681f341297f
2019-03-01 10:04:18 +00:00
Anton Hansson
192798513e Move combo makefile parsing
These files may be setting variables usually defined in the
BoardConfig. This moves that setting into board_config.mk so
that the relevant variables can be made readonly.

Test: build_test
Test: diff presubmit target_files vs base cl
Change-Id: I4dab09fa67c0f2e88a8ce1402a35b4ef5f8a0560
2019-03-01 09:54:33 +00:00
Treehugger Robot
1b9a0c8f7d Merge "Remove libnpt from system again." 2019-03-01 02:23:50 +00:00
Nicolas Geoffray
ac1f90c39c Pass the --api-flags to appcompat explicitly.
Bug: 125794065
Test: m && appcompat logs contain data
Change-Id: Idef875138d6670efc9ed7b9c63f653229b173d3e
2019-02-28 13:51:14 +00:00
Anton Hansson
c651ef8529 Merge "Make it an error to specify the wrong ARCH_VARIANT" 2019-02-28 10:29:05 +00:00
Anton Hansson
67d3081d3f Merge "Move WITH_DEXPREOPT default value" 2019-02-28 10:26:31 +00:00
Anton Hansson
2507ce486d Merge "Modify INTERNAL_KERNEL_CMDLINE instead of BOARD_ variant" 2019-02-28 10:26:18 +00:00
Anton Hansson
d265f52005 Merge "Consolidate some BoardConfig variable checks" 2019-02-28 09:21:41 +00:00
Martin Stjernholm
616dc79043 Remove libnpt from system again.
http://r.android.com/914573 fixes libjdwp to look for it in the APEX.

Test: Flash and boot
Test: adb forward tcp:5555 jdwp:`adb shell pidof com.android.email` && jdb -attach localhost:5555
Test: atest CtsJdwpTestCases
Bug: 124498388
Change-Id: Idf380660a21c88969e42d6a03a6b50fd2baa4c17
2019-02-27 20:51:56 +00:00
Anton Hansson
be1f9cb2fa Make it an error to specify the wrong ARCH_VARIANT
It was previously a warning to set an incorrect ARCH_VARIANT
when CPU_VARIANT was set to a cpu for which we knew the arch.

Make it an error, as there are no offenders in the tree.

Re-structure the code to make it a little clearer when you get
a default and when you get an error.

Test: build_test
Change-Id: I5821a8162a59e8c2aed2370068f9eb656ced9d99
2019-02-27 17:27:16 +00:00
Anton Hansson
74dc00b88f Move WITH_DEXPREOPT default value
This allows setting the variable READONLY after reading the BoardConfig.

This is safe to do because this flag is only set in BoardConfig.mk
files. The same is not true for many of the other default preopt flags,
like DEX_PREOPT_DEFAULT or WITH_DEXPREOPT_BOOT_IMG_AND_SYSTEM_SERVER_ONLY
which are set in mixture of product / board config files.

Test: boot blueline
Change-Id: I961ba581f9790bcdc7cf6b36d8b53bcdb8861a92
2019-02-27 15:03:23 +00:00
Anton Hansson
72e36f0278 Modify INTERNAL_KERNEL_CMDLINE instead of BOARD_ variant
The current modification of the variable within the build system
prohibits making the variable readonly.

Test: build_test
Test: boot blueline
Change-Id: Iec6058a163b5951db389d4adc0d9d0397431efb1
2019-02-27 14:29:01 +00:00
Anton Hansson
b9544694a5 Consolidate some BoardConfig variable checks
Move a few more variable stripping/sanity checking from
config.mk to board_config.mk

Test: build_test
Change-Id: I93fde7293de38398039dbb679b2399c8a68c190d
2019-02-27 14:07:43 +00:00
Anton Hansson
45747a037a Merge "Split out board_config.mk" 2019-02-27 13:21:17 +00:00
Colin Cross
7293c1e4b9 Update manifest merger to use binary
Manifest merger is now a java_binary instead of a collection of jars,
it can use the single binary as the dependency.

Bug: 112607039
Test: m checkbuild
Change-Id: Id97b01542314cb165ebf7c90409a09482d8c53bc
2019-02-27 06:18:35 +00:00