Commit Graph

44814 Commits

Author SHA1 Message Date
Treehugger Robot
e29c1e9a9c Merge "[LSC] Add LOCAL_LICENSE_KINDS to build/soong" am: cc1990f564
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1811859

Change-Id: I1f14f7e37557af3be87f8c322fc02d433cb79b4a
2021-08-27 21:56:22 +00:00
Christopher Ferris
6720a903c3 Merge "Make this script use python3." am: cd989defab
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1811857

Change-Id: Ia1d35a6f2204fd4d0649cfa18c8538e47b836100
2021-08-27 21:56:13 +00:00
Treehugger Robot
cc1990f564 Merge "[LSC] Add LOCAL_LICENSE_KINDS to build/soong" 2021-08-27 21:54:03 +00:00
Christopher Ferris
cd989defab Merge "Make this script use python3." 2021-08-27 21:42:09 +00:00
Romain Jobredeaux
51727abdad Merge "Set --noautodetect_server_javabase in mixed build bazel." am: e4447e4e97
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1811776

Change-Id: I839abc03e68b90dec195b22c6727278d1213a74a
2021-08-27 21:11:24 +00:00
Romain Jobredeaux
70905362b7 Merge "Exempt build/bazel/examples/java BUILD files from bp2build overwriting." am: 274aca4464
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1810537

Change-Id: I57698cb6e912ec33815bc3228af6be74b10aec92
2021-08-27 21:11:22 +00:00
Romain Jobredeaux
e4447e4e97 Merge "Set --noautodetect_server_javabase in mixed build bazel." 2021-08-27 20:53:47 +00:00
Romain Jobredeaux
274aca4464 Merge "Exempt build/bazel/examples/java BUILD files from bp2build overwriting." 2021-08-27 20:53:47 +00:00
Bob Badour
36dc7c60b5 [LSC] Add LOCAL_LICENSE_KINDS to build/soong
Added SPDX-license-identifier-Apache-2.0 to:
  java/core-libraries/Android.bp
  mk2rbc/Android.bp

Bug: 68860345
Bug: 151177513
Bug: 151953481

Test: m all

Exempt-From-Owner-Approval: janitorial work
Change-Id: Iaf8546fc945b04b71cd5cb1c7c16a9e15f608d02
2021-08-27 13:30:35 -07:00
Lukács T. Berki
7d82946f5f Merge "Print the JSON module graph correctly." am: b8e5cb0511
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1808900

Change-Id: I44b3b35f1694a55573a55ad088f431327fb37140
2021-08-27 19:56:54 +00:00
Lukács T. Berki
b8e5cb0511 Merge "Print the JSON module graph correctly." 2021-08-27 19:39:24 +00:00
Christopher Ferris
cce6d652c5 Make this script use python3.
There is nothing in this script that is not python3, so
make it python3. Without this, a system without python will
fail when trying to run gdbclient.py.

Test: Ran gdbclient.py on a system without a python executable.
Change-Id: I9f8418932628569c445ee01bc6f9ead8aed7989f
2021-08-27 11:54:19 -07:00
Romain Jobredeaux
41fd5e402f Set --noautodetect_server_javabase in mixed build bazel.
If a valid JAVA_HOME is set in the environment when running
bazel with --experimental_repository_disable_download, bazel
will unsuccessfully attempt to download rules_java. The above
flag has the practical effect of preventing the download attempt
(some clues as to why in the doc at go/aosp-bazel-jdk).

Note that this also prevents building java targets in mixed mode.
Eventually, we will pull in the java_rules into AOSP so they don't
need to be downloaded.

Test: build/bazel/ci/mixed_libc.sh
Change-Id: Icdb186c18a3334f4caa17243a8620a1cc8c1db0e
2021-08-27 17:34:16 +00:00
Romain Jobredeaux
5cc9c9d8e7 Exempt build/bazel/examples/java BUILD files from bp2build overwriting.
Test: b build build/bazel/examples/java/...
Change-Id: Iab4934d99f734979350742a3a14aca7899d4cada
2021-08-27 16:14:13 +00:00
Alex Márquez Pérez Muñíz Díaz Púras Thaureaux
f44f440665 python_{binary,library}{,_host} handle lib property am: 560cb6685c
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1811016

Change-Id: I1d4b7f3eef90d91e1a378015556e5bb5184849f3
2021-08-27 14:31:06 +00:00
Alex Márquez Pérez Muñíz Díaz Púras Thaureaux
560cb6685c python_{binary,library}{,_host} handle lib property
Have binary and library bp2build convert `libs` to
`deps` for bazel

Bug: 196083751
Test: python_{binary,library}_conversion_test.go
Test: build/bazel/ci/mixed_{libc,droid}.sh
Change-Id: I2d5f6ef2e83dd608910edb7adb2eb9a56d25293c
2021-08-27 14:10:33 +00:00
Lukacs T. Berki
e571dc3bd0 Print the JSON module graph correctly.
Before, we piggybacked on the implementation of regular soong_build and
wrote a fake build.ninja file to satisfy Ninja.

