Permalink
Browse files

Fix examples script and Eclipse classpath to work with JNA coming fro…

…m gradle

Not sure how brittle the classpath is going to be, but the hash in the jar path
seems stable when rebuilding.
  • Loading branch information...
EtiennePerot committed Nov 10, 2013
1 parent 3ff0014 commit 4ca1ed4dfff9bd46cdf43e70c18b6cb34de71359
Showing with 8 additions and 4 deletions.
  1. +1 −1 .classpath
  2. +1 −0 .gitignore
  3. +6 −3 examples/run.sh
View
@@ -2,6 +2,6 @@
<classpath>
<classpathentry kind="src" path="src/main/java"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
- <classpathentry kind="lib" path="lib/jna/jna-3.5.2.jar" sourcepath="lib/jna/jna-3.5.2-sources.jar"/>
+ <classpathentry kind="lib" path="gradle/caches/artifacts-26/filestore/net.java.dev.jna/jna/3.5.2/jar/f1bf9fe267e17c1a8f7d1aa2c985e7fe81a06da6/jna-3.5.2.jar"/>
<classpathentry kind="output" path="bin"/>
</classpath>
View
@@ -5,6 +5,7 @@ bin
*.class
*~
.gradle
+gradle
*.ipr
*.iws
*.iml
View
@@ -12,11 +12,14 @@ if ! which gradle &> /dev/null; then
exit 1
fi
-cd "`dirname "$0"`/.."
mountPoint="${@: -1}"
if [ ! -d "$mountPoint" ]; then
- mkdir -p "$mountPoint" || exit 1
+ mkdir -p "$mountPoint"
fi
+absoluteMountpoint="$(cd "$mountPoint" && pwd)"
+set -- "${@:1:$(expr "$#" - 1)}" "$absoluteMountpoint"
-gradle uberJar
+cd "$(dirname "$BASH_SOURCE")/.."
+
+GRADLE_USER_HOME=gradle gradle uberJar
java -cp build/libs/\* "$@"

0 comments on commit 4ca1ed4

Please sign in to comment.