Commit graph

47388 commits

Author SHA1 Message Date
Treehugger Robot
8f5399889b Merge "Start unblocking com.android.runtime deps" 2022-01-13 19:57:01 +00:00
Romain Jobredeaux
8a9a97b4a0 Merge "Revert "Add static_libs support to android_app bp2build converter."" 2022-01-13 17:03:26 +00:00
Romain Jobredeaux
b33e0b8b5b Revert "Add static_libs support to android_app bp2build converter."
This reverts commit de722acd96.

Reason for revert: broke bp2build CI

Change-Id: I535e8746e846c20f1a47c2a1eb0362276af49206
2022-01-13 15:16:12 +00:00
Romain Jobredeaux
24431448b2 Merge "Add static_libs support to android_app bp2build converter." 2022-01-13 15:00:44 +00:00
Jiakai Zhang
6decef916c Allow installing boot images outside of APEX.
After this change, `bootImageConfig.installDirOnDevice` can be set to a
path outside of the APEX, in which case, the boot image will not be
installed in the APEX. Instead, it will be installed to the given path
by Make.

This is a no-op change. Current behavior is not affected.

Bug: 211973309
Test: m nothing
Test: -
  1. m com.android.art
  2. See the boot image still being installed in the ART APEX.
Test: -
  1. Change `installDirOnDevice` of the ART boot image config to
     `system/framework`.
  2. See the boot image being installed in `/system/framework/<arch>`.
Change-Id: Ib13b17cc9e94dc5754c9b51b04df3307323b8783
2022-01-13 14:50:05 +00:00
Paul Duffin
da88a2599a Merge "Prevent using android_app_import in instrumentation_for property" 2022-01-13 11:56:52 +00:00
Martin Stjernholm
3a1a4b070e Merge "Fix genrule tool dependencies when a prebuilt tool is preferred." 2022-01-13 07:43:15 +00:00
Kousik Kumar
35faaef43e Pass along local resource fraction to reproxy
Reproxy should be respecting the -j value set by the user and not be
doing excessive local executions assuming the whole machine is available
to it. The local_resource_fraction flag is a way to ensure reproxy
consumes CPU only upto the -j value specified by the user.

Test:
1. Ran with `USE_RBE=true m -j 10 nothing` and local_resource_fraction
was set to 0.14 on a 72-core workstation.
2. Ran with `USE_RBE=true m nothing` and local_resource_fraction was set
to 1.0 on a 72-core machine.

Bug: b/207296459
Change-Id: I118bc10109f5a55df7a6c1ecd79499320055f2ed
2022-01-13 02:13:10 -05:00
Treehugger Robot
de232dbed2 Merge "Generate tidy-* rules unless tidy is disabled" 2022-01-13 03:46:37 +00:00
Muhammad Haseeb Ahmad
be63328574 Merge "Add java_fuzz_packaging" 2022-01-13 01:22:16 +00:00
Wei Li
3842a91f54 Merge "Correct the comments on property exclude_kotlinc_generated_file, which defaults to false actually." 2022-01-13 01:10:01 +00:00
Chih-Hung Hsieh
7540a78a35 Generate tidy-* rules unless tidy is disabled
* make tidy-soong_subset, or make tidy-<any_directory>,
  should trigger the same clang-tidy compilations
  with or without global WITH_TIDY=1.
* Normal make should not trigger clang-tidy compilations
  unless global WITH_TIDY=1 or a module has set tidy:true.

Bug: 213918926
Test: NINJA_ARGS="-n" make tidy-soong_subset
Test: NINJA_ARGS="-n" make <some-library>
Change-Id: Iafffd3894abe137c9584c2c01830898422f9a677
2022-01-12 16:48:40 -08:00
Treehugger Robot
757feca3ed Merge "[coverage] Override -Wframe-larger-than" 2022-01-13 00:38:20 +00:00
Martin Stjernholm
dbd814d44e Fix genrule tool dependencies when a prebuilt tool is preferred.
Since the genrule tool dep mutator runs after the prebuilt mutators,
this adds a helper function android.PrebuiltGetPreferred to resolve the
source or prebuilt as appropriate.

Test: m SOONG_CONFIG_art_module_source_build=false droid
  in internal
Bug: 214292395
Change-Id: I1a208fd048b998f9f19ad1f45d8389decda2cb9e
2022-01-12 23:35:57 +00:00
Wei Li
92cd54b29d Correct the comments on property exclude_kotlinc_generated_file, which defaults to false actually.
Bug: 204888276
Test: Treehugger

