[llvm-commits] CVS: llvm-java/test/Makefile.test

Alkis Evlogimenos alkis at cs.uiuc.edu
Mon Dec 13 18:59:46 PST 2004



Changes in directory llvm-java/test:

Makefile.test updated: 1.28 -> 1.29
---
Log message:

Make rules pick up any java files in a directory and compile
them. There is no need to add them explicitely now.


---
Diffs of the changes:  (+17 -18)

Index: llvm-java/test/Makefile.test
diff -u llvm-java/test/Makefile.test:1.28 llvm-java/test/Makefile.test:1.29
--- llvm-java/test/Makefile.test:1.28	Sun Dec 12 22:45:50 2004
+++ llvm-java/test/Makefile.test	Mon Dec 13 20:59:35 2004
@@ -7,8 +7,6 @@
 #
 ##===----------------------------------------------------------------------===##
 
-include $(LEVEL)/Makefile.common
-
 .PHONY: clean
 
 clean::
@@ -17,22 +15,12 @@
 
 # we don't want these files to be deleted by make, even if they are
 # intermediate results
-.PRECIOUS: Output/.dir %.linked.bc %.raw.bc %.ll %.llvm.bc
-
-# -simplifycfg -mem2reg -instcombine 
-
-# rule to link bytecode with runtime
-%.llvm %.llvm.bc: %.linked.bc $(LibDir)/libjrt.bca $(EXTRA_OBJS) $(LOPT)
-	$(Echo) Linking $< with the Java runtime
-	$(Verb)$(GCCLD) -o=$*.llvm $< -L $(LibDir) $(EXTRA_OBJS)
-
-# rule to make assembly from bytecode
-%.dis-ll: %.bc
-	$(Echo) Disassembling $<
-	$(Verb)$(LDIS) -f -o=$@ $<
+.PRECIOUS: %.linked.bc %.raw.bc %.ll %.llvm.bc
 
 # rule to compile java sources
-ifdef JAVA_TESTS
+ifdef BUILD_JAVA_SOURCES
+JAVA_SOURCES := $(wildcard *.java)
+JAVA_TESTS := $(basename $(JAVA_SOURCES))
 PREFIXED_JAVA_TESTS := $(addprefix Output/, $(JAVA_TESTS))
 PREFIXED_CLASS_FILES := $(addsuffix .class/, $(PREFIXED_JAVA_TESTS))
 
@@ -55,8 +43,6 @@
 # Keep the output and diffs
 .PRECIOUS: %.out-nat %.out-jit %.diff
 
-all:: $(DIFFS)
-
 # rule to run a .class file with the jvm
 %.out-nat: %.class
 	-$(Verb)LD_LIBRARY_PATH=$(LibDir) $(JAVA) -cp Output $(notdir $*) \
@@ -71,4 +57,17 @@
 	$(Verb)diff $*.out-nat $*.out-jit > $@ \
 	&& echo "PASS: $(notdir $*)" \
 	|| echo "FAIL: $(notdir $*)"
+
+# rule to link bytecode with runtime
+%.llvm %.llvm.bc: %.linked.bc $(LibDir)/libjrt.bca $(EXTRA_OBJS) $(LOPT)
+	$(Echo) Linking $< with the Java runtime
+	-$(Verb)$(GCCLD) -o=$*.llvm $< -L $(LibDir) $(EXTRA_OBJS)
+
+# rule to make assembly from bytecode
+%.dis-ll: %.bc
+	$(Echo) Disassembling $<
+	$(Verb)$(LDIS) -f -o=$@ $<
+
+all-local:: $(DIFFS)
+
 endif






More information about the llvm-commits mailing list