Commit graph

66380 commits

Author SHA1 Message Date
Aditya Kumar
9488eb82d4 Merge "gsimple-template-names" into main 2023-07-11 05:54:11 +00:00
Treehugger Robot
5af242249d Merge "Copy imported APKs to output filename" into main 2023-07-11 04:52:46 +00:00
Igor Foox
24739676c7 Remove openwrt modules from genrule denylist.
With the other change in this topic,
`OpenwrtControlServerProto_h` and
`OpenwrtControlServerProto_cc` both successfully build with sandboxing
on.

Test: build/soong/tests/genrule_sandbox_test.py --show-diff OpenwrtControlServerProto_h OpenwrtControlServerProto_cc
Test: GENRULE_SANDBOXING=true m OpenwrtControlServerProto_h OpenwrtControlServerProto_cc
Test: GENRULE_SANDBOXING=true m droid
Change-Id: Id56824ed935e1d16d2333e5a1aeac248cdfcaeb6
2023-07-10 23:15:43 -04:00
Igor Foox
921a465919 Merge "Update genrule denylist to make m droid build." into main 2023-07-10 22:51:44 +00:00
Wei Li
59df0ee442 Add integration test for m build SBOM of APEXs/APKs.
Bug: 266726655
Test: build/soong/tests/sbom_test.sh
Change-Id: Id8002042f607f8e158f561ca47e0a84a8b8927e2
2023-07-10 15:50:38 -07:00
Colin Cross
5780d57a71 Copy imported APKs to output filename
android_app_import and android_test_import modules with processed: true
and skip_preprocessed_apk_checks are used directly from the source tree.
If the source file name doesn t match the module name and the file is
used as test data it can result in the wrong filename being used.  Copy
the source file to an output file with the correct name first.

Bug: 290376750
Test: m CtsAppSecurityHostTestCases
Change-Id: I4a6dd1c5e48db7085ea41035def31f0844948a46
2023-07-10 22:18:01 +00:00
Fabián Cañas
bc10544dec Make clang debug level configurable
The -g flag is controllable with CLANG_DEFAULT_DEBUG_LEVEL from -g0 to
-g3. The default remains -g

Test: Build with CLANG_DEFAULT_DEBUG_LEVEL=debug_level_1

Change-Id: I913d3a0cb028484f9496a7e0a2298852f9b699cd
2023-07-10 20:49:22 +00:00
Igor Foox
04ff5f90ae Update genrule denylist to make m droid build.
Test: lunch aosp_cf_x86_phone && GENRULE_SANDBOXING=true m droid
Change-Id: I9092df9a407ffe9a7f1c12f18fb0ce1c5fa027a1
2023-07-10 14:58:51 -04:00
AdityaK
423e4ce9e3 gsimple-template-names
Based on: https://chromium-review.googlesource.com/c/chromium/src/+/3988987

```
Savings are almost 330M on 11G

du -s out.diff/target/product/vsoc_arm64/symbols
10751692        out.diff/target/product/vsoc_arm64/symbols
du -s out/target/product/vsoc_arm64/symbols
11086508        out/target/product/vsoc_arm64/symbols
```

Change-Id: I49a5c4cadc77cb0d97e680e95c4efa7156a42f13
2023-07-10 17:36:22 +00:00
Romain Jobredeaux
496660d38a Support target and max sdk version in app bp2build.
Test: Unit tests + CI
Bug: 285304294
Bug: 280465047
Change-Id: I9bb1b6f9729ad783a43837d77dcf2d02b50ca77e
2023-07-10 11:50:00 -04:00
Elliott Hughes
ff96fe1589 Merge "Remove -fstrict-aliasing from arm32." into main 2023-07-10 14:37:39 +00:00
Liz Kammer
b492843c3f Handle static binary repetition of system deps
Test: b build `bmod toybox-static`
Test: go test bp2build tests
Change-Id: Id728f6fd08832a4fc153f0ff5282cdfb6b19c2f6
2023-07-10 10:28:02 -04:00
Treehugger Robot
ab8ed75b6b Merge "kzip build: pipe error message to stderr." into main 2023-07-10 11:45:09 +00:00
Jingwen Chen
ce08efd395 kzip build: pipe error message to stderr.
This was going to stdout so it wasn't showing up on build_error.log.