Change-Id: Ib0405395da9a8cf8dd7bb1983fcd13425fe69b34
2022-01-12 13:27:36 -08:00
Sam Delmerico
443703ab32 Merge "Support enabled flag in product variable config" 2022-01-12 20:34:14 +00:00
Pirama Arumuga Nainar
e6840726bd [coverage] Override -Wframe-larger-than
Bug: http://b/214221000
Bug: http://b/194128476

Adding `-mllvm -runtime-counter-relocation` for continuous coverage has
caused -Wframe-larger-than warnings when linking libart.  These warnings
need not be enforced on coverage builds, so override the flag.

Test: NATIVE_COVERAGE_PATHS=art CLANG_COVERAGE=true m libart;
      also go/abtd on failing target.
Change-Id: I8f5ac725ff5c674e6dd0831136d3d8b2e42b0428
2022-01-12 11:52:26 -08:00
Muhammad Haseeb Ahmad
e380310a9e Add java_fuzz_packaging
java_fuzz_package is a prelude to a haiku-java build target.

Test: m example_java_fuzzer
Change-Id: I78caa53d7687e24f7180c7e16013b668991d6fe6
2022-01-12 18:48:39 +00:00
Sam Delmerico
0e33c9d772 Support enabled flag in product variable config
Some Android.bp modules have `enabled: false` but only use a product
variable such as `source_build` to enable the module.  Currently b2build
does not handle this case at all. This commit adds the functionality
to support this use case.

Also, remove `__enabled` suffix in ProductVariable SelectKey.

Bug: 210546943
Test: go test ./bp2build
Topic: use_enabled_flag_product_variable_config
Change-Id: I459c17a84c172df010666391066bf4d11d19253e
2022-01-12 16:26:44 +00:00
Liz Kammer
adf1b2a2cd Merge "Add SetProperties to json-module-graph" 2022-01-12 13:23:33 +00:00
Liz Kammer
e844132b85 Merge "Revert "Revert "bp2build: convert host & prebuilt header libraries""" 2022-01-12 13:23:16 +00:00
Wei Li
9ab9437b40 Merge "Add new property "exclude_files_in_output" for excluding files from the output files of Java related modules." 2022-01-12 09:25:22 +00:00
Sundong Ahn
a5c5b9c845 Support installable property
Support not installing sh_binary when installable property is false

Bug: 205065320
Test: m -j
Change-Id: I71a0fd24e8867d6cb2527ecdacc775253f12c9f8
2022-01-12 03:29:17 +00:00
Treehugger Robot
e751b5355e Merge "Remove self from OWNERS" 2022-01-12 01:45:56 +00:00
Wei Li
1e73c6573e Add new property "exclude_files_in_output" for excluding files from the output files of Java related modules.
Bug: 204888276
Test: m service-permission
Change-Id: I9f6113834826358b0e3af22ed1dd63a43c255452
2022-01-11 14:20:16 -08:00
Liz Kammer
3d3b35c94e Revert "Revert "bp2build: convert host & prebuilt header libraries""
This reverts commit 105deedfc7.

Reason for revert: Revert with forward fix

Change-Id: Ib0b6f6b1cbb011b4c5f2133e1cc15ec76ff29253
2022-01-11 16:02:50 +00:00
Liz Kammer
9525e71003 Add SetProperties to json-module-graph
SetProperties contains name and type of properties set in the bp file
and any set via defaults. There may be properties that were not
specified in an Android.bp file due to:
* specified via go code (e.g. LoadHooks)
* property is _not_ a pointer -- so it is not possible to tell between
  not set in bp file and default value.

Test: soong tests
Test: m json-module-graph and verify
Change-Id: I4cb868b1d7db566e72636c6fb53bb9c7090f236a
2022-01-11 10:47:23 -05:00
Jingwen Chen
ed4900f9d9 Merge "Revert "bp2build: convert host & prebuilt header libraries"" 2022-01-11 14:58:56 +00:00
Paul Duffin
53a70a4870 Prevent using android_app_import in instrumentation_for property
Previously, referencing a prebuilt android_app_import in an
android_test's instrumentation_for property instead of the source
android_app module (e.g. because the prebuilt is preferred) could
result in compilation errors if the android_test sources depended on
classes from the app. That is because while the android_app provides a
classes jar file to be added to the android_test's classpath the
android_app_import does not.

This change reports that situation as an error.

Bug: 207128192
Test: m nothing
Change-Id: I26ea90e7a3f57707fc0c094e0d8b8dc9a9e135ac
2022-01-11 14:47:38 +00:00
Jingwen Chen
105deedfc7 Revert "bp2build: convert host & prebuilt header libraries"
This reverts commit d8a72d7dc9.

Reason for revert: root cause for b/214013899

