Commit graph

72556 commits

Author SHA1 Message Date
Colin Cross
a69b809425 Don't create compatibility suite copy rules for installed path
Don't create compatibility suite copy rules for $(LOCAL_BUILT_MODULE)
to $(LOCAL_INSTALLED_MODULE), as that could conflict with a Soong
install rule.  Instead, always create the install rule the normal way,
and replace the compatibility suite copy rule with a noop if it is the
same as the normal rule.

Bug: 204136549
Test: m checkbuild
Change-Id: Ic8ac80eda8554fae2b7ecc2516165da020bdaebe
2021-11-08 15:23:32 -08:00
Colin Cross
cf5c18aa8e Clean SOONG_HOST_OUT for moving rust and sh_binary modules
Bug: 204136549
Bug: 205530905
Test: m checkbuild
Test: m && acloud create --local-instance --local-image
Change-Id: I51c2b94bccff3893b9b7c88f08a798a5daccb0f5
2021-11-08 13:31:28 -08:00
Cole Faust
2f1bd70c9c Merge "Make starlark board configuration work with sdk_phone_x86_64" 2021-11-05 18:42:12 +00:00
Cole Faust
fdb8f17a83 Merge "Prepare release tools for python 3" 2021-11-05 17:33:04 +00:00
Colin Cross
11b78c16ad Merge "Move tools compiled by Soong to HOST_OUT_EXECUTABLES" 2021-11-05 17:14:59 +00:00
Cole Faust
b820bcd829 Prepare release tools for python 3
- Sort dictionaries before looping over them
- Don't call sorted() on lists with Nones
- Open file in binary format when serializing protobufs

Change-Id: If5dbc908f7125f6184014b3c1c7891f833d1d8bf
Bug: 203436762
Test: Presubmits
2021-11-04 17:58:44 -07:00
Cole Faust
985fa48a98 Make starlark board configuration work with sdk_phone_x86_64
The main issue with board configuration up till this
cl was that it didn't have access to the product configuration
variables. Pass those in by dumping the make variables to a
temporary file, which is then converted to RBC, loaded,
and passed to the starlark board config..

Bug: 201700692
Test: build/bazel/ci/rbc_product_config.sh -pb sdk_phone_x86_64-userdebug
Change-Id: I9a4946b970ca43c5b5f53a6c507ad2c1a2eca61e
2021-11-04 16:13:24 -07:00
Steven Moreland
ec71cbf0c8 Merge "vintf recovery install parity w/ init_rc" 2021-11-04 22:28:51 +00:00
Treehugger Robot
936e704999 Merge "Fix a failure in signing test" 2021-11-04 07:04:42 +00:00
Kelvin Zhang
2639048c21 Fix a failure in signing test
Pixel moved away from sparse images, so validate_target_files is failing
because it expects sparse images.

Test: th
Change-Id: I322ff10c2afbacfb4d78991be60c11aac92a6d4c
2021-11-03 21:43:22 -07:00
Treehugger Robot
1e392720c2 Merge "Add a compressor types option" 2021-11-04 04:13:13 +00:00
Treehugger Robot
cd128891ed Merge changes from topic "tproto"
* changes:
  Convert .meta_lic files to textproto
  Add macros for non-module license metadata and deps
2021-11-03 18:31:02 +00:00
Kelvin Zhang
9b6d4ec01b Add a compressor types option
Test: th
Change-Id: I1ff1bccf179bfd87ce9e08def0e5e38921d7d158
2021-11-03 11:17:04 -07:00
Bill Yi
fcdbafa7fe Merge "Merge SP1A.211105.004 to aosp-master - DO NOT MERGE" 2021-11-03 17:50:39 +00:00
Colin Cross
1ee26cae73 Convert .meta_lic files to textproto
Make it easier to write tools against .meta_lic files and store complex
data by writing them in textproto.

Test: builds
Change-Id: Ibbb6cfbb1bdddd3d938a86d563673a049d826d66
2021-11-03 15:44:00 +00:00
Bill Yi
468572bad8 Merge SP1A.211105.004 to aosp-master - DO NOT MERGE
Merged-In: I68a7e42b3bd2b27e0c9ff8480f71af7aaf9dcb46
Merged-In: Ia18162968822dfbee5299c2692aef1e3c75ba843
Change-Id: I2b422d3dffe04be00304663294b48052a9a29aca
2021-11-03 12:17:35 +00:00
Bob Badour
879cfa867d Add macros for non-module license metadata and deps
Gets rid of .meta_module files and instead defers emitting rules until
after all the non-module targets have been processed. Allows direct
dependency on .meta_lic files, which in turn depend on license text
files.

Bug: 68860345
Bug: 151177513
Bug: 151953481

Test: m all
Test: m systemlicense
Test: m reportmissinglicenses

Change-Id: I2c467feac6e13a9366ff66f924889f1dbd48c3f1
2021-11-03 00:52:25 +00:00
Treehugger Robot
dcb0e44c46 Merge "Add share_libs and system_share_libs to module-info" 2021-11-02 01:52:17 +00:00
Steven Moreland
b186183ae2 vintf recovery install parity w/ init_rc
There was a relatively recent change (id
I82d0f40d6d7047e271612204391c5a027f84f52f) which avoided installing
init_rc scripts to system when a module was installed to system. This
same bug also existed in VINTF installs.

