285 Commits

Author SHA1 Message Date
Bill Yang
7afafe4eea Export TARGET_BOARD_PLATFORM to soong
Bug: 369980366
Test: lunch aosp_cheetah-trunk_staging-userdebug; \
      m memtrack.gs201
Change-Id: Icf89ec1de42ba6a95622bba3f2cf130c316837f1
2025-02-18 09:44:16 +08:00
Bill Yang
d36230676e Export libacryl related flags to soong
Export BOARD_LIBACRYL_DEFAULT_COMPOSITOR, BOARD_LIBACRYL_DEFAULT_SCALER,
BOARD_LIBACRYL_DEFAULT_BLTER, and BOARD_LIBACRYL_G2D_HDR_PLUGIN to
soong. Also export one include path to sooong but check if the path
exist before export to soong due to soong does not allowed non-existed
path.

Bug: 370414334
Test: m libacryl
Change-Id: Ib7f7af43da0359e691dee8bd538664147704c648
2025-02-18 09:44:10 +08:00
Bill Yang
4367d5a8f3 Export ril related flag to soong
Export SIM_COUNT, DISABLE_RILD_OEM_HOOK and ENABLE_VENDOR_RIL_SERVICE
to soong

Bug: 347679222
Test: m libril libreference-ril rild
Change-Id: Ic1f8262f260c3fec70635809acf80d340502a77c
2025-02-18 09:44:03 +08:00
Cole Faust
52273b16fa Add soong_config_set_bool
To allow typing soong config variables as bools for using in soong
select expressions.

Bug: 323382414
Test: m nothing --no-skip-soong-tests
Change-Id: I39496cd2a3366689e3f232ba10353a7d56d8d1ed
2025-02-11 23:32:48 +08:00
Treehugger Robot
04d2989388 Merge "Export USE_CAMERA_V4L2_HAL to soong" into main am: 48a08682fa am: 8f91d9801d
Original change: https://android-review.googlesource.com/c/platform/build/+/3256421

Change-Id: Ic415d2e7b964b0fc470895078bba08c3fc603efc
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-09-19 01:45:05 +00:00
Treehugger Robot
48a08682fa Merge "Export USE_CAMERA_V4L2_HAL to soong" into main 2024-09-19 01:14:21 +00:00
Yu-Ting Tseng
4688186da8 flag guarded move of uprobestats into Mainline
Bug: 355315669
Test: m
Ignore-AOSP-First: uprobestats is an internal-first project
Change-Id: Ifc74630a56a0be8669f0fb56ba6c8ba5f6435fc6
2024-09-13 09:32:36 -07:00
Treehugger Robot
c170e080a2 Merge "Add a new Soong config variable EMMA_INSTRUMENT" into main am: 1d09815d07 am: 44b86ab2c2
Original change: https://android-review.googlesource.com/c/platform/build/+/3247731

Change-Id: Ib4c6f9e8bd8d7c5da59a00c5830ecc1dc0bef697
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-09-12 03:21:06 +00:00
Bill Yang
ab5457c038 Export USE_CAMERA_V4L2_HAL to soong
Export the variable for hardware/libhardware/modules/camera/3_4:camera.v4l2

Bug: 349300092
Test: lunch aosp_cheetah-trunk_staging-userdebug; \
      USE_CAMERA_V4L2_HAL=true m camera.v4l2 camera.v4l2_test

Change-Id: I590e5218dbe51af004a15d2da4456da7515e72dc
2024-09-10 03:39:50 +00:00
Nelson Li
3114519c89 Add a new Soong config variable EMMA_INSTRUMENT
This change introduces a new Soong config variable named
`EMMA_INSTRUMENT`. This variable mirrors the behavior of the existing
`EMMA_INSTRUMENT` condition in Android.mk files, allowing for
conditional build configurations based on whether EMMA instrumentation
is enabled.

Bug: 342330305
Test: 1) EMMA_INSTRUMENT=true m ahat-tests
      2) m -j ahat-tests
Change-Id: I7bc28cd3de936d1e6bfb218683bcf07b40e80784
2024-08-28 11:55:21 +00:00
Treehugger Robot
7d6ec4fb0b Merge "Remove module_build_from_source soong config variable" into main am: 5ab8f4a84b am: 32ae3f892b
Original change: https://android-review.googlesource.com/c/platform/build/+/3216810

