From 4fe07e394439e9dbaa31551ff65e741f7d29acec Mon Sep 17 00:00:00 2001 From: kbaati Date: Fri, 24 Jul 2015 14:57:23 +0200 Subject: [PATCH] [psg] update: Makefile, run.sh,test.sh --- contrib/psg/Makefile | 27 +++++++++++++++++++++++++++ contrib/psg/run.sh | 2 +- contrib/psg/test.sh | 8 ++++---- 3 files changed, 32 insertions(+), 5 deletions(-) create mode 100644 contrib/psg/Makefile diff --git a/contrib/psg/Makefile b/contrib/psg/Makefile new file mode 100644 index 0000000000..43fc9dd4d7 --- /dev/null +++ b/contrib/psg/Makefile @@ -0,0 +1,27 @@ +LIB_JARS= lib.jar + +all: compile doc + +compile: + mkdir -p classes + javac -sourcepath src -classpath $(LIB_JARS):../../simgrid.jar -d classes `find -L -name "*.java"` + +doc: + mkdir -p doc + javadoc -sourcepath src -classpath $(LIB_JARS):../../simgrid.jar -d doc psgsim + +test: + ./test.sh + +clean: + rm -rf classes doc outputs + +# Help Target +help: + @echo "The following are a valid targets for this Makefile:" + @echo "................ all (the default if no target is provided)" + @echo "................ compile" + @echo "................ doc" + @echo "................ test" + @echo "................ clean" + diff --git a/contrib/psg/run.sh b/contrib/psg/run.sh index ecac88ca98..baac2eed8f 100755 --- a/contrib/psg/run.sh +++ b/contrib/psg/run.sh @@ -6,7 +6,7 @@ else eval ulimit -s 128 fi echo '------------- Start execution..'; -java -Xmx1024m -cp lib.jar:classes peersim.Simulator $1 +java -Xmx1024m -cp lib.jar:classes:../../simgrid.jar peersim.Simulator $1 echo '------------- done -------------'; exit 0 diff --git a/contrib/psg/test.sh b/contrib/psg/test.sh index f5b7f09dad..7f6d61c7e3 100755 --- a/contrib/psg/test.sh +++ b/contrib/psg/test.sh @@ -9,19 +9,19 @@ fi echo -e "\n"; echo '------------- Execute the edaggregation example under PSG -------------'; echo -e "\n"; -java -Xmx1024m -cp lib.jar:classes peersim.Simulator configs/edaggregationPSG.txt +java -Xmx1024m -cp lib.jar:classes:../../simgrid.jar peersim.Simulator configs/edaggregationPSG.txt echo -e "\n"; echo '------------- Execute the edaggregation example under PS -------------'; echo -e "\n"; -java -Xmx1024m -cp lib.jar:classes peersim.Simulator configs/edaggregation.txt +java -Xmx1024m -cp lib.jar:classes:../../simgrid.jar peersim.Simulator configs/edaggregation.txt echo -e "\n"; echo '------------- Execute the chord example under PSG -------------'; echo -e "\n"; -java -Xmx1024m -cp lib.jar:classes peersim.Simulator configs/chordPSG.txt +java -Xmx1024m -cp lib.jar:classes:../../simgrid.jar peersim.Simulator configs/chordPSG.txt echo -e "\n"; echo '------------- Execute the chord example under PS -------------'; echo -e "\n"; -java -Xmx1024m -cp lib.jar:classes peersim.Simulator configs/chord.txt +java -Xmx1024m -cp lib.jar:classes:../../simgrid.jar peersim.Simulator configs/chord.txt echo -e "\n"; echo '------------- Compare the 2 results PS and PSG -------------'; echo -e "\n"; -- 2.20.1