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

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

Issue 1559463002: [NaCl SDK] Don't include gtest/gmock in library form (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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/tests/sdk_util_test/example.dsc ('k') | native_client_sdk/src/tools/host_vc.mk » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: native_client_sdk/src/tools/common.mk
diff --git a/native_client_sdk/src/tools/common.mk b/native_client_sdk/src/tools/common.mk
index c3227985c1c9d84fd77bc5143a11d192e15bad25..f43ed63e5f1bedd7c772379c6ef90d6f2212bca7 100644
--- a/native_client_sdk/src/tools/common.mk
+++ b/native_client_sdk/src/tools/common.mk
@@ -379,12 +379,16 @@ endif
#
# Convert a source path to a object file path.
+# If source path is absolute then just use the basename of for the object
+# file name (absolute sources paths with the same basename are not allowed).
+# For relative paths use the full path to the source in the object file path
+# name.
#
# $1 = Source Name
# $2 = Arch suffix
#
define SRC_TO_OBJ
-$(OUTDIR)/$(basename $(subst ..,__,$(1)))$(2).o
+$(if $(filter /%,$(1)), $(OUTDIR)/$(basename $(notdir $(1)))$(2).o, $(OUTDIR)/$(basename $(subst ..,__,$(1)))$(2).o)
endef
« no previous file with comments | « native_client_sdk/src/tests/sdk_util_test/example.dsc ('k') | native_client_sdk/src/tools/host_vc.mk » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698