Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(959)

Unified Diff: native_client_sdk/src/tools/nacl_gcc.mk

Issue 118553007: [NaCl SDK] Use nacl_config.py in common.mk build system. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 12 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « native_client_sdk/src/tools/nacl_config.py ('k') | native_client_sdk/src/tools/nacl_llvm.mk » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: native_client_sdk/src/tools/nacl_gcc.mk
diff --git a/native_client_sdk/src/tools/nacl_gcc.mk b/native_client_sdk/src/tools/nacl_gcc.mk
index 2f51e361bb0309cdefd4cc1a075721c1970c9d72..22e20f010ae5b2ca65034d7ed9fe0a3e49bcc336 100644
--- a/native_client_sdk/src/tools/nacl_gcc.mk
+++ b/native_client_sdk/src/tools/nacl_gcc.mk
@@ -13,29 +13,28 @@
# We always link with the C++ compiler but include -Wl,-as-needed flag
# in LDFLAGS so the linker should drop libc++ unless it's actually needed.
#
-X86_TC_BIN ?= $(TC_PATH)/$(OSNAME)_x86_$(TOOLCHAIN)/bin
-ARM_TC_BIN ?= $(TC_PATH)/$(OSNAME)_arm_$(TOOLCHAIN)/bin
-
-X86_32_CC ?= $(NACL_COMPILER_PREFIX) $(X86_TC_BIN)/i686-nacl-gcc
-X86_32_CXX ?= $(NACL_COMPILER_PREFIX) $(X86_TC_BIN)/i686-nacl-g++
-X86_32_LINK ?= $(X86_TC_BIN)/i686-nacl-g++
-X86_32_LIB ?= $(X86_TC_BIN)/i686-nacl-ar
-X86_32_STRIP ?= $(X86_TC_BIN)/i686-nacl-strip
-X86_32_NM ?= $(X86_TC_BIN)/i686-nacl-nm
-
-X86_64_CC ?= $(NACL_COMPILER_PREFIX) $(X86_TC_BIN)/x86_64-nacl-gcc
-X86_64_CXX ?= $(NACL_COMPILER_PREFIX) $(X86_TC_BIN)/x86_64-nacl-g++
-X86_64_LINK ?= $(X86_TC_BIN)/x86_64-nacl-g++
-X86_64_LIB ?= $(X86_TC_BIN)/x86_64-nacl-ar
-X86_64_STRIP ?= $(X86_TC_BIN)/x86_64-nacl-strip
-X86_64_NM ?= $(X86_TC_BIN)/x86_64-nacl-nm
-
-ARM_CC ?= $(NACL_COMPILER_PREFIX) $(ARM_TC_BIN)/arm-nacl-gcc
-ARM_CXX ?= $(NACL_COMPILER_PREFIX) $(ARM_TC_BIN)/arm-nacl-g++
-ARM_LINK ?= $(ARM_TC_BIN)/arm-nacl-g++
-ARM_LIB ?= $(ARM_TC_BIN)/arm-nacl-ar
-ARM_STRIP ?= $(ARM_TC_BIN)/arm-nacl-strip
-ARM_NM ?= $(ARM_TC_BIN)/arm-nacl-nm
+X86_32_CC ?= $(NACL_COMPILER_PREFIX) $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a x86_32 --tool=cc)
+X86_32_CXX ?= $(NACL_COMPILER_PREFIX) $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a x86_32 --tool=c++)
+X86_32_LINK ?= $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a x86_32 --tool=c++)
+X86_32_LIB ?= $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a x86_32 --tool=ar)
+X86_32_STRIP ?= $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a x86_32 --tool=strip)
+X86_32_NM ?= $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a x86_32 --tool=nm)
+
+X86_64_CC ?= $(NACL_COMPILER_PREFIX) $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a x86_64 --tool=cc)
+X86_64_CXX ?= $(NACL_COMPILER_PREFIX) $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a x86_64 --tool=c++)
+X86_64_LINK ?= $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a x86_64 --tool=c++)
+X86_64_LIB ?= $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a x86_64 --tool=ar)
+X86_64_STRIP ?= $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a x86_64 --tool=strip)
+X86_64_NM ?= $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a x86_64 --tool=nm)
+
+ifneq ($(TOOLCHAIN),glibc)
+ARM_CC ?= $(NACL_COMPILER_PREFIX) $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a arm --tool=cc)
+ARM_CXX ?= $(NACL_COMPILER_PREFIX) $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a arm --tool=c++)
+ARM_LINK ?= $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a arm --tool=c++)
+ARM_LIB ?= $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a arm --tool=ar)
+ARM_STRIP ?= $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a arm --tool=strip)
+ARM_NM ?= $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a arm --tool=nm)
+endif
NCVAL ?= python $(NACL_SDK_ROOT)/tools/ncval.py
« no previous file with comments | « native_client_sdk/src/tools/nacl_config.py ('k') | native_client_sdk/src/tools/nacl_llvm.mk » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698