Now, instead, the JSON module graph is a a separate action in the Ninja
output file. This has the pleasant side effect that one can flip back
and forth between generating the JSON file and regular Soong without
loss of incrementality.

Side cleanup: write .d files in a slightly cleaner way.

Test: Presubmits.
Change-Id: Ia853383567b9dd31c53f3bdf56cfc8d517b498ec
2021-08-27 15:55:51 +02:00
Lukács T. Berki
8526bc95ef Merge "Rename BuildDir and NinjaBuildDir." am: 5602d33025
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1810356

Change-Id: I6af3316fb122af7a05b71de7f9cd371746bb5f21
2021-08-27 13:54:13 +00:00
Lukács T. Berki
5602d33025 Merge "Rename BuildDir and NinjaBuildDir." 2021-08-27 13:39:11 +00:00
Nicolas Geoffray
9e1902daca Merge "Add exclude_runtime_libs to more targets." am: 7e4c05fcc8
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1810756

Change-Id: I170171b9b1edc4551e2c89452c49ed1274b0267f
2021-08-27 11:43:58 +00:00
Nicolas Geoffray
7e4c05fcc8 Merge "Add exclude_runtime_libs to more targets." 2021-08-27 11:33:39 +00:00
Lukacs T. Berki
9f6c24a887 Rename BuildDir and NinjaBuildDir.
These are just out/ and out/soong/ and the old names were quite
confusing.

Test: Presubmits.
Merged-In: I999ca62162062f27e449f83ffb00fa580d4065b8
Merged-In: I2fcd80a9e376a6842a06aa104a9f6f5c5e16f8c7
Change-Id: Ib481d2aac40df8da1b74174dc8ec576c1cb48be0
2021-08-27 10:08:49 +02:00
Treehugger Robot
a88fc3e79e Merge "Make bpfs properties overridable" am: 60dc5c0db2
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1810456

Change-Id: Ib8196d660983d724e4ecde5c08a9ab2da979df99
2021-08-27 05:07:16 +00:00
Treehugger Robot
60dc5c0db2 Merge "Make bpfs properties overridable" 2021-08-27 04:57:10 +00:00
Treehugger Robot
f5a2c80d1f Merge "Apply pylint to conv_linker_config.py" am: 5edc77d06c
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1809499

Change-Id: Ic5f5060862fd03efff5b6e9b173151aa15c8778b
2021-08-27 04:13:31 +00:00
Treehugger Robot
5edc77d06c Merge "Apply pylint to conv_linker_config.py" 2021-08-27 04:04:14 +00:00
markchien
7c803b8746 Make bpfs properties overridable
To support different variable bpfs file between mainline module and
non-updatable module(e.g. Android GO). Make bpfs properties overridable.

Test: m
Bug: 190523685
Change-Id: I4c63e35f74230de94b21f3ceb2beb90f0f9ddb11
2021-08-27 03:03:45 +00:00
Matthew Maurer
280760b701 rust: Add UWB to allowlist am: 80f0eb1e01
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1811036

Change-Id: I56929af2e36c1a588f9dc51eb42dc7eb4e39ae44
2021-08-26 22:20:12 +00:00
Matthew Maurer
80f0eb1e01 rust: Add UWB to allowlist
Change-Id: Ic89e274412c97631f615e6e9ccd711e9300397d1
Test: None
2021-08-26 20:38:16 +00:00
Treehugger Robot
fae3bd3531 Merge "Apply pylint to scripts/construct_context*.py" am: af44faad9f
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1809636

Change-Id: Ic2b0fff730afd30c7045552c81dd469d5b9232e7
2021-08-26 16:59:50 +00:00
Treehugger Robot
a3037d1239 Merge "Keep existing BUILD files for bazel_common_rules" am: 9da0a435ef
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1807117

Change-Id: Ief2269eaa089bc5aa9c4c8185c99b3ae452fed35
2021-08-26 16:59:41 +00:00
Treehugger Robot
af44faad9f Merge "Apply pylint to scripts/construct_context*.py" 2021-08-26 16:57:10 +00:00
Spandan Das
1d4bfd8ca4 Apply pylint to conv_linker_config.py
1. Run pyformat scripts/conv_linker_config.py -s 4 --force_quote_type none -i to fix formatting
2. Annotate #pylint: disable=import-error for linker_config_pb2 since it
will be provided by soong

Test: m conv_linker_config
Test: pylint --rcfile tools/repohooks/tools/pylintrc
build/soong/scripts/conv_linker_config.py
Bug: 195738175

Change-Id: I791576cf65cb053f68c804f8ec5c2fc22976fdb4
2021-08-26 16:48:59 +00:00
Treehugger Robot
9da0a435ef Merge "Keep existing BUILD files for bazel_common_rules" 2021-08-26 16:41:30 +00:00
Martin Stjernholm
3aa9544ec1 Add exclude_runtime_libs to more targets.
Test: `m droid` with https://r.android.com/1810717
Bug: 197856821
Change-Id: I4c93ae4b1f686796827a9635ba4ed50db00e6a8c
2021-08-26 17:29:49 +01:00
Alex Márquez Pérez Muñíz Díaz Púras Thaureaux
96fd2fe208 Add python_library_host -> py_library bp2build support am: dc212c0b24
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1807776

