Commit 749e854e authored by Martin Deinhofer's avatar Martin Deinhofer
Browse files

fixed JAVA_HOME, .java dependency and clean target

* JAVA_HOME must be set to the path of the java installation. Actually the default path should be set automatically
* fixed clean target: delete $(CLASS_PATH) folder
* %.class target: added dependency '.java' to force a recompilation if a java file changed
parent dafca4c1
# Define common variables
CLASS_PATH = ../bin
JAVA_SRC_PATH = ../src
#Paths to libmcp23s17 and libpifacecad
......@@ -16,7 +16,7 @@ all :
run :
java -cp $(CLASS_PATH) -Djava.library.path=../jni java_exercises8_1_1.HelloJNI
java_exercises8_1_1/HelloJNI.class: $(JAVA_SRC_PATH)/java_exercises8_1_1/
javac -cp $(CLASS_PATH) -d $(CLASS_PATH) $(JAVA_SRC_PATH)/java_exercises8_1_1/
# Targets for java_exercises8_1_1
......@@ -33,4 +33,4 @@ HelloJNI.h : java_exercises8_1_1/HelloJNI.class
javah -o HelloJNI.h -classpath $(CLASS_PATH) java_exercises8_1_1.$*
clean :
rm HelloJNI.h HelloJNI.o
\ No newline at end of file
rm -rf HelloJNI.h HelloJNI.o $(CLASS_PATH)/*
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment