aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorandroid-build-team Robot <android-build-team-robot@google.com>2021-01-13 21:05:01 +0000
committerandroid-build-team Robot <android-build-team-robot@google.com>2021-01-13 21:05:01 +0000
commit7e085e33020c1c311111cf6b0fb3a9329c1fb640 (patch)
tree74fca80e686a63132e6fa1b1b90bfdd1d27f094a
parentdab5f8e7e0846925fc3c39f2b34e431d29a54b68 (diff)
parent8aec0e51b93487f775a05f061d453365c95b42ae (diff)
downloadbuild-android11-mainline-release.tar.gz
Change-Id: I1887abf4205d5123ab2719609bcea958c762cf55
-rw-r--r--core/dex_preopt_config.mk2
-rw-r--r--core/version_defaults.mk2
-rw-r--r--rbesetup.sh37
-rw-r--r--target/board/BoardConfigModuleCommon.mk6
-rw-r--r--target/board/module_arm/BoardConfig.mk22
-rw-r--r--target/board/module_arm/README.md2
-rw-r--r--target/board/module_arm/device.mk18
-rw-r--r--target/board/module_arm64/BoardConfig.mk27
-rw-r--r--target/board/module_arm64/README.md3
-rw-r--r--target/board/module_arm64/device.mk19
-rw-r--r--target/board/module_x86/BoardConfig.mk20
-rw-r--r--target/board/module_x86/README.md2
-rw-r--r--target/board/module_x86/device.mk18
-rw-r--r--target/board/module_x86_64/BoardConfig.mk24
-rw-r--r--target/board/module_x86_64/README.md3
-rw-r--r--target/board/module_x86_64/device.mk19
16 files changed, 219 insertions, 5 deletions
diff --git a/core/dex_preopt_config.mk b/core/dex_preopt_config.mk
index ccf53f5229..c154f56bcf 100644
--- a/core/dex_preopt_config.mk
+++ b/core/dex_preopt_config.mk
@@ -1,7 +1,7 @@
DEX_PREOPT_CONFIG := $(SOONG_OUT_DIR)/dexpreopt.config
# The default value for LOCAL_DEX_PREOPT
-DEX_PREOPT_DEFAULT ?= true
+DEX_PREOPT_DEFAULT ?= $(ENABLE_PREOPT)
# The default filter for which files go into the system_other image (if it is
# being used). Note that each pattern p here matches both '/<p>' and /system/<p>'.
diff --git a/core/version_defaults.mk b/core/version_defaults.mk
index e610490f44..9c7ac2c8f5 100644
--- a/core/version_defaults.mk
+++ b/core/version_defaults.mk
@@ -240,7 +240,7 @@ ifndef PLATFORM_SECURITY_PATCH
# It must be of the form "YYYY-MM-DD" on production devices.
# It must match one of the Android Security Patch Level strings of the Public Security Bulletins.
# If there is no $PLATFORM_SECURITY_PATCH set, keep it empty.
- PLATFORM_SECURITY_PATCH := 2021-02-05
+ PLATFORM_SECURITY_PATCH := 2021-03-05
endif
.KATI_READONLY := PLATFORM_SECURITY_PATCH
diff --git a/rbesetup.sh b/rbesetup.sh
index 25a1703075..8f65b2924d 100644
--- a/rbesetup.sh
+++ b/rbesetup.sh
@@ -1,4 +1,31 @@
-source build/envsetup.sh
+function _source_env_setup_script() {
+ local -r ENV_SETUP_SCRIPT="build/make/envsetup.sh"
+ local -r TOP_DIR=$(
+ while [[ ! -f "${ENV_SETUP_SCRIPT}" ]] && [[ "${PWD}" != "/" ]]; do
+ \cd ..
+ done
+ if [[ -f "${ENV_SETUP_SCRIPT}" ]]; then
+ echo "$(PWD= /bin/pwd -P)"
+ fi
+ )
+
+ local -r FULL_PATH_ENV_SETUP_SCRIPT="${TOP_DIR}/${ENV_SETUP_SCRIPT}"
+ if [[ ! -f "${FULL_PATH_ENV_SETUP_SCRIPT}" ]]; then
+ echo "ERROR: Unable to source ${ENV_SETUP_SCRIPT}"
+ return 1
+ fi
+
+ # Need to change directory to the repo root so vendor scripts can be sourced
+ # as well.
+ local -r CUR_DIR=$PWD
+ \cd "${TOP_DIR}"
+ source "${FULL_PATH_ENV_SETUP_SCRIPT}"
+ \cd "${CUR_DIR}"
+}
+
+# This function needs to run first as the remaining defining functions may be
+# using the envsetup.sh defined functions.
+_source_env_setup_script || return
# This function prefixes the given command with appropriate variables needed
# for the build to be executed with RBE.
@@ -28,7 +55,7 @@ function use_rbe() {
# ANDROID_ENABLE_METRICS_UPLOAD.
function _export_metrics_uploader() {
local uploader_path="$(gettop)/vendor/google/misc/metrics_uploader_prebuilt/metrics_uploader.sh"
- if [ -x "${uploader_path}" ]; then
+ if [[ -x "${uploader_path}" ]]; then
export ANDROID_ENABLE_METRICS_UPLOAD="${uploader_path}"
fi
}
@@ -37,7 +64,11 @@ function _export_metrics_uploader() {
# executed by RBE. This file should be sourced once per checkout of Android code.
function _set_rbe_vars() {
export USE_RBE="true"
- export RBE_CXX_EXEC_STRATEGY="remote_local_fallback"
+ export RBE_CXX_EXEC_STRATEGY="racing"
+ export RBE_JAVAC_EXEC_STRATEGY="racing"
+ export RBE_R8_EXEC_STRATEGY="racing"
+ export RBE_D8_EXEC_STRATEGY="racing"
+ export RBE_use_unified_cas_ops="true"
export RBE_JAVAC=1
export RBE_R8=1
export RBE_D8=1
diff --git a/target/board/BoardConfigModuleCommon.mk b/target/board/BoardConfigModuleCommon.mk
new file mode 100644
index 0000000000..24c01a58ef
--- /dev/null
+++ b/target/board/BoardConfigModuleCommon.mk
@@ -0,0 +1,6 @@
+# BoardConfigModuleCommon.mk
+#
+# Common compile-time settings for module builds.
+
+# Required for all module devices.
+TARGET_USES_64_BIT_BINDER := true
diff --git a/target/board/module_arm/BoardConfig.mk b/target/board/module_arm/BoardConfig.mk
new file mode 100644
index 0000000000..3f35c060e1
--- /dev/null
+++ b/target/board/module_arm/BoardConfig.mk
@@ -0,0 +1,22 @@
+# Copyright (C) 2020 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+include build/make/target/board/BoardConfigModuleCommon.mk
+
+TARGET_ARCH := arm
+TARGET_ARCH_VARIANT := armv7-a-neon
+TARGET_CPU_VARIANT := generic
+TARGET_CPU_ABI := armeabi-v7a
+TARGET_CPU_ABI2 := armeabi
diff --git a/target/board/module_arm/README.md b/target/board/module_arm/README.md
new file mode 100644
index 0000000000..b893573bd1
--- /dev/null
+++ b/target/board/module_arm/README.md
@@ -0,0 +1,2 @@
+This device is suitable for an unbundled module targeted specifically to an arm
+device.
diff --git a/target/board/module_arm/device.mk b/target/board/module_arm/device.mk
new file mode 100644
index 0000000000..7cac5f8430
--- /dev/null
+++ b/target/board/module_arm/device.mk
@@ -0,0 +1,18 @@
+#
+# Copyright (C) 2020 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+$(call inherit-product, build/make/target/product/bootclasspath.mk)
+$(call inherit-product, build/make/target/product/languages_default.mk)
diff --git a/target/board/module_arm64/BoardConfig.mk b/target/board/module_arm64/BoardConfig.mk
new file mode 100644
index 0000000000..3700056da3
--- /dev/null
+++ b/target/board/module_arm64/BoardConfig.mk
@@ -0,0 +1,27 @@
+# Copyright (C) 2020 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+include build/make/target/board/BoardConfigModuleCommon.mk
+
+TARGET_ARCH := arm64
+TARGET_ARCH_VARIANT := armv8-a
+TARGET_CPU_VARIANT := generic
+TARGET_CPU_ABI := arm64-v8a
+
+TARGET_2ND_ARCH := arm
+TARGET_2ND_ARCH_VARIANT := armv8-a
+TARGET_2ND_CPU_ABI := armeabi-v7a
+TARGET_2ND_CPU_ABI2 := armeabi
+TARGET_2ND_CPU_VARIANT := generic
diff --git a/target/board/module_arm64/README.md b/target/board/module_arm64/README.md
new file mode 100644
index 0000000000..cb36fbf258
--- /dev/null
+++ b/target/board/module_arm64/README.md
@@ -0,0 +1,3 @@
+This device is suitable for an unbundled module targeted specifically to an
+arm64 device. 32 bit binaries built with this product will not be suitable for a
+32-bit arm device.
diff --git a/target/board/module_arm64/device.mk b/target/board/module_arm64/device.mk
new file mode 100644
index 0000000000..9065d4b66d
--- /dev/null
+++ b/target/board/module_arm64/device.mk
@@ -0,0 +1,19 @@
+#
+# Copyright (C) 2020 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+$(call inherit-product, build/make/target/product/bootclasspath.mk)
+$(call inherit-product, build/make/target/product/core_64_bit.mk)
+$(call inherit-product, build/make/target/product/languages_default.mk)
diff --git a/target/board/module_x86/BoardConfig.mk b/target/board/module_x86/BoardConfig.mk
new file mode 100644
index 0000000000..a93ac9779c
--- /dev/null
+++ b/target/board/module_x86/BoardConfig.mk
@@ -0,0 +1,20 @@
+# Copyright (C) 2020 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+include build/make/target/board/BoardConfigModuleCommon.mk
+
+TARGET_CPU_ABI := x86
+TARGET_ARCH := x86
+TARGET_ARCH_VARIANT := x86
diff --git a/target/board/module_x86/README.md b/target/board/module_x86/README.md
new file mode 100644
index 0000000000..10866b7c5f
--- /dev/null
+++ b/target/board/module_x86/README.md
@@ -0,0 +1,2 @@
+This device is suitable for an unbundled module targeted specifically to an
+x86 device.
diff --git a/target/board/module_x86/device.mk b/target/board/module_x86/device.mk
new file mode 100644
index 0000000000..7cac5f8430
--- /dev/null
+++ b/target/board/module_x86/device.mk
@@ -0,0 +1,18 @@
+#
+# Copyright (C) 2020 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+$(call inherit-product, build/make/target/product/bootclasspath.mk)
+$(call inherit-product, build/make/target/product/languages_default.mk)
diff --git a/target/board/module_x86_64/BoardConfig.mk b/target/board/module_x86_64/BoardConfig.mk
new file mode 100644
index 0000000000..1ed3be0ba6
--- /dev/null
+++ b/target/board/module_x86_64/BoardConfig.mk
@@ -0,0 +1,24 @@
+# Copyright (C) 2020 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+include build/make/target/board/BoardConfigModuleCommon.mk
+
+TARGET_CPU_ABI := x86_64
+TARGET_ARCH := x86_64
+TARGET_ARCH_VARIANT := x86_64
+
+TARGET_2ND_CPU_ABI := x86
+TARGET_2ND_ARCH := x86
+TARGET_2ND_ARCH_VARIANT := x86_64
diff --git a/target/board/module_x86_64/README.md b/target/board/module_x86_64/README.md
new file mode 100644
index 0000000000..3377baad2a
--- /dev/null
+++ b/target/board/module_x86_64/README.md
@@ -0,0 +1,3 @@
+This device is suitable for an unbundled module targeted specifically to an
+x86_64 device. 32 bit binaries built with this product will not be suitable for
+a 32-bit x86 device.
diff --git a/target/board/module_x86_64/device.mk b/target/board/module_x86_64/device.mk
new file mode 100644
index 0000000000..9065d4b66d
--- /dev/null
+++ b/target/board/module_x86_64/device.mk
@@ -0,0 +1,19 @@
+#
+# Copyright (C) 2020 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+$(call inherit-product, build/make/target/product/bootclasspath.mk)
+$(call inherit-product, build/make/target/product/core_64_bit.mk)
+$(call inherit-product, build/make/target/product/languages_default.mk)