Merge "Remove (C|CPP|CONLY|LD)FLAGS checked by Soong" am: 15409e8f20

am: c78767f66d

* commit 'c78767f66d06f2edd46e10fcc5c1ee2053565549':
  Remove (C|CPP|CONLY|LD)FLAGS checked by Soong

Change-Id: I9e63f52a421f9a4358887fdb76c055b51d7903ea
This commit is contained in:
Dan Willemsen 2016-05-19 22:20:34 +00:00 committed by android-build-merger
commit 3f6927a862
24 changed files with 0 additions and 592 deletions

View file

@ -36,20 +36,4 @@ CLANG_CONFIG_x86_HOST_CROSS_EXTRA_LDFLAGS := \
$(CLANG_CONFIG_x86_HOST_CROSS_COMBO_EXTRA_LDFLAGS) \ $(CLANG_CONFIG_x86_HOST_CROSS_COMBO_EXTRA_LDFLAGS) \
-target $(CLANG_CONFIG_x86_HOST_CROSS_TRIPLE) -target $(CLANG_CONFIG_x86_HOST_CROSS_TRIPLE)
$(clang_2nd_arch_prefix)CLANG_HOST_CROSS_GLOBAL_CFLAGS := \
$(call convert-to-host-clang-flags,$($(clang_2nd_arch_prefix)HOST_CROSS_GLOBAL_CFLAGS)) \
$(CLANG_CONFIG_x86_HOST_CROSS_EXTRA_CFLAGS)
$(clang_2nd_arch_prefix)CLANG_HOST_CROSS_GLOBAL_CONLYFLAGS := \
$(call convert-to-host-clang-flags,$($(clang_2nd_arch_prefix)HOST_CROSS_GLOBAL_CONLYFLAGS)) \
$(CLANG_CONFIG_x86_HOST_CROSS_EXTRA_CONLYFLAGS)
$(clang_2nd_arch_prefix)CLANG_HOST_CROSS_GLOBAL_CPPFLAGS := \
$(call convert-to-host-clang-flags,$($(clang_2nd_arch_prefix)HOST_CROSS_GLOBAL_CPPFLAGS)) \
$(CLANG_CONFIG_x86_HOST_CROSS_EXTRA_CPPFLAGS)
$(clang_2nd_arch_prefix)CLANG_HOST_CROSS_GLOBAL_LDFLAGS := \
$(call convert-to-host-clang-flags,$($(clang_2nd_arch_prefix)HOST_CROSS_GLOBAL_LDFLAGS)) \
$(CLANG_CONFIG_x86_HOST_CROSS_EXTRA_LDFLAGS)
$(clang_2nd_arch_prefix)HOST_CROSS_LIBPROFILE_RT := $(LLVM_RTLIB_PATH)/libclang_rt.profile-i686.a $(clang_2nd_arch_prefix)HOST_CROSS_LIBPROFILE_RT := $(LLVM_RTLIB_PATH)/libclang_rt.profile-i686.a

View file

@ -36,20 +36,4 @@ CLANG_CONFIG_x86_64_HOST_CROSS_EXTRA_LDFLAGS := \
$(CLANG_CONFIG_x86_64_HOST_CROSS_COMBO_EXTRA_LDFLAGS) \ $(CLANG_CONFIG_x86_64_HOST_CROSS_COMBO_EXTRA_LDFLAGS) \
-target $(CLANG_CONFIG_x86_64_HOST_CROSS_TRIPLE) -target $(CLANG_CONFIG_x86_64_HOST_CROSS_TRIPLE)
$(clang_2nd_arch_prefix)CLANG_HOST_CROSS_GLOBAL_CFLAGS := \
$(call convert-to-host-clang-flags,$($(clang_2nd_arch_prefix)HOST_CROSS_GLOBAL_CFLAGS)) \
$(CLANG_CONFIG_x86_64_HOST_CROSS_EXTRA_CFLAGS)
$(clang_2nd_arch_prefix)CLANG_HOST_CROSS_GLOBAL_CONLYFLAGS := \
$(call convert-to-host-clang-flags,$($(clang_2nd_arch_prefix)HOST_CROSS_GLOBAL_CONLYFLAGS)) \
$(CLANG_CONFIG_x86_64_HOST_CROSS_EXTRA_CONLYFLAGS)
$(clang_2nd_arch_prefix)CLANG_HOST_CROSS_GLOBAL_CPPFLAGS := \
$(call convert-to-host-clang-flags,$($(clang_2nd_arch_prefix)HOST_CROSS_GLOBAL_CPPFLAGS)) \
$(CLANG_CONFIG_x86_64_HOST_CROSS_EXTRA_CPPFLAGS)
$(clang_2nd_arch_prefix)CLANG_HOST_CROSS_GLOBAL_LDFLAGS := \
$(call convert-to-host-clang-flags,$($(clang_2nd_arch_prefix)HOST_CROSS_GLOBAL_LDFLAGS)) \
$(CLANG_CONFIG_x86_64_HOST_CROSS_EXTRA_LDFLAGS)
$(clang_2nd_arch_prefix)HOST_CROSS_LIBPROFILE_RT := $(LLVM_RTLIB_PATH)/libclang_rt.profile-x86_64.a $(clang_2nd_arch_prefix)HOST_CROSS_LIBPROFILE_RT := $(LLVM_RTLIB_PATH)/libclang_rt.profile-x86_64.a

View file

@ -57,20 +57,4 @@ define $(clang_2nd_arch_prefix)convert-to-host-clang-flags
$(1)))) $(1))))
endef endef
$(clang_2nd_arch_prefix)CLANG_HOST_GLOBAL_CFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-host-clang-flags,$($(clang_2nd_arch_prefix)HOST_GLOBAL_CFLAGS)) \
$(CLANG_CONFIG_x86_HOST_EXTRA_CFLAGS)
$(clang_2nd_arch_prefix)CLANG_HOST_GLOBAL_CONLYFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-host-clang-flags,$($(clang_2nd_arch_prefix)HOST_GLOBAL_CONLYFLAGS)) \
$(CLANG_CONFIG_x86_HOST_EXTRA_CONLYFLAGS)
$(clang_2nd_arch_prefix)CLANG_HOST_GLOBAL_CPPFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-host-clang-flags,$($(clang_2nd_arch_prefix)HOST_GLOBAL_CPPFLAGS)) \
$(CLANG_CONFIG_x86_HOST_EXTRA_CPPFLAGS)
$(clang_2nd_arch_prefix)CLANG_HOST_GLOBAL_LDFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-host-clang-flags,$($(clang_2nd_arch_prefix)HOST_GLOBAL_LDFLAGS)) \
$(CLANG_CONFIG_x86_HOST_EXTRA_LDFLAGS)
$(clang_2nd_arch_prefix)HOST_LIBPROFILE_RT := $(LLVM_RTLIB_PATH)/libclang_rt.profile-i686.a $(clang_2nd_arch_prefix)HOST_LIBPROFILE_RT := $(LLVM_RTLIB_PATH)/libclang_rt.profile-i686.a

View file

