From 95028db2b0b55a73e8da7a05ce489bc4cb29f69b Mon Sep 17 00:00:00 2001 From: Martin Stjernholm Date: Tue, 2 Feb 2021 11:23:53 +0000 Subject: Merge the module_* device.mk files into their corresponding product mk files. To clean up an unnecessary indirection. Instead introduce a common file for module products. Test: lunch module_{arm,arm64,x86,x86_64} inspect the build banners Merged-In: Ia312431a664e731f5d801ee2671f62f5cd23bd51 Change-Id: Ia312431a664e731f5d801ee2671f62f5cd23bd51 (cherry picked from commit e118347e562f358002248a0ec65f523232b1461f) --- target/board/module_arm/device.mk | 18 ------------------ target/board/module_arm64/device.mk | 19 ------------------- target/board/module_x86/device.mk | 18 ------------------ target/board/module_x86_64/device.mk | 19 ------------------- target/product/module_arm.mk | 2 +- target/product/module_arm64.mk | 3 ++- target/product/module_common.mk | 18 ++++++++++++++++++ target/product/module_x86.mk | 2 +- target/product/module_x86_64.mk | 3 ++- 9 files changed, 24 insertions(+), 78 deletions(-) delete mode 100644 target/board/module_arm/device.mk delete mode 100644 target/board/module_arm64/device.mk delete mode 100644 target/board/module_x86/device.mk delete mode 100644 target/board/module_x86_64/device.mk create mode 100644 target/product/module_common.mk diff --git a/target/board/module_arm/device.mk b/target/board/module_arm/device.mk deleted file mode 100644 index 7cac5f8430..0000000000 --- a/target/board/module_arm/device.mk +++ /dev/null @@ -1,18 +0,0 @@ -# -# 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/device.mk b/target/board/module_arm64/device.mk deleted file mode 100644 index 9065d4b66d..0000000000 --- a/target/board/module_arm64/device.mk +++ /dev/null @@ -1,19 +0,0 @@ -# -# 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/device.mk b/target/board/module_x86/device.mk deleted file mode 100644 index 7cac5f8430..0000000000 --- a/target/board/module_x86/device.mk +++ /dev/null @@ -1,18 +0,0 @@ -# -# 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/device.mk b/target/board/module_x86_64/device.mk deleted file mode 100644 index 9065d4b66d..0000000000 --- a/target/board/module_x86_64/device.mk +++ /dev/null @@ -1,19 +0,0 @@ -# -# 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/product/module_arm.mk b/target/product/module_arm.mk index 09ccf5fa0d..d99dce8b2b 100644 --- a/target/product/module_arm.mk +++ b/target/product/module_arm.mk @@ -14,7 +14,7 @@ # limitations under the License. # -$(call inherit-product, $(SRC_TARGET_DIR)/board/module_arm/device.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/module_common.mk) PRODUCT_NAME := module_arm PRODUCT_BRAND := Android diff --git a/target/product/module_arm64.mk b/target/product/module_arm64.mk index 468c9db9a5..fc9529ce39 100644 --- a/target/product/module_arm64.mk +++ b/target/product/module_arm64.mk @@ -14,7 +14,8 @@ # limitations under the License. # -$(call inherit-product, $(SRC_TARGET_DIR)/board/module_arm64/device.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/module_common.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) PRODUCT_NAME := module_arm64 PRODUCT_BRAND := Android diff --git a/target/product/module_common.mk b/target/product/module_common.mk new file mode 100644 index 0000000000..eb8f92c5e8 --- /dev/null +++ b/target/product/module_common.mk @@ -0,0 +1,18 @@ +# +# Copyright (C) 2021 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, $(SRC_TARGET_DIR)/product/bootclasspath.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/languages_default.mk) diff --git a/target/product/module_x86.mk b/target/product/module_x86.mk index dec4aedca0..b852e7a6de 100644 --- a/target/product/module_x86.mk +++ b/target/product/module_x86.mk @@ -14,7 +14,7 @@ # limitations under the License. # -$(call inherit-product, $(SRC_TARGET_DIR)/board/module_x86/device.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/module_common.mk) PRODUCT_NAME := module_x86 PRODUCT_BRAND := Android diff --git a/target/product/module_x86_64.mk b/target/product/module_x86_64.mk index 5fabade708..f6bc1fc307 100644 --- a/target/product/module_x86_64.mk +++ b/target/product/module_x86_64.mk @@ -14,7 +14,8 @@ # limitations under the License. # -$(call inherit-product, $(SRC_TARGET_DIR)/board/module_x86_64/device.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/module_common.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) PRODUCT_NAME := module_x86_64 PRODUCT_BRAND := Android -- cgit v1.2.3 From bb56b5d42fbf966232b41fbca1393411fdf03c7f Mon Sep 17 00:00:00 2001 From: Anton Hansson Date: Thu, 15 Apr 2021 14:41:15 +0100 Subject: Make module_* inherit aosp_* This reverts a previous effort to build modules without the large number of config flags in aosp_*, as it caused unintentional diffs and test failures. Bug: 184018787 Test: build and install com.android.media.swcodec && adb reboot && wait-for-boot && atest \ android.provider.cts.media.MediaStore_Video_ThumbnailsTest#testInsertUpdateDelete Change-Id: I357624136e3e5427ab8077649a699e7f4a2e299e (cherry picked from commit 708b854c4a333b92bd41023d7d92fafcd16ab8f2) --- target/product/module_arm.mk | 3 +-- target/product/module_arm64.mk | 4 +--- target/product/module_x86.mk | 3 +-- target/product/module_x86_64.mk | 4 +--- 4 files changed, 4 insertions(+), 10 deletions(-) diff --git a/target/product/module_arm.mk b/target/product/module_arm.mk index d99dce8b2b..0deb43df93 100644 --- a/target/product/module_arm.mk +++ b/target/product/module_arm.mk @@ -14,8 +14,7 @@ # limitations under the License. # -$(call inherit-product, $(SRC_TARGET_DIR)/product/module_common.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_arm.mk) PRODUCT_NAME := module_arm PRODUCT_BRAND := Android -PRODUCT_DEVICE := module_arm diff --git a/target/product/module_arm64.mk b/target/product/module_arm64.mk index fc9529ce39..8effa785a9 100644 --- a/target/product/module_arm64.mk +++ b/target/product/module_arm64.mk @@ -14,9 +14,7 @@ # limitations under the License. # -$(call inherit-product, $(SRC_TARGET_DIR)/product/module_common.mk) -$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_arm64.mk) PRODUCT_NAME := module_arm64 PRODUCT_BRAND := Android -PRODUCT_DEVICE := module_arm64 diff --git a/target/product/module_x86.mk b/target/product/module_x86.mk index b852e7a6de..5f75c82b55 100644 --- a/target/product/module_x86.mk +++ b/target/product/module_x86.mk @@ -14,8 +14,7 @@ # limitations under the License. # -$(call inherit-product, $(SRC_TARGET_DIR)/product/module_common.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_x86.mk) PRODUCT_NAME := module_x86 PRODUCT_BRAND := Android -PRODUCT_DEVICE := module_x86 diff --git a/target/product/module_x86_64.mk b/target/product/module_x86_64.mk index f6bc1fc307..9196cd2503 100644 --- a/target/product/module_x86_64.mk +++ b/target/product/module_x86_64.mk @@ -14,9 +14,7 @@ # limitations under the License. # -$(call inherit-product, $(SRC_TARGET_DIR)/product/module_common.mk) -$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_x86_64.mk) PRODUCT_NAME := module_x86_64 PRODUCT_BRAND := Android -PRODUCT_DEVICE := module_x86_64 -- cgit v1.2.3