This is an automated email from the git hooks/post-receive script.

sebastic-guest pushed a commit to branch master
in repository mkgmap-splitter.

commit c16a4986e5ad188602788e227e7c841cb56a179c
Author: Bas Couwenberg <sebas...@xs4all.nl>
Date:   Fri Jan 9 18:16:38 2015 +0100

    Pass commandline options along to splitter.jar and honor JAVA_OPTS if set.
---
 debian/mkgmap-splitter.sh | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/debian/mkgmap-splitter.sh b/debian/mkgmap-splitter.sh
index dda75fe..8796cc1 100644
--- a/debian/mkgmap-splitter.sh
+++ b/debian/mkgmap-splitter.sh
@@ -10,7 +10,9 @@ ARCH="`dpkg --print-architecture`"
 
 JAVA_CMDS="$JAVA_HOME/bin/java /usr/lib/jvm/java-7-openjdk-$ARCH/bin/java 
/usr/bin/java"
 
-JAVA_OPTS="$JAVA_OPTS -Xmx2000m"
+if [ -z "$JAVA_OPTS" -o $(echo "$JAVA_OPTS" | grep "\-Xmx" | wc -l) -eq 0 ]; 
then
+   JAVA_OPTS="$JAVA_OPTS -Xmx2000m"
+fi
 
 for jcmd in $JAVA_CMDS; do
    if [ "z$ALTERNATIVE_JDK" = "z`readlink -n -f $jcmd`" ] && [ -z "${JAVACMD}" 
]; then
@@ -26,7 +28,7 @@ done
 
 if [ "$JAVACMD" ]; then
    echo "Using $JAVACMD to execute mkgmap-splitter."
-   exec $JAVACMD $JAVA_OPTS -jar /usr/share/mkgmap-splitter/splitter.jar
+   exec $JAVACMD $JAVA_OPTS -jar /usr/share/mkgmap-splitter/splitter.jar "$@"
 else
    echo "No valid JVM found to run mkgmap-splitter."
    exit 1

-- 
Alioth's /usr/local/bin/git-commit-notice on 
/srv/git.debian.org/git/pkg-grass/mkgmap-splitter.git

_______________________________________________
Pkg-grass-devel mailing list
Pkg-grass-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-grass-devel

Reply via email to