From lattner at cs.uiuc.edu Mon Sep 4 00:23:34 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:23:34 -0500 Subject: [llvm-commits] CVS: llvm/Makefile.rules Message-ID: <200609040523.k845NYpT014482@zion.cs.uiuc.edu> Changes in directory llvm: Makefile.rules updated: 1.402 -> 1.403 --- Log message: Bugfix for llvm-config support --- Diffs of the changes: (+16 -13) Makefile.rules | 29 ++++++++++++++++------------- 1 files changed, 16 insertions(+), 13 deletions(-) Index: llvm/Makefile.rules diff -u llvm/Makefile.rules:1.402 llvm/Makefile.rules:1.403 --- llvm/Makefile.rules:1.402 Sun Sep 3 23:50:10 2006 +++ llvm/Makefile.rules Mon Sep 4 00:23:20 2006 @@ -73,6 +73,7 @@ ifneq ($(MakefileCommonIn),) PreConditions += $(MakefileCommon) endif + ifneq ($(MakefileConfigIn),) PreConditions += $(MakefileConfig) endif @@ -304,7 +305,7 @@ ifndef GCCLD GCCLD := $(LLVMToolDir)/gccld$(EXEEXT) endif -ifndef LDIS +ifndef LLVMDIS LLVMDIS := $(LLVMToolDir)/llvm-dis$(EXEEXT) endif ifndef LLI @@ -707,10 +708,19 @@ LLVMLibsPaths := $(addprefix $(LLVMLibDir)/,$(LLVMUsedLibs)) endif -ifneq ($(strip($(filter-out clean clean-local dist-clean,$(MAKECMDGOALS)))),) +ifeq ($(strip $(filter clean clean-local dist-clean,$(MAKECMDGOALS))),) ifdef LINK_COMPONENTS -ProjLibsOptions := $(shell $(LLVM_CONFIG) --libs $(LINK_COMPONENTS)) -ProjLibsPaths := $(shell $(LLVM_CONFIG) --libfiles $(LINK_COMPONENTS)) + +# If LLVM_CONFIG doesn't exist, build it. This can happen if you do a make +# clean in tools, then do a make in tools (instead of at the top level). +$(LLVM_CONFIG): + @echo "*** llvm-config doesn't exist - rebuilding it." + @$(MAKE) -C $(PROJ_OBJ_ROOT)/tools/llvm-config + +$(ToolDir)/$(strip $(TOOLNAME))$(EXEEXT): $(LLVM_CONFIG) + +ProjLibsOptions = $(shell $(LLVM_CONFIG) --libs $(LINK_COMPONENTS)) +ProjLibsPaths = $(shell $(LLVM_CONFIG) --libfiles $(LINK_COMPONENTS)) endif endif @@ -990,13 +1000,6 @@ endif #--------------------------------------------------------- -# Tell make that we need to rebuild subdirectories before -# we can link the tool. This affects things like LLI which -# has library subdirectories. -#--------------------------------------------------------- -$(ToolBuildPath): $(addsuffix /.makeall, $(PARALLEL_DIRS)) - -#--------------------------------------------------------- # Provide targets for building the tools #--------------------------------------------------------- all-local:: $(ToolBuildPath) @@ -1012,7 +1015,7 @@ $(ToolBuildPath): $(ToolDir)/.dir endif -$(ToolBuildPath): $(ObjectsO) $(ProjLibsPaths) $(LLVMLibsPaths) +$(ToolBuildPath): $(ObjectsO) $(LLVM_CONFIG) $(ProjLibsPaths) $(LLVMLibsPaths) $(Echo) Linking $(BuildMode) executable $(TOOLNAME) $(StripWarnMsg) $(Verb) $(LTLink) -o $@ $(TOOLLINKOPTS) $(ObjectsO) $(ProjLibsOptions) \ $(LLVMLibsOptions) $(ExtraLibs) $(TOOLLINKOPTSB) $(LIBS) @@ -1417,7 +1420,7 @@ ifndef DISABLE_AUTO_DEPENDENCIES # If its not one of the cleaning targets -ifneq ($(strip($(filter-out clean clean-local dist-clean,$(MAKECMDGOALS)))),) +ifneq ($(strip $(filter-out clean clean-local dist-clean,$(MAKECMDGOALS)))),) # Get the list of dependency files DependFiles := $(basename $(filter %.cpp %.c %.cc, $(Sources))) From lattner at cs.uiuc.edu Mon Sep 4 00:24:30 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:24:30 -0500 Subject: [llvm-commits] CVS: llvm/tools/llvm-dis/Makefile Message-ID: <200609040524.k845OUfP014524@zion.cs.uiuc.edu> Changes in directory llvm/tools/llvm-dis: Makefile updated: 1.19 -> 1.20 --- Log message: Switch to using llvm-config to build --- Diffs of the changes: (+1 -1) Makefile | 2 +- 1 files changed, 1 insertion(+), 1 deletion(-) Index: llvm/tools/llvm-dis/Makefile diff -u llvm/tools/llvm-dis/Makefile:1.19 llvm/tools/llvm-dis/Makefile:1.20 --- llvm/tools/llvm-dis/Makefile:1.19 Thu Jul 6 19:46:18 2006 +++ llvm/tools/llvm-dis/Makefile Mon Sep 4 00:24:16 2006 @@ -9,7 +9,7 @@ LEVEL = ../.. TOOLNAME = llvm-dis -USEDLIBS = LLVMBCReader.a LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS := bcreader REQUIRES_EH := 1 include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:35:37 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:35:37 -0500 Subject: [llvm-commits] CVS: llvm/tools/llvm-config/llvm-config.in.in Message-ID: <200609040535.k845ZbkD014735@zion.cs.uiuc.edu> Changes in directory llvm/tools/llvm-config: llvm-config.in.in updated: 1.22 -> 1.23 --- Log message: Allow things like --libs CBackend --- Diffs of the changes: (+3 -0) llvm-config.in.in | 3 +++ 1 files changed, 3 insertions(+) Index: llvm/tools/llvm-config/llvm-config.in.in diff -u llvm/tools/llvm-config/llvm-config.in.in:1.22 llvm/tools/llvm-config/llvm-config.in.in:1.23 --- llvm/tools/llvm-config/llvm-config.in.in:1.22 Fri Aug 11 16:50:24 2006 +++ llvm/tools/llvm-config/llvm-config.in.in Mon Sep 4 00:35:23 2006 @@ -143,6 +143,9 @@ push @components, 'all'; } +# Force component names to lower case. + at components = map lc, @components; + # Handle any arguments which require building our dependency graph. if ($want_libs || $want_libnames || $want_libfiles) { my @libs = expand_dependencies(@components); From lattner at cs.uiuc.edu Mon Sep 4 00:59:46 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:46 -0500 Subject: [llvm-commits] CVS: llvm/tools/llvm-ar/Makefile Message-ID: <200609040559.k845xkkr015221@zion.cs.uiuc.edu> Changes in directory llvm/tools/llvm-ar: Makefile updated: 1.10 -> 1.11 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+1 -2) Makefile | 3 +-- 1 files changed, 1 insertion(+), 2 deletions(-) Index: llvm/tools/llvm-ar/Makefile diff -u llvm/tools/llvm-ar/Makefile:1.10 llvm/tools/llvm-ar/Makefile:1.11 --- llvm/tools/llvm-ar/Makefile:1.10 Thu Jul 6 19:46:18 2006 +++ llvm/tools/llvm-ar/Makefile Mon Sep 4 00:59:09 2006 @@ -9,8 +9,7 @@ LEVEL = ../.. TOOLNAME = llvm-ar -USEDLIBS = LLVMArchive.a LLVMBCReader.a \ - LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS = archive bcreader REQUIRES_EH := 1 include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:46 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:46 -0500 Subject: [llvm-commits] CVS: llvm/tools/llvm-ranlib/Makefile Message-ID: <200609040559.k845xkO2015226@zion.cs.uiuc.edu> Changes in directory llvm/tools/llvm-ranlib: Makefile updated: 1.5 -> 1.6 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+1 -2) Makefile | 3 +-- 1 files changed, 1 insertion(+), 2 deletions(-) Index: llvm/tools/llvm-ranlib/Makefile diff -u llvm/tools/llvm-ranlib/Makefile:1.5 llvm/tools/llvm-ranlib/Makefile:1.6 --- llvm/tools/llvm-ranlib/Makefile:1.5 Thu Jul 6 19:46:19 2006 +++ llvm/tools/llvm-ranlib/Makefile Mon Sep 4 00:59:09 2006 @@ -9,8 +9,7 @@ LEVEL = ../.. TOOLNAME = llvm-ranlib -USEDLIBS = LLVMArchive.a LLVMBCReader.a \ - LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS = archive bcreader REQUIRES_EH := 1 include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:46 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:46 -0500 Subject: [llvm-commits] CVS: llvm/tools/bugpoint/Makefile Message-ID: <200609040559.k845xkbY015230@zion.cs.uiuc.edu> Changes in directory llvm/tools/bugpoint: Makefile updated: 1.18 -> 1.19 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+2 -7) Makefile | 9 ++------- 1 files changed, 2 insertions(+), 7 deletions(-) Index: llvm/tools/bugpoint/Makefile diff -u llvm/tools/bugpoint/Makefile:1.18 llvm/tools/bugpoint/Makefile:1.19 --- llvm/tools/bugpoint/Makefile:1.18 Thu Jul 6 19:46:18 2006 +++ llvm/tools/bugpoint/Makefile Mon Sep 4 00:59:09 2006 @@ -10,13 +10,8 @@ TOOLNAME = bugpoint -OPTLIBS = LLVMTransforms.a LLVMInstrumentation.a -ANALIBS = LLVMDataStructure LLVMipa.a LLVMTarget.a - -USEDLIBS = LLVMipo.a LLVMScalarOpts.a $(OPTLIBS) $(ANALIBS) LLVMAnalysis.a \ - LLVMTransformUtils.a \ - LLVMAsmParser.a LLVMLinker.a LLVMBCReader.a LLVMBCWriter.a \ - LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS := bcreader bcwriter asmparser instrumentation scalaropts ipo \ + datastructure transforms linker REQUIRES_EH := 1 include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:46 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:46 -0500 Subject: [llvm-commits] CVS: llvm/tools/opt/Makefile Message-ID: <200609040559.k845xk8I015231@zion.cs.uiuc.edu> Changes in directory llvm/tools/opt: Makefile updated: 1.58 -> 1.59 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+2 -4) Makefile | 6 ++---- 1 files changed, 2 insertions(+), 4 deletions(-) Index: llvm/tools/opt/Makefile diff -u llvm/tools/opt/Makefile:1.58 llvm/tools/opt/Makefile:1.59 --- llvm/tools/opt/Makefile:1.58 Sun Aug 27 17:07:01 2006 +++ llvm/tools/opt/Makefile Mon Sep 4 00:59:09 2006 @@ -10,9 +10,7 @@ TOOLNAME = opt REQUIRES_EH := 1 -USEDLIBS = LLVMBCReader.a LLVMBCWriter.a LLVMInstrumentation.a \ - LLVMScalarOpts.a LLVMipo.a LLVMipa.a LLVMDataStructure \ - LLVMTransforms.a LLVMTarget.a LLVMTransformUtils.a LLVMAnalysis.a \ - LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS := bcreader bcwriter instrumentation scalaropts ipo \ + datastructure transforms include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:47 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:47 -0500 Subject: [llvm-commits] CVS: llvm/tools/llvm-link/Makefile Message-ID: <200609040559.k845xlwk015241@zion.cs.uiuc.edu> Changes in directory llvm/tools/llvm-link: Makefile updated: 1.14 -> 1.15 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+1 -2) Makefile | 3 +-- 1 files changed, 1 insertion(+), 2 deletions(-) Index: llvm/tools/llvm-link/Makefile diff -u llvm/tools/llvm-link/Makefile:1.14 llvm/tools/llvm-link/Makefile:1.15 --- llvm/tools/llvm-link/Makefile:1.14 Thu Jul 6 19:46:18 2006 +++ llvm/tools/llvm-link/Makefile Mon Sep 4 00:59:09 2006 @@ -9,8 +9,7 @@ LEVEL = ../.. TOOLNAME = llvm-link -USEDLIBS = LLVMLinker.a LLVMBCReader.a LLVMBCWriter.a \ - LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS = linker bcreader bcwriter REQUIRES_EH := 1 include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:47 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:47 -0500 Subject: [llvm-commits] CVS: llvm/tools/llvm-ld/Makefile Message-ID: <200609040559.k845xlid015247@zion.cs.uiuc.edu> Changes in directory llvm/tools/llvm-ld: Makefile updated: 1.9 -> 1.10 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+1 -4) Makefile | 5 +---- 1 files changed, 1 insertion(+), 4 deletions(-) Index: llvm/tools/llvm-ld/Makefile diff -u llvm/tools/llvm-ld/Makefile:1.9 llvm/tools/llvm-ld/Makefile:1.10 --- llvm/tools/llvm-ld/Makefile:1.9 Thu Jul 6 19:46:18 2006 +++ llvm/tools/llvm-ld/Makefile Mon Sep 4 00:59:09 2006 @@ -10,10 +10,7 @@ LEVEL = ../.. TOOLNAME = llvm-ld -USEDLIBS = LLVMipo.a LLVMTransforms.a LLVMScalarOpts.a LLVMAnalysis.a \ - LLVMipa.a LLVMTransformUtils.a LLVMTarget.a LLVMLinker.a \ - LLVMArchive.a LLVMBCReader.a LLVMBCWriter.a \ - LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS = ipo scalaropts linker archive bcreader bcwriter REQUIRES_EH := 1 include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:48 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:48 -0500 Subject: [llvm-commits] CVS: llvm/tools/gccas/Makefile Message-ID: <200609040559.k845xmmn015257@zion.cs.uiuc.edu> Changes in directory llvm/tools/gccas: Makefile updated: 1.26 -> 1.27 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+1 -3) Makefile | 4 +--- 1 files changed, 1 insertion(+), 3 deletions(-) Index: llvm/tools/gccas/Makefile diff -u llvm/tools/gccas/Makefile:1.26 llvm/tools/gccas/Makefile:1.27 --- llvm/tools/gccas/Makefile:1.26 Thu Jul 6 19:46:18 2006 +++ llvm/tools/gccas/Makefile Mon Sep 4 00:59:09 2006 @@ -9,9 +9,7 @@ LEVEL = ../.. TOOLNAME = gccas -USEDLIBS = LLVMAsmParser.a LLVMBCWriter.a LLVMTransforms.a LLVMipo.a LLVMipa.a \ - LLVMScalarOpts.a LLVMAnalysis.a LLVMTarget.a LLVMTransformUtils.a \ - LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS = asmparser bcwriter scalaropts ipo ipa transforms REQUIRES_EH := 1 include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:49 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:49 -0500 Subject: [llvm-commits] CVS: llvm/tools/llvm2cpp/Makefile Message-ID: <200609040559.k845xnVW015262@zion.cs.uiuc.edu> Changes in directory llvm/tools/llvm2cpp: Makefile updated: 1.7 -> 1.8 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+1 -2) Makefile | 3 +-- 1 files changed, 1 insertion(+), 2 deletions(-) Index: llvm/tools/llvm2cpp/Makefile diff -u llvm/tools/llvm2cpp/Makefile:1.7 llvm/tools/llvm2cpp/Makefile:1.8 --- llvm/tools/llvm2cpp/Makefile:1.7 Thu Jul 6 19:46:19 2006 +++ llvm/tools/llvm2cpp/Makefile Mon Sep 4 00:59:09 2006 @@ -8,10 +8,9 @@ ##===----------------------------------------------------------------------===## LEVEL = ../.. TOOLNAME = llvm2cpp -USEDLIBS = LLVMBCReader.a LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS = bcreader REQUIRES_EH := 1 include $(LEVEL)/Makefile.common CompileCommonOpts := $(filter-out -pedantic,$(CompileCommonOpts)) -CompileCommonOpts := $(filter-out -Wno-long-long,$(CompileCommonOpts)) From lattner at cs.uiuc.edu Mon Sep 4 00:59:50 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:50 -0500 Subject: [llvm-commits] CVS: llvm/tools/llc/Makefile Message-ID: <200609040559.k845xol2015267@zion.cs.uiuc.edu> Changes in directory llvm/tools/llc: Makefile updated: 1.89 -> 1.90 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+2 -16) Makefile | 18 ++---------------- 1 files changed, 2 insertions(+), 16 deletions(-) Index: llvm/tools/llc/Makefile diff -u llvm/tools/llc/Makefile:1.89 llvm/tools/llc/Makefile:1.90 --- llvm/tools/llc/Makefile:1.89 Sun Sep 3 23:04:41 2006 +++ llvm/tools/llc/Makefile Mon Sep 4 00:59:09 2006 @@ -13,24 +13,10 @@ # 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 USEDLIBS properly before includeing Makefile.rules +# early so we can set up LINK_COMPONENTS before including Makefile.rules include $(LEVEL)/Makefile.config -USEDLIBS := $(addprefix LLVM,$(TARGETS_TO_BUILD)) \ - LLVMTarget.a \ - LLVMCodeGen.a \ - LLVMSelectionDAG.a \ - LLVMipa.a \ - LLVMTransforms.a \ - LLVMScalarOpts.a \ - LLVMTransformUtils.a \ - LLVMAnalysis.a \ - LLVMBCReader.a \ - LLVMBCWriter.a \ - LLVMCore.a \ - LLVMSupport.a \ - LLVMbzip2.a \ - LLVMSystem.a +LINK_COMPONENTS := $(TARGETS_TO_BUILD) bcreader include $(LLVM_SRC_ROOT)/Makefile.rules From lattner at cs.uiuc.edu Mon Sep 4 00:59:50 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:50 -0500 Subject: [llvm-commits] CVS: llvm/tools/gccld/Makefile Message-ID: <200609040559.k845xol0015282@zion.cs.uiuc.edu> Changes in directory llvm/tools/gccld: Makefile updated: 1.16 -> 1.17 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+1 -4) Makefile | 5 +---- 1 files changed, 1 insertion(+), 4 deletions(-) Index: llvm/tools/gccld/Makefile diff -u llvm/tools/gccld/Makefile:1.16 llvm/tools/gccld/Makefile:1.17 --- llvm/tools/gccld/Makefile:1.16 Thu Jul 6 19:46:18 2006 +++ llvm/tools/gccld/Makefile Mon Sep 4 00:59:09 2006 @@ -10,10 +10,7 @@ LEVEL = ../.. TOOLNAME = gccld -USEDLIBS = LLVMipo.a LLVMTransforms.a LLVMScalarOpts.a LLVMAnalysis.a \ - LLVMipa.a LLVMTransformUtils.a LLVMTarget.a LLVMLinker.a \ - LLVMArchive.a LLVMBCReader.a LLVMBCWriter.a \ - LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS = bcreader bcwriter ipo scalaropts ipa linker REQUIRES_EH := 1 include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:48 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:48 -0500 Subject: [llvm-commits] CVS: llvm/tools/llvm-nm/Makefile Message-ID: <200609040559.k845xmuo015252@zion.cs.uiuc.edu> Changes in directory llvm/tools/llvm-nm: Makefile updated: 1.8 -> 1.9 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+1 -2) Makefile | 3 +-- 1 files changed, 1 insertion(+), 2 deletions(-) Index: llvm/tools/llvm-nm/Makefile diff -u llvm/tools/llvm-nm/Makefile:1.8 llvm/tools/llvm-nm/Makefile:1.9 --- llvm/tools/llvm-nm/Makefile:1.8 Thu Jul 6 19:46:18 2006 +++ llvm/tools/llvm-nm/Makefile Mon Sep 4 00:59:09 2006 @@ -9,8 +9,7 @@ LEVEL = ../.. TOOLNAME = llvm-nm -USEDLIBS = LLVMArchive.a LLVMBCReader.a \ - LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS = archive bcreader REQUIRES_EH := 1 include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:50 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:50 -0500 Subject: [llvm-commits] CVS: llvm/tools/llvm-db/Makefile Message-ID: <200609040559.k845xo3c015277@zion.cs.uiuc.edu> Changes in directory llvm/tools/llvm-db: Makefile updated: 1.12 -> 1.13 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+1 -2) Makefile | 3 +-- 1 files changed, 1 insertion(+), 2 deletions(-) Index: llvm/tools/llvm-db/Makefile diff -u llvm/tools/llvm-db/Makefile:1.12 llvm/tools/llvm-db/Makefile:1.13 --- llvm/tools/llvm-db/Makefile:1.12 Thu Jul 20 19:10:47 2006 +++ llvm/tools/llvm-db/Makefile Mon Sep 4 00:59:09 2006 @@ -9,8 +9,7 @@ LEVEL = ../.. TOOLNAME = llvm-db -USEDLIBS = LLVMDebugger.a LLVMBCReader.a LLVMCore.a LLVMSupport.a \ - LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS := debugger bcreader REQUIRES_EH := 1 include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:50 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:50 -0500 Subject: [llvm-commits] CVS: llvm/tools/llvm-prof/Makefile Message-ID: <200609040559.k845xo7T015272@zion.cs.uiuc.edu> Changes in directory llvm/tools/llvm-prof: Makefile updated: 1.8 -> 1.9 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+1 -2) Makefile | 3 +-- 1 files changed, 1 insertion(+), 2 deletions(-) Index: llvm/tools/llvm-prof/Makefile diff -u llvm/tools/llvm-prof/Makefile:1.8 llvm/tools/llvm-prof/Makefile:1.9 --- llvm/tools/llvm-prof/Makefile:1.8 Thu Jul 6 19:46:18 2006 +++ llvm/tools/llvm-prof/Makefile Mon Sep 4 00:59:09 2006 @@ -9,8 +9,7 @@ LEVEL = ../.. TOOLNAME = llvm-prof -USEDLIBS = LLVMAnalysis.a LLVMBCReader.a \ - LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS = bcreader analysis REQUIRES_EH := 1 include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:51 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:51 -0500 Subject: [llvm-commits] CVS: llvm/tools/llvm-bcanalyzer/Makefile Message-ID: <200609040559.k845xpAJ015295@zion.cs.uiuc.edu> Changes in directory llvm/tools/llvm-bcanalyzer: Makefile updated: 1.6 -> 1.7 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+1 -1) Makefile | 2 +- 1 files changed, 1 insertion(+), 1 deletion(-) Index: llvm/tools/llvm-bcanalyzer/Makefile diff -u llvm/tools/llvm-bcanalyzer/Makefile:1.6 llvm/tools/llvm-bcanalyzer/Makefile:1.7 --- llvm/tools/llvm-bcanalyzer/Makefile:1.6 Thu Jul 6 19:46:18 2006 +++ llvm/tools/llvm-bcanalyzer/Makefile Mon Sep 4 00:59:09 2006 @@ -9,7 +9,7 @@ LEVEL = ../.. TOOLNAME = llvm-bcanalyzer -USEDLIBS = LLVMBCReader.a LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS := bcreader REQUIRES_EH := 1 include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:51 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:51 -0500 Subject: [llvm-commits] CVS: llvm/tools/lto/Makefile Message-ID: <200609040559.k845xprX015287@zion.cs.uiuc.edu> Changes in directory llvm/tools/lto: Makefile updated: 1.4 -> 1.5 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+2 -6) Makefile | 8 ++------ 1 files changed, 2 insertions(+), 6 deletions(-) Index: llvm/tools/lto/Makefile diff -u llvm/tools/lto/Makefile:1.4 llvm/tools/lto/Makefile:1.5 --- llvm/tools/lto/Makefile:1.4 Thu Aug 3 12:26:30 2006 +++ llvm/tools/lto/Makefile Mon Sep 4 00:59:09 2006 @@ -17,14 +17,10 @@ # 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 USEDLIBS properly before includeing Makefile.rules +# early so we can set up LINK_COMPONENTS before includeing Makefile.rules include $(LEVEL)/Makefile.config -USEDLIBS := $(addprefix LLVM,$(TARGETS_TO_BUILD)) \ - LLVMSelectionDAG.a LLVMCodeGen.a LLVMipo.a LLVMTransforms.a \ - LLVMScalarOpts.a LLVMipa.a LLVMTransformUtils.a LLVMAnalysis.a \ - LLVMTarget.a LLVMBCReader.a LLVMBCWriter.a LLVMSystem.a LLVMLinker.a \ - LLVMCore.a LLVMSupport.a LLVMbzip2.a +LINK_COMPONENTS := $(TARGETS_TO_BUILD) ipo scalaropts bcreader bcwriter include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:51 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:51 -0500 Subject: [llvm-commits] CVS: llvm/tools/llvm-extract/Makefile Message-ID: <200609040559.k845xpXe015300@zion.cs.uiuc.edu> Changes in directory llvm/tools/llvm-extract: Makefile updated: 1.5 -> 1.6 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+1 -3) Makefile | 4 +--- 1 files changed, 1 insertion(+), 3 deletions(-) Index: llvm/tools/llvm-extract/Makefile diff -u llvm/tools/llvm-extract/Makefile:1.5 llvm/tools/llvm-extract/Makefile:1.6 --- llvm/tools/llvm-extract/Makefile:1.5 Thu Jul 6 19:46:18 2006 +++ llvm/tools/llvm-extract/Makefile Mon Sep 4 00:59:09 2006 @@ -9,9 +9,7 @@ LEVEL = ../.. TOOLNAME = llvm-extract -USEDLIBS = LLVMBCReader.a LLVMBCWriter.a LLVMTransforms.a LLVMipo.a \ - LLVMTarget.a LLVMAnalysis.a LLVMTransformUtils.a LLVMipa.a \ - LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS := bcreader bcwriter ipo REQUIRES_EH := 1 include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 00:59:51 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 00:59:51 -0500 Subject: [llvm-commits] CVS: llvm/tools/llvmc/Makefile llvmc.cpp Message-ID: <200609040559.k845xpxu015291@zion.cs.uiuc.edu> Changes in directory llvm/tools/llvmc: Makefile updated: 1.21 -> 1.22 llvmc.cpp updated: 1.30 -> 1.31 --- Log message: Use LINK_COMPONENTS to specify *components* to link against instead of using USED_LIBS to specify *libraries* to link against. --- Diffs of the changes: (+1 -2) Makefile | 2 +- llvmc.cpp | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) Index: llvm/tools/llvmc/Makefile diff -u llvm/tools/llvmc/Makefile:1.21 llvm/tools/llvmc/Makefile:1.22 --- llvm/tools/llvmc/Makefile:1.21 Wed Aug 16 15:31:44 2006 +++ llvm/tools/llvmc/Makefile Mon Sep 4 00:59:09 2006 @@ -8,7 +8,7 @@ ##===----------------------------------------------------------------------===## LEVEL = ../.. TOOLNAME = llvmc -USEDLIBS = LLVMCore.a LLVMSupport.a LLVMSystem.a +LINK_COMPONENTS = support system CONFIG_FILES = c cpp ll EXTRA_DIST = c cpp ll ConfigLexer.cpp.cvs ConfigLexer.l.cvs REQUIRES_EH := 1 Index: llvm/tools/llvmc/llvmc.cpp diff -u llvm/tools/llvmc/llvmc.cpp:1.30 llvm/tools/llvmc/llvmc.cpp:1.31 --- llvm/tools/llvmc/llvmc.cpp:1.30 Mon Aug 21 01:04:45 2006 +++ llvm/tools/llvmc/llvmc.cpp Mon Sep 4 00:59:09 2006 @@ -295,7 +295,6 @@ if (KeepTemps) flags |= CompilerDriver::KEEP_TEMPS_FLAG; if (ShowStats) flags |= CompilerDriver::SHOW_STATS_FLAG; if (TimeActions) flags |= CompilerDriver::TIME_ACTIONS_FLAG; - if (TimePassesIsEnabled) flags |= CompilerDriver::TIME_PASSES_FLAG; if (StripOutput) flags |= CompilerDriver::STRIP_OUTPUT_FLAG; CD->setDriverFlags(flags); From lattner at cs.uiuc.edu Mon Sep 4 01:01:57 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 01:01:57 -0500 Subject: [llvm-commits] CVS: llvm/tools/lli/Makefile Message-ID: <200609040601.k8461v9r015372@zion.cs.uiuc.edu> Changes in directory llvm/tools/lli: Makefile updated: 1.49 -> 1.50 --- Log message: Use llvm-config instead of magic JIT thing to link in libs --- Diffs of the changes: (+1 -1) Makefile | 2 +- 1 files changed, 1 insertion(+), 1 deletion(-) Index: llvm/tools/lli/Makefile diff -u llvm/tools/lli/Makefile:1.49 llvm/tools/lli/Makefile:1.50 --- llvm/tools/lli/Makefile:1.49 Thu Jul 6 19:46:18 2006 +++ llvm/tools/lli/Makefile Mon Sep 4 01:01:43 2006 @@ -8,7 +8,7 @@ ##===----------------------------------------------------------------------===## LEVEL := ../.. TOOLNAME := lli -LLVMLIBS := JIT +LINK_COMPONENTS := jit interpreter native bcreader REQUIRES_EH := 1 # Enable JIT support From lattner at cs.uiuc.edu Mon Sep 4 01:04:19 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 01:04:19 -0500 Subject: [llvm-commits] CVS: llvm/examples/ModuleMaker/Makefile Message-ID: <200609040604.k8464JfM015445@zion.cs.uiuc.edu> Changes in directory llvm/examples/ModuleMaker: Makefile updated: 1.11 -> 1.12 --- Log message: Use llvm-config to determine what to link in --- Diffs of the changes: (+1 -1) Makefile | 2 +- 1 files changed, 1 insertion(+), 1 deletion(-) Index: llvm/examples/ModuleMaker/Makefile diff -u llvm/examples/ModuleMaker/Makefile:1.11 llvm/examples/ModuleMaker/Makefile:1.12 --- llvm/examples/ModuleMaker/Makefile:1.11 Fri Jul 28 17:08:23 2006 +++ llvm/examples/ModuleMaker/Makefile Mon Sep 4 01:04:03 2006 @@ -9,6 +9,6 @@ LEVEL=../.. TOOLNAME=ModuleMaker EXAMPLE_TOOL = 1 -USEDLIBS= LLVMBCWriter.a LLVMCore.a LLVMSupport.a LLVMbzip2.a LLVMSystem.a +LINK_COMPONENTS := bcwriter include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 01:04:20 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 01:04:20 -0500 Subject: [llvm-commits] CVS: llvm/examples/Fibonacci/Makefile Message-ID: <200609040604.k8464K7Q015450@zion.cs.uiuc.edu> Changes in directory llvm/examples/Fibonacci: Makefile updated: 1.7 -> 1.8 --- Log message: Use llvm-config to determine what to link in --- Diffs of the changes: (+2 -2) Makefile | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) Index: llvm/examples/Fibonacci/Makefile diff -u llvm/examples/Fibonacci/Makefile:1.7 llvm/examples/Fibonacci/Makefile:1.8 --- llvm/examples/Fibonacci/Makefile:1.7 Mon Nov 29 01:17:19 2004 +++ llvm/examples/Fibonacci/Makefile Mon Sep 4 01:04:03 2006 @@ -11,7 +11,7 @@ TOOLNAME = Fibonacci EXAMPLE_TOOL = 1 -# Enable JIT support -LLVMLIBS := JIT +# Link in JIT support +LINK_COMPONENTS := jit interpreter native include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 01:04:22 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 01:04:22 -0500 Subject: [llvm-commits] CVS: llvm/examples/ParallelJIT/Makefile Message-ID: <200609040604.k8464MnW015455@zion.cs.uiuc.edu> Changes in directory llvm/examples/ParallelJIT: Makefile updated: 1.3 -> 1.4 --- Log message: Use llvm-config to determine what to link in --- Diffs of the changes: (+1 -2) Makefile | 3 +-- 1 files changed, 1 insertion(+), 2 deletions(-) Index: llvm/examples/ParallelJIT/Makefile diff -u llvm/examples/ParallelJIT/Makefile:1.3 llvm/examples/ParallelJIT/Makefile:1.4 --- llvm/examples/ParallelJIT/Makefile:1.3 Wed Aug 24 05:07:21 2005 +++ llvm/examples/ParallelJIT/Makefile Mon Sep 4 01:04:03 2006 @@ -10,8 +10,7 @@ TOOLNAME = ParallelJIT EXAMPLE_TOOL = 1 -# Enable JIT support -LLVMLIBS := JIT +LINK_COMPONENTS := jit interpreter native include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 01:04:22 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 01:04:22 -0500 Subject: [llvm-commits] CVS: llvm/examples/HowToUseJIT/Makefile Message-ID: <200609040604.k8464Mt3015460@zion.cs.uiuc.edu> Changes in directory llvm/examples/HowToUseJIT: Makefile updated: 1.8 -> 1.9 --- Log message: Use llvm-config to determine what to link in --- Diffs of the changes: (+1 -2) Makefile | 3 +-- 1 files changed, 1 insertion(+), 2 deletions(-) Index: llvm/examples/HowToUseJIT/Makefile diff -u llvm/examples/HowToUseJIT/Makefile:1.8 llvm/examples/HowToUseJIT/Makefile:1.9 --- llvm/examples/HowToUseJIT/Makefile:1.8 Mon Nov 29 01:17:19 2004 +++ llvm/examples/HowToUseJIT/Makefile Mon Sep 4 01:04:03 2006 @@ -10,7 +10,6 @@ TOOLNAME = HowToUseJIT EXAMPLE_TOOL = 1 -# Enable JIT support -LLVMLIBS := JIT +LINK_COMPONENTS := jit interpreter native include $(LEVEL)/Makefile.common From lattner at cs.uiuc.edu Mon Sep 4 01:07:26 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 01:07:26 -0500 Subject: [llvm-commits] CVS: llvm/Makefile.rules Message-ID: <200609040607.k8467QfE015547@zion.cs.uiuc.edu> Changes in directory llvm: Makefile.rules updated: 1.403 -> 1.404 --- Log message: Remove some dead makefilery --- Diffs of the changes: (+0 -62) Makefile.rules | 62 --------------------------------------------------------- 1 files changed, 62 deletions(-) Index: llvm/Makefile.rules diff -u llvm/Makefile.rules:1.403 llvm/Makefile.rules:1.404 --- llvm/Makefile.rules:1.403 Mon Sep 4 00:23:20 2006 +++ llvm/Makefile.rules Mon Sep 4 01:07:12 2006 @@ -626,68 +626,6 @@ ############################################################################### #--------------------------------------------------------- -# Handle the special "JIT" value for LLVM_LIBS which is a -# shorthand for a bunch of libraries that get the correct -# JIT support for a library or a tool that runs JIT. -#--------------------------------------------------------- -ifeq ($(firstword $(LLVMLIBS)),config) -LLVMLIBS := $(shell $(LLVM_CONFIG) --libnames $(wordlist 2,9999,$(LLVMLIBS))) -LLVMLIBS := $(patsubst lib%.a,%.a,$(LLVMLIBS)) -LLVMLIBS := $(patsubst %.o,%,$(LLVMLIBS)) -endif - -ifeq ($(LLVMLIBS),JIT) - -# Make sure we can get our own symbols in the tool -Link += -dlopen self - -# Generic JIT libraries -JIT_LIBS := LLVMInterpreter LLVMJIT - -# You can enable the X86 JIT on a non-X86 host by setting the flag -# ENABLE_X86_JIT on the make command line. If not, it will still be -# enabled automagically on an X86 host. -ifeq ($(ARCH), x86) - ENABLE_X86_JIT = 1 -endif - -# What the X86 JIT requires -ifdef ENABLE_X86_JIT - JIT_LIBS += LLVMX86 -endif - -# You can enable the PowerPC JIT on a non-PowerPC host by setting the flag -# ENABLE_PPC_JIT on the make command line. If not, it will still be -# enabled automagically on an PowerPC host. -ifeq ($(ARCH), PowerPC) - ENABLE_PPC_JIT = 1 -endif - -# What the PowerPC JIT requires -ifdef ENABLE_PPC_JIT - JIT_LIBS += LLVMPowerPC -endif - -# You can enable the Alpha JIT on a non-Alpha host by setting the flag -# ENABLE_ALPHA_JIT on the make command line. If not, it will still be -# enabled automagically on an Alpha host. -ifeq ($(ARCH), Alpha) - ENABLE_ALPHA_JIT = 1 -endif - -# What the Alpha JIT requires -ifdef ENABLE_ALPHA_JIT - JIT_LIBS += LLVMAlpha -endif - -JIT_LIBS += LLVMTarget.a LLVMSelectionDAG.a LLVMCodeGen.a LLVMExecutionEngine - -LLVMLIBS := $(JIT_LIBS) LLVMScalarOpts.a LLVMTransformUtils.a LLVMAnalysis.a \ - LLVMBCReader.a LLVMCore.a LLVMSupport.a LLVMbzip2.a \ - LLVMSystem.a $(PLATFORMLIBDL) -endif - -#--------------------------------------------------------- # Define various command line options pertaining to the # libraries needed when linking. There are "Proj" libs # (defined by the user's project) and "LLVM" libs (defined From lattner at cs.uiuc.edu Mon Sep 4 01:12:29 2006 From: lattner at cs.uiuc.edu (Chris Lattner) Date: Mon, 4 Sep 2006 01:12:29 -0500 Subject: [llvm-commits] CVS: llvm/docs/MakefileGuide.html Message-ID: <200609040612.k846CTNK015688@zion.cs.uiuc.edu> Changes in directory llvm/docs: MakefileGuide.html updated: 1.37 -> 1.38 --- Log message: Update this to reflect llvm-config usage --- Diffs of the changes: (+11 -25) MakefileGuide.html | 36 +++++++++++------------------------- 1 files changed, 11 insertions(+), 25 deletions(-) Index: llvm/docs/MakefileGuide.html diff -u llvm/docs/MakefileGuide.html:1.37 llvm/docs/MakefileGuide.html:1.38 --- llvm/docs/MakefileGuide.html:1.37 Mon Aug 7 18:44:59 2006 +++ llvm/docs/MakefileGuide.html Mon Sep 4 01:12:14 2006 @@ -297,7 +297,7 @@
LIBRARYNAME := MyMod
LOADABLE_MODULE := 1
- USEDLIBS := LLVMSupport.a LLVMSystem.a
+ LINK_COMPONENTS := support system
Use of the LOADABLE_MODULE facility implies several things:
TOOLNAME = mytool
USEDLIBS = mylib
- LLVMLIBS = LLVMSupport.a LLVMSystem.a
+ LINK_COMPONENTS = support system
says that we are to build a tool name mytool and that it requires three libraries: mylib, LLVMSupport.a and @@ -352,36 +352,22 @@
Many tools will want to use the JIT features of LLVM. However, getting the - right set of libraries to link with is tedious, platform specific, and error - prone. Additionally, the JIT has special linker switch options that it needs. - Consequently, to make it easier to build tools that use the JIT, you can - use a special value for the LLVMLIBS variable:
+Many tools will want to use the JIT features of LLVM. To do this, you + simply specify that you want an execution 'engine', and the makefiles will + automatically link in the appropriate JIT for the host or an interpreter + if none is available:
TOOLNAME = my_jit_tool
USEDLIBS = mylib
- LLVMLIBS = JIT
+ LINK_COMPONENTS = engine
- Using a value of JIT for LLVMLIBS tells the makefile - system to construct a special value for LLVMLIBS that gives the program all - the LLVM libraries needed to run the JIT. Any additional libraries needed can - still be specified with USEDLIBS. To get a full understanding of how - this changes the linker command, it is recommended that you:
+Of course, any additional libraries may be listed as other components. To + get a full understanding of how this changes the linker command, it is + recommended that you:
cd examples/Fibonacci
make VERBOSE=1
- By default, using LLVMLIBS=JIT will link in enough to support JIT - code generation for the architecture on which the tool is linked. If you need - additional target architectures linked in, you may specify them on the command - line or in your Makefile. For example:
-- ENABLE_X86_JIT=1 - ENABLE_SPARCV9_JIT=1 - ENALBE_PPC_JIT=1 --
will cause the tool to be able to generate code for all three platforms. -