@ -57,20 +57,4 @@ define convert-to-host-clang-flags
$(1)))) $(1))))
endef endef
CLANG_HOST_GLOBAL_CFLAGS := \
$(call convert-to-host-clang-flags,$(HOST_GLOBAL_CFLAGS)) \
$(CLANG_CONFIG_x86_64_HOST_EXTRA_CFLAGS)
CLANG_HOST_GLOBAL_CONLYFLAGS := \
$(call convert-to-host-clang-flags,$(HOST_GLOBAL_CONLYFLAGS)) \
$(CLANG_CONFIG_x86_64_HOST_EXTRA_CONLYFLAGS)
CLANG_HOST_GLOBAL_CPPFLAGS := \
$(call convert-to-host-clang-flags,$(HOST_GLOBAL_CPPFLAGS)) \
$(CLANG_CONFIG_x86_64_HOST_EXTRA_CPPFLAGS)
CLANG_HOST_GLOBAL_LDFLAGS := \
$(call convert-to-host-clang-flags,$(HOST_GLOBAL_LDFLAGS)) \
$(CLANG_CONFIG_x86_64_HOST_EXTRA_LDFLAGS)
HOST_LIBPROFILE_RT := $(LLVM_RTLIB_PATH)/libclang_rt.profile-x86_64.a HOST_LIBPROFILE_RT := $(LLVM_RTLIB_PATH)/libclang_rt.profile-x86_64.a

View file

@ -44,22 +44,6 @@ define $(clang_2nd_arch_prefix)convert-to-clang-flags
$(1)))) $(1))))
endef endef
$(clang_2nd_arch_prefix)CLANG_TARGET_GLOBAL_CFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-clang-flags,$($(clang_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS)) \
$(CLANG_CONFIG_arm_TARGET_EXTRA_CFLAGS)
$(clang_2nd_arch_prefix)CLANG_TARGET_GLOBAL_CONLYFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-clang-flags,$($(clang_2nd_arch_prefix)TARGET_GLOBAL_CONLYFLAGS)) \
$(CLANG_CONFIG_arm_TARGET_EXTRA_CONLYFLAGS)
$(clang_2nd_arch_prefix)CLANG_TARGET_GLOBAL_CPPFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-clang-flags,$($(clang_2nd_arch_prefix)TARGET_GLOBAL_CPPFLAGS)) \
$(CLANG_CONFIG_arm_TARGET_EXTRA_CPPFLAGS)
$(clang_2nd_arch_prefix)CLANG_TARGET_GLOBAL_LDFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-clang-flags,$($(clang_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS)) \
$(CLANG_CONFIG_arm_TARGET_EXTRA_LDFLAGS)
$(clang_2nd_arch_prefix)RS_TRIPLE := armv7-linux-androideabi $(clang_2nd_arch_prefix)RS_TRIPLE := armv7-linux-androideabi
$(clang_2nd_arch_prefix)RS_TRIPLE_CFLAGS := $(clang_2nd_arch_prefix)RS_TRIPLE_CFLAGS :=
$(clang_2nd_arch_prefix)RS_COMPAT_TRIPLE := armv7-none-linux-gnueabi $(clang_2nd_arch_prefix)RS_COMPAT_TRIPLE := armv7-none-linux-gnueabi

View file

@ -43,22 +43,6 @@ define convert-to-clang-flags
$(1)))) $(1))))
endef endef
CLANG_TARGET_GLOBAL_CFLAGS := \
$(call convert-to-clang-flags,$(TARGET_GLOBAL_CFLAGS)) \
$(CLANG_CONFIG_arm64_TARGET_EXTRA_CFLAGS)
CLANG_TARGET_GLOBAL_CONLYFLAGS := \
$(call convert-to-clang-flags,$(TARGET_GLOBAL_CONLYFLAGS)) \
$(CLANG_CONFIG_arm64_TARGET_EXTRA_CONLYFLAGS)
CLANG_TARGET_GLOBAL_CPPFLAGS := \
$(call convert-to-clang-flags,$(TARGET_GLOBAL_CPPFLAGS)) \
$(CLANG_CONFIG_arm64_TARGET_EXTRA_CPPFLAGS)
CLANG_TARGET_GLOBAL_LDFLAGS := \
$(call convert-to-clang-flags,$(TARGET_GLOBAL_LDFLAGS)) \
$(CLANG_CONFIG_arm64_TARGET_EXTRA_LDFLAGS)
RS_TRIPLE := aarch64-linux-android RS_TRIPLE := aarch64-linux-android
RS_TRIPLE_CFLAGS := RS_TRIPLE_CFLAGS :=
RS_COMPAT_TRIPLE := aarch64-linux-android RS_COMPAT_TRIPLE := aarch64-linux-android

View file

@ -44,22 +44,6 @@ define $(clang_2nd_arch_prefix)convert-to-clang-flags
$(1)))) $(1))))
endef endef
$(clang_2nd_arch_prefix)CLANG_TARGET_GLOBAL_CFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-clang-flags,$($(clang_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS)) \
$(CLANG_CONFIG_mips_TARGET_EXTRA_CFLAGS)
$(clang_2nd_arch_prefix)CLANG_TARGET_GLOBAL_CONLYFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-clang-flags,$($(clang_2nd_arch_prefix)TARGET_GLOBAL_CONLYFLAGS)) \
$(CLANG_CONFIG_mips_TARGET_EXTRA_CONLYFLAGS)
$(clang_2nd_arch_prefix)CLANG_TARGET_GLOBAL_CPPFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-clang-flags,$($(clang_2nd_arch_prefix)TARGET_GLOBAL_CPPFLAGS)) \
$(CLANG_CONFIG_mips_TARGET_EXTRA_CPPFLAGS)
$(clang_2nd_arch_prefix)CLANG_TARGET_GLOBAL_LDFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-clang-flags,$($(clang_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS)) \
$(CLANG_CONFIG_mips_TARGET_EXTRA_LDFLAGS)
$(clang_2nd_arch_prefix)RS_TRIPLE := armv7-linux-androideabi $(clang_2nd_arch_prefix)RS_TRIPLE := armv7-linux-androideabi
$(clang_2nd_arch_prefix)RS_TRIPLE_CFLAGS := $(clang_2nd_arch_prefix)RS_TRIPLE_CFLAGS :=
RS_COMPAT_TRIPLE := mipsel-linux-android RS_COMPAT_TRIPLE := mipsel-linux-android

View file

@ -43,22 +43,6 @@ define convert-to-clang-flags
$(1)))) $(1))))
endef endef
CLANG_TARGET_GLOBAL_CFLAGS := \
$(call convert-to-clang-flags,$(TARGET_GLOBAL_CFLAGS)) \
$(CLANG_CONFIG_mips64_TARGET_EXTRA_CFLAGS)
CLANG_TARGET_GLOBAL_CONLYFLAGS := \
$(call convert-to-clang-flags,$(TARGET_GLOBAL_CONLYFLAGS)) \
$(CLANG_CONFIG_mips64_TARGET_EXTRA_CONLYFLAGS)
CLANG_TARGET_GLOBAL_CPPFLAGS := \
$(call convert-to-clang-flags,$(TARGET_GLOBAL_CPPFLAGS)) \
$(CLANG_CONFIG_mips64_TARGET_EXTRA_CPPFLAGS)
CLANG_TARGET_GLOBAL_LDFLAGS := \
$(call convert-to-clang-flags,$(TARGET_GLOBAL_LDFLAGS)) \
$(CLANG_CONFIG_mips64_TARGET_EXTRA_LDFLAGS)
RS_TRIPLE := aarch64-linux-android RS_TRIPLE := aarch64-linux-android
RS_TRIPLE_CFLAGS := RS_TRIPLE_CFLAGS :=
RS_COMPAT_TRIPLE := mips64el-linux-android RS_COMPAT_TRIPLE := mips64el-linux-android