Change-Id: I99599f55076f6d23d6a3514b2543e3d556429576
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-08-14 01:17:46 +00:00
Spandan Das
8a58e78f9e Remove module_build_from_source soong config variable
This value is a noop in V+ trees. It was previously used as one of the
inputs for source vs prebuilts selection of mainline modules.

Bug: 308187800
Test: presubmits
Change-Id: I24432a982b6fadd3e7a1a89c730c8ccc0abb4709
2024-08-13 23:11:15 +00:00
Treehugger Robot
05a9a0e6b4 Merge "Export related make variables for gralloc.default to soong" into main am: b3984cac84 am: 7f937c4bd2
Original change: https://android-review.googlesource.com/c/platform/build/+/3211281

Change-Id: I43729d8cc69347434d97ad951d10b1778f7f4421
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-08-09 03:23:36 +00:00
yangbill
43c861469d Export related make variables for gralloc.default to soong
Bug: 356533884
Test: ./prebuilts/build-tools/linux-x86/bin/py3-cmd build/bazel/ci/rbc_dashboard.py --quick
Change-Id: I05849a6f20aae807d47c9cf46d127234d53c36e8
2024-08-08 07:35:58 +00:00
Jordan Silva
886249bfdf Add a soong flag to use Compose in Launcher (1/3)
This will allow us to add/remove Compose dependencies from Launcher during the build. It prevents landing the dependencies without having any feature using it.

Ignore-AOSP-First: in topic with internal-first/internal-only projects

Bug: 346288480
Flag: EXEMPT We added a build flag. Soong flag: release_enable_compose_in_launcher. Gantry Build flag: RELEASE_ENABLE_COMPOSE_IN_LAUNCHER.
Test: Builds
Change-Id: Ie2dabc98977dfb267a9bc7934354a72052c6664d
2024-08-05 23:36:05 +00:00
Treehugger Robot
9b6324bf40 Merge "Add art_build_host_debug to soong config variable" into main 2024-08-02 04:50:44 +00:00
Inseob Kim
ef566ac4f6 Reland "Add variables for init.environ.rc"
Relanding with a fix for hwasan build.
HWADDRESS_SANITIZER_GLOBAL_OPTIONS is set by Soong's MakeVars, so we
can't refer the variable on soong config modules. Instead, as the
variable is hard-coded, this change hard-codes options in Android.bp.

Bug: 353429422
Test: boot shiba with SANITIZE_TARGET=hwaddress
Change-Id: Idaf4417e3f51c1933264866799c211de7bd0821d
2024-08-01 03:31:28 +00:00
Liana Kazanova
f2289bfdd2 Revert "Add variables for init.environ.rc"
Revert submission 3197177-init_environ_rc_soong

Reason for revert: DroidMonitor: Potential culprit for b/356587212 - verifying through ABTD before revert submission. This is part of the standard investigation process, and does not mean your CL will be reverted.

Reverted changes: /q/submissionid:3197177-init_environ_rc_soong

Change-Id: I7cfe54a994179577a7f3e3f86618ff04980aaf35
2024-07-31 17:56:40 +00:00
Inseob Kim
6808b94f6d Add variables for init.environ.rc
Bug: 353429422
Test: boot cuttlefish
Change-Id: If46706c6fd89b5da2e56a84f1f7de946bdc74cb9
2024-07-30 17:48:06 +09:00
Nelson Li
bdab1b5329 Add art_build_host_debug to soong config variable
The `ART_BUILD_HOST_DEBUG` environment variable is frequently used in
Android.mk files within the art/ directory. By adding it to
soong_config_variable, we make it accessible to the Soong build system,
which will be essential when converting art modules to Android.bp.

Bug: 347142939
Test: 1) m -j art-libartd-libopenjdkd-host-dependency
      2) ART_BUILD_HOST_DEBUG=false m -j art-libartd-libopenjdkd-host-dependency
      3) cd art && mm/mmm/mmma, then, check `libopenjdkd` be built.
Change-Id: I20401f29a1636b98dd8fc2dc4e679d1832a89435
2024-07-26 15:28:46 +08:00
Nelson Li
e63be2a724 Add HOST_PREFER_32_BIT to Soong Config and move art-tools to product configuration.
This change accomplishes two things:

Adds `HOST_PREFER_32_BIT` to Soong config variables:
The `HOST_PREFER_32_BIT` environment variable is frequently used in
Android.mk files within the art/ directory. By adding it to
soong_config_variable, we make it accessible to the Soong build system,
which will be essential when converting art modules to Android.bp.

