diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2018-03-09 16:53:27 +0000 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2018-03-09 16:53:27 +0000 |
commit | 80208fb578cf92cc308906660ca6d7860c6b2a1f (patch) | |
tree | 6f06818031b553c506fc10dfe9908a835df288aa /sci-misc/netlogo-bin/files | |
parent | 06a7b5647e11a8ddf69b1c3d3ded6a8ba28b923e (diff) |
gentoo resync : 09.03.2018
Diffstat (limited to 'sci-misc/netlogo-bin/files')
-rwxr-xr-x | sci-misc/netlogo-bin/files/behaviorsearch-6.0.2.sh | 38 | ||||
-rwxr-xr-x | sci-misc/netlogo-bin/files/hubnetclient-6.0.2.sh | 40 | ||||
-rwxr-xr-x | sci-misc/netlogo-bin/files/netlogo-6.0.2.sh | 40 | ||||
-rwxr-xr-x | sci-misc/netlogo-bin/files/netlogo3d-6.0.2.sh | 40 |
4 files changed, 158 insertions, 0 deletions
diff --git a/sci-misc/netlogo-bin/files/behaviorsearch-6.0.2.sh b/sci-misc/netlogo-bin/files/behaviorsearch-6.0.2.sh new file mode 100755 index 000000000000..225f4a332cff --- /dev/null +++ b/sci-misc/netlogo-bin/files/behaviorsearch-6.0.2.sh @@ -0,0 +1,38 @@ +#!/bin/bash + +WD="`pwd`" #store the current working directory, where this script was called from. + +#BehaviorSearch needs to start in the NetLogo base folder, +# and "behaviorsearch" must be installed in a subfolder of the NetLogo folder. +NETLOGO_DIR="$( dirname $( readlink -f "$0" ))" # the copious quoting is for handling paths with spaces +cd "$NETLOGO_DIR" +NETLOGO_DIR="`pwd`" #in case it's a relative path, like "." +LIBRARY_DIR="${NETLOGO_DIR}/app" +BSEARCH_DIR="${LIBRARY_DIR}/behaviorsearch" + +JARS="" +for f in `ls -1 "$LIBRARY_DIR" | grep "jar"`; do + JARS="$LIBRARY_DIR/$f:$JARS" +done + +# If you want to use a different version of java, or if "java" is not in your PATH, +# you can run this script with the BSEARCH_JAVA environment variable pointing +# to the java executable you want to use. e.g. "/opt/java6/bin/java" +if [ -z "$BSEARCH_JAVA" ]; then + BSEARCH_JAVA="java" +fi + +JAVA_VERSION=`"$BSEARCH_JAVA" -version 2>&1 | head -n1 | awk '{ print substr($3,2,3) }' | sed -e 's;\.;0;g'` +if [ $JAVA_VERSION -lt 108 ]; then #108 = java 1.8 + echo "Sorry, this program requires Java Runtime Environment 1.8 or higher" + exit 1 +fi + +# If you have enough RAM, up the '1536m' below to '2048m' or more. +# Or you can set the BSEARCH_MAXMEM environment variable when running the script +# More RAM is especially helpful for multiple threads/parallel execution. +if [ -z "$BSEARCH_MAXMEM" ]; then + BSEARCH_MAXMEM=1536m +fi + +"$BSEARCH_JAVA" -Dbsearch.startupfolder="$WD" -Dbsearch.appfolder="$BSEARCH_DIR" -server -Xms256m "-Xmx$BSEARCH_MAXMEM" -classpath "$JARS" bsearch.app.BehaviorSearch "$@" diff --git a/sci-misc/netlogo-bin/files/hubnetclient-6.0.2.sh b/sci-misc/netlogo-bin/files/hubnetclient-6.0.2.sh new file mode 100755 index 000000000000..3fb98d0909f1 --- /dev/null +++ b/sci-misc/netlogo-bin/files/hubnetclient-6.0.2.sh @@ -0,0 +1,40 @@ +#!/bin/bash + +BASE_DIR="$( cd "$( dirname $( readlink -f "${BASH_SOURCE[0]}" ) )" && pwd -P )" + +if [[ ${JAVA_HOME+1} ]]; then + JAVA="${JAVA_HOME}/bin/java" +else + echo "JAVA_HOME undefined, using java from path. For control over exact java version, set JAVA_HOME" + JAVA="java" +fi; + +# -Xmx1024m use up to 1GB RAM (edit to increase) +# -Dfile.encoding=UTF-8 ensure Unicode characters in model files are compatible cross-platform +JVM_OPTS=(-Xmx1024m -Dfile.encoding=UTF-8) +OPTS_INDEX=2 + +ARGS=() +INDEX=0 + +for arg in "$@"; do + if [[ "$arg" == -D* ]]; then + JVM_OPTS[OPTS_INDEX++]="$arg" + else + ARGS[INDEX++]="$arg" + fi +done + +RAW_CLASSPATH="args4j-2.0.12.jar:asm-all-5.0.4.jar:asm-all-5.0.4.jar:autolink-0.6.0.jar:behaviorsearch.jar:commons-codec-1.10.jar:commons-logging-1.1.1.jar:config-1.3.1.jar:flexmark-0.20.0.jar:flexmark-ext-autolink-0.20.0.jar:flexmark-ext-escaped-character-0.20.0.jar:flexmark-ext-typographic-0.20.0.jar:flexmark-formatter-0.20.0.jar:flexmark-util-0.20.0.jar:gluegen-rt-2.3.2.jar:httpclient-4.2.jar:httpcore-4.2.jar:httpmime-4.2.jar:jcommon-1.0.16.jar:jfreechart-1.0.13.jar:jhotdraw-6.0b1.jar:jmf-2.1.1e.jar:jogl-all-2.3.2.jar:json-simple-1.1.1.jar:log4j-1.2.16.jar:macro-compat_2.12-1.1.1.jar:macro-compat_2.12-1.1.1.jar:netlogo-6.0.2.jar:parboiled_2.12-2.1.3.jar:parboiled_2.12-2.1.3.jar:picocontainer-2.13.6.jar:picocontainer-2.13.6.jar:rsyntaxtextarea-2.6.0.jar:scala-library-2.12.2.jar:scala-parser-combinators_2.12-1.0.5.jar:shapeless_2.12-2.3.2.jar:shapeless_2.12-2.3.2.jar" +CLASSPATH='' + +for jar in `echo $RAW_CLASSPATH | sed 's/:/ /g'`; do + CLASSPATH="$CLASSPATH:$BASE_DIR/app/$jar" +done + +CLASSPATH=`echo $CLASSPATH | sed 's/://'` + +# -classpath .... specify jars +# org.nlogo.headless.Main specify we want headless, not GUI +# "${ARGS[0]}" pass along any additional arguments +java "${JVM_OPTS[@]}" -Dnetlogo.extensions.dir="${BASE_DIR}/app/extensions" -classpath "$CLASSPATH" -Dorg.nlogo.is3d=true org.nlogo.hubnet.client.App "${ARGS[@]}" diff --git a/sci-misc/netlogo-bin/files/netlogo-6.0.2.sh b/sci-misc/netlogo-bin/files/netlogo-6.0.2.sh new file mode 100755 index 000000000000..5ad35832ba28 --- /dev/null +++ b/sci-misc/netlogo-bin/files/netlogo-6.0.2.sh @@ -0,0 +1,40 @@ +#!/bin/bash + +BASE_DIR="$( cd "$( dirname $( readlink -f "${BASH_SOURCE[0]}" ) )" && pwd -P )" + +if [[ ${JAVA_HOME+1} ]]; then + JAVA="${JAVA_HOME}/bin/java" +else + echo "JAVA_HOME undefined, using java from path. For control over exact java version, set JAVA_HOME" + JAVA="java" +fi; + +# -Xmx1024m use up to 1GB RAM (edit to increase) +# -Dfile.encoding=UTF-8 ensure Unicode characters in model files are compatible cross-platform +JVM_OPTS=(-Xmx1024m -Dfile.encoding=UTF-8) +OPTS_INDEX=2 + +ARGS=() +INDEX=0 + +for arg in "$@"; do + if [[ "$arg" == -D* ]]; then + JVM_OPTS[OPTS_INDEX++]="$arg" + else + ARGS[INDEX++]="$arg" + fi +done + +RAW_CLASSPATH="args4j-2.0.12.jar:asm-all-5.0.4.jar:asm-all-5.0.4.jar:autolink-0.6.0.jar:behaviorsearch.jar:commons-codec-1.10.jar:commons-logging-1.1.1.jar:config-1.3.1.jar:flexmark-0.20.0.jar:flexmark-ext-autolink-0.20.0.jar:flexmark-ext-escaped-character-0.20.0.jar:flexmark-ext-typographic-0.20.0.jar:flexmark-formatter-0.20.0.jar:flexmark-util-0.20.0.jar:gluegen-rt-2.3.2.jar:httpclient-4.2.jar:httpcore-4.2.jar:httpmime-4.2.jar:jcommon-1.0.16.jar:jfreechart-1.0.13.jar:jhotdraw-6.0b1.jar:jmf-2.1.1e.jar:jogl-all-2.3.2.jar:json-simple-1.1.1.jar:log4j-1.2.16.jar:macro-compat_2.12-1.1.1.jar:macro-compat_2.12-1.1.1.jar:netlogo-6.0.2.jar:parboiled_2.12-2.1.3.jar:parboiled_2.12-2.1.3.jar:picocontainer-2.13.6.jar:picocontainer-2.13.6.jar:rsyntaxtextarea-2.6.0.jar:scala-library-2.12.2.jar:scala-parser-combinators_2.12-1.0.5.jar:shapeless_2.12-2.3.2.jar:shapeless_2.12-2.3.2.jar" +CLASSPATH='' + +for jar in `echo $RAW_CLASSPATH | sed 's/:/ /g'`; do + CLASSPATH="$CLASSPATH:$BASE_DIR/app/$jar" +done + +CLASSPATH=`echo $CLASSPATH | sed 's/://'` + +# -classpath .... specify jars +# org.nlogo.headless.Main specify we want headless, not GUI +# "${ARGS[0]}" pass along any additional arguments +java "${JVM_OPTS[@]}" -Dnetlogo.extensions.dir="${BASE_DIR}/app/extensions" -classpath "$CLASSPATH" org.nlogo.app.App "${ARGS[@]}" diff --git a/sci-misc/netlogo-bin/files/netlogo3d-6.0.2.sh b/sci-misc/netlogo-bin/files/netlogo3d-6.0.2.sh new file mode 100755 index 000000000000..5db1d3a2847b --- /dev/null +++ b/sci-misc/netlogo-bin/files/netlogo3d-6.0.2.sh @@ -0,0 +1,40 @@ +#!/bin/bash + +BASE_DIR="$( cd "$( dirname $( readlink -f "${BASH_SOURCE[0]}" ) )" && pwd -P )" + +if [[ ${JAVA_HOME+1} ]]; then + JAVA="${JAVA_HOME}/bin/java" +else + echo "JAVA_HOME undefined, using java from path. For control over exact java version, set JAVA_HOME" + JAVA="java" +fi; + +# -Xmx1024m use up to 1GB RAM (edit to increase) +# -Dfile.encoding=UTF-8 ensure Unicode characters in model files are compatible cross-platform +JVM_OPTS=(-Xmx1024m -Dfile.encoding=UTF-8) +OPTS_INDEX=2 + +ARGS=() +INDEX=0 + +for arg in "$@"; do + if [[ "$arg" == -D* ]]; then + JVM_OPTS[OPTS_INDEX++]="$arg" + else + ARGS[INDEX++]="$arg" + fi +done + +RAW_CLASSPATH="args4j-2.0.12.jar:asm-all-5.0.4.jar:asm-all-5.0.4.jar:autolink-0.6.0.jar:behaviorsearch.jar:commons-codec-1.10.jar:commons-logging-1.1.1.jar:config-1.3.1.jar:flexmark-0.20.0.jar:flexmark-ext-autolink-0.20.0.jar:flexmark-ext-escaped-character-0.20.0.jar:flexmark-ext-typographic-0.20.0.jar:flexmark-formatter-0.20.0.jar:flexmark-util-0.20.0.jar:gluegen-rt-2.3.2.jar:httpclient-4.2.jar:httpcore-4.2.jar:httpmime-4.2.jar:jcommon-1.0.16.jar:jfreechart-1.0.13.jar:jhotdraw-6.0b1.jar:jmf-2.1.1e.jar:jogl-all-2.3.2.jar:json-simple-1.1.1.jar:log4j-1.2.16.jar:macro-compat_2.12-1.1.1.jar:macro-compat_2.12-1.1.1.jar:netlogo-6.0.2.jar:parboiled_2.12-2.1.3.jar:parboiled_2.12-2.1.3.jar:picocontainer-2.13.6.jar:picocontainer-2.13.6.jar:rsyntaxtextarea-2.6.0.jar:scala-library-2.12.2.jar:scala-parser-combinators_2.12-1.0.5.jar:shapeless_2.12-2.3.2.jar:shapeless_2.12-2.3.2.jar" +CLASSPATH='' + +for jar in `echo $RAW_CLASSPATH | sed 's/:/ /g'`; do + CLASSPATH="$CLASSPATH:$BASE_DIR/app/$jar" +done + +CLASSPATH=`echo $CLASSPATH | sed 's/://'` + +# -classpath .... specify jars +# org.nlogo.headless.Main specify we want headless, not GUI +# "${ARGS[0]}" pass along any additional arguments +java "${JVM_OPTS[@]}" -Dnetlogo.extensions.dir="${BASE_DIR}/app/extensions" -classpath "$CLASSPATH" -Dorg.nlogo.is3d=true -Djava.library.path="${BASE_DIR}/app/natives/linux-amd64/:${env_var:PATH}" org.nlogo.app.App "${ARGS[@]}" |