Future consideration: macrotize behavior (delaying since there are some
subtle differences in paths/variables and given bazel efforts).

Fixes: 204270700
Test: boot
Test: 'mmma hardware/interfaces/health/aidl/default' installs vintf
fragments to '/system/etc/vintf/manifest' before this change but not
after.

Change-Id: Icf505af74c95386a0ed8cb4468dcf7c1122db847
2021-11-01 17:58:28 -07:00
Colin Cross
bca6483b07 Move tools compiled by Soong to HOST_OUT_EXECUTABLES
Soong now installs native tools to HOST_OUT_EXECUTABLES instead
of SOONG_HOST_OUT_EXECUTABLES.

Also add a cleanspec for SOONG_HOST_OUT to remove old files from
SOONG_HOST_OUT_EXECUTABLES.

Bug: 204136549
Test: m checkbuild
Change-Id: Id18213b9294b6d2cf78f657740c6d5a02733b8ad
2021-11-01 15:03:01 -07:00
Colin Cross
3a79e5b459 Merge "Support generating install rules in Soong" 2021-11-01 21:31:56 +00:00
Ulyana Trafimovich
75342c1932 Merge "Deprecate system server jars defined in Android.mk." 2021-11-01 10:01:10 +00:00
yangbill
5f5e2362fa Add share_libs and system_share_libs to module-info
Bug: 202922558
Bug: 204269866
Test: m out/target/product/vsoc_x86_64/module-info.json

Change-Id: Idb4e66216cac4835968454f83196107f6bec4c1c
2021-11-01 06:38:43 +00:00
Treehugger Robot
76a4c62f56 Merge "Support custom APEX signing tool" 2021-10-29 23:39:26 +00:00
Colin Cross
23ee375a4a Support generating install rules in Soong
Support moving some install rules into Soong by allowing Soong to
provide a Makefile containing install rules, and by skipping parts
of base_rules.mk when Soong already created an install rule.

The install rules are exported as a Makefile instead of directly
in Soong's build.ninja file so that base_rules.mk can add dependencies
from the `required` property that are hard to resolve in Soong.

