[llvm-commits] [llvm] r46432 - /llvm/trunk/Makefile.rules
Chris Lattner
sabre at nondot.org
Sun Jan 27 20:18:42 PST 2008
Author: lattner
Date: Sun Jan 27 22:18:41 2008
New Revision: 46432
URL: http://llvm.org/viewvc/llvm-project?rev=46432&view=rev
Log:
reduce duplicate -I flags passed to the compiler, cleaning up the VERBOSE
output. Patch contributed by Sam Bishop!
Modified:
llvm/trunk/Makefile.rules
Modified: llvm/trunk/Makefile.rules
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/Makefile.rules?rev=46432&r1=46431&r2=46432&view=diff
==============================================================================
--- llvm/trunk/Makefile.rules (original)
+++ llvm/trunk/Makefile.rules Sun Jan 27 22:18:41 2008
@@ -454,12 +454,11 @@
LD.Flags += -L$(LibDir) -L$(LLVMLibDir)
CPP.BaseFlags += -D_GNU_SOURCE -D__STDC_LIMIT_MACROS
# All -I flags should go here, so that they don't confuse llvm-config.
-CPP.Flags += -I$(PROJ_OBJ_DIR) -I$(PROJ_SRC_DIR) \
- -I$(PROJ_OBJ_ROOT)/include \
- -I$(PROJ_SRC_ROOT)/include \
- -I$(LLVM_OBJ_ROOT)/include \
- -I$(LLVM_SRC_ROOT)/include \
- $(CPP.BaseFlags)
+CPP.Flags += $(patsubst %,-I%/include,$(sort \
+ $(PROJ_OBJ_DIR) $(PROJ_SRC_DIR) \
+ $(PROJ_OBJ_ROOT) $(PROJ_SRC_ROOT) \
+ $(LLVM_OBJ_ROOT) $(LLVM_SRC_ROOT))) \
+ $(CPP.BaseFlags)
Compile.C = $(CC) $(CPP.Flags) $(C.Flags) $(CompileCommonOpts) -c
LTCompile.C = $(LIBTOOL) $(LibTool.Flags) --mode=compile $(Compile.C)
More information about the llvm-commits
mailing list