Moves `art-tools` to product configuration:
Originally, `art-tools` was a phony target added to
PRODUCT_HOST_PACKAGES. This approach is incorrect because
PRODUCT_HOST_PACKAGES should only contain actual modules, not phony
targets. We are addressing this by converting the dependencies and
conditional statements (ifeq) within `art-tools` into
PRODUCT_HOST_PACKAGES entries in base_system.mk.

Bug: 346702835
Test: m -j; Then, check related dependencies build in the system.
Change-Id: Iab252dea71c9df9d75f2701b33d3cd4d391e7f5d
2024-07-26 12:57:41 +08:00
Treehugger Robot
3d99e42579 Merge "Add soong config for early VM" into main 2024-07-24 04:54:24 +00:00
Treehugger Robot
eb41879e1f Merge "Add BOARD_PERFSETUP_SCRIPT as a soong config variable" into main 2024-07-24 01:25:40 +00:00
yangbill
90b90af5f6 Add BOARD_PERFSETUP_SCRIPT as a soong config variable
This variable is used to customize different perf script used by
perf-setup under platform_testing/scripts/perf-setup/.
This CL also add perf-setup.sh by default installed for eng and
userdebug build.

Bug: 343133111
Test: . build/envsetup.sh; lunch aosp_akita-trunk_staging-userdebug;\
      m perf-setup
Test: . build/envsetup.sh; lunch aosp_panther-trunk_staging-userdebug; \
      m perf-setup
Test: . build/envseup.sh; lunch aosp_cf_x86_64_phone-trunk_staging-userdebug; \
      m perf-setup
Change-Id: I0f81f5296aa59bef5b5d608a6cfda6d8b05b4e0f
2024-07-23 02:49:41 +00:00
Inseob Kim
42ed91a914 Add soong config for early VM
Bug: 354059066
Test: build
Change-Id: I0efc023b307694809b68f1e84a649c1578eca313
2024-07-23 11:18:41 +09:00
Treehugger Robot
60f44e93a8 Merge "Add ASAN_ENABLED and SANITIZE_TARGET_SYSTEM_ENABLED to Soong config variables:" into main 2024-07-18 05:52:52 +00:00
Nelson Li
39f5cc4153 Add ASAN_ENABLED and SANITIZE_TARGET_SYSTEM_ENABLED to Soong config variables:
`SANITIZE_TARGET` is a variable in Android's build system used to
enable sanitizers. Currently, Soong only supports enabling SANITIZE for
individual modules in Android.bp.
Adding ASAN_ENABLED and SANITIZE_TARGET_SYSTEM_ENABLED as Soong config
variables would allow Soong to also support building with Sanitizers by
directly setting the SANITIZE_TARGET environment variable.

Bug: 353164536
Test: SANITIZE_TARGET_SYSTEM=true SANITIZE_TARGET=address m -j asan_extract
Change-Id: I542239ee25d210d903d2481a2b1426f756656308
2024-07-17 16:56:58 +08:00
Nelson Li
12c7751ff2 Add BOARD_MOVE_GSI_AVB_KEYS_TO_VENDOR_BOOT as a soong config variable
This variable allow customizing whether the `ramdisk` and
`vendor_ramdisk` are included in the boot image (ramdisk) or the
vendor boot image (vendor_ramdisk). This is useful for devices that
move recovery resources to the vendor boot partition

Bug: 347636127
Test: Add it to soong_config_module_type
Change-Id: If7a126fe8bdc69173921c0b01f85fb9480f4a36f
2024-07-17 12:02:59 +08:00
Nelson Li
ab9e6521c2 Change BOARD_USES_RECOVERY_AS_BOOT to a Boolean type
Set `BOARD_USES_RECOVERY_AS_BOOT` to a Boolean type and use the
`select` syntax in Android.bp.
This usage is more concise and easier to understand compared to
`soong_config_module_type`.

Bug: 347605145
Test: m init_vendor
Change-Id: I551b560688c9bd792e3b9cadcdfc01b4e0215823
2024-06-25 02:49:47 +00:00
Cole Faust
95ff089b84 Add soong_config_set_bool
To allow typing soong config variables as bools for using in soong
select expressions.

Bug: 323382414
Test: m nothing --no-skip-soong-tests
Change-Id: I39496cd2a3366689e3f232ba10353a7d56d8d1ed
2024-06-20 14:51:39 -07:00
Cole Faust
318fc99a13 Merge "Add PLATFORM_SEPOLICY_VERSION as a soong config variable" into main 2024-06-18 18:05:42 +00:00
Cole Faust
f4ad02f818 Add PLATFORM_SEPOLICY_VERSION as a soong config variable
So that it can be used in android.bp files. This is to replace the
existing usages of PLATFORM_SEPOLICY_COMPAT_VERSIONS.