Test: n/a
Change-Id: I58ac08961b089d06720a307ece3398594b3456de
2023-07-10 08:18:58 +00:00
Treehugger Robot
b2ace8d72d Merge "Implement OutputFileProducer for android_app_import and android_test_import" into main 2023-07-08 00:36:53 +00:00
Liz Kammer
8822ff5193 Experiment with not using ninja weights
Test: CI
Change-Id: Id611059dba35aaaebc7cf787381669c4294ceb53
2023-07-07 18:31:39 -04:00
Treehugger Robot
00042a4875 Merge "rust: Allow any host tool for custom_bindgen" into main 2023-07-07 22:10:25 +00:00
Elliott Hughes
9bbe96068d Remove -fstrict-aliasing from arm32.
Our global default is -fno-strict-aliasing (including for 32-bit x86),
so let's avoid a source of arm32-only bugs.

Bug: http://b/31600139
Test: treehugger
Change-Id: Iaf3069200b2969718593387dc5b756c574a5d68a
2023-07-07 19:45:24 +00:00
Trevor Radcliffe
e3c6a296cf Revert "Revert "add media.swcodec to Bazel prod allowlist""
This reverts commit 061012475c.

Reason for revert:
Debugging the failures from the previous attempt

Change-Id: Ide7161ca46fd3bac087e976712e07ddeecf6335e
2023-07-07 19:29:04 +00:00
Jason Macnak
4ae9c14557 Merge "Remove FrontendStub_[cc|h] from SandboxingDenyModuleList" into main 2023-07-07 19:16:14 +00:00
Colin Cross
5368d0b44a Implement OutputFileProducer for android_app_import and android_test_import
Fixes: 290376750
Test: builds
Change-Id: I5fc3a759462cfd4342b9330ac8978368feee26ca
2023-07-07 18:36:08 +00:00
Colin Cross
ff3ff7f354 Add tests for code that will be affected by resource processor feature
Add a test for the aapt2 resource processing code that will be affected
by the resource processor feature in a subsequent CL.

Test: TestAndroidResourceProcessor
Change-Id: I39712853f7bbfb7963f1b71e234d039d5ccaae53
2023-07-07 10:58:31 -07:00
Colin Cross
702ef0a07a Merge changes I70f81120,If8f2534e into main
* changes:
  Export ReverseSliceInPlace and ReverseSlice
  Make CopyOf generic
2023-07-07 17:07:50 +00:00
Andrei Homescu
4494685aec rust: Allow any host tool for custom_bindgen
Switch custom_bindgen to use any HostToolProvider
instead of just Rust modules, so any host binary can
be used as the bindgen wrapper.

Bug: 242243245
Test: presubmit
Change-Id: I9ba189b2857b3049dcf14842c178ce5846bab2f7
2023-07-07 04:59:07 +00:00
Yabin Cui
f67bc44848 Merge "Update clang version to clang-r498229" into main 2023-07-06 23:54:42 +00:00
Colin Cross
b5e3f7dad5 Export ReverseSliceInPlace and ReverseSlice
... and add tests.

Test: TestReverseSliceInPlace, TestReverseSlice
Change-Id: I70f811207fdb2af891f7ef3fe19cbe5c7276135a
2023-07-06 16:36:50 -07:00
Cole Faust
39381dc2bd Merge "Handle RepoMappingManifest actions" into main 2023-07-06 23:14:11 +00:00
Colin Cross
13aeb689af Make CopyOf generic
Test: util_test.go
Change-Id: If8f2534ec454903eb967dc9ec0c8708096d1baff
2023-07-06 15:02:56 -07:00
Cole Faust
950689a9c2 Handle RepoMappingManifest actions
These are essentially FileWrite actions, like SourceSymlinkManifest.

However, currently aquery appears to give non-deterministic results
for the file content. Emit an empty file for now to avoid the
non-determinism.

Fixes: 288292933
Bug: 287539324
Test: Presubmits
Change-Id: Ieaf8aff0d58d2d69087e4e34dc99074a015e700c
2023-07-06 09:44:14 -07:00
Treehugger Robot
a9778d576b Merge "Revert "Commend out dcla_apex_comparison_test.sh"" 2023-07-06 01:27:04 +00:00
Treehugger Robot
253054a175 Merge "Add comment for afdo flag" 2023-07-05 20:40:46 +00:00
Treehugger Robot
0b42c30273 Merge "Remove --skip-soong-tests from kzip builds" 2023-07-05 17:00:41 +00:00
Vinh Tran
056effb8b1 Add comment for afdo flag
Change-Id: If80df0ac0527784b13158325589c29587db8d5f9
Test: N/A
2023-07-05 15:48:21 +00:00
Liz Kammer
e58161b93f Remove --skip-soong-tests from kzip builds
Bug:289993105
Change-Id: I12d0a980141a9ef03a42c943ae92d19b717e7ff9
2023-07-05 12:27:49 +00:00
Yi Kong
b9d5046d8b Simplify LTO flags handling
... and add more comments about the use of --lto-O0.

