Commit Graph

3129 Commits

Author SHA1 Message Date
Sophie Zheng
7b5fa4277f Merge "Java APIs used by Mainline modules." 2021-11-15 06:40:31 +00:00
sophiez
0234737f30 Java APIs used by Mainline modules.
Add scripts to generate java APIs used by Mainline modules. This is
aosp/1879177 with fixed build error that caused by dexdeps analyzing
resource only APKs which doesn't contains any .dex files. Now skip the
error generates in that case in gen_java_usedby_apex.sh

Forrest run:https://android-build.googleplex.com/builds/abtd/run/L38900000951898586

Test: TARGET_BUILD_APPS=com.android.adbd m dist apps_only
Change-Id: Id539cbe1b7306ace69c047f95ffc02265a467511
2021-11-12 23:39:35 +00:00
Daniel Norman
e19437e8f7 Adds multi_install_skip_symbol_files field (default false) to apex.
Multi-installed APEXes share the same apex_name and are installed
at the same time.

Should be set to true for all multi-installed APEXes except the singular
default version within the multi-installed group.
Only the default version can install symbol files in $(PRODUCT_OUT}/apex,
or else conflicting build rules may be created.

Bug: 199290365
Test: see https://r.android.com/1872018
Change-Id: I0cd9d748d7be3a2de40ed14f13bad71912457ddc
2021-11-12 20:45:50 +00:00
Colin Cross
32b9cd0fc2 Merge "Revert "Move apex module installation into Soong"" am: 152911f807 am: 35ee47dcbf am: ca03de2828 am: 21d7f625c3
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1890806

Change-Id: I2647b410bb76f237367d127490193249ce04324d
2021-11-12 20:08:22 +00:00
Colin Cross
ccba23db44 Revert "Move apex module installation into Soong"
This reverts commit e3d156a622.

Reason for revert: b/206119621

Bug: 204136549
Change-Id: I380223b86660c27bea8f5dcc2d61f32df2704c02
Fixes: 206119621
2021-11-12 19:01:29 +00:00
Ivan Lozano
d06cc748c1 Use new soong_cc_rust_prebuilt.mk
soong_{cc,rust}_prebuilt.mk has been merged. Use the new file.

Bug: N/A, clean-up
Test: m
Change-Id: I3f03e866815f6394aacd8cb0deba04f381b78c29
2021-11-12 13:27:58 -05:00
Colin Cross
66f1ef1e46 Merge "Move apex module installation into Soong" am: 4e278e5f68 am: 8dfdabc4c9 am: f24e7a7f4e am: 2098ff63f4
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1880605

Change-Id: I63132d59c3dc63e78b9cca1cb075bedc106b793b
2021-11-12 18:13:03 +00:00
Colin Cross
e3d156a622 Move apex module installation into Soong
Move apex module installation rules into Soong by overriding
InstallBypassMake.

Soong installs don't support post install commands, so move the
symlinks into separate rules and add dependencies on them.

Bug: 204136549
Test: m checkbuild
Change-Id: If65d283abc86f18ad266da0bf16fe95971a0bf9c
2021-11-11 17:44:42 -08:00
Laura Tsai
89c5e3a402 Merge "Revert "Add scripts to generate java APIs used by Mainline modules."" am: 33b60e4983 am: 463f87c7c5 am: fb1e24c1c7 am: 2883262457 am: 5f49af419f
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1885670

Change-Id: Ib9e95d6a0ce32be7d059a09a863cc1bb6edb70dc
2021-11-10 08:13:51 +00:00
Laura Tsai
33b60e4983 Merge "Revert "Add scripts to generate java APIs used by Mainline modules."" 2021-11-10 07:00:38 +00:00
Laura Tsai
be3c7eacfe Revert "Add scripts to generate java APIs used by Mainline modules."
This reverts commit c92380f001.

Reason for revert:
DroidMonitor:

DroidMonitor-triggered revert due to breakage
https://android-build.googleplex.com/builds/quarterdeck?branch=git_master&target=mainline_modules_arm64-userdebug&lkgb=7898389&lkbb=7900541&fkbb=7898474,
bug 205746850

Change-Id: Ibd84dfe68dfe150b7e05b4287364d1946375bf72
2021-11-10 06:59:37 +00:00
Spandan Das
efd3f2b7f3 Merge "Add android.safetycenter to permission module permitted_packges" 2021-11-09 19:44:16 +00:00
Sophie Zheng
1ca1a4e1f9 Merge "Add scripts to generate java APIs used by Mainline modules." am: 4bb0b7a0c3 am: 5518e10391 am: 240288cbbd am: e6bcc6cb18 am: 6079902056
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1879177

