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

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

Issue 914983003: [NaCl SDK] Switch ppapi_simple to C library (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update sdk_files.list Created 5 years, 10 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
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 37fb448bd0f211d0389447a161704c435aecd57e..7b130ad02c767fe2f97a83104887d77bd2066ee6 100644
--- a/native_client_sdk/src/tools/nacl_gcc.mk
+++ b/native_client_sdk/src/tools/nacl_gcc.mk
@@ -393,6 +393,62 @@ endef
#
+# Macro to generate linker scripts
+#
+# $1 = Target Name
+# $2 = Static Linker Script
+# $3 = Shared Linker Script
+#
+define LINKER_SCRIPT_RULE
+$(STAMPDIR)/$(1).stamp:
+ @echo " STAMP $$@"
+ @echo "TOUCHED $$@" > $(STAMPDIR)/$(1).stamp
+
+ifneq (,$(findstring x86_32,$(ARCHES)))
+$(STAMPDIR)/$(1).stamp: $(LIBDIR)/$(TOOLCHAIN)_x86_32/$(CONFIG)/lib$(1).a
+install: $(LIBDIR)/$(TOOLCHAIN)_x86_32/$(CONFIG)/lib$(1).a
+$(LIBDIR)/$(TOOLCHAIN)_x86_32/$(CONFIG)/lib$(1).a: $(2)
+ $(MKDIR) -p $$(dir $$@)
+ $(call LOG,CP ,$$@,$(OSHELPERS) cp $$^ $$@)
+endif
+
+ifneq (,$(findstring x86_64,$(ARCHES)))
+$(STAMPDIR)/$(1).stamp: $(LIBDIR)/$(TOOLCHAIN)_x86_64/$(CONFIG)/lib$(1).a
+install: $(LIBDIR)/$(TOOLCHAIN)_x86_64/$(CONFIG)/lib$(1).a
+$(LIBDIR)/$(TOOLCHAIN)_x86_64/$(CONFIG)/lib$(1).a: $(2)
+ $(MKDIR) -p $$(dir $$@)
+ $(call LOG,CP ,$$@,$(OSHELPERS) cp $$^ $$@)
+endif
+
+ifneq (,$(findstring arm,$(ARCHES)))
+$(STAMPDIR)/$(1).stamp: $(LIBDIR)/$(TOOLCHAIN)_arm/$(CONFIG)/lib$(1).a
+install: $(LIBDIR)/$(TOOLCHAIN)_arm/$(CONFIG)/lib$(1).a
+$(LIBDIR)/$(TOOLCHAIN)_arm/$(CONFIG)/lib$(1).a: $(2)
+ $(MKDIR) -p $$(dir $$@)
+ $(call LOG,CP ,$$@,$(OSHELPERS) cp $$^ $$@)
+endif
+
+ifeq ($(TOOLCHAIN),glibc)
+ifneq (,$(findstring x86_32,$(ARCHES)))
+$(STAMPDIR)/$(1).stamp: $(LIBDIR)/$(TOOLCHAIN)_x86_32/$(CONFIG)/lib$(1).so
+install: $(LIBDIR)/$(TOOLCHAIN)_x86_32/$(CONFIG)/lib$(1).so
+$(LIBDIR)/$(TOOLCHAIN)_x86_32/$(CONFIG)/lib$(1).so: $(3)
+ $(MKDIR) -p $$(dir $$@)
+ $(call LOG,CP ,$$@,$(OSHELPERS) cp $$^ $$@)
+endif
+
+ifneq (,$(findstring x86_64,$(ARCHES)))
+$(STAMPDIR)/$(1).stamp: $(LIBDIR)/$(TOOLCHAIN)_x86_64/$(CONFIG)/lib$(1).so
+install: $(LIBDIR)/$(TOOLCHAIN)_x86_64/$(CONFIG)/lib$(1).so
+$(LIBDIR)/$(TOOLCHAIN)_x86_64/$(CONFIG)/lib$(1).so: $(3)
+ $(MKDIR) -p $$(dir $$@)
+ $(call LOG,CP ,$$@,$(OSHELPERS) cp $$^ $$@)
+endif
+endif
+endef
+
+
+#
# Strip Macro for each arch (e.g., each arch supported by LINKER_RULE).
#
# $1 = Target Name

Powered by Google App Engine
This is Rietveld 408576698