[llvm-commits] CVS: llvm/test/Programs/SingleSource/Makefile.singlesrc

John Criswell criswell at cs.uiuc.edu
Sat Sep 6 10:16:55 PDT 2003


Changes in directory llvm/test/Programs/SingleSource:

Makefile.singlesrc updated: 1.21 -> 1.22

---
Log message:

Checkin of autoconf-style object root.

Adjusted the Makefile rules to handle building outside the source directory.


---
Diffs of the changes:

Index: llvm/test/Programs/SingleSource/Makefile.singlesrc
diff -u llvm/test/Programs/SingleSource/Makefile.singlesrc:1.21 llvm/test/Programs/SingleSource/Makefile.singlesrc:1.22
--- llvm/test/Programs/SingleSource/Makefile.singlesrc:1.21	Sun Aug 17 23:33:18 2003
+++ llvm/test/Programs/SingleSource/Makefile.singlesrc	Sat Sep  6 10:13:41 2003
@@ -16,7 +16,7 @@
 #
 ##===----------------------------------------------------------------------===##
 
-PROGRAMS_TO_TEST = $(basename $(Source))
+PROGRAMS_TO_TEST = $(patsubst $(SourceDir)%,%,$(basename $(Source)))
 
 include $(LEVEL)/test/Programs/Makefile.programs
 .PRECIOUS: Output/%.linked.rll
@@ -25,14 +25,14 @@
 Output/%.linked.rll: Output/%.ll
 	cp -f $< $@
 
-Output/%.LOC.txt: %.c
+Output/%.LOC.txt: $(SourceDir)/%.c
 	cat $< | wc -l > $@
-Output/%.LOC.txt: %.cpp
+Output/%.LOC.txt: $(SourceDir)/%.cpp
 	cat $< | wc -l > $@
 endif
 
 # FIXME: LIBS should be specified, not hardcoded to -lm
-Output/%.native: %.c Output/.dir
+Output/%.native: $(SourceDir)/%.c Output/.dir
 	$(CC) $(CFLAGS) -O2 $< -lm -o $@
-Output/%.native: %.cpp Output/.dir
+Output/%.native: $(SourceDir)/%.cpp Output/.dir
 	$(CXX) $(CXXFLAGS) -O2 $< -lm -o $@





More information about the llvm-commits mailing list