Test: presubmit
Change-Id: I2ef7bf4f100a8d7559a6b738e9211c596d579dc6
2023-07-03 17:16:42 +09:00
Treehugger Robot
222995b2c1 Merge "don't export systemserverclasspath_fragment if contents are empty" 2023-07-01 00:07:12 +00:00
Treehugger Robot
ece97e5658 Merge "Suppress resourceshrinker stdout in soong" 2023-06-30 23:26:28 +00:00
Cole Faust
837c3b9a55 Revert "Commend out dcla_apex_comparison_test.sh"
This reverts commit a56663f695.

Reason for revert: Original breaking change was reverted

Change-Id: I8e0c97f0b511f686f5efdb8a9e8c9f862fc41010
2023-06-30 22:53:10 +00:00
Sam Delmerico
35881365b4 don't export systemserverclasspath_fragment if contents are empty
If a systemserverclasspath_fragment only contains libraries that have a
higher min_sdk_version than the target build release version, then we
should not export the systemserverclasspath_fragment. Before this
change, the fragment was exported with an empty `contents` property
which caused errors after being dropped as a prebuilt.

Bug: 289183551
Test: go test ./sdk
Change-Id: Ifefc6880228e4dd37f5e42b2bda31a83df785375
2023-06-30 15:25:16 -04:00
Treehugger Robot
c627847e1b Merge "Disable rust in Kythe builds for now" 2023-06-30 16:42:26 +00:00
Treehugger Robot
b54a3d08ac Merge "Don't use RBE for bp2build/queryview/api_bp2build/json_module_graph, even with USE_RBE=true." 2023-06-30 14:35:49 +00:00
Nicolas Geoffray
3799533b87 Merge "Don't strip oat files on host." 2023-06-30 10:49:50 +00:00
Treehugger Robot
043893465c Merge "Extract class files from dep_api_srcs instead of java files" 2023-06-30 09:36:42 +00:00
Jingwen Chen
d7ccde11d6 Don't use RBE for bp2build/queryview/api_bp2build/json_module_graph,
even with USE_RBE=true.

These are alternate modes of soong_build that don't use rbe/reclient.

This lets us to remove USE_RBE=false from the bp2build run.

Test: presubmits
Change-Id: I439f9cf7e92ec85ca56baec5f62a83ee49b510d4
2023-06-30 09:32:32 +00:00
Jingwen Chen
661b2ee719 Merge "Revert "add media.swcodec to Bazel prod allowlist"" 2023-06-30 04:23:40 +00:00
Treehugger Robot
bf815a135a Merge "Ensure we get cross refs for Bazel-built artifacts" 2023-06-30 02:22:27 +00:00
Jihoon Kang
ca198c2639 Extract class files from dep_api_srcs instead of java files
Currently, stub java files are extracted from srcjar file provided from
dep_api_srcs in java_api_library module generated in java_sdk_library
per api scope. However, compiling the java files may lead to difference
in the content of the generated class files even if the stub java files
are equivalent, as javac may arbitrarily add overridden methods. Thus,
create a stub jar file instead of creating a stub srcjar file and
compiling it, in order to guarantee stub jar files content equivalence
and thus enable hiddenapi during from-text stub build.

Note that this change does not fully resolve differences between the
full api surface csv and the per sdk_library csv. Instead, it removes
the difference caused by methods arbitrarily added by javac.

This change also renames dep_api_srcs to full_api_surface_stubs to be
more intuitive.

Test: rebase on top of aosp/2617274 and `m --build-from-text-stub`
Bug: 275570206
Change-Id: I22b6d56624633681f5c3b000370b5782655c7b8d
2023-06-29 22:43:05 +00:00
Trevor Radcliffe
061012475c Revert "add media.swcodec to Bazel prod allowlist"
This reverts commit b1274236e8.

Reason for revert: 
b/289418267

Change-Id: I0a94675e09a82b55d62e58dbeea0d3186c754ed3
2023-06-29 22:30:18 +00:00
Cole Faust
a56663f695 Commend out dcla_apex_comparison_test.sh
Is currently failing on ci, uncomment when fix is submitted.

Bug: 289141798
Test: Presubmits
Change-Id: Ic7b220f917cb0b9f0914d8e9575081004610cf63
2023-06-29 12:36:00 -07:00
Treehugger Robot
da169a1ee3 Merge "Fix FirstUniqueStrings after conversion to generics" 2023-06-29 18:46:20 +00:00