Bug: 347605145
Bug: 342006386
Test: m nothing --no-skip-soong-tests
Change-Id: Ia2831fa2c77b2f55d4e39e48b71acf13c605bf1e
2024-06-17 12:38:41 -07:00
Vilas Bhat
c39e47f792 Merge "Propagate libpower no lock during binder transaction flag to soong" into main am: eae45e70ca
Original change: https://android-review.googlesource.com/c/platform/build/+/3107745

Change-Id: Id7c5484f3b09a6747c3d5da5338109931d968f74
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-06 04:13:37 +00:00
Vilas Bhat
eae45e70ca Merge "Propagate libpower no lock during binder transaction flag to soong" into main 2024-06-06 03:55:52 +00:00
Vilas Bhat
e8bec60526 Propagate libpower no lock during binder transaction flag to soong
Bug: 343527537
Test: (On internal branch)
      lunch, make and flash Pixel 8 target
      atest libpower_test
Change-Id: I8fabec0919e180b0e3c65f06280032fc5eea37dc
2024-06-03 22:25:20 +00:00
Nate Myren
c39dc6a8d7 Merge "Set appcompat system properties flag if userdebug/eng" into main am: 7de8a01cc1
Original change: https://android-review.googlesource.com/c/platform/build/+/3107744

Change-Id: Iffb914e72be4c1c69bd59f5b2caec5aad28e55f3
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-05-31 01:38:56 +00:00
Nate Myren
eb2648eacc Set appcompat system properties flag if userdebug/eng
Bug: 331307495
Test: m
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:c7d08b74321a355c5a5daefdb899d1ac63b861fa)
Merged-In: I7d3080487b60536f5948ab1482a3fd4aee8371d4
Change-Id: I7d3080487b60536f5948ab1482a3fd4aee8371d4
2024-05-30 19:03:56 +00:00
Alice Wang
e73a902801 Merge "Allow AVF remote attestation to be disabled" into main am: 9347e36e33
Original change: https://android-review.googlesource.com/c/platform/build/+/3092139

Change-Id: I1ce6dfb7f4fe21f0e6b0e84d0ea7e1a3dee1e461
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-05-27 08:57:16 +00:00
Xin Li
b04e9cc36f Merge Android 24Q2 Release (ab/11526283) to aosp-main-future
Bug: 337098550
Merged-In: I713a528d437e3446d32461add648e3b52b036d7a
Change-Id: I7fdd415a218d1425f7fc37095d02c674ddfae6eb
2024-05-24 08:30:06 -07:00
Alice Wang
28a57dc1cc Allow AVF remote attestation to be disabled
This CL adds a variable in makefile that allows the
AVF remote attestation feature to be disabled easily.

The remote attestation feature is opt-in by default, as it
is a strongly recommended feature from Android V. It will
be disabled if PRODUCT_AVF_REMOTE_ATTESTATION_DISABLED is
set to true in the Makefile, otherwise it will be enabled
when the feature flag
RELEASE_AVF_ENABLE_REMOTE_ATTESTATION is on.

Bug: 331269709
Bug: 341292601
Test: run VM remote attestation on Pixel 6 and check it is
disabled

Change-Id: Id48ebd0eacf0d7a6c69b9100aee5ab6e4f112fe5
2024-05-24 09:22:41 +00:00
Seungjae Yoo
0475d91f16 Introduce RELEASE_AVF_ENABLE_NETWORK build flag into Soong
Bug: 340376951
Test: Presubmit
Change-Id: I5ac003ca7656f74e6a10aa8317c1443a28138a4d
2024-05-14 14:35:32 +09:00
Spandan Das
9429bf9074 Building mainline modules from source is now the default
RELEASE_APEX_CONTRIBUTIONS_* flags per module will be used to toggle
between sources and prebuilts of a mainline module in ap3a and above in
internal and partner builds.

Test: git_aosp-main-with-phones:aosp_cf_arm64_only_phone-next-userdebug
https://android-build.corp.google.com/builds/abtd/run/L61500030003577619

Test: lunch gsi_partner_arm-ap31-userdebug in v-aml-prebuilt-dev
Test: m out/soong/prebuil_info.json # identical before and after