View file

@ -50,22 +50,6 @@ define $(clang_2nd_arch_prefix)convert-to-clang-flags
$(1)))) $(1))))
endef endef
$(clang_2nd_arch_prefix)CLANG_TARGET_GLOBAL_CFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-clang-flags,$($(clang_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS)) \
$(CLANG_CONFIG_x86_TARGET_EXTRA_CFLAGS)
$(clang_2nd_arch_prefix)CLANG_TARGET_GLOBAL_CONLYFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-clang-flags,$($(clang_2nd_arch_prefix)TARGET_GLOBAL_CONLYFLAGS)) \
$(CLANG_CONFIG_x86_TARGET_EXTRA_CONLYFLAGS)
$(clang_2nd_arch_prefix)CLANG_TARGET_GLOBAL_CPPFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-clang-flags,$($(clang_2nd_arch_prefix)TARGET_GLOBAL_CPPFLAGS)) \
$(CLANG_CONFIG_x86_TARGET_EXTRA_CPPFLAGS)
$(clang_2nd_arch_prefix)CLANG_TARGET_GLOBAL_LDFLAGS := \
$(call $(clang_2nd_arch_prefix)convert-to-clang-flags,$($(clang_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS)) \
$(CLANG_CONFIG_x86_TARGET_EXTRA_LDFLAGS)
$(clang_2nd_arch_prefix)RS_TRIPLE := armv7-linux-androideabi $(clang_2nd_arch_prefix)RS_TRIPLE := armv7-linux-androideabi
$(clang_2nd_arch_prefix)RS_TRIPLE_CFLAGS := -D__i386__ $(clang_2nd_arch_prefix)RS_TRIPLE_CFLAGS := -D__i386__
$(clang_2nd_arch_prefix)RS_COMPAT_TRIPLE := i686-linux-android $(clang_2nd_arch_prefix)RS_COMPAT_TRIPLE := i686-linux-android

View file

@ -43,22 +43,6 @@ define convert-to-clang-flags
$(1)))) $(1))))
endef endef
CLANG_TARGET_GLOBAL_CFLAGS := \
$(call convert-to-clang-flags,$(TARGET_GLOBAL_CFLAGS)) \
$(CLANG_CONFIG_x86_64_TARGET_EXTRA_CFLAGS)
CLANG_TARGET_GLOBAL_CONLYFLAGS := \
$(call convert-to-clang-flags,$(TARGET_GLOBAL_CONLYFLAGS)) \
$(CLANG_CONFIG_x86_64_TARGET_EXTRA_CONLYFLAGS)
CLANG_TARGET_GLOBAL_CPPFLAGS := \
$(call convert-to-clang-flags,$(TARGET_GLOBAL_CPPFLAGS)) \
$(CLANG_CONFIG_x86_64_TARGET_EXTRA_CPPFLAGS)
CLANG_TARGET_GLOBAL_LDFLAGS := \
$(call convert-to-clang-flags,$(TARGET_GLOBAL_LDFLAGS)) \
$(CLANG_CONFIG_x86_64_TARGET_EXTRA_LDFLAGS)
RS_TRIPLE := aarch64-linux-android RS_TRIPLE := aarch64-linux-android
RS_TRIPLE_CFLAGS := -D__x86_64__ RS_TRIPLE_CFLAGS := -D__x86_64__
RS_COMPAT_TRIPLE := x86_64-linux-android RS_COMPAT_TRIPLE := x86_64-linux-android

View file

@ -17,38 +17,14 @@
# Settings to use MinGW as a cross-compiler under Linux # Settings to use MinGW as a cross-compiler under Linux
# Included by combo/select.make # Included by combo/select.make
$(combo_var_prefix)GLOBAL_CFLAGS += -DUSE_MINGW -DWIN32_LEAN_AND_MEAN
$(combo_var_prefix)GLOBAL_CFLAGS += -Wno-unused-parameter
$(combo_var_prefix)GLOBAL_CFLAGS += --sysroot prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/x86_64-w64-mingw32
$(combo_var_prefix)GLOBAL_CFLAGS += -m32
$(combo_var_prefix)GLOBAL_LDFLAGS += -m32
$(combo_var_prefix)GLOBAL_LDFLAGS += -Lprebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/x86_64-w64-mingw32/lib32
$(combo_var_prefix)C_INCLUDES += prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/x86_64-w64-mingw32/include $(combo_var_prefix)C_INCLUDES += prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/x86_64-w64-mingw32/include
$(combo_var_prefix)C_INCLUDES += prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/lib/gcc/x86_64-w64-mingw32/4.8.3/include $(combo_var_prefix)C_INCLUDES += prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/lib/gcc/x86_64-w64-mingw32/4.8.3/include
# Workaround differences in inttypes.h between host and target.
# See bug 12708004.
$(combo_var_prefix)GLOBAL_CFLAGS += -D__STDC_FORMAT_MACROS -D__STDC_CONSTANT_MACROS
# Use C99-compliant printf functions (%zd).
$(combo_var_prefix)GLOBAL_CFLAGS += -D__USE_MINGW_ANSI_STDIO=1
# Admit to using >= Vista. Both are needed because of <_mingw.h>.
$(combo_var_prefix)GLOBAL_CFLAGS += -D_WIN32_WINNT=0x0600 -DWINVER=0x0600
# Get 64-bit off_t and related functions.
$(combo_var_prefix)GLOBAL_CFLAGS += -D_FILE_OFFSET_BITS=64
define $(combo_var_prefix)transform-shared-lib-to-toc define $(combo_var_prefix)transform-shared-lib-to-toc
$(hide) $($(PRIVATE_2ND_ARCH_VAR_PREFIX)$(PRIVATE_PREFIX)OBJDUMP) -x $(1) | grep "^Name" | cut -f3 -d" " > $(2) $(hide) $($(PRIVATE_2ND_ARCH_VAR_PREFIX)$(PRIVATE_PREFIX)OBJDUMP) -x $(1) | grep "^Name" | cut -f3 -d" " > $(2)
$(hide) $($(PRIVATE_2ND_ARCH_VAR_PREFIX)$(PRIVATE_PREFIX)NM) -g -f p $(1) | cut -f1-2 -d" " >> $(2) $(hide) $($(PRIVATE_2ND_ARCH_VAR_PREFIX)$(PRIVATE_PREFIX)NM) -g -f p $(1) | cut -f1-2 -d" " >> $(2)
endef endef
$(combo_var_prefix)GLOBAL_LDFLAGS += \
--enable-stdcall-fixup
ifneq ($(strip $(BUILD_HOST_static)),)
# Statically-linked binaries are desirable for sandboxed environment
$(combo_var_prefix)GLOBAL_LDFLAGS += -static
endif # BUILD_HOST_static
$(combo_var_prefix)SHLIB_SUFFIX := .dll $(combo_var_prefix)SHLIB_SUFFIX := .dll
$(combo_var_prefix)EXECUTABLE_SUFFIX := .exe $(combo_var_prefix)EXECUTABLE_SUFFIX := .exe

View file

@ -17,38 +17,14 @@
# Settings to use MinGW as a cross-compiler under Linux # Settings to use MinGW as a cross-compiler under Linux
# Included by combo/select.make # Included by combo/select.make
$(combo_var_prefix)GLOBAL_CFLAGS += -DUSE_MINGW -DWIN32_LEAN_AND_MEAN
$(combo_var_prefix)GLOBAL_CFLAGS += -Wno-unused-parameter
$(combo_var_prefix)GLOBAL_CFLAGS += --sysroot prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/x86_64-w64-mingw32
$(combo_var_prefix)GLOBAL_CFLAGS += -m64
$(combo_var_prefix)GLOBAL_LDFLAGS += -m64
$(combo_var_prefix)GLOBAL_LDFLAGS += -Lprebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/x86_64-w64-mingw32/lib64
$(combo_var_prefix)C_INCLUDES += prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/x86_64-w64-mingw32/include $(combo_var_prefix)C_INCLUDES += prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/x86_64-w64-mingw32/include
$(combo_var_prefix)C_INCLUDES += prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/lib/gcc/x86_64-w64-mingw32/4.8.3/include $(combo_var_prefix)C_INCLUDES += prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/lib/gcc/x86_64-w64-mingw32/4.8.3/include
# Workaround differences in inttypes.h between host and target.
# See bug 12708004.
$(combo_var_prefix)GLOBAL_CFLAGS += -D__STDC_FORMAT_MACROS -D__STDC_CONSTANT_MACROS
# Use C99-compliant printf functions (%zd).
$(combo_var_prefix)GLOBAL_CFLAGS += -D__USE_MINGW_ANSI_STDIO=1
# Admit to using >= Vista. Both are needed because of <_mingw.h>.
$(combo_var_prefix)GLOBAL_CFLAGS += -D_WIN32_WINNT=0x0600 -DWINVER=0x0600
# Get 64-bit off_t and related functions.
$(combo_var_prefix)GLOBAL_CFLAGS += -D_FILE_OFFSET_BITS=64
define $(combo_var_prefix)transform-shared-lib-to-toc define $(combo_var_prefix)transform-shared-lib-to-toc
$(hide) $($(PRIVATE_2ND_ARCH_VAR_PREFIX)$(PRIVATE_PREFIX)OBJDUMP) -x $(1) | grep "^Name" | cut -f3 -d" " > $(2) $(hide) $($(PRIVATE_2ND_ARCH_VAR_PREFIX)$(PRIVATE_PREFIX)OBJDUMP) -x $(1) | grep "^Name" | cut -f3 -d" " > $(2)
$(hide) $($(PRIVATE_2ND_ARCH_VAR_PREFIX)$(PRIVATE_PREFIX)NM) -g -f p $(1) | cut -f1-2 -d" " >> $(2) $(hide) $($(PRIVATE_2ND_ARCH_VAR_PREFIX)$(PRIVATE_PREFIX)NM) -g -f p $(1) | cut -f1-2 -d" " >> $(2)
endef endef
$(combo_var_prefix)GLOBAL_LDFLAGS += \
--enable-stdcall-fixup
ifneq ($(strip $(BUILD_HOST_static)),)
# Statically-linked binaries are desirable for sandboxed environment
$(combo_var_prefix)GLOBAL_LDFLAGS += -static
endif # BUILD_HOST_static
$(combo_var_prefix)SHLIB_SUFFIX := .dll $(combo_var_prefix)SHLIB_SUFFIX := .dll
$(combo_var_prefix)EXECUTABLE_SUFFIX := .exe $(combo_var_prefix)EXECUTABLE_SUFFIX := .exe

View file

@ -17,29 +17,12 @@
# Configuration for Darwin (Mac OS X) on x86. # Configuration for Darwin (Mac OS X) on x86.
# Included by combo/select.mk # Included by combo/select.mk
$(combo_2nd_arch_prefix)HOST_GLOBAL_CFLAGS += -m32
$(combo_2nd_arch_prefix)HOST_GLOBAL_LDFLAGS += -m32
ifneq ($(strip $(BUILD_HOST_static)),)
# Statically-linked binaries are desirable for sandboxed environment
$(combo_2nd_arch_prefix)HOST_GLOBAL_LDFLAGS += -static
endif # BUILD_HOST_static
# Workaround differences in inttypes.h between host and target.
# See bug 12708004.
$(combo_2nd_arch_prefix)HOST_GLOBAL_CFLAGS += -D__STDC_FORMAT_MACROS -D__STDC_CONSTANT_MACROS
include $(BUILD_COMBOS)/mac_version.mk include $(BUILD_COMBOS)/mac_version.mk
define $(combo_var_prefix)transform-shared-lib-to-toc define $(combo_var_prefix)transform-shared-lib-to-toc
$(call _gen_toc_command_for_macho,$(1),$(2)) $(call _gen_toc_command_for_macho,$(1),$(2))
endef endef
$(combo_2nd_arch_prefix)HOST_GLOBAL_CFLAGS += -isysroot $(mac_sdk_root) -mmacosx-version-min=$(mac_sdk_version) -DMACOSX_DEPLOYMENT_TARGET=$(mac_sdk_version)
$(combo_2nd_arch_prefix)HOST_GLOBAL_LDFLAGS += -isysroot $(mac_sdk_root) -Wl,-syslibroot,$(mac_sdk_root) -mmacosx-version-min=$(mac_sdk_version)
$(combo_2nd_arch_prefix)HOST_GLOBAL_CFLAGS += -fPIC -funwind-tables
$(combo_2nd_arch_prefix)HOST_SHLIB_SUFFIX := .dylib $(combo_2nd_arch_prefix)HOST_SHLIB_SUFFIX := .dylib
$(combo_2nd_arch_prefix)HOST_JNILIB_SUFFIX := .jnilib $(combo_2nd_arch_prefix)HOST_JNILIB_SUFFIX := .jnilib

View file

@ -17,29 +17,12 @@
# Configuration for Darwin (Mac OS X) on x86_64. # Configuration for Darwin (Mac OS X) on x86_64.
# Included by combo/select.mk # Included by combo/select.mk
HOST_GLOBAL_CFLAGS += -m64
HOST_GLOBAL_LDFLAGS += -m64
ifneq ($(strip $(BUILD_HOST_static)),)
# Statically-linked binaries are desirable for sandboxed environment
HOST_GLOBAL_LDFLAGS += -static
endif # BUILD_HOST_static
# Workaround differences in inttypes.h between host and target.
# See bug 12708004.
HOST_GLOBAL_CFLAGS += -D__STDC_FORMAT_MACROS -D__STDC_CONSTANT_MACROS
include $(BUILD_COMBOS)/mac_version.mk include $(BUILD_COMBOS)/mac_version.mk
define $(combo_var_prefix)transform-shared-lib-to-toc define $(combo_var_prefix)transform-shared-lib-to-toc
$(call _gen_toc_command_for_macho,$(1),$(2)) $(call _gen_toc_command_for_macho,$(1),$(2))
endef endef
HOST_GLOBAL_CFLAGS += -isysroot $(mac_sdk_root) -mmacosx-version-min=$(mac_sdk_version) -DMACOSX_DEPLOYMENT_TARGET=$(mac_sdk_version)
HOST_GLOBAL_LDFLAGS += -isysroot $(mac_sdk_root) -Wl,-syslibroot,$(mac_sdk_root) -mmacosx-version-min=$(mac_sdk_version)
HOST_GLOBAL_CFLAGS += -fPIC -funwind-tables
HOST_SHLIB_SUFFIX := .dylib HOST_SHLIB_SUFFIX := .dylib
HOST_JNILIB_SUFFIX := .jnilib HOST_JNILIB_SUFFIX := .jnilib

