build: Add MinusOS build support
Squashed also with the following changes: Author: Luca Stefani <luca020400@lineageos.org> Date: Thu Aug 17 22:22:13 2017 +0200 core: Include PixelProject pathmap Change-Id: Ie25dee383cc5bc9bb6390cff2cb2460d526d80b6 Author: Simon Shields <simon@lineageos.org> Date: Fri Mar 2 12:55:47 2018 +1100 build: unconditionally use PixelProject pathmap even if we're not building a pixelproject target, we need to use the pixelproject pathmap to make things like recovery and ril happy Change-Id: I974c30ad10d4ff5b7805c3df9c22010f1e002bf1 Author: Luca Stefani <luca.stefani.ge1@gmail.com> Date: Tue Jan 22 15:50:52 2019 +0100 Don't export BUILD_NUMBER in envsetup * The value is meant to be set only before running an /official/ build * This allows us to execute consecutive make commands without running kati for every invocation Change-Id: Ifa94b839f30c7260009c8a3c91c202b50e28022e Author: Luca Stefani <luca020400@lineageos.org> Date: Fri Aug 18 10:17:00 2017 +0200 envsetup: Call fixup_common_out_dir Change-Id: I84e16b0df5822cfd8514c46d709109a13c20f86e Author: Adrian DC <radian.dc@gmail.com> Date: Sat May 12 11:24:33 2018 +0200 build: Include PixelProject specific properties in build.prop * Our properties were supposed to go to /system/etc/prop.default after the following commit: "pixelproject: Move to Google's method of defining system default props" Change-Id: I6cb0e28a7599b010b389cc541015a37010a00f4b * However if BOARD_PROPERTY_OVERRIDES_SPLIT_ENABLED is not true, only /default.prop will retain the properties contents of ADDITIONAL_DEFAULT_PROPERTIES and PRODUCT_SYSTEM_DEFAULT_PROPERTIES, and none of our versioning identification was held in the system * Enabling BOARD_PROPERTY_OVERRIDES_SPLIT_ENABLED globally would break all properties on devices that handle partitions usually at the device level rather than the kernel due to mounting races * Include the vendor/aosp/config/main.mk entrypoint to be allowed to extend ADDITION_BUILD_PROPERTIES as we need to define our releases Change-Id: I19918eece0f0dd3ee967db0339b4d09c9a6d540e Signed-off-by: Adrian DC <radian.dc@gmail.com> Author: Rashed Abdel-Tawab <rashed@linux.com> Date: Thu Sep 5 21:35:38 2019 -0700 core: Only include PixelProject SE policy if repo exists Change-Id: If799106d2da6d8c303430e316edff365a22f7c99 Author: dianlujitao <dianlujitao@lineageos.org> Date: Thu Sep 5 21:56:36 2019 +0800 product: Exclude AOSP apn list on PixelProject build Change-Id: I1fd10089421a2e4b57ef565d87ad1f6036bd1898 Author: Michael Bestas <mkbestas@lineageos.org> Date: Fri Apr 12 02:10:12 2019 +0300 build: Conditionally include AudioPackage14.mk instead of AllAudio.mk * AllAudio.mk doesn't contain latest material files and also contains multiple duplicate files. Just copy the latest material ones and we'll include the older files in vendor/aosp Change-Id: Ic7353216a3f3dc3c51006d951ac932cfd6e5f3b5 Author: dhacker29 <dhackerdvm@gmail.com> Date: Sat Jun 6 22:22:05 2015 -0400 Remove LatinIME as it is included per target in vendor/aosp Change-Id: Ibce4a244ec0653a7c7798d864047ac667866a1dc Author: razorloves <razorloves@gmail.com> Date: Mon Oct 7 05:10:56 2019 -0500 build: Remove su inclusion This stops including su in all pixelproject userdebug/eng builds. Inclusion of su is conditionally handled in /vendor/aosp. Change-Id: Ia3ad978146f170a2b260d77afe9eb580d4b4f823 Author: Michael Bestas <mkbestas@lineageos.org> Date: Sat Nov 7 22:45:12 2020 +0200 Stop including vendor specific clear_vars.mk vendor/aosp/build/core/clear_vars.mk is no-op since 16.0 Change-Id: I7e159cc9ed5a838c9a04c1a8b7dcf925d83f0e20 Change-Id: Iab8b2ef8b644a7bea10bfd28b99d9e69539b1357 Signed-off-by: RITEFANG <1721985272@qq.com>
This commit is contained in:
@@ -453,6 +453,10 @@ endif
|
|||||||
# See envsetup.mk for a description of SCAN_EXCLUDE_DIRS
|
# See envsetup.mk for a description of SCAN_EXCLUDE_DIRS
|
||||||
FIND_LEAVES_EXCLUDES := $(addprefix --prune=, $(SCAN_EXCLUDE_DIRS) .repo .git)
|
FIND_LEAVES_EXCLUDES := $(addprefix --prune=, $(SCAN_EXCLUDE_DIRS) .repo .git)
|
||||||
|
|
||||||
|
ifneq ($(MINUS_BUILD),)
|
||||||
|
include vendor/minus/config/BoardConfigCustom.mk
|
||||||
|
endif
|
||||||
|
|
||||||
# The build system exposes several variables for where to find the kernel
|
# The build system exposes several variables for where to find the kernel
|
||||||
# headers:
|
# headers:
|
||||||
# TARGET_DEVICE_KERNEL_HEADERS is automatically created for the current
|
# TARGET_DEVICE_KERNEL_HEADERS is automatically created for the current
|
||||||
@@ -1295,6 +1299,14 @@ endif
|
|||||||
SOONG_VARIABLES := $(SOONG_OUT_DIR)/soong.$(TARGET_PRODUCT)$(COVERAGE_SUFFIX).variables
|
SOONG_VARIABLES := $(SOONG_OUT_DIR)/soong.$(TARGET_PRODUCT)$(COVERAGE_SUFFIX).variables
|
||||||
SOONG_EXTRA_VARIABLES := $(SOONG_OUT_DIR)/soong.$(TARGET_PRODUCT)$(COVERAGE_SUFFIX).extra.variables
|
SOONG_EXTRA_VARIABLES := $(SOONG_OUT_DIR)/soong.$(TARGET_PRODUCT)$(COVERAGE_SUFFIX).extra.variables
|
||||||
|
|
||||||
|
ifneq ($(MINUS_BUILD),)
|
||||||
|
ifneq ($(wildcard device/lineage/sepolicy/common/sepolicy.mk),)
|
||||||
|
## We need to be sure the global selinux policies are included
|
||||||
|
## last, to avoid accidental resetting by device configs
|
||||||
|
$(eval include device/lineage/sepolicy/common/sepolicy.mk)
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
ifeq ($(CALLED_FROM_SETUP),true)
|
ifeq ($(CALLED_FROM_SETUP),true)
|
||||||
include $(BUILD_SYSTEM)/ninja_config.mk
|
include $(BUILD_SYSTEM)/ninja_config.mk
|
||||||
include $(BUILD_SYSTEM)/soong_config.mk
|
include $(BUILD_SYSTEM)/soong_config.mk
|
||||||
@@ -1307,6 +1319,9 @@ SOONG_EXTRA_VARIABLES :=
|
|||||||
DEFAULT_DATA_OUT_MODULES := ltp $(ltp_packages)
|
DEFAULT_DATA_OUT_MODULES := ltp $(ltp_packages)
|
||||||
.KATI_READONLY := DEFAULT_DATA_OUT_MODULES
|
.KATI_READONLY := DEFAULT_DATA_OUT_MODULES
|
||||||
|
|
||||||
|
# Include any vendor specific config.mk file
|
||||||
|
-include vendor/*/build/core/config.mk
|
||||||
|
|
||||||
include $(BUILD_SYSTEM)/dumpvar.mk
|
include $(BUILD_SYSTEM)/dumpvar.mk
|
||||||
|
|
||||||
ifdef BOARD_VNDK_VERSION
|
ifdef BOARD_VNDK_VERSION
|
||||||
|
@@ -208,6 +208,10 @@ endif
|
|||||||
|
|
||||||
BUILD_WITHOUT_PV := true
|
BUILD_WITHOUT_PV := true
|
||||||
|
|
||||||
|
# ------------------------------------------------------------
|
||||||
|
# Include vendor specific additions to build properties
|
||||||
|
-include vendor/minus/build/core/main.mk
|
||||||
|
|
||||||
# ------------------------------------------------------------
|
# ------------------------------------------------------------
|
||||||
# Define a function that, given a list of module tags, returns
|
# Define a function that, given a list of module tags, returns
|
||||||
# non-empty if that module should be installed in /system.
|
# non-empty if that module should be installed in /system.
|
||||||
|
@@ -92,3 +92,5 @@ FRAMEWORKS_BASE_SUBDIRS := \
|
|||||||
#
|
#
|
||||||
FRAMEWORKS_BASE_JAVA_SRC_DIRS := \
|
FRAMEWORKS_BASE_JAVA_SRC_DIRS := \
|
||||||
$(addprefix frameworks/base/,$(FRAMEWORKS_BASE_SUBDIRS))
|
$(addprefix frameworks/base/,$(FRAMEWORKS_BASE_SUBDIRS))
|
||||||
|
|
||||||
|
-include vendor/minus/build/core/pathmap.mk
|
||||||
|
@@ -62,7 +62,7 @@ $(call add_json_bool, Debuggable, $(filter userdebug eng,
|
|||||||
$(call add_json_bool, Eng, $(filter eng,$(TARGET_BUILD_VARIANT)))
|
$(call add_json_bool, Eng, $(filter eng,$(TARGET_BUILD_VARIANT)))
|
||||||
$(call add_json_str, BuildType, $(TARGET_BUILD_TYPE))
|
$(call add_json_str, BuildType, $(TARGET_BUILD_TYPE))
|
||||||
|
|
||||||
$(call add_json_str, DeviceName, $(TARGET_DEVICE))
|
$(call add_json_str, MinusDeviceName, $(TARGET_DEVICE))
|
||||||
$(call add_json_str, DeviceProduct, $(TARGET_PRODUCT))
|
$(call add_json_str, DeviceProduct, $(TARGET_PRODUCT))
|
||||||
$(call add_json_str, DeviceArch, $(TARGET_ARCH))
|
$(call add_json_str, DeviceArch, $(TARGET_ARCH))
|
||||||
$(call add_json_str, DeviceArchVariant, $(TARGET_ARCH_VARIANT))
|
$(call add_json_str, DeviceArchVariant, $(TARGET_ARCH_VARIANT))
|
||||||
@@ -366,6 +366,7 @@ $(call add_json_list, DeviceFrameworkCompatibilityMatrixFile, $(DEVICE_FRAMEWORK
|
|||||||
$(call add_json_list, DeviceProductCompatibilityMatrixFile, $(DEVICE_PRODUCT_COMPATIBILITY_MATRIX_FILE))
|
$(call add_json_list, DeviceProductCompatibilityMatrixFile, $(DEVICE_PRODUCT_COMPATIBILITY_MATRIX_FILE))
|
||||||
$(call add_json_list, BoardAvbSystemAddHashtreeFooterArgs, $(BOARD_AVB_SYSTEM_ADD_HASHTREE_FOOTER_ARGS))
|
$(call add_json_list, BoardAvbSystemAddHashtreeFooterArgs, $(BOARD_AVB_SYSTEM_ADD_HASHTREE_FOOTER_ARGS))
|
||||||
$(call add_json_bool, BoardAvbEnable, $(filter true,$(BOARD_AVB_ENABLE)))
|
$(call add_json_bool, BoardAvbEnable, $(filter true,$(BOARD_AVB_ENABLE)))
|
||||||
|
$(call add_json_list, MinusDevice, $(TARGET_DEVICE))
|
||||||
|
|
||||||
$(call json_end)
|
$(call json_end)
|
||||||
|
|
||||||
|
@@ -500,6 +500,13 @@ function lunch()
|
|||||||
|
|
||||||
function _lunch_meat()
|
function _lunch_meat()
|
||||||
{
|
{
|
||||||
|
if (echo -n $1 | grep -q -e "^minus_") ; then
|
||||||
|
MINUS_BUILD=$(echo -n $1 | sed -e 's/^minus_//g')
|
||||||
|
else
|
||||||
|
MINUS_BUILD=
|
||||||
|
fi
|
||||||
|
export MINUS_BUILD
|
||||||
|
|
||||||
local product=$1
|
local product=$1
|
||||||
local release=$2
|
local release=$2
|
||||||
local variant=$3
|
local variant=$3
|
||||||
|
@@ -19,7 +19,11 @@ $(call inherit-product, $(SRC_TARGET_DIR)/product/handheld_product.mk)
|
|||||||
$(call inherit-product, $(SRC_TARGET_DIR)/product/telephony_product.mk)
|
$(call inherit-product, $(SRC_TARGET_DIR)/product/telephony_product.mk)
|
||||||
|
|
||||||
# Default AOSP sounds
|
# Default AOSP sounds
|
||||||
|
ifeq ($(MINUS_BUILD),)
|
||||||
$(call inherit-product-if-exists, frameworks/base/data/sounds/AllAudio.mk)
|
$(call inherit-product-if-exists, frameworks/base/data/sounds/AllAudio.mk)
|
||||||
|
else
|
||||||
|
$(call inherit-product-if-exists, frameworks/base/data/sounds/AudioPackage14.mk)
|
||||||
|
endif
|
||||||
|
|
||||||
# Additional settings used in all AOSP builds
|
# Additional settings used in all AOSP builds
|
||||||
PRODUCT_PRODUCT_PROPERTIES += \
|
PRODUCT_PRODUCT_PROPERTIES += \
|
||||||
@@ -37,5 +41,7 @@ PRODUCT_PACKAGES += \
|
|||||||
|
|
||||||
# Telephony:
|
# Telephony:
|
||||||
# Provide a APN configuration to GSI product
|
# Provide a APN configuration to GSI product
|
||||||
|
ifeq ($(MINUS_BUILD),)
|
||||||
PRODUCT_COPY_FILES += \
|
PRODUCT_COPY_FILES += \
|
||||||
device/sample/etc/apns-full-conf.xml:$(TARGET_COPY_OUT_PRODUCT)/etc/apns-conf.xml
|
device/sample/etc/apns-full-conf.xml:$(TARGET_COPY_OUT_PRODUCT)/etc/apns-conf.xml
|
||||||
|
endif
|
||||||
|
@@ -507,7 +507,6 @@ PRODUCT_PACKAGES_DEBUG := \
|
|||||||
ss \
|
ss \
|
||||||
start_with_lockagent \
|
start_with_lockagent \
|
||||||
strace \
|
strace \
|
||||||
su \
|
|
||||||
sanitizer-status \
|
sanitizer-status \
|
||||||
tracepath \
|
tracepath \
|
||||||
tracepath6 \
|
tracepath6 \
|
||||||
@@ -516,6 +515,11 @@ PRODUCT_PACKAGES_DEBUG := \
|
|||||||
unwind_reg_info \
|
unwind_reg_info \
|
||||||
unwind_symbols \
|
unwind_symbols \
|
||||||
|
|
||||||
|
ifeq ($(MINUS_BUILD),)
|
||||||
|
PRODUCT_PACKAGES_DEBUG += \
|
||||||
|
su
|
||||||
|
endif
|
||||||
|
|
||||||
# The set of packages whose code can be loaded by the system server.
|
# The set of packages whose code can be loaded by the system server.
|
||||||
PRODUCT_SYSTEM_SERVER_APPS += \
|
PRODUCT_SYSTEM_SERVER_APPS += \
|
||||||
SettingsProvider \
|
SettingsProvider \
|
||||||
|
@@ -45,7 +45,11 @@ PRODUCT_VENDOR_PROPERTIES := \
|
|||||||
PRODUCT_LOCALES := en_US
|
PRODUCT_LOCALES := en_US
|
||||||
|
|
||||||
# Get some sounds
|
# Get some sounds
|
||||||
|
ifeq ($(MINUS_BUILD),)
|
||||||
$(call inherit-product-if-exists, frameworks/base/data/sounds/AllAudio.mk)
|
$(call inherit-product-if-exists, frameworks/base/data/sounds/AllAudio.mk)
|
||||||
|
else
|
||||||
|
$(call inherit-product-if-exists, frameworks/base/data/sounds/AudioPackage14.mk)
|
||||||
|
endif
|
||||||
|
|
||||||
# Get a list of languages.
|
# Get a list of languages.
|
||||||
$(call inherit-product, $(SRC_TARGET_DIR)/product/languages_full.mk)
|
$(call inherit-product, $(SRC_TARGET_DIR)/product/languages_full.mk)
|
||||||
|
@@ -24,8 +24,12 @@ PRODUCT_VENDOR_PROPERTIES := \
|
|||||||
ro.com.android.dataroaming?=true
|
ro.com.android.dataroaming?=true
|
||||||
|
|
||||||
PRODUCT_COPY_FILES := \
|
PRODUCT_COPY_FILES := \
|
||||||
device/sample/etc/apns-full-conf.xml:system/etc/apns-conf.xml \
|
|
||||||
frameworks/native/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml
|
frameworks/native/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml
|
||||||
|
|
||||||
|
ifeq ($(MINUS_BUILD),)
|
||||||
|
PRODUCT_COPY_FILES += \
|
||||||
|
device/sample/etc/apns-full-conf.xml:system/etc/apns-conf.xml
|
||||||
|
endif
|
||||||
|
|
||||||
$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_base.mk)
|
$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_base.mk)
|
||||||
$(call inherit-product, $(SRC_TARGET_DIR)/product/telephony.mk)
|
$(call inherit-product, $(SRC_TARGET_DIR)/product/telephony.mk)
|
||||||
|
@@ -28,12 +28,16 @@ PRODUCT_PACKAGES += \
|
|||||||
Contacts \
|
Contacts \
|
||||||
DeskClock \
|
DeskClock \
|
||||||
Gallery2 \
|
Gallery2 \
|
||||||
LatinIME \
|
|
||||||
Music \
|
Music \
|
||||||
preinstalled-packages-platform-handheld-product.xml \
|
preinstalled-packages-platform-handheld-product.xml \
|
||||||
QuickSearchBox \
|
QuickSearchBox \
|
||||||
SettingsIntelligence \
|
SettingsIntelligence \
|
||||||
frameworks-base-overlays
|
frameworks-base-overlays
|
||||||
|
|
||||||
|
ifeq ($(MINUS_BUILD),)
|
||||||
|
PRODUCT_PACKAGES += \
|
||||||
|
LatinIME
|
||||||
|
endif
|
||||||
|
|
||||||
PRODUCT_PACKAGES_DEBUG += \
|
PRODUCT_PACKAGES_DEBUG += \
|
||||||
frameworks-base-overlays-debug
|
frameworks-base-overlays-debug
|
||||||
|
Reference in New Issue
Block a user