Added TOOLLINKOPTSB to pass options to the linker (e.g. adding search
authorDinakar Dhurjati <dhurjati@cs.uiuc.edu>
Wed, 29 Oct 2003 14:28:35 +0000 (14:28 +0000)
committerDinakar Dhurjati <dhurjati@cs.uiuc.edu>
Wed, 29 Oct 2003 14:28:35 +0000 (14:28 +0000)
path for external libraries).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9582 91177308-0d34-0410-b5e6-96231b3b80d8

Makefile.rules

index 65599cc795399753b1cb1a537302d1b106a27558..fb2191d4a018c2f3ab4d604329fdc8afbb375a95 100644 (file)
@@ -328,6 +328,16 @@ LinkG    := $(Link) -g -L$(PROJLIBDEBUGSOURCE)  -L$(LLVMLIBDEBUGSOURCE) $(STRIP)
 LinkO    := $(Link) -O3 -L$(PROJLIBRELEASESOURCE) -L$(LLVMLIBRELEASESOURCE)
 LinkP    := $(Link) -O3 -L$(PROJLIBPROFILESOURCE) -L$(LLVMLIBPROFILESOURCE) $(PROFILE)
 
+# TOOLLINKOPTSB to pass options to the linker like library search path etc
+# Note that this is different from TOOLLINKOPTS, these options
+# are passed to the linker *before* the USEDLIBS options are passed.
+# e.g. usage TOOLLINKOPTSB =  -L/home/xxx/lib
+ifdef TOOLLINKOPTSB
+LinkG    := $(LinkG) $(TOOLLINKOPTSB) 
+LinkO    := $(LinkG) $(TOOLLINKOPTSB) 
+LinkP    := $(LinkG) $(TOOLLINKOPTSB) 
+endif
+
 # Create one .o file from a bunch of .o files...
 Relink := ${LIBTOOL} --mode=link $(CXX)