Bug: 308188056
Change-Id: I308f071763297eb95ca5c8fb0191c8bb794789f7
2024-05-06 20:01:12 +00:00
Spandan Das
1dcca5239a Drop ART_MODULE_BUILD_FROM_SOURCE
RELEASE_APEX_CONTRIBUTIONS_ART provides a similar functionality, and
also allows selection of a specific art prebuilt if multiple art
prebuilts exists in the tree

`art_module.source_build` was also previously used to conditionally
disable the source soong modules of art/, but this conditional disabling
has been removed with r.android.com/3045792

Bug: 308188056
Test: presubmits
Test: lunch cf_x86_64_phone-trunk_staging-userdebug; mmma art
Test: git_master-art:art-host-x86_64,art-target-arm64,mainline_modules
https://android-build.corp.google.com/builds/abtd/run/L30200030003163172
Test: git_master-art-host:art-build,art-gtest,art-test,art-preopt
https://android-build.corp.google.com/builds/abtd/run/L07600030003164399

Change-Id: Idbb129d2ec304d5320754cd61d40e10e5c7d5414
2024-05-03 02:27:39 +00:00
Spandan Das
4049cdb23a Revert "Drop cmdgoals special case from prebuilt selection"
This reverts commit e18b9fee63.

Reason for revert: Likely causing build failures for go/ab/git_aosp-main-with-phones

Change-Id: If01f58908bd66c7afa42b9c96d048dfcd2d70812
2024-04-26 23:08:10 +00:00
Spandan Das
e18b9fee63 Drop cmdgoals special case from prebuilt selection
Before trunk stable, this check ensured that `docs` and `sdk` builds
contained all the apis provided by an apex. If source apex was used, it
would use the source java_sdk_library. If prebuilt apex was used, it
would use the prebuilt java_sdk_library.

After trunk stable, all release configurations for platform development
use the everything stubs of source java_sdk_library for javac, and
exportable stubs of source java_sdk_library for sdk/docs. The exportable
stubs is aware of the enabled flags for a specific release
configuration.

Since sdk and docs builds use the exportable stubs, we can drop this
special case to use the prebuilt stubs/srcjar files.

Test: presubmits
Test: in internal, lunch cf_x86_64_phone-next-userdebug (currently uses
bt prebuilts)
Test: m docs
Test: aninja -t path docs
out/soong/.intermediates/packages/modules/Bluetooth/framework/framework-bluetooth.stubs.source/android_common/exportable/framework-bluetooth.stubs.source-stubs.srcjar;
still exists after this cl

Bug: 308188056

Change-Id: I65da9f25634f0e8c3d514a4c175f89c3e5eb9712
2024-04-26 20:50:50 +00:00
Treehugger Robot
83f8fb1643 Merge "Add appcompat system properties flag to soong" into main 2024-04-24 22:35:37 +00:00
Treehugger Robot
7123699d09 Merge "Drop INDIVIDUALLY_TOGGLEABLE_PREBUILT_MODULES" into main 2024-04-24 01:30:43 +00:00
Spandan Das
8ec0862bdd Drop INDIVIDUALLY_TOGGLEABLE_PREBUILT_MODULES
This list is used to create soong config namespaces per toggle-able
module, and set source_build property. internal and partner branches now
use RELEASE_APEX_CONTRIBUTIONS_* for source vs selection, so remove this
mechanism to prevent confusing behaviors when these two mechanisms have
conflicting values.

`art_module.source_build` is a special-case which uses an additional variable
`ART_MODULE_SOURCE_BUILD`. This will be tracked in
https://r.android.com/3037396

Bug: 308188056
Test: presubmits
Test: downloaded this CL in v-aml branch, m
out/soong/prebuilt_info.json; file is identical

Merged-In: I3f9cbb24d6f3a7a0312683906826708147f469ee
Change-Id: I3f9cbb24d6f3a7a0312683906826708147f469ee
2024-04-24 00:44:59 +00:00
Treehugger Robot
96407369b1 Merge "Add soong config variables for selinux" into main 2024-04-23 01:14:44 +00:00
Nate Myren
eed5dcf31e Add appcompat system properties flag to soong
Bug: 331307495
Test: m
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:7e5f93f3cccdc38a25e6b9304752f0b2f7f8b0b9)
Merged-In: I554c499f6239e62c33640a81d9da73545fc7631b
Change-Id: I554c499f6239e62c33640a81d9da73545fc7631b
2024-04-19 19:07:40 +00:00