View file

@ -24,28 +24,6 @@ endef
# gcc location for clang; to be updated when clang is updated # gcc location for clang; to be updated when clang is updated
$(combo_2nd_arch_prefix)HOST_TOOLCHAIN_FOR_CLANG := prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8 $(combo_2nd_arch_prefix)HOST_TOOLCHAIN_FOR_CLANG := prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8
# We expect SSE3 floating point math.
$(combo_2nd_arch_prefix)HOST_GLOBAL_CFLAGS += -msse3 -mfpmath=sse -m32 -Wa,--noexecstack -march=prescott
$(combo_2nd_arch_prefix)HOST_GLOBAL_LDFLAGS += -m32 -Wl,-z,noexecstack -Wl,-z,relro -Wl,-z,now -Wl,--no-undefined-version
ifneq ($(strip $(BUILD_HOST_static)),)
# Statically-linked binaries are desirable for sandboxed environment
$(combo_2nd_arch_prefix)HOST_GLOBAL_LDFLAGS += -static
endif # BUILD_HOST_static
$(combo_2nd_arch_prefix)HOST_GLOBAL_CFLAGS += -fPIC \
-no-canonical-prefixes \
$(combo_2nd_arch_prefix)HOST_GLOBAL_CFLAGS += -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -fstack-protector
# Workaround differences in inttypes.h between host and target.
# See bug 12708004.
$(combo_2nd_arch_prefix)HOST_GLOBAL_CFLAGS += -D__STDC_FORMAT_MACROS -D__STDC_CONSTANT_MACROS
# We build a 32-bit host art, and right now that also means building *all* host libraries
# both 32- and 64-bit (whether art uses them or not --- 9d59f417767991246848c3e101cb27d2dfea5988).
$(combo_2nd_arch_prefix)HOST_GLOBAL_CFLAGS += -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE=1
############################################################ ############################################################
## Macros after this line are shared by the 64-bit config. ## Macros after this line are shared by the 64-bit config.

View file

@ -23,20 +23,3 @@ endef
# gcc location for clang; to be updated when clang is updated # gcc location for clang; to be updated when clang is updated
HOST_TOOLCHAIN_FOR_CLANG := prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8 HOST_TOOLCHAIN_FOR_CLANG := prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8
HOST_GLOBAL_CFLAGS += -m64 -Wa,--noexecstack
HOST_GLOBAL_LDFLAGS += -m64 -Wl,-z,noexecstack -Wl,-z,relro -Wl,-z,now -Wl,--no-undefined-version
ifneq ($(strip $(BUILD_HOST_static)),)
# Statically-linked binaries are desirable for sandboxed environment
HOST_GLOBAL_LDFLAGS += -static
endif # BUILD_HOST_static
HOST_GLOBAL_CFLAGS += -fPIC \
-no-canonical-prefixes \
HOST_GLOBAL_CFLAGS += -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -fstack-protector
# Workaround differences in inttypes.h between host and target.
# See bug 12708004.
HOST_GLOBAL_CFLAGS += -D__STDC_FORMAT_MACROS -D__STDC_CONSTANT_MACROS

View file