Change-Id: If769708408c419c2fd3d9484fbf40202b7276299
2022-01-11 12:51:27 +00:00
Ian Zerny
a52cbd67a3 Merge "Add mapping id to source file information for R8 full-mode builds." 2022-01-11 07:20:50 +00:00
Treehugger Robot
57271b9f45 Merge changes I9ad66ea2,I4c95b77b
* changes:
  Make android_app.stem overridable
  Use 'stem' to override APK name
2022-01-11 06:38:25 +00:00
Jooyung Han
01d80d8b4b Make android_app.stem overridable
override_android_app can set "stem" property to set the APK name.

Bug: 193504286
Test: m (soong test)
Change-Id: I9ad66ea28bd1b030cb2c588d1f070d72e62ab1c7
2022-01-11 13:07:44 +09:00
Jooyung Han
29e2f6d2c4 Use 'stem' to override APK name
When android_app.stem is set, use it as the APK name like other module
types.

Bug: 193504286
Test: m (soong test)
Change-Id: I4c95b77be382cff3cfecaf6ce38f99aed9f3238f
2022-01-11 13:03:49 +09:00
Sasha Smundak
6bc132aff9 Check missing uncoditionally loaded missing modules at runtime
A potentially inherited (via dynamically calculated path) module may in turn
unconditionally load a module that does no exist in a source tree -- it is
not an error if this potentially inherited module is actually never inherited
because its dynamically calculated path will never reference it. Instead of
emitting an uncoditional `load` for a non-existent file (which is going to fail
in the Starlark parser), emit conditional load and a runtime check.

Fixes: 213922819
Test: internal
Change-Id: I92177878e199a1f00e5f0c4045c0c0daeddd6bdb
2022-01-10 19:58:14 -08:00
Treehugger Robot
35f94eba51 Merge "Consolidate conversions of is-board-platform(2)" 2022-01-11 03:51:21 +00:00
Keyi Gui
f4bf09feba Merge "Update droidstubs to support putting action inputs/outputs into the module-graph.json." 2022-01-11 03:33:01 +00:00
Treehugger Robot
4cfd37e617 Merge "Convert math functions" 2022-01-11 03:28:01 +00:00
Treehugger Robot
03a0679529 Merge "Make include_top comments only apply to the next statement" 2022-01-11 03:11:51 +00:00
Pirama Arumuga Nainar
6609484961 Merge "Enable memory-mapped coverage instrumentation" 2022-01-10 22:36:57 +00:00
Sam Delmerico
88a1b9da85 Merge "Convert javacflags -> javacopts for java_binary_host" 2022-01-10 20:53:39 +00:00
Keyi
fe310a9305 Update droidstubs to support putting action inputs/outputs into the module-graph.json.
Test: local test

Change-Id: I6ce657f2ad53c261bcbdd317c266cf179a0cc6e9
2022-01-10 21:28:37 +08:00
Inseob Kim
865d5e6c9d Merge "Revert^3 "Add seapp_contexts to allowlist of makefile goal"" 2022-01-10 11:15:28 +00:00
Treehugger Robot
25656c401b Merge "Use Module.GetProperties() instead of ModuleBase.generalProperties" 2022-01-10 08:49:17 +00:00
Ian Zerny
fc7df6124f Add mapping id to source file information for R8 full-mode builds.
Bug: 204293621
Test: atest --host r8retrace-check-retraced-stacktrace
Change-Id: I09703cfaab72350efe67217be9e2d37988218f4d
2022-01-10 08:56:19 +01:00
Treehugger Robot
bac9e97c50 Merge "Add sepolicy compat versions to soong config" 2022-01-10 02:09:23 +00:00
Usta
851a3271ce Use Module.GetProperties() instead of ModuleBase.generalProperties
ModuleBase.generalProperties served the pupose of being a subset
of ModuleBase.customizableProperties. But now with the removal of
the latter, the former is simply a redirection to Module.GetProperties()

Bug: 206961391
Test: m nothing and diff the ninja files
Change-Id: I6dd8b7ba74eb5e7ffb61029b0f9129eec2ccfdaf
2022-01-08 03:09:52 +00:00
Treehugger Robot
e508f6a50b Merge "Fix format" 2022-01-08 02:20:02 +00:00
Treehugger Robot
77d93ba871 Merge "bp2build: convert host & prebuilt header libraries" 2022-01-08 00:55:32 +00:00
Cole Faust
b2e0b60126 Consolidate conversions of is-board-platform(2)
mk2rbc implements conversions for both
is-board-platform(-in-list) and
is-board-platform(-in-list)2. The conversions
are not the same despite the functions being the
same. Make them convert to the same thing.

Bug: 201477826
Test: go test
Change-Id: I688a2f6114e1688c713e42f0f9229cbc5ee6a917
2022-01-07 15:46:58 -08:00