Loading core/config.mk +25 −10 Original line number Diff line number Diff line Loading @@ -231,12 +231,13 @@ combo_2nd_arch_prefix := $(TARGET_2ND_ARCH_VAR_PREFIX) include $(BUILD_SYSTEM)/combo/select.mk endif # "ro.product.cpu.abilist" is a comma separated list of ABIs (in order # of preference) that the target supports. If a TARGET_CPU_ABI_LIST # is specified by the board configuration, we use that. If not, we # build a list out of the TARGET_CPU_ABIs specified by the config. ifeq (,$(TARGET_CPU_ABI_LIST)) TARGET_CPU_ABI_LIST := $(TARGET_CPU_ABI) $(TARGET_CPU_ABI2) $(TARGET_2ND_CPU_ABI) $(TARGET_2ND_CPU_ABI2) ifdef TARGET_PREFER_32_BIT TARGET_PREFER_32_BIT_APPS := true TARGET_PREFER_32_BIT_EXECUTABLES := true endif ifeq (,$(TARGET_SUPPORTS_32_BIT_APPS)$(TARGET_SUPPORTS_64_BIT_APPS)) TARGET_SUPPORTS_32_BIT_APPS := true endif # "ro.product.cpu.abilist32" and "ro.product.cpu.abilist64" are Loading @@ -249,7 +250,7 @@ endif # is always 32 bits. If this isn't the case, these variables should # be overriden in the boarc configuration. ifeq (,$(TARGET_CPU_ABI_LIST_64_BIT)) ifeq (true,$(TARGET_IS_64_BIT)) ifeq (true|true,$(TARGET_IS_64_BIT)|$(TARGET_SUPPORTS_64_BIT_APPS)) TARGET_CPU_ABI_LIST_64_BIT := $(TARGET_CPU_ABI) $(TARGET_CPU_ABI2) endif endif Loading @@ -258,11 +259,25 @@ ifeq (,$(TARGET_CPU_ABI_LIST_32_BIT)) ifneq (true,$(TARGET_IS_64_BIT)) TARGET_CPU_ABI_LIST_32_BIT := $(TARGET_CPU_ABI) $(TARGET_CPU_ABI2) else ifeq (true,$(TARGET_SUPPORTS_32_BIT_APPS)) # For a 64 bit target, assume that the 2ND_CPU_ABI # is a 32 bit ABI. TARGET_CPU_ABI_LIST_32_BIT := $(TARGET_2ND_CPU_ABI) $(TARGET_2ND_CPU_ABI2) endif endif endif # "ro.product.cpu.abilist" is a comma separated list of ABIs (in order # of preference) that the target supports. If a TARGET_CPU_ABI_LIST # is specified by the board configuration, we use that. If not, we # build a list out of the TARGET_CPU_ABIs specified by the config. ifeq (,$(TARGET_CPU_ABI_LIST)) ifeq ($(TARGET_IS_64_BIT)|$(TARGET_PREFER_32_BIT_APPS),true|true) TARGET_CPU_ABI_LIST := $(TARGET_CPU_ABI_LIST_32_BIT) $(TARGET_CPU_ABI_LIST_64_BIT) else TARGET_CPU_ABI_LIST := $(TARGET_CPU_ABI_LIST_64_BIT) $(TARGET_CPU_ABI_LIST_32_BIT) endif endif # Strip whitespace from the ABI list string. TARGET_CPU_ABI_LIST := $(subst $(space),$(comma),$(strip $(TARGET_CPU_ABI_LIST))) Loading core/executable.mk +3 −3 Original line number Diff line number Diff line Loading @@ -19,9 +19,9 @@ else #!LOCAL_MULTILIB == both LOCAL_NO_2ND_ARCH_MODULE_SUFFIX := true endif # if TARGET_PREFER_32_BIT is set, try to build 32-bit first # if TARGET_PREFER_32_BIT_EXECUTABLES is set, try to build 32-bit first ifdef TARGET_2ND_ARCH ifeq ($(TARGET_PREFER_32_BIT),true) ifeq ($(TARGET_PREFER_32_BIT_EXECUTABLES),true) LOCAL_2ND_ARCH_VAR_PREFIX := $(TARGET_2ND_ARCH_VAR_PREFIX) else LOCAL_2ND_ARCH_VAR_PREFIX := Loading @@ -45,7 +45,7 @@ ifndef my_skip_non_preferred_arch ifdef TARGET_2ND_ARCH # check if the non-preferred arch is the primary or secondary ifeq ($(TARGET_PREFER_32_BIT),true) ifeq ($(TARGET_PREFER_32_BIT_EXECUTABLES),true) LOCAL_2ND_ARCH_VAR_PREFIX := else LOCAL_2ND_ARCH_VAR_PREFIX := $(TARGET_2ND_ARCH_VAR_PREFIX) Loading core/package.mk +3 −3 Original line number Diff line number Diff line Loading @@ -40,9 +40,9 @@ endif LOCAL_NO_2ND_ARCH_MODULE_SUFFIX := true # if TARGET_PREFER_32_BIT is set, try to build 32-bit first # if TARGET_PREFER_32_BIT_APPS is set, try to build 32-bit first ifdef TARGET_2ND_ARCH ifeq ($(TARGET_PREFER_32_BIT),true) ifeq ($(TARGET_PREFER_32_BIT_APPS),true) LOCAL_2ND_ARCH_VAR_PREFIX := $(TARGET_2ND_ARCH_VAR_PREFIX) else LOCAL_2ND_ARCH_VAR_PREFIX := Loading @@ -56,7 +56,7 @@ ifeq ($(my_module_arch_supported),true) include $(BUILD_SYSTEM)/package_internal.mk else ifneq (,$(TARGET_2ND_ARCH)) # check if the non-preferred arch is the primary or secondary ifeq ($(TARGET_PREFER_32_BIT),true) ifeq ($(TARGET_PREFER_32_BIT_APPS),true) LOCAL_2ND_ARCH_VAR_PREFIX := else LOCAL_2ND_ARCH_VAR_PREFIX := $(TARGET_2ND_ARCH_VAR_PREFIX) Loading target/product/aosp_arm64.mk +1 −0 Original line number Diff line number Diff line Loading @@ -19,6 +19,7 @@ # build quite specifically for the emulator, and might not be # entirely appropriate to inherit from for on-device configurations. $(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) $(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_base_telephony.mk) $(call inherit-product, $(SRC_TARGET_DIR)/board/generic_arm64/device.mk) Loading target/product/core_64_bit.mk 0 → 100644 +40 −0 Original line number Diff line number Diff line # # Copyright (C) 2014 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. # # Inherit from this product for devices that support 64-bit apps using: # $(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) # The inheritance for this must come before the inheritance chain that leads # to core_minimal.mk # For now this will allow 64-bit apps, but still compile all apps with JNI # for 32-bit only. # Copy the 32-bit primary, 64-bit secondary zygote startup script PRODUCT_COPY_FILES += system/core/rootdir/init.zygote32_64.rc:root/init.zygote32_64.rc # Set the zygote property to select the 32-bit primary, 64-bit secondary script # This line must be parsed before the one in core_minimal.mk PRODUCT_DEFAULT_PROPERTY_OVERRIDES += ro.zygote=zygote32_64 # Temporary hack to prefer launching processes as 32 bit # instead of 64 bit. # # STOPSHIP: Revert this to allow products to select it themselves TARGET_PREFER_32_BIT_APPS := true # Temporarily leave these unset to keep all apps with JNI building as 32-bit # TARGET_SUPPORTS_32_BIT_APPS := true # TARGET_SUPPORTS_64_BIT_APPS := true Loading
core/config.mk +25 −10 Original line number Diff line number Diff line Loading @@ -231,12 +231,13 @@ combo_2nd_arch_prefix := $(TARGET_2ND_ARCH_VAR_PREFIX) include $(BUILD_SYSTEM)/combo/select.mk endif # "ro.product.cpu.abilist" is a comma separated list of ABIs (in order # of preference) that the target supports. If a TARGET_CPU_ABI_LIST # is specified by the board configuration, we use that. If not, we # build a list out of the TARGET_CPU_ABIs specified by the config. ifeq (,$(TARGET_CPU_ABI_LIST)) TARGET_CPU_ABI_LIST := $(TARGET_CPU_ABI) $(TARGET_CPU_ABI2) $(TARGET_2ND_CPU_ABI) $(TARGET_2ND_CPU_ABI2) ifdef TARGET_PREFER_32_BIT TARGET_PREFER_32_BIT_APPS := true TARGET_PREFER_32_BIT_EXECUTABLES := true endif ifeq (,$(TARGET_SUPPORTS_32_BIT_APPS)$(TARGET_SUPPORTS_64_BIT_APPS)) TARGET_SUPPORTS_32_BIT_APPS := true endif # "ro.product.cpu.abilist32" and "ro.product.cpu.abilist64" are Loading @@ -249,7 +250,7 @@ endif # is always 32 bits. If this isn't the case, these variables should # be overriden in the boarc configuration. ifeq (,$(TARGET_CPU_ABI_LIST_64_BIT)) ifeq (true,$(TARGET_IS_64_BIT)) ifeq (true|true,$(TARGET_IS_64_BIT)|$(TARGET_SUPPORTS_64_BIT_APPS)) TARGET_CPU_ABI_LIST_64_BIT := $(TARGET_CPU_ABI) $(TARGET_CPU_ABI2) endif endif Loading @@ -258,11 +259,25 @@ ifeq (,$(TARGET_CPU_ABI_LIST_32_BIT)) ifneq (true,$(TARGET_IS_64_BIT)) TARGET_CPU_ABI_LIST_32_BIT := $(TARGET_CPU_ABI) $(TARGET_CPU_ABI2) else ifeq (true,$(TARGET_SUPPORTS_32_BIT_APPS)) # For a 64 bit target, assume that the 2ND_CPU_ABI # is a 32 bit ABI. TARGET_CPU_ABI_LIST_32_BIT := $(TARGET_2ND_CPU_ABI) $(TARGET_2ND_CPU_ABI2) endif endif endif # "ro.product.cpu.abilist" is a comma separated list of ABIs (in order # of preference) that the target supports. If a TARGET_CPU_ABI_LIST # is specified by the board configuration, we use that. If not, we # build a list out of the TARGET_CPU_ABIs specified by the config. ifeq (,$(TARGET_CPU_ABI_LIST)) ifeq ($(TARGET_IS_64_BIT)|$(TARGET_PREFER_32_BIT_APPS),true|true) TARGET_CPU_ABI_LIST := $(TARGET_CPU_ABI_LIST_32_BIT) $(TARGET_CPU_ABI_LIST_64_BIT) else TARGET_CPU_ABI_LIST := $(TARGET_CPU_ABI_LIST_64_BIT) $(TARGET_CPU_ABI_LIST_32_BIT) endif endif # Strip whitespace from the ABI list string. TARGET_CPU_ABI_LIST := $(subst $(space),$(comma),$(strip $(TARGET_CPU_ABI_LIST))) Loading
core/executable.mk +3 −3 Original line number Diff line number Diff line Loading @@ -19,9 +19,9 @@ else #!LOCAL_MULTILIB == both LOCAL_NO_2ND_ARCH_MODULE_SUFFIX := true endif # if TARGET_PREFER_32_BIT is set, try to build 32-bit first # if TARGET_PREFER_32_BIT_EXECUTABLES is set, try to build 32-bit first ifdef TARGET_2ND_ARCH ifeq ($(TARGET_PREFER_32_BIT),true) ifeq ($(TARGET_PREFER_32_BIT_EXECUTABLES),true) LOCAL_2ND_ARCH_VAR_PREFIX := $(TARGET_2ND_ARCH_VAR_PREFIX) else LOCAL_2ND_ARCH_VAR_PREFIX := Loading @@ -45,7 +45,7 @@ ifndef my_skip_non_preferred_arch ifdef TARGET_2ND_ARCH # check if the non-preferred arch is the primary or secondary ifeq ($(TARGET_PREFER_32_BIT),true) ifeq ($(TARGET_PREFER_32_BIT_EXECUTABLES),true) LOCAL_2ND_ARCH_VAR_PREFIX := else LOCAL_2ND_ARCH_VAR_PREFIX := $(TARGET_2ND_ARCH_VAR_PREFIX) Loading
core/package.mk +3 −3 Original line number Diff line number Diff line Loading @@ -40,9 +40,9 @@ endif LOCAL_NO_2ND_ARCH_MODULE_SUFFIX := true # if TARGET_PREFER_32_BIT is set, try to build 32-bit first # if TARGET_PREFER_32_BIT_APPS is set, try to build 32-bit first ifdef TARGET_2ND_ARCH ifeq ($(TARGET_PREFER_32_BIT),true) ifeq ($(TARGET_PREFER_32_BIT_APPS),true) LOCAL_2ND_ARCH_VAR_PREFIX := $(TARGET_2ND_ARCH_VAR_PREFIX) else LOCAL_2ND_ARCH_VAR_PREFIX := Loading @@ -56,7 +56,7 @@ ifeq ($(my_module_arch_supported),true) include $(BUILD_SYSTEM)/package_internal.mk else ifneq (,$(TARGET_2ND_ARCH)) # check if the non-preferred arch is the primary or secondary ifeq ($(TARGET_PREFER_32_BIT),true) ifeq ($(TARGET_PREFER_32_BIT_APPS),true) LOCAL_2ND_ARCH_VAR_PREFIX := else LOCAL_2ND_ARCH_VAR_PREFIX := $(TARGET_2ND_ARCH_VAR_PREFIX) Loading
target/product/aosp_arm64.mk +1 −0 Original line number Diff line number Diff line Loading @@ -19,6 +19,7 @@ # build quite specifically for the emulator, and might not be # entirely appropriate to inherit from for on-device configurations. $(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) $(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_base_telephony.mk) $(call inherit-product, $(SRC_TARGET_DIR)/board/generic_arm64/device.mk) Loading
target/product/core_64_bit.mk 0 → 100644 +40 −0 Original line number Diff line number Diff line # # Copyright (C) 2014 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. # # Inherit from this product for devices that support 64-bit apps using: # $(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) # The inheritance for this must come before the inheritance chain that leads # to core_minimal.mk # For now this will allow 64-bit apps, but still compile all apps with JNI # for 32-bit only. # Copy the 32-bit primary, 64-bit secondary zygote startup script PRODUCT_COPY_FILES += system/core/rootdir/init.zygote32_64.rc:root/init.zygote32_64.rc # Set the zygote property to select the 32-bit primary, 64-bit secondary script # This line must be parsed before the one in core_minimal.mk PRODUCT_DEFAULT_PROPERTY_OVERRIDES += ro.zygote=zygote32_64 # Temporary hack to prefer launching processes as 32 bit # instead of 64 bit. # # STOPSHIP: Revert this to allow products to select it themselves TARGET_PREFER_32_BIT_APPS := true # Temporarily leave these unset to keep all apps with JNI building as 32-bit # TARGET_SUPPORTS_32_BIT_APPS := true # TARGET_SUPPORTS_64_BIT_APPS := true