@ -77,45 +77,6 @@ ifeq ($(FORCE_ARM_DEBUGGING),true)
$(combo_2nd_arch_prefix)TARGET_thumb_CFLAGS += -marm -fno-omit-frame-pointer $(combo_2nd_arch_prefix)TARGET_thumb_CFLAGS += -marm -fno-omit-frame-pointer
endif endif
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS += \
-msoft-float \
-ffunction-sections \
-fdata-sections \
-funwind-tables \
-fstack-protector-strong \
-Wa,--noexecstack \
-Werror=format-security \
-D_FORTIFY_SOURCE=2 \
-fno-short-enums \
-no-canonical-prefixes \
-fno-canonical-system-headers \
$(arch_variant_cflags) \
# The "-Wunused-but-set-variable" option often breaks projects that enable
# "-Wall -Werror" due to a commom idiom "ALOGV(mesg)" where ALOGV is turned
# into no-op in some builds while mesg is defined earlier. So we explicitly
# disable "-Wunused-but-set-variable" here.
ifneq ($(filter 4.6 4.6.% 4.7 4.7.% 4.8 4.9, $($(combo_2nd_arch_prefix)TARGET_GCC_VERSION)),)
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS += -fno-builtin-sin \
-fno-strict-volatile-bitfields
endif
$(combo_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS += \
-Wl,-z,noexecstack \
-Wl,-z,relro \
-Wl,-z,now \
-Wl,--build-id=md5 \
-Wl,--warn-shared-textrel \
-Wl,--fatal-warnings \
-Wl,--icf=safe \
-Wl,--hash-style=gnu \
-Wl,--no-undefined-version \
$(arch_variant_ldflags)
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS += -mthumb-interwork
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CPPFLAGS += -fvisibility-inlines-hidden
# More flags/options can be added here # More flags/options can be added here
$(combo_2nd_arch_prefix)TARGET_RELEASE_CFLAGS := \ $(combo_2nd_arch_prefix)TARGET_RELEASE_CFLAGS := \
-DNDEBUG \ -DNDEBUG \

View file

@ -52,50 +52,6 @@ define $(combo_var_prefix)transform-shared-lib-to-toc
$(call _gen_toc_command_for_elf,$(1),$(2)) $(call _gen_toc_command_for_elf,$(1),$(2))
endef endef
TARGET_GLOBAL_CFLAGS += \
-fno-strict-aliasing \
TARGET_GLOBAL_CFLAGS += \
-fstack-protector-strong \
-ffunction-sections \
-fdata-sections \
-funwind-tables \
-Wa,--noexecstack \
-Werror=format-security \
-D_FORTIFY_SOURCE=2 \
-fno-short-enums \
-no-canonical-prefixes \
-fno-canonical-system-headers \
$(arch_variant_cflags) \
# Help catch common 32/64-bit errors.
TARGET_GLOBAL_CFLAGS += \
-Werror=pointer-to-int-cast \
-Werror=int-to-pointer-cast \
-Werror=implicit-function-declaration \
TARGET_GLOBAL_CFLAGS += -fno-strict-volatile-bitfields
TARGET_GLOBAL_LDFLAGS += \
-Wl,-z,noexecstack \
-Wl,-z,relro \
-Wl,-z,now \
-Wl,--build-id=md5 \
-Wl,--warn-shared-textrel \
-Wl,--fatal-warnings \
-Wl,-maarch64linux \
-Wl,--hash-style=gnu \
-Wl,--fix-cortex-a53-843419 \
-fuse-ld=gold \
-Wl,--icf=safe \
-Wl,--no-undefined-version \
$(arch_variant_ldflags)
# Disable transitive dependency library symbol resolving.
TARGET_GLOBAL_LDFLAGS += -Wl,--allow-shlib-undefined
TARGET_GLOBAL_CPPFLAGS += -fvisibility-inlines-hidden
# More flags/options can be added here # More flags/options can be added here
TARGET_RELEASE_CFLAGS := \ TARGET_RELEASE_CFLAGS := \
-DNDEBUG \ -DNDEBUG \

View file

@ -64,39 +64,6 @@ ifeq ($(FORCE_MIPS_DEBUGGING),true)
TARGET_mips_CFLAGS += -fno-omit-frame-pointer TARGET_mips_CFLAGS += -fno-omit-frame-pointer
endif endif
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS += \
$(TARGET_mips_CFLAGS) \
-U__unix -U__unix__ -Umips \
-ffunction-sections \
-fdata-sections \
-funwind-tables \
-fstack-protector-strong \
-Wa,--noexecstack \
-Werror=format-security \
-D_FORTIFY_SOURCE=2 \
-no-canonical-prefixes \
-fno-canonical-system-headers \
$(arch_variant_cflags) \
ifneq ($(ARCH_MIPS_PAGE_SHIFT),)
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS += -DPAGE_SHIFT=$(ARCH_MIPS_PAGE_SHIFT)
endif
$(combo_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS += \
-Wl,-z,noexecstack \
-Wl,-z,relro \
-Wl,-z,now \
-Wl,--build-id=md5 \
-Wl,--warn-shared-textrel \
-Wl,--fatal-warnings \
-Wl,--no-undefined-version \
$(arch_variant_ldflags)
# Disable transitive dependency library symbol resolving.
$(combo_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS += -Wl,--allow-shlib-undefined
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CPPFLAGS += -fvisibility-inlines-hidden
# More flags/options can be added here # More flags/options can be added here
$(combo_2nd_arch_prefix)TARGET_RELEASE_CFLAGS := \ $(combo_2nd_arch_prefix)TARGET_RELEASE_CFLAGS := \
-DNDEBUG \ -DNDEBUG \

View file

@ -64,45 +64,6 @@ ifeq ($(FORCE_MIPS_DEBUGGING),true)
TARGET_mips_CFLAGS += -fno-omit-frame-pointer TARGET_mips_CFLAGS += -fno-omit-frame-pointer
endif endif
TARGET_GLOBAL_CFLAGS += \
$(TARGET_mips_CFLAGS) \
-U__unix -U__unix__ -Umips \
-ffunction-sections \
-fdata-sections \
-funwind-tables \
-fstack-protector-strong \
-Wa,--noexecstack \
-Werror=format-security \
-D_FORTIFY_SOURCE=2 \
-no-canonical-prefixes \
-fno-canonical-system-headers \
$(arch_variant_cflags) \
# Help catch common 32/64-bit errors.
TARGET_GLOBAL_CFLAGS += \
-Werror=pointer-to-int-cast \
-Werror=int-to-pointer-cast \
-Werror=implicit-function-declaration \
ifneq ($(ARCH_MIPS_PAGE_SHIFT),)
TARGET_GLOBAL_CFLAGS += -DPAGE_SHIFT=$(ARCH_MIPS_PAGE_SHIFT)
endif
TARGET_GLOBAL_LDFLAGS += \
-Wl,-z,noexecstack \
-Wl,-z,relro \
-Wl,-z,now \
-Wl,--build-id=md5 \
-Wl,--warn-shared-textrel \
-Wl,--fatal-warnings \
-Wl,--no-undefined-version \
$(arch_variant_ldflags)
# Disable transitive dependency library symbol resolving.
TARGET_GLOBAL_LDFLAGS += -Wl,--allow-shlib-undefined
TARGET_GLOBAL_CPPFLAGS += -fvisibility-inlines-hidden
# More flags/options can be added here # More flags/options can be added here
TARGET_RELEASE_CFLAGS := \ TARGET_RELEASE_CFLAGS := \
-DNDEBUG \ -DNDEBUG \

View file

@ -52,56 +52,6 @@ KERNEL_HEADERS_COMMON += $(libc_root)/kernel/common
KERNEL_HEADERS_ARCH := $(libc_root)/kernel/uapi/asm-x86 # x86 covers both x86 and x86_64. KERNEL_HEADERS_ARCH := $(libc_root)/kernel/uapi/asm-x86 # x86 covers both x86 and x86_64.
KERNEL_HEADERS := $(KERNEL_HEADERS_COMMON) $(KERNEL_HEADERS_ARCH) KERNEL_HEADERS := $(KERNEL_HEADERS_COMMON) $(KERNEL_HEADERS_ARCH)
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS += \
-O2 \
-Wa,--noexecstack \
-Werror=format-security \
-D_FORTIFY_SOURCE=2 \
-Wstrict-aliasing=2 \
-ffunction-sections \
-finline-functions \
-finline-limit=300 \
-fno-short-enums \
-fstrict-aliasing \
-funswitch-loops \
-funwind-tables \
-fstack-protector-strong \
-m32 \
-no-canonical-prefixes \
-fno-canonical-system-headers \
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS += $(arch_variant_cflags)
ifeq ($(ARCH_X86_HAVE_SSSE3),true) # yes, really SSSE3, not SSE3!
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS += -DUSE_SSSE3 -mssse3
endif
ifeq ($(ARCH_X86_HAVE_SSE4),true)
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS += -msse4
endif
ifeq ($(ARCH_X86_HAVE_SSE4_1),true)
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS += -msse4.1
endif
ifeq ($(ARCH_X86_HAVE_SSE4_2),true)
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS += -msse4.2
endif
ifeq ($(ARCH_X86_HAVE_AVX),true)
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS += -mavx
endif
ifeq ($(ARCH_X86_HAVE_AES_NI),true)
$(combo_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS += -maes
endif
$(combo_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS += -m32
$(combo_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS += -Wl,-z,noexecstack
$(combo_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS += -Wl,-z,relro -Wl,-z,now
$(combo_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS += -Wl,--build-id=md5
$(combo_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS += -Wl,--warn-shared-textrel
$(combo_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS += -Wl,--fatal-warnings
$(combo_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS += -Wl,--gc-sections
$(combo_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS += -Wl,--hash-style=gnu
$(combo_2nd_arch_prefix)TARGET_GLOBAL_LDFLAGS += -Wl,--no-undefined-version
$(combo_2nd_arch_prefix)TARGET_C_INCLUDES := \ $(combo_2nd_arch_prefix)TARGET_C_INCLUDES := \
$(libc_root)/arch-x86/include \ $(libc_root)/arch-x86/include \
$(libc_root)/include \ $(libc_root)/include \

View file

@ -52,65 +52,6 @@ KERNEL_HEADERS_COMMON += $(libc_root)/kernel/common
KERNEL_HEADERS_ARCH := $(libc_root)/kernel/uapi/asm-x86 # x86 covers both x86 and x86_64. KERNEL_HEADERS_ARCH := $(libc_root)/kernel/uapi/asm-x86 # x86 covers both x86 and x86_64.
KERNEL_HEADERS := $(KERNEL_HEADERS_COMMON) $(KERNEL_HEADERS_ARCH) KERNEL_HEADERS := $(KERNEL_HEADERS_COMMON) $(KERNEL_HEADERS_ARCH)
TARGET_GLOBAL_CFLAGS += \
-O2 \
-Wa,--noexecstack \
-Werror=format-security \
-D_FORTIFY_SOURCE=2 \
-Wstrict-aliasing=2 \
-ffunction-sections \
-finline-functions \
-finline-limit=300 \
-fno-short-enums \
-fstrict-aliasing \
-funswitch-loops \
-funwind-tables \
-fstack-protector-strong \
-m64 \
-no-canonical-prefixes \
-fno-canonical-system-headers
# Help catch common 32/64-bit errors.
TARGET_GLOBAL_CFLAGS += \
-Werror=pointer-to-int-cast \
-Werror=int-to-pointer-cast \
-Werror=implicit-function-declaration \
TARGET_GLOBAL_CFLAGS += $(arch_variant_cflags)
ifeq ($(ARCH_X86_HAVE_SSSE3),true) # yes, really SSSE3, not SSE3!
TARGET_GLOBAL_CFLAGS += -DUSE_SSSE3 -mssse3
endif
ifeq ($(ARCH_X86_HAVE_SSE4),true)
TARGET_GLOBAL_CFLAGS += -msse4
endif
ifeq ($(ARCH_X86_HAVE_SSE4_1),true)
TARGET_GLOBAL_CFLAGS += -msse4.1
endif
ifeq ($(ARCH_X86_HAVE_SSE4_2),true)
TARGET_GLOBAL_CFLAGS += -msse4.2
endif
ifeq ($(ARCH_X86_HAVE_POPCNT),true)
TARGET_GLOBAL_CFLAGS += -mpopcnt
endif
ifeq ($(ARCH_X86_HAVE_AVX),true)
TARGET_GLOBAL_CFLAGS += -mavx
endif
ifeq ($(ARCH_X86_HAVE_AES_NI),true)
TARGET_GLOBAL_CFLAGS += -maes
endif
TARGET_GLOBAL_LDFLAGS += -m64
TARGET_GLOBAL_LDFLAGS += -Wl,-z,noexecstack
TARGET_GLOBAL_LDFLAGS += -Wl,-z,relro -Wl,-z,now
TARGET_GLOBAL_LDFLAGS += -Wl,--build-id=md5
TARGET_GLOBAL_LDFLAGS += -Wl,--warn-shared-textrel
TARGET_GLOBAL_LDFLAGS += -Wl,--fatal-warnings
TARGET_GLOBAL_LDFLAGS += -Wl,--gc-sections
TARGET_GLOBAL_LDFLAGS += -Wl,--hash-style=gnu
TARGET_GLOBAL_LDFLAGS += -Wl,--no-undefined-version
TARGET_C_INCLUDES := \ TARGET_C_INCLUDES := \
$(libc_root)/arch-x86_64/include \ $(libc_root)/arch-x86_64/include \
$(libc_root)/include \ $(libc_root)/include \

View file

@ -28,10 +28,7 @@ combo_var_prefix := $(combo_2nd_arch_prefix)$(combo_target)
# Set reasonable defaults for the various variables # Set reasonable defaults for the various variables
$(combo_var_prefix)GLOBAL_CFLAGS := -fno-exceptions -Wno-multichar
$(combo_var_prefix)RELEASE_CFLAGS := -O2 -g -fno-strict-aliasing $(combo_var_prefix)RELEASE_CFLAGS := -O2 -g -fno-strict-aliasing
$(combo_var_prefix)GLOBAL_CPPFLAGS :=
$(combo_var_prefix)GLOBAL_LDFLAGS :=
$(combo_var_prefix)GLOBAL_ARFLAGS := crsPD $(combo_var_prefix)GLOBAL_ARFLAGS := crsPD
$(combo_var_prefix)GLOBAL_LD_DIRS := $(combo_var_prefix)GLOBAL_LD_DIRS :=

View file

@ -713,16 +713,12 @@ ifeq ($(OVERRIDE_C_DATE_TIME),true)
COMMON_GLOBAL_CFLAGS += -Wno-builtin-macro-redefined -D__DATE__="\"$(BUILD_DATETIME_C_DATE)\"" -D__TIME__=\"$(BUILD_DATETIME_C_TIME)\" COMMON_GLOBAL_CFLAGS += -Wno-builtin-macro-redefined -D__DATE__="\"$(BUILD_DATETIME_C_DATE)\"" -D__TIME__=\"$(BUILD_DATETIME_C_TIME)\"
endif endif
HOST_GLOBAL_CFLAGS += $(COMMON_GLOBAL_CFLAGS)
HOST_RELEASE_CFLAGS += $(COMMON_RELEASE_CFLAGS) HOST_RELEASE_CFLAGS += $(COMMON_RELEASE_CFLAGS)
HOST_GLOBAL_CPPFLAGS += $(COMMON_GLOBAL_CPPFLAGS)
HOST_RELEASE_CPPFLAGS += $(COMMON_RELEASE_CPPFLAGS) HOST_RELEASE_CPPFLAGS += $(COMMON_RELEASE_CPPFLAGS)
TARGET_GLOBAL_CFLAGS += $(COMMON_GLOBAL_CFLAGS)
TARGET_RELEASE_CFLAGS += $(COMMON_RELEASE_CFLAGS) TARGET_RELEASE_CFLAGS += $(COMMON_RELEASE_CFLAGS)
TARGET_GLOBAL_CPPFLAGS += $(COMMON_GLOBAL_CPPFLAGS)
TARGET_RELEASE_CPPFLAGS += $(COMMON_RELEASE_CPPFLAGS) TARGET_RELEASE_CPPFLAGS += $(COMMON_RELEASE_CPPFLAGS)
HOST_GLOBAL_LD_DIRS += -L$(HOST_OUT_INTERMEDIATE_LIBRARIES) HOST_GLOBAL_LD_DIRS += -L$(HOST_OUT_INTERMEDIATE_LIBRARIES)
@ -733,71 +729,31 @@ TARGET_PROJECT_INCLUDES:= $(SRC_HEADERS) $(TARGET_OUT_HEADERS) \
$(TARGET_DEVICE_KERNEL_HEADERS) $(TARGET_BOARD_KERNEL_HEADERS) \ $(TARGET_DEVICE_KERNEL_HEADERS) $(TARGET_BOARD_KERNEL_HEADERS) \
$(TARGET_PRODUCT_KERNEL_HEADERS) $(TARGET_PRODUCT_KERNEL_HEADERS)
# Many host compilers don't support these flags, so we have to make
# sure to only specify them for the target compilers checked in to
# the source tree.
TARGET_GLOBAL_CFLAGS += $(TARGET_ERROR_FLAGS)
HOST_GLOBAL_CFLAGS += $(HOST_RELEASE_CFLAGS)
HOST_GLOBAL_CPPFLAGS += $(HOST_RELEASE_CPPFLAGS)
TARGET_GLOBAL_CFLAGS += $(TARGET_RELEASE_CFLAGS)
TARGET_GLOBAL_CPPFLAGS += $(TARGET_RELEASE_CPPFLAGS)
ifdef TARGET_2ND_ARCH ifdef TARGET_2ND_ARCH
$(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_GLOBAL_CFLAGS += $(COMMON_GLOBAL_CFLAGS)
$(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_RELEASE_CFLAGS += $(COMMON_RELEASE_CFLAGS) $(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_RELEASE_CFLAGS += $(COMMON_RELEASE_CFLAGS)
$(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_GLOBAL_CPPFLAGS += $(COMMON_GLOBAL_CPPFLAGS)
$(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_RELEASE_CPPFLAGS += $(COMMON_RELEASE_CPPFLAGS) $(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_RELEASE_CPPFLAGS += $(COMMON_RELEASE_CPPFLAGS)
$(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_GLOBAL_LD_DIRS += -L$($(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_OUT_INTERMEDIATE_LIBRARIES) $(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_GLOBAL_LD_DIRS += -L$($(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_OUT_INTERMEDIATE_LIBRARIES)
$(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_PROJECT_INCLUDES := $(TARGET_PROJECT_INCLUDES) $(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_PROJECT_INCLUDES := $(TARGET_PROJECT_INCLUDES)
$(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_GLOBAL_CFLAGS += $(TARGET_ERROR_FLAGS)
$(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_GLOBAL_CFLAGS += $($(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_RELEASE_CFLAGS)
$(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_GLOBAL_CPPFLAGS += $($(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_RELEASE_CPPFLAGS)
endif endif
ifdef HOST_2ND_ARCH ifdef HOST_2ND_ARCH
$(HOST_2ND_ARCH_VAR_PREFIX)HOST_GLOBAL_CFLAGS += $(COMMON_GLOBAL_CFLAGS)
$(HOST_2ND_ARCH_VAR_PREFIX)HOST_RELEASE_CFLAGS += $(COMMON_RELEASE_CFLAGS) $(HOST_2ND_ARCH_VAR_PREFIX)HOST_RELEASE_CFLAGS += $(COMMON_RELEASE_CFLAGS)
$(HOST_2ND_ARCH_VAR_PREFIX)HOST_GLOBAL_CPPFLAGS += $(COMMON_GLOBAL_CPPFLAGS)
$(HOST_2ND_ARCH_VAR_PREFIX)HOST_RELEASE_CPPFLAGS += $(COMMON_RELEASE_CPPFLAGS) $(HOST_2ND_ARCH_VAR_PREFIX)HOST_RELEASE_CPPFLAGS += $(COMMON_RELEASE_CPPFLAGS)
$(HOST_2ND_ARCH_VAR_PREFIX)HOST_GLOBAL_LD_DIRS += -L$($(HOST_2ND_ARCH_VAR_PREFIX)HOST_OUT_INTERMEDIATE_LIBRARIES) $(HOST_2ND_ARCH_VAR_PREFIX)HOST_GLOBAL_LD_DIRS += -L$($(HOST_2ND_ARCH_VAR_PREFIX)HOST_OUT_INTERMEDIATE_LIBRARIES)
$(HOST_2ND_ARCH_VAR_PREFIX)HOST_PROJECT_INCLUDES := $(HOST_PROJECT_INCLUDES) $(HOST_2ND_ARCH_VAR_PREFIX)HOST_PROJECT_INCLUDES := $(HOST_PROJECT_INCLUDES)
$(HOST_2ND_ARCH_VAR_PREFIX)HOST_GLOBAL_CFLAGS += $($(HOST_2ND_ARCH_VAR_PREFIX)HOST_RELEASE_CFLAGS)
$(HOST_2ND_ARCH_VAR_PREFIX)HOST_GLOBAL_CPPFLAGS += $($(HOST_2ND_ARCH_VAR_PREFIX)HOST_RELEASE_CPPFLAGS)
endif endif
ifdef HOST_CROSS_OS ifdef HOST_CROSS_OS
HOST_CROSS_GLOBAL_CFLAGS += $(filter-out $(HOST_CROSS_UNKNOWN_CFLAGS),$(COMMON_GLOBAL_CFLAGS))
HOST_CROSS_RELEASE_CFLAGS += $(COMMON_RELEASE_CFLAGS) HOST_CROSS_RELEASE_CFLAGS += $(COMMON_RELEASE_CFLAGS)
HOST_CROSS_GLOBAL_CPPFLAGS += $(COMMON_GLOBAL_CPPFLAGS)
HOST_CROSS_RELEASE_CPPFLAGS += $(COMMON_RELEASE_CPPFLAGS) HOST_CROSS_RELEASE_CPPFLAGS += $(COMMON_RELEASE_CPPFLAGS)
HOST_CROSS_GLOBAL_LD_DIRS += -L$(HOST_CROSS_OUT_INTERMEDIATE_LIBRARIES) HOST_CROSS_GLOBAL_LD_DIRS += -L$(HOST_CROSS_OUT_INTERMEDIATE_LIBRARIES)
HOST_CROSS_PROJECT_INCLUDES:= $(SRC_HEADERS) $(HOST_CROSS_OUT_HEADERS) HOST_CROSS_PROJECT_INCLUDES:= $(SRC_HEADERS) $(HOST_CROSS_OUT_HEADERS)
HOST_CROSS_GLOBAL_CFLAGS += $(HOST_CROSS_RELEASE_CFLAGS)
HOST_CROSS_GLOBAL_CPPFLAGS += $(HOST_CROSS_RELEASE_CPPFLAGS)
ifdef HOST_CROSS_2ND_ARCH ifdef HOST_CROSS_2ND_ARCH
$(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_GLOBAL_CFLAGS += $(filter-out $($(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_UNKNOWN_CFLAGS),$(COMMON_GLOBAL_CFLAGS))
$(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_RELEASE_CFLAGS += $(COMMON_RELEASE_CFLAGS) $(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_RELEASE_CFLAGS += $(COMMON_RELEASE_CFLAGS)
$(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_GLOBAL_CPPFLAGS += $(COMMON_GLOBAL_CPPFLAGS)
$(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_RELEASE_CPPFLAGS += $(COMMON_RELEASE_CPPFLAGS) $(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_RELEASE_CPPFLAGS += $(COMMON_RELEASE_CPPFLAGS)
$(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_GLOBAL_LD_DIRS += -L$($(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_OUT_INTERMEDIATE_LIBRARIES) $(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_GLOBAL_LD_DIRS += -L$($(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_OUT_INTERMEDIATE_LIBRARIES)
$(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_PROJECT_INCLUDES:= $(SRC_HEADERS) $($(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_OUT_HEADERS) $(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_PROJECT_INCLUDES:= $(SRC_HEADERS) $($(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_OUT_HEADERS)
$(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_GLOBAL_CFLAGS += $($(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_RELEASE_CFLAGS)
$(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_GLOBAL_CPPFLAGS += $($(HOST_CROSS_2ND_ARCH_VAR_PREFIX)HOST_CROSS_RELEASE_CPPFLAGS)
endif
endif
ifdef BRILLO
# Add a C define that identifies Brillo targets. __BRILLO__ should only be used
# to differentiate between Brillo and non-Brillo-but-Android environments. Use
# __ANDROID__ instead to test if something is being built in an Android-derived
# environment (including Brillo) as opposed to an entirely different
# environment (e.g. Chrome OS).
TARGET_GLOBAL_CFLAGS += -D__BRILLO__
ifdef TARGET_2ND_ARCH
$(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_GLOBAL_CFLAGS += -D__BRILLO__
endif endif
endif endif