From 338559da711d7792ba9d92e7ed0eb071fb11fac4 Mon Sep 17 00:00:00 2001 From: heck Date: Sun, 15 Dec 2019 00:43:15 +0100 Subject: [PATCH] Further project/Makefile structures for tests --- Makefile | 8 ++++---- test/Basic/Makefile | 15 ++++++++++++--- test/JNI_85/Makefile | 14 ++++++++++++-- 3 files changed, 28 insertions(+), 9 deletions(-) diff --git a/Makefile b/Makefile index b329780..e7876bc 100644 --- a/Makefile +++ b/Makefile @@ -21,14 +21,14 @@ endif .PHONY: all src test clean -all: src test +all: test + +test: src + $(MAKE) -C test compile src: $(MAKE) -C src -test: src - $(MAKE) -C test - clean: $(MAKE) -C src clean $(MAKE) -C test clean diff --git a/test/Basic/Makefile b/test/Basic/Makefile index e6f7068..0bf2735 100644 --- a/test/Basic/Makefile +++ b/test/Basic/Makefile @@ -1,18 +1,27 @@ include ../../Makefile.conf include ../Makefile.conf -.PHONY: test clean +JAVA_CLASSES = \ + Testing.class \ + SyncCallbacks.class -test: Testing.class SyncCallbacks.class +.PHONY: compile run test clean + +all: compile + $(MAKE) run + +run: compile HOME=$(PWD) CLASSPATH=$(CLASSPATH) time $(VM) Testing +compile: $(JAVA_CLASSES) + %.class: %.java CLASSPATH=$(CLASSPATH) javac $< clean: rm -f *.class rm -f *.log - rm -f .pEp_* + rm -rf .pEp_* rm -Rf .pEp rm -Rf .gnupg rm -Rf .lldb diff --git a/test/JNI_85/Makefile b/test/JNI_85/Makefile index 9958ab9..9a36766 100644 --- a/test/JNI_85/Makefile +++ b/test/JNI_85/Makefile @@ -4,12 +4,22 @@ include ../Makefile.conf #TODO: Remove when successufuly reproduce the error, and then use it to avoid regression $(info This is to be run using pEpJNIAdapter 626) -.PHONY: test clean +JAVA_CLASSES = \ + SyncCallbacks.class \ + Step1.class \ + Step2.class -test: SyncCallbacks.class Step1.class Step2.class +.PHONY: compile run test clean + +all: compile + $(MAKE) run + +run: compile -HOME=$(PWD) CLASSPATH=$(CLASSPATH) time $(VM) Step1 HOME=$(PWD) CLASSPATH=$(CLASSPATH) time $(VM) Step2 +compile: $(JAVA_CLASSES) + %.class: %.java CLASSPATH=$(CLASSPATH) javac $<