Change-Id: I88e7c5d5e7db86cd7976eb19c8161930228e1004
2021-08-26 16:15:34 +00:00
Alex Márquez Pérez Muñíz Díaz Púras Thaureaux
dc212c0b24 Add python_library_host -> py_library bp2build support
Bug: 196081770
Test: bp2build/python_library_conversion_test.go
Test: build/bazel/ci/mixed_{libc,droid}.sh
Change-Id: I4da9938eb0b039f97b83badd2269af153c7edbcc
2021-08-26 16:03:34 +00:00
Colin Cross
8dae8cbcc1 Merge "Support musl builds in Make" am: b37a92ccc8
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1797129

Change-Id: I771db86c62207bde3e4ba60569e4d3ebbfe32358
2021-08-26 01:27:24 +00:00
Colin Cross
b37a92ccc8 Merge "Support musl builds in Make" 2021-08-26 01:14:47 +00:00
Spandan Das
ec555f1a99 Apply pylint to scripts/construct_context*.py
1. Run pyformat scripts/construct_context.py -s 4 --force_quote_type
none -i to fix formatting
2. Wrap #pylint: [disable|enable]=line-too-long in tests

Test: m construct_context construct_context_test
Test: pylint --rcfile tools/repohooks/tools/pylintrc
build/soong/scripts/construct_context.py
build/soong/scripts/construct_context_test.py
Bug: 195738175

Change-Id: I2e756b17aae3e70ddaa03356c78f1f2f85c0f6a5
2021-08-26 01:06:48 +00:00
Jiyong Park
b4adefa58e Merge changes I15328e0b,I731227c2 am: 19312d4224
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1808218

Change-Id: I58224f0fc056f174567241a13d9eb54dbaef5d12
2021-08-25 22:48:34 +00:00
Jiyong Park
19312d4224 Merge changes I15328e0b,I731227c2
* changes:
  crt objects for APEX and vendor variants have correct target API levels
  crt modules produces cc rules for testing
2021-08-25 22:30:40 +00:00
Alex Márquez Pérez Muñíz Díaz Púras Thaureaux
620ec23ca0 Merge "Add python_library -> py_library bp2build support" am: bb1fd68495
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1807636

Change-Id: Ibe68940c69f96b2d5ce82c6dff3ccf3393351547
2021-08-25 20:35:07 +00:00
Alex Márquez Pérez Muñíz Díaz Púras Thaureaux
bb1fd68495 Merge "Add python_library -> py_library bp2build support" 2021-08-25 20:25:42 +00:00
Alex Márquez Pérez Muñíz Díaz Púras Thaureaux
0fc781c7c2 Add python_library -> py_library bp2build support
Bug: 196091681
Test: bp2build/python_library_conversion_test.go
Test: build/bazel/ci/mixed_{libc,droid}.sh
Change-Id: Ice87d75533c97fd9c139dc59de09a039e2713a01
2021-08-25 15:57:01 +00:00
Florian Mayer
f38f955bdb Merge "Use new pass manager for HWASan builds." am: 35fc86c9cf
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1802330

Change-Id: Ieaef02fc55baa0fd76c79659192a29fde5876d73
2021-08-25 10:57:59 +00:00
Florian Mayer
35fc86c9cf Merge "Use new pass manager for HWASan builds." 2021-08-25 10:39:37 +00:00
Jiyong Park
5df7bd33f7 crt objects for APEX and vendor variants have correct target API levels
Previously, crt objects for APEX and vendor variants targetted API level
16 regardless of their context. For example, even if BOARD_VNDK_VERSION
is set to 29, or an APEX has `min_sdk_version: "29"`, the target API
level was from `min_sdk_version` property of the crt object which is set
to 16.

The meaning of min_sdk_version is quite different when it comes to crt
objects. It means the lowest API level that it CAN target for. It does
NOT mean the API level it SHOULD always target.

This has caused some other problems like TLS segment underalignment for
vendor libraries because the vendor libraries were all built with TLS
layout from API level 16.

This change fixes the problem by correctly implementing the different
semantic of min_sdk_version for crt objects.

Bug: N/A
Test: m nothing

Change-Id: I15328e0b6cbabbe151dd65c7469c6355e167b78a
2021-08-25 16:26:47 +09:00
Jiyong Park
7549d460f0 crt modules produces cc rules for testing
Previously, crt modules didn't produce cc rules because they didn't have
any input src files set. This prevented us from having a test which
checks the cflags of the crt modules.

Fixing that by adding source file to the crt modules. crtbrand is also
added as an 'objs' dep, because otherwise partialLd rules won't be
generated.

Bug: N/A
Test: m nothing
Change-Id: I731227c20c662c876c40f0c41e1769a271e2c643
2021-08-25 16:16:03 +09:00
Sophie Zheng
5e640b6b45 Merge "Also generate api lists based on symbol files for cc_library rule during build time." am: d9287b6c35
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1797135

Change-Id: Ie272b922a62dbb655535fef3a4c1888d4019cedb
2021-08-25 04:29:18 +00:00