2015-05-29 15:33:47 +02:00
|
|
|
#!/usr/bin/env bash
|
2013-10-28 10:10:14 +01:00
|
|
|
|
2012-11-03 17:37:50 +01:00
|
|
|
APPDIR="$(dirname -- "$(readlink -f -- "${0}")" )"
|
2010-01-29 21:53:21 +01:00
|
|
|
|
2009-05-31 17:53:33 +02:00
|
|
|
for LIB in \
|
2015-06-30 09:07:02 +02:00
|
|
|
$APPDIR/java/lib/rt.jar \
|
|
|
|
$APPDIR/java/lib/tools.jar \
|
|
|
|
$APPDIR/lib/*.jar \
|
2009-05-31 17:53:33 +02:00
|
|
|
;
|
|
|
|
do
|
2010-11-27 19:50:33 +01:00
|
|
|
CLASSPATH="${CLASSPATH}:${LIB}"
|
2009-05-31 17:53:33 +02:00
|
|
|
done
|
|
|
|
export CLASSPATH
|
|
|
|
|
2015-06-30 09:07:02 +02:00
|
|
|
LD_LIBRARY_PATH=$APPDIR/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}
|
2009-08-03 22:57:46 +02:00
|
|
|
export LD_LIBRARY_PATH
|
|
|
|
|
2009-05-31 17:53:33 +02:00
|
|
|
export PATH="${APPDIR}/java/bin:${PATH}"
|
|
|
|
|
2015-04-08 13:59:29 +02:00
|
|
|
if [[ "$@" == *"--upload"* || "$@" == *"--verify"* || "$@" == *"--get-pref"* || "$@" == *"--install-board"* || "$@" == *"--install-library"* ]] ; then
|
2015-03-11 16:26:59 +01:00
|
|
|
SPLASH=""
|
|
|
|
else
|
2015-06-30 09:07:02 +02:00
|
|
|
SPLASH="-splash:$APPDIR/lib/splash.png"
|
2015-03-11 16:26:59 +01:00
|
|
|
fi
|
|
|
|
|
2015-05-12 10:48:53 +02:00
|
|
|
export JAVA_TOOL_OPTIONS=`echo $JAVA_TOOL_OPTIONS | sed 's|-javaagent:/usr/share/java/jayatanaag.jar||g'`
|
|
|
|
|
2015-06-09 17:38:09 +02:00
|
|
|
JAVA=java
|
2015-06-30 09:07:02 +02:00
|
|
|
if [ -x $APPDIR/java/bin/java ]; then
|
|
|
|
JAVA=$APPDIR/java/bin/java
|
2015-06-09 17:38:09 +02:00
|
|
|
fi
|
2013-10-28 10:10:14 +01:00
|
|
|
|
2015-06-30 09:07:02 +02:00
|
|
|
$JAVA -DAPP_DIR="$APPDIR" -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel $SPLASH processing.app.Base "$@"
|
2015-06-26 08:57:51 +02:00
|
|
|
|