forked from OSchip/llvm-project
Makefiles: Set Clang CPP compiler flags in a single location, instead of scattered throughout the project Makefiles.
llvm-svn: 105638
This commit is contained in:
parent
e6c1daa8fd
commit
ee6b692551
|
@ -32,6 +32,12 @@ LEVEL := $(CLANG_LEVEL)/../..
|
||||||
# Include LLVM common makefile.
|
# Include LLVM common makefile.
|
||||||
include $(LEVEL)/Makefile.common
|
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.
|
# Clang Top Level specific stuff.
|
||||||
|
|
||||||
|
|
|
@ -10,8 +10,6 @@
|
||||||
CLANG_LEVEL := ../..
|
CLANG_LEVEL := ../..
|
||||||
LIBRARYNAME = PrintFunctionNames
|
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
|
# 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
|
# been configured for construction. We have to do this early so we can set up
|
||||||
# LINK_COMPONENTS before including Makefile.rules
|
# LINK_COMPONENTS before including Makefile.rules
|
||||||
|
|
|
@ -10,7 +10,6 @@
|
||||||
CLANG_LEVEL := ../..
|
CLANG_LEVEL := ../..
|
||||||
|
|
||||||
TOOLNAME = clang-interpreter
|
TOOLNAME = clang-interpreter
|
||||||
CPPFLAGS += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
NO_INSTALL = 1
|
NO_INSTALL = 1
|
||||||
|
|
||||||
# No plugins, optimize startup time.
|
# No plugins, optimize startup time.
|
||||||
|
|
|
@ -10,7 +10,6 @@
|
||||||
CLANG_LEVEL := ../..
|
CLANG_LEVEL := ../..
|
||||||
|
|
||||||
TOOLNAME = clang-wpa
|
TOOLNAME = clang-wpa
|
||||||
CPPFLAGS += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
NO_INSTALL = 1
|
NO_INSTALL = 1
|
||||||
|
|
||||||
# No plugins, optimize startup time.
|
# No plugins, optimize startup time.
|
||||||
|
|
|
@ -15,7 +15,5 @@ CLANG_LEVEL := ../..
|
||||||
LIBRARYNAME := clangAST
|
LIBRARYNAME := clangAST
|
||||||
BUILD_ARCHIVE = 1
|
BUILD_ARCHIVE = 1
|
||||||
|
|
||||||
CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
|
|
||||||
include $(CLANG_LEVEL)/Makefile
|
include $(CLANG_LEVEL)/Makefile
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,5 @@ CLANG_LEVEL := ../..
|
||||||
LIBRARYNAME := clangAnalysis
|
LIBRARYNAME := clangAnalysis
|
||||||
BUILD_ARCHIVE = 1
|
BUILD_ARCHIVE = 1
|
||||||
|
|
||||||
CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
|
|
||||||
include $(CLANG_LEVEL)/Makefile
|
include $(CLANG_LEVEL)/Makefile
|
||||||
|
|
||||||
|
|
|
@ -15,11 +15,6 @@ CLANG_LEVEL := ../..
|
||||||
LIBRARYNAME := clangBasic
|
LIBRARYNAME := clangBasic
|
||||||
BUILD_ARCHIVE = 1
|
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
|
include $(CLANG_LEVEL)/Makefile
|
||||||
|
|
||||||
SVN_REVISION := $(shell $(LLVM_SRC_ROOT)/utils/GetSourceVersion $(PROJ_SRC_DIR)/../..)
|
SVN_REVISION := $(shell $(LLVM_SRC_ROOT)/utils/GetSourceVersion $(PROJ_SRC_DIR)/../..)
|
||||||
|
|
|
@ -15,7 +15,5 @@ CLANG_LEVEL := ../..
|
||||||
LIBRARYNAME := clangChecker
|
LIBRARYNAME := clangChecker
|
||||||
BUILD_ARCHIVE = 1
|
BUILD_ARCHIVE = 1
|
||||||
|
|
||||||
CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
|
|
||||||
include $(CLANG_LEVEL)/Makefile
|
include $(CLANG_LEVEL)/Makefile
|
||||||
|
|
||||||
|
|
|
@ -16,10 +16,5 @@ CLANG_LEVEL := ../..
|
||||||
LIBRARYNAME := clangCodeGen
|
LIBRARYNAME := clangCodeGen
|
||||||
BUILD_ARCHIVE = 1
|
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
|
include $(CLANG_LEVEL)/Makefile
|
||||||
|
|
||||||
|
|
|
@ -11,6 +11,4 @@ CLANG_LEVEL := ../..
|
||||||
LIBRARYNAME := clangDriver
|
LIBRARYNAME := clangDriver
|
||||||
BUILD_ARCHIVE = 1
|
BUILD_ARCHIVE = 1
|
||||||
|
|
||||||
CPPFLAGS += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
|
|
||||||
include $(CLANG_LEVEL)/Makefile
|
include $(CLANG_LEVEL)/Makefile
|
||||||
|
|
|
@ -11,7 +11,5 @@ CLANG_LEVEL := ../..
|
||||||
LIBRARYNAME := clangFrontend
|
LIBRARYNAME := clangFrontend
|
||||||
BUILD_ARCHIVE = 1
|
BUILD_ARCHIVE = 1
|
||||||
|
|
||||||
CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
|
|
||||||
include $(CLANG_LEVEL)/Makefile
|
include $(CLANG_LEVEL)/Makefile
|
||||||
|
|
||||||
|
|
|
@ -21,7 +21,5 @@ ifeq ($(ARCH),PowerPC)
|
||||||
CXX.Flags += -maltivec
|
CXX.Flags += -maltivec
|
||||||
endif
|
endif
|
||||||
|
|
||||||
CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
|
|
||||||
include $(CLANG_LEVEL)/Makefile
|
include $(CLANG_LEVEL)/Makefile
|
||||||
|
|
||||||
|
|
|
@ -21,7 +21,5 @@ ifeq ($(ARCH),PowerPC)
|
||||||
CXX.Flags += -maltivec
|
CXX.Flags += -maltivec
|
||||||
endif
|
endif
|
||||||
|
|
||||||
CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
|
|
||||||
include $(CLANG_LEVEL)/Makefile
|
include $(CLANG_LEVEL)/Makefile
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,5 @@ CLANG_LEVEL := ../..
|
||||||
LIBRARYNAME := clangParse
|
LIBRARYNAME := clangParse
|
||||||
BUILD_ARCHIVE = 1
|
BUILD_ARCHIVE = 1
|
||||||
|
|
||||||
CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
|
|
||||||
include $(CLANG_LEVEL)/Makefile
|
include $(CLANG_LEVEL)/Makefile
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,5 @@ CLANG_LEVEL := ../..
|
||||||
LIBRARYNAME := clangRewrite
|
LIBRARYNAME := clangRewrite
|
||||||
BUILD_ARCHIVE = 1
|
BUILD_ARCHIVE = 1
|
||||||
|
|
||||||
CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
|
|
||||||
include $(CLANG_LEVEL)/Makefile
|
include $(CLANG_LEVEL)/Makefile
|
||||||
|
|
||||||
|
|
|
@ -16,7 +16,5 @@ CLANG_LEVEL := ../..
|
||||||
LIBRARYNAME := clangSema
|
LIBRARYNAME := clangSema
|
||||||
BUILD_ARCHIVE = 1
|
BUILD_ARCHIVE = 1
|
||||||
|
|
||||||
CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
|
|
||||||
include $(CLANG_LEVEL)/Makefile
|
include $(CLANG_LEVEL)/Makefile
|
||||||
|
|
||||||
|
|
|
@ -9,7 +9,6 @@
|
||||||
CLANG_LEVEL := ../..
|
CLANG_LEVEL := ../..
|
||||||
|
|
||||||
TOOLNAME = c-index-test
|
TOOLNAME = c-index-test
|
||||||
CPPFLAGS += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
|
|
||||||
# No plugins, optimize startup time.
|
# No plugins, optimize startup time.
|
||||||
TOOL_NO_EXPORTS = 1
|
TOOL_NO_EXPORTS = 1
|
||||||
|
|
|
@ -16,7 +16,6 @@ else
|
||||||
TOOLALIAS = clang++
|
TOOLALIAS = clang++
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
CPP.Flags += -I$(PROJ_SRC_DIR)/../../include -I$(PROJ_OBJ_DIR)/../../include
|
|
||||||
|
|
||||||
# Clang tool has no plugins, optimize startup time.
|
# Clang tool has no plugins, optimize startup time.
|
||||||
TOOL_NO_EXPORTS = 1
|
TOOL_NO_EXPORTS = 1
|
||||||
|
|
|
@ -12,8 +12,6 @@ LIBRARYNAME = clang
|
||||||
|
|
||||||
EXPORTED_SYMBOL_FILE = $(PROJ_SRC_DIR)/libclang.exports
|
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
|
# Include this here so we can get the configuration of the targets
|
||||||
# that have been configured for construction. We have to do this
|
# that have been configured for construction. We have to do this
|
||||||
# early so we can set up LINK_COMPONENTS before including Makefile.rules
|
# early so we can set up LINK_COMPONENTS before including Makefile.rules
|
||||||
|
|
Loading…
Reference in New Issue