Bug: 204136549
Test: m checkbuild
Change-Id: Ife2964d76469b385e90c0c5f6adf21bd2b5e8bf6
2021-10-29 15:43:39 -07:00
Jiakai Zhang
3f35c93578 Merge "Add a build-time check for dexpreopting system server jars." 2021-10-29 18:00:51 +00:00
Jiakai Zhang
b6931f2f5b Add a build-time check for dexpreopting system server jars.
Bug: 201371822
Test: m nothing
Test: manual -
  1. Add "service-permission" to DEXPREOPT_DISABLED_MODULES (https://cs.android.com/android/platform/superproject/+/master:build/make/core/product_config.mk?q=DEXPREOPT_DISABLED_MODULES)
  2. m nothing
  3. See the error:
    Missing compilation artifacts. Dexpreopting is not working for some system server jars
    Offending entries:
    system/framework/oat/x86_64/apex@com.android.permission@javalib@service-permission.jar@classes.odex
    system/framework/oat/x86_64/apex@com.android.permission@javalib@service-permission.jar@classes.vdex

Change-Id: If29b1c367e22e302f76bfbae29588e69536414b7
2021-10-29 11:56:49 +00:00
Treehugger Robot
bf406bc182 Merge "Use findstring to check MODULE_BUILD_FROM_SOURCE" 2021-10-29 10:18:07 +00:00
Treehugger Robot
2faf6d512f Merge changes from topics "is_board_platform", "soong_config_namespace"
* changes:
  Add board_platform_in/board_platform_is runtime functions.
  Better Soong namespace support in the RBC runtime.
2021-10-28 19:57:09 +00:00
Jooyung Han
f531336c6f Merge changes from topic "sign_apex-sign_tool"
* changes:
  sign_apex --sign_tool
  fix releasetools_test
2021-10-28 04:39:25 +00:00
Cheonho Park
440467376e Use findstring to check MODULE_BUILD_FROM_SOURCE
Android 12 can have _compressed target
(e.g com.google.android.conscrypt_compressed),
changed function from `filter` to `findstring`

Same change applied to com.google.android.art checking

Also modify to check `true` value of the MODULE_BUILD_FROM_SOURCE
to filter out both unset variable and `false`

Test: adding one error code temporally, install prebuilt
  train, and check result with,without this fix

    MODULE_BUILD_FROM_SOURCE := true
  + $(error we are here, true $(PRODUCT_PACKAGES))
  endif

Bug: 197282276
Change-Id: I864ba1bb5da61ccc6b8576029ab6c569959b2c93
2021-10-27 23:53:29 +00:00
Elliott Hughes
267c6a8595 Merge "Don't package mdnsd for the host." 2021-10-27 21:49:13 +00:00
Jooyung Han
8caba5e14e Support custom APEX signing tool
When an APEX specifies its custom signing tool (custom_sign_tool:),
apexkeys.txt contains the info and sign_target_files_apks pass the value
to apex_util.

For now the Virt APEX has its own custom signing tool (sign_virt_apex),
which is added to OTATOOLS.

Bug: 193504286
Test: sign_target_files_apks invokes sign_virt_apex
Change-Id: Iba845723fe3e18f542963324b9c58cd00914c5ba
2021-10-27 16:56:22 +09:00
Jooyung Han
0f5a41da56 sign_apex --sign_tool
A new argument is a custom signing tool for APEX contents. When
specified, apex_util invokes the tool with payload's key and payload
directory.

For now, the Virt APEX has its own custom signing tool (sign_virt_apex)
to re-sign filesystem images in it.

Bug: 193504286
Test: atest releasetools_test
Test: m sign_apex sign_virt_apex
Test: sign_apex --sign_tool sign_virt_apex --payload_key ..
  --container_key .. resigned.apex
      adb install resigned.apex
      reboot & vm run-app
Change-Id: Ic4d369c2ba42a8295044a0a75e054dc8def93208
2021-10-27 16:56:22 +09:00
Jooyung Han
c4b7b34b4b fix releasetools_test
Some test cases are failing because tests are not updated accordinly.

Bug: n/a
Test: atest releasetools_test
Change-Id: I3df071f72f01dedd6df4fa462ca52b8a0b1ffd4e
2021-10-27 16:06:10 +09:00
Treehugger Robot
2992dccd43 Merge "Allow data wipe for full OTAs" 2021-10-27 04:53:16 +00:00
Elliott Hughes
68d2f8ce91 Don't package mdnsd for the host.
I don't think anyone needs this since Brillo died.

Test: treehugger
Change-Id: Iaa7b84375c9d31f443cba4556dc25b9b00bae5f8
2021-10-26 16:38:58 -07:00
Kelvin Zhang
81641afae4 Allow data wipe for full OTAs
Test: th
Change-Id: I7a751b461a5442d22ebca07c98624f35c02dca15
2021-10-26 16:03:25 -07:00
Steven Moreland
387b39fc91 Merge "Add health to VNDK list" 2021-10-26 22:33:31 +00:00
Alexander Smundak
d79a15a8ad Merge "Provide abspath for backward compatibility." 2021-10-26 17:08:50 +00:00
Ulya Trafimovich
7693ec7e03 Deprecate system server jars defined in Android.mk.
Add PRODUCT_BROKEN_DEPRECATED_MK_SYSTEM_SERVER_JARS variable that is
undefined by default. Setting that variable to true enables support for
system server jars defined in Android.mk. It should be enabled on a
per-product basis in product makefiles.

Bug: 203618671
Test: m nothing
Change-Id: If90d7131d37f308c468e395c236d5aa5ad053bad
2021-10-26 14:47:24 +01:00
Yifan Hong
01b140d7f1 Add health to VNDK list
Test: pass
Bug: 177269435
Change-Id: I1653670a02284542eaa39ed7dc33ccc0aec54312
2021-10-25 21:00:42 -07:00
Treehugger Robot
8cdc80bc24 Merge "Support -s in installmod command" 2021-10-26 01:15:57 +00:00
Cole Faust
3e1923867a Support -s in installmod command
The -s flag must be passed before the adb command,
as in `adb -s emulator-5554 install myapp.apk`
instead of `adb install -s emulator-5554 myapp.apk`.
Parse it and move it to the correct location if it
exists.

Test: Manually
Change-Id: I4b296d7fe4efbe3b25d21d33a8082b321787651a
2021-10-25 13:43:48 -07:00
Sasha Smundak
3370ad5b70 Add board_platform_in/board_platform_is runtime functions.
Bug: 190051051
Test: treehugger
Change-Id: I27269fc0f0f7063635fbb1b1645919b604afb762
2021-10-25 10:41:56 -07:00
Sasha Smundak
dc154164db Better Soong namespace support in the RBC runtime.
Includes:
* Defining namespace again should have no effect
* Allow appending to a variable defined in a namespace
* Consistent naming
* Print namespace variable assignments even if they are empty

Bug: 200297238
Test: rbcrun make/build/tests/run.rbc
Change-Id: I64aa22c4498ae89e4bc3a077d6206ad37d5c7c38
2021-10-25 10:41:46 -07:00
Sasha Smundak
da2f56ebe4 Provide abspath for backward compatibility.
Bug: 194864642
Test: N/A
Change-Id: Ie30c57d8ea93e4247911b6ebf6fd5a3a469ac5e7
2021-10-25 10:33:16 -07:00
Yi-Yo Chiang
09f68abca7 Merge "Revert "Renames boot-debug-*.img in GSI targets"" 2021-10-21 07:22:03 +00:00
Yi-Yo Chiang
be32848ce6 Merge "Stop building boot-(debug|with-debug-ramdisk)-*.img for GSI/GKI" 2021-10-21 04:59:33 +00:00
Treehugger Robot
ee7853cae9 Merge "Rename cmd/main.go to cmd/canoninja.go" 2021-10-21 02:57:53 +00:00