]> granicus.if.org Git - clang/commitdiff
Makefiles: Set Clang CPP compiler flags in a single location, instead of scattered...
authorDaniel Dunbar <daniel@zuster.org>
Tue, 8 Jun 2010 20:44:43 +0000 (20:44 +0000)
committerDaniel Dunbar <daniel@zuster.org>
Tue, 8 Jun 2010 20:44:43 +0000 (20:44 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@105638 91177308-0d34-0410-b5e6-96231b3b80d8

19 files changed:
Makefile
examples/PrintFunctionNames/Makefile
examples/clang-interpreter/Makefile
examples/wpa/Makefile
lib/AST/Makefile
lib/Analysis/Makefile
lib/Basic/Makefile
lib/Checker/Makefile
lib/CodeGen/Makefile
lib/Driver/Makefile
lib/Frontend/Makefile
lib/Index/Makefile
lib/Lex/Makefile
lib/Parse/Makefile
lib/Rewrite/Makefile
lib/Sema/Makefile
tools/c-index-test/Makefile
tools/driver/Makefile
tools/libclang/Makefile

index 7b2a365f973711086a347be07a1673079591d0b5..acb620dddd2054cedfae178b6e45bb17a13866ca 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -32,6 +32,12 @@ LEVEL := $(CLANG_LEVEL)/../..
 # Include LLVM common makefile.
 include $(LEVEL)/Makefile.common
 
+# Set common Clang build flags.
+CPP.Flags += -I$(PROJ_SRC_DIR)/$(CLANG_LEVEL)/include -I$(PROJ_OBJ_DIR)/$(CLANG_LEVEL)/include
+ifdef CLANG_VENDOR
+CPP.Flags += -DCLANG_VENDOR='"$(CLANG_VENDOR) "'
+endif
+
 ###
 # Clang Top Level specific stuff.
 
index 4136a98c5cdcf8f99311fdf60ae8bdb21024cc32..fe9712f8f222bcfbc062faa165915d398fbd7a40 100644 (file)
@@ -10,8 +10,6 @@
 CLANG_LEVEL := ../..
 LIBRARYNAME = PrintFunctionNames
 
-CPPFLAGS += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-
 # Include this here so we can get the configuration of the targets that have
 # been configured for construction. We have to do this early so we can set up
 # LINK_COMPONENTS before including Makefile.rules
index 6683a57c3b9c1c6e6c141ee6c98afb829f7dbcad..e46b2037b9d6d3176fd7793b82f54769c47ce097 100644 (file)
@@ -10,7 +10,6 @@
 CLANG_LEVEL := ../..
 
 TOOLNAME = clang-interpreter
-CPPFLAGS += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
 NO_INSTALL = 1
 
 # No plugins, optimize startup time.
index 16f92804aca79a6acad0bb12af3155df331076b8..2c2154d8d303f745e56da59088c25522df3c26b3 100644 (file)
@@ -10,7 +10,6 @@
 CLANG_LEVEL := ../..
 
 TOOLNAME = clang-wpa
-CPPFLAGS += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
 NO_INSTALL = 1
 
 # No plugins, optimize startup time.
index a4bb9aa99db7af19f556da2c2f37919ae067286d..7a1672b81728e3279321ba8e9004e9f878d49088 100644 (file)
@@ -15,7 +15,5 @@ CLANG_LEVEL := ../..
 LIBRARYNAME := clangAST
 BUILD_ARCHIVE = 1
 
-CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-
 include $(CLANG_LEVEL)/Makefile
 
index e9950fc440789497ea92186e13119a940b8bdeff..03bf7a6712f3027d7a632b6b9c68fbfd8b5410d2 100644 (file)
@@ -15,7 +15,5 @@ CLANG_LEVEL := ../..
 LIBRARYNAME := clangAnalysis
 BUILD_ARCHIVE = 1
 
-CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-
 include $(CLANG_LEVEL)/Makefile
 
index f36a1bcff6e25514a5f119f3032faa459bc0b385..51b8ac1b45695adf4b0f35df1ee7aa1e8c6d881f 100644 (file)
@@ -15,11 +15,6 @@ CLANG_LEVEL := ../..
 LIBRARYNAME := clangBasic
 BUILD_ARCHIVE = 1
 
-CPPFLAGS += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-ifdef CLANG_VENDOR
-CPPFLAGS += -DCLANG_VENDOR='"$(CLANG_VENDOR) "'
-endif
-
 include $(CLANG_LEVEL)/Makefile
 
 SVN_REVISION := $(shell $(LLVM_SRC_ROOT)/utils/GetSourceVersion $(PROJ_SRC_DIR)/../..)
index fc2bc507219c4f39f9b9664d02fed13bbe9e879a..1bc6529164035b83f3899762329df672d64347ff 100644 (file)
@@ -15,7 +15,5 @@ CLANG_LEVEL := ../..
 LIBRARYNAME := clangChecker
 BUILD_ARCHIVE = 1
 
-CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-
 include $(CLANG_LEVEL)/Makefile
 
index cfa021794235edcc4918b09ca3c0d7b3ec24782e..4b93524267aedc0a2080cdc86bde3ced4d26a73c 100644 (file)
@@ -16,10 +16,5 @@ CLANG_LEVEL := ../..
 LIBRARYNAME := clangCodeGen
 BUILD_ARCHIVE = 1
 
-CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-ifdef CLANG_VENDOR
-CPP.Flags += -DCLANG_VENDOR='"$(CLANG_VENDOR) "'
-endif
-
 include $(CLANG_LEVEL)/Makefile
 
index 5ee4abc99ca8c2ae7446d3ba094c35a5ac9f5f3b..7bc340e109d3e3c1c52a40f38605c414723f1123 100644 (file)
@@ -11,6 +11,4 @@ CLANG_LEVEL := ../..
 LIBRARYNAME := clangDriver
 BUILD_ARCHIVE = 1
 
-CPPFLAGS += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-
 include $(CLANG_LEVEL)/Makefile
index 962568b58d21e0823d4ef8edd805cee72d302af9..3eb4bc95f4c3fcaf1e1f81d8a07f318899b780c5 100644 (file)
@@ -11,7 +11,5 @@ CLANG_LEVEL := ../..
 LIBRARYNAME := clangFrontend
 BUILD_ARCHIVE = 1
 
-CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-
 include $(CLANG_LEVEL)/Makefile
 
index 191e9d4b595dc434d70137f51c204fb5f4e1fc0a..c902db0d56bf25ce9f0be553d44ccab098f0e006 100644 (file)
@@ -21,7 +21,5 @@ ifeq ($(ARCH),PowerPC)
 CXX.Flags += -maltivec
 endif
 
-CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-
 include $(CLANG_LEVEL)/Makefile
 
index 98452146c07f1950592edd8dca7997ab27d38edb..938b8d5f05404cf322eddb3889b63dfdc27d3e5e 100644 (file)
@@ -21,7 +21,5 @@ ifeq ($(ARCH),PowerPC)
 CXX.Flags += -maltivec
 endif
 
-CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-
 include $(CLANG_LEVEL)/Makefile
 
index e6bac34be284d5a71ae887d09ecd2b63d3a4b5ea..238e02d9996cef1943c4bfc55f73e200d822bb8f 100644 (file)
@@ -15,7 +15,5 @@ CLANG_LEVEL := ../..
 LIBRARYNAME := clangParse
 BUILD_ARCHIVE = 1
 
-CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-
 include $(CLANG_LEVEL)/Makefile
 
index 29e0595c1d6a7ace99d6f0a79fd9c20956046f55..1c5b8a8117c2d1a4be4a0d2c490a188a4ddc6815 100644 (file)
@@ -15,7 +15,5 @@ CLANG_LEVEL := ../..
 LIBRARYNAME := clangRewrite
 BUILD_ARCHIVE = 1
 
-CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-
 include $(CLANG_LEVEL)/Makefile
 
index 6e13327af1a232f828a4441341446e55e61eebbc..90f2dffa0f1b02021f520a873683738b5d78ee58 100644 (file)
@@ -16,7 +16,5 @@ CLANG_LEVEL := ../..
 LIBRARYNAME := clangSema
 BUILD_ARCHIVE = 1
 
-CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-
 include $(CLANG_LEVEL)/Makefile
 
index dd39d25e579c053bd247fb491eb82e16fbcbc88e..ff3dbe9a8abfe5057931fdc91542e6546ea2301d 100644 (file)
@@ -9,7 +9,6 @@
 CLANG_LEVEL := ../..
 
 TOOLNAME = c-index-test
-CPPFLAGS += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
 
 # No plugins, optimize startup time.
 TOOL_NO_EXPORTS = 1
index 5125892efb376d2c71dab8fa6fb7b84e28ba4b9b..b1f020667a4a1e1ffc0c73224039c44f0a221c3e 100644 (file)
@@ -16,7 +16,6 @@ else
     TOOLALIAS = clang++
   endif
 endif
-CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
 
 # Clang tool has no plugins, optimize startup time.
 TOOL_NO_EXPORTS = 1
index 4cfe1260fdbecaa9e8d421dbb6b8bc7022653070..2fbdb0c6f3519afe4fda9bb9e591383f234d1e10 100644 (file)
@@ -12,8 +12,6 @@ LIBRARYNAME = clang
 
 EXPORTED_SYMBOL_FILE = $(PROJ_SRC_DIR)/libclang.exports
 
-CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
-
 # Include this here so we can get the configuration of the targets
 # that have been configured for construction. We have to do this 
 # early so we can set up LINK_COMPONENTS before including Makefile.rules