Change-Id: Id47ead91179b60532eae6b956c9eb9605e125c54
2021-11-09 19:32:51 +00:00
Spandan Das
79e332c02d Add android.safetycenter to permission module permitted_packges
Currently the permitted_packages check is per apex and not per jar.
Adding android.safetycenter to the allowlist to unblock ag/16182563

Bug: 205289292
Test: TH
Change-Id: I9fc315a987af937a527872f24bf73263d2c9c9f2
2021-11-09 18:01:42 +00:00
Sophie Zheng
4bb0b7a0c3 Merge "Add scripts to generate java APIs used by Mainline modules." 2021-11-09 17:13:33 +00:00
sophiez
c92380f001 Add scripts to generate java APIs used by Mainline modules.
Test: TARGET_BUILD_APPS=com.android.adbd m dist apps_only

Change-Id: Icd854fd40c3026ae9aae6dc30c9e79027e1303a0
2021-11-05 15:38:09 -07:00
Treehugger Robot
dbb2a94cda Merge "Respect required property of apex modules" 2021-11-05 01:54:36 +00:00
TreeHugger Robot
0a96339c45 Merge "Respect required property of apex modules" 2021-11-02 00:50:46 +00:00
Colin Cross
25f69e8278 Merge changes I04f2f558,Ie16a6264,I83a3be9f,Icb3eeef3 am: 91eaa6316a am: 19aa461cc0 am: 204c59ef91 am: e097970ad8 am: ac0c4570bc
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1869551

Change-Id: I01b8b582aa53394710f71eb74df28054fafde04f
2021-10-30 20:54:49 +00:00
Colin Cross
91eaa6316a Merge changes I04f2f558,Ie16a6264,I83a3be9f,Icb3eeef3
* changes:
  Rename amod variable in AndroidMkEntries.fillInEntries to base
  Make HostToolPath, HostJNIToolPath and sboxPathForToolRel use pathForInstall
  Add PathForGoBinary
  Remove PathForOutput from InstallPathToOnDevicePath
2021-10-30 19:19:53 +00:00
Treehugger Robot
cff5016d88 Merge "apex.custom_sign_tool property" am: cae893ae40 am: e18be41278 am: f11c7c9e18 am: 4c549b825a am: a18a62bafa
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1869522

Change-Id: Id484c324ea7c73ddb8e610c476535bb11785202d
2021-10-30 01:06:39 +00:00
Treehugger Robot
cae893ae40 Merge "apex.custom_sign_tool property" 2021-10-29 23:39:26 +00:00
Colin Cross
790ef35d1e Make HostToolPath, HostJNIToolPath and sboxPathForToolRel use pathForInstall
Use pathForInstall instead of PathForOutput for HostToolPath,
HostJNIToolPath and sboxPathForToolRel so that they internally produce
an InstallPath that can later support being converted to Make install
path.

Bug: 204136549
Test: m checkbuild
Change-Id: Ie16a62641d113873daeec4d1dd4261251bc0d0eb
2021-10-29 16:34:55 -07:00
Colin Cross
a44551fec6 Add PathForGoBinary
Add PathForGoBinary that uses pathForInstall to return the install
path of a GoBinaryTool.  This will replace various places that used
PathForOutput to reconstruct a path to a Go tool, and will support
moving Go tools to the Make install directory outside of the
PathForOutput directory in a future patch.

Bug: 204136549
Test: m checkbuild
Change-Id: I83a3be9f5c621975540f5ed601a0b9e2611c98b9
2021-10-29 16:34:55 -07:00
Treehugger Robot
65388ec852 Merge "Make a pass over our codebase cleaning up non-precise / non-inclusive language." am: c9e85ca825 am: e68637799b am: 5bb9910ea6 am: df50b4ba4b am: 3be5075c71
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1871701

Change-Id: I744d6e359d05f169084b7844732fcc3a2870b9cf
2021-10-28 22:11:33 +00:00
Treehugger Robot
c9e85ca825 Merge "Make a pass over our codebase cleaning up non-precise / non-inclusive language." 2021-10-28 20:51:17 +00:00
Joe Onorato
b4638c1ac3 Make a pass over our codebase cleaning up non-precise / non-inclusive language.
Test: treehugger
Bug: 204369779
Change-Id: I6e63cae824d323535cdb14b493edd868df47738d
2021-10-28 10:32:07 -07:00
Jiyong Park
80751747e8 Respect required property of apex modules
This CL fixes a bug that `required` property of apex modules is not
reflected to the generated Android.mk file.

Ignore-AOSP-First: needs to be merged together with a change in vendor
directory

Bug: N/A
Test: m nothing
Change-Id: I36ccf538882f083f9433bd3eb05b3a5127f3822b
2021-10-28 15:33:55 +09:00
Jiyong Park
cacc4f358a Respect required property of apex modules
This CL fixes a bug that `required` property of apex modules is not
reflected to the generated Android.mk file.

Bug: N/A
Test: m nothing
Change-Id: I36ccf538882f083f9433bd3eb05b3a5127f3822b
2021-10-28 14:35:34 +09:00
Jooyung Han
09c11adf51 apex.custom_sign_tool property
A new property indicates a CLI tool to sign the APEX contents. The value
is stored in apexkeys.txt so that releasetool (sign_target_files_apks)
can use it to invoke the tool to re-sign the apex contents.

Bug: 193504286
Test: m out/soong/apexkeys.txt
      com.android.virt.apex line has sign_tool value
Change-Id: Ifd472049b75b5b87c1ed320f5e1190ff65ed54f2
2021-10-27 04:02:48 +09:00
Sophie Zheng
7a32a1ccec Merge "Save all the detected native shared library backing by mainline modules." am: 7fe4ccafc1 am: 3148f72c42 am: 4975230387 am: 751134c4af am: d15ba0c37f
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1858614

Change-Id: If96b6d20b0e61052063f7448ea014eceace404a5
2021-10-21 20:14:25 +00:00
Sophie Zheng
7fe4ccafc1 Merge "Save all the detected native shared library backing by mainline modules." 2021-10-21 18:42:35 +00:00
Paul Duffin
47142c77db Merge "Remove artApex parameter from ApexBundleFactory" am: e760c3b724 am: fcba421625 am: 84e2edf8f2 am: 53ce24889a am: b8d29f3b84
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1862814

Change-Id: I2f3c6f1a69796431a3c6d683a5ae5cd073118163
2021-10-20 11:37:27 +00:00
Paul Duffin
eb8051d80d Remove artApex parameter from ApexBundleFactory
Since coverage support was added to bootclasspath_fragment in
https://r.android.com/1684807 and bootclasspath_fragments were
integrated into the ART APEX it is no longer necessary to treat ART
APEXes differently to other APEXes.

Change https://r.android.com/1684807 added coverage support, follow
up changes integrated

Bug: 177892522
Test: m droid
      m EMMA_INSTRUMENT=true EMMA_INSTRUMENT_FRAMEWORK=true
Change-Id: I4800a003c7459c4686607e16f4c5bde0be105f16
2021-10-20 10:29:14 +00:00
sophiez
9a6eabf952 Save all the detected native shared library backing by mainline modules.
Test: TARGET_BUILD_APPS=com.google.android.adbd m dist apps_only

Change-Id: I510292542bf2550c9244e9374cd6f7b40a971486
2021-10-19 14:33:57 -07:00
Dan Willemsen
142126e68f Fix mac/allowmissingdeps builds am: 47e1a75851 am: a24a2c7d6e am: 933fb2296e am: f6b3379ee4 am: 316f60c2c1
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1860414

Change-Id: Ib163545c88297b48c13a3d75a2521f2558166055
2021-10-18 01:03:33 +00:00
Dan Willemsen
47e1a75851 Fix mac/allowmissingdeps builds
This WalkDeps loop was expecting the dependencies to be fully filled
out, which isn't necessarily true on AllowMissingDependencies builds,
especially on Mac when the modules may exist, but not be enabled.

This was triggered when make_erofs was added to an apex, but wasn't
enabled on Mac.

It shouldn't be a problem to skip the disabled dependencies, since we'll
have already marked the current module as missing dependencies, which
means it won't actually get built.

Test: `m nothing` on a mac
Change-Id: Icd6d597117be4cde5bff041be3fd47361c54cad9
2021-10-17 01:40:34 +00:00
Mohammad Islam
7d314d5517 Merge "Add EROFS support for APEX build system" am: 214a923f0d am: 7654b6b27c am: cfa380c303 am: 34a6362f47 am: b0f8eab3fe
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1784471

Change-Id: I3f719ef39b671cc8337008be5e86955043c3a1ce
2021-10-15 16:56:53 +00:00
Mohammad Islam
214a923f0d Merge "Add EROFS support for APEX build system" 2021-10-15 15:44:47 +00:00
Jiyong Park
81dbef72d4 Merge "Remove use_apex_name_macro" am: ddf4ebae19 am: c05ccb3724 am: 7330b2652e am: e9907ef104 am: 28e6e4098c
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1853655

Change-Id: Ida69fb806665f65159f19516b06d8e35e4d99b56
2021-10-14 03:46:27 +00:00
Jiyong Park
ddf4ebae19 Merge "Remove use_apex_name_macro" 2021-10-14 02:32:43 +00:00
Jiyong Park
91f1b42226 Remove use_apex_name_macro
The property is no longer used.

Bug: 161926892
Test: m
Change-Id: I98948152d6d09bde2eeba4875c7ca01531a24930
2021-10-14 08:57:59 +09:00
Paul Duffin
86e05669a3 Merge "Stop prebuilt_apex/apex_set exporting invalid jars to Make" am: 13dd220448 am: 964d2d7a51 am: a242a29f0e am: 3f3d8dcbd5 am: b97af3ed95
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1853520

Change-Id: I343c4daae8859a679f56f0f05bc0697ada471dd2
2021-10-13 16:05:31 +00:00
Paul Duffin
13dd220448 Merge "Stop prebuilt_apex/apex_set exporting invalid jars to Make" 2021-10-13 14:53:17 +00:00
Jiakai Zhang
007b110239 Merge "Add more tests for dexpreopting." am: 40eb3b3e94 am: 39f65b16e3 am: d6954f0b0f am: 0b2280aa1c am: 5318a52fad
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1840057

Change-Id: Iff6cc79f68889bba3830096854b4833131fb538a
2021-10-13 04:28:38 +00:00
Jiakai Zhang
470b7e22a7 Add more tests for dexpreopting.
This CL adds more tests to ensure that dexpreopted files are generated
and APEXes depends on them.

Bug: 201371822
Test: m nothing
Change-Id: I407ad54c55cbca9ef78bbd335e95d4b765e174a0
2021-10-12 03:25:52 +00:00
Paul Duffin
2579631bd1 Stop prebuilt_apex/apex_set exporting invalid jars to Make
A prebuilt_apex/apex_set module can make a dex implementation jar
available for use by Make targets but it does not have access to a real
classes implementation jar; the jar in the corresponding sdk is just an
empty file. Exporting that invalid file to Make means that the phony
target created for the module depends on an invalid classes jar which
causes the build to fail.

This change removes the logic that make classes and header jars
available to Make so that building the phony target no longer fails.

Bug: 202521005
Test: m TARGET_PRODUCT=armv8 TARGET_PRODUCT_VARIANT=eng TARGET_BUILD_UNBUNDLED=true SOONG_ALLOW_MISSING_DEPENDENCIES=true core-icu4j
      - above was performed in master-art.
Change-Id: If667b36b988e2d331acd85f60f3369778838d034
2021-10-11 17:53:54 +01:00
Paul Duffin
fca846b4eb Retry: Separate hidden API flags needed in sdk snapshots for S and T am: 191be3a186 am: bf027e4e58 am: 1f45d4a4d9 am: 16a312a1e6 am: 812583f057
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1844294

Change-Id: I02a215a9702e4c4b2eae3084c0e5e751dfa76f9a
2021-10-05 19:00:18 +00:00
Paul Duffin
bf027e4e58 Retry: Separate hidden API flags needed in sdk snapshots for S and T am: 191be3a186
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1844294

Change-Id: Id8977b8160f175b736214428cae94ea27f95675b
2021-10-05 18:04:10 +00:00
Paul Duffin
191be3a186 Retry: Separate hidden API flags needed in sdk snapshots for S and T
Previous change that was reverted: https://r.android.com/1835222
An additional test was added that revealed a bug in the previous change
which has been fixed here.

Previously, the behavior of the stub_flags and all_flags properties
was different between S and T. In S they contained paths for the
complete set of stub flags and all the encoded flags. However, in T
they contained filtered sets of flags which if used in S would prevent
build checks from detecting possible inconsistencies. Also, a new
signature_patterns property was added in T that is not supported in S.

This change creates separate properties/files for T and reverts the
behavior of the properties/files that were added in S back to how they
behaved in S. The new properties are called filtered_stub_flags and
filtered_flags.

The S and T properties are tagged with the appropriate
supported_build_releases tag to ensure that they are only output when
specifically targeted.

Bug: 197842263
Test: m nothing
Change-Id: I1ce0a3d6623dabf73e32af1a7457b9b444fc3b7c
2021-10-05 15:27:42 +01:00