Make sure that the C Frontend's runtime library directory is included as
authorReid Spencer <rspencer@reidspencer.com>
Wed, 12 Apr 2006 18:21:35 +0000 (18:21 +0000)
committerReid Spencer <rspencer@reidspencer.com>
Wed, 12 Apr 2006 18:21:35 +0000 (18:21 +0000)
a -L option to gccld whenever we're building a bytecode module or archive.
This gets around the "Cannot find library 'crtend'" warning messages.

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

Makefile.rules

index 42bfccbdaa1dad8ed96e154444d13686c132c28f..b9b0a2b5b7278dd135ab36999bb0beea38f87216 100644 (file)
@@ -690,7 +690,8 @@ $(warning Modules require llvm-gcc but no llvm-gcc is available ****)
 else
 
 Module     := $(LibDir)/$(MODULE_NAME).bc
-LinkModule := $(GCCLD)
+LinkModule := $(GCCLD) -L$(CFERuntimeLibDir)
+
 
 ifdef EXPORTED_SYMBOL_FILE
 LinkModule += -internalize-public-api-file=$(EXPORTED_SYMBOL_FILE)
@@ -800,7 +801,7 @@ else
 all-local:: $(LibName.BCA)
 
 ifdef EXPORTED_SYMBOL_FILE
-BCLinkLib = $(GCCLD) -internalize-public-api-file=$(EXPORTED_SYMBOL_FILE)
+BCLinkLib = $(GCCLD) -L$(CFERuntimeLibDir) -internalize-public-api-file=$(EXPORTED_SYMBOL_FILE)
 
 $(LibName.BCA): $(ObjectsBC) $(LibDir)/.dir $(GCCLD) \
                 $(LLVMToolDir)/llvm-ar