Skip to content
Commits on Source (2)
imagej (1.52i-1) UNRELEASED; urgency=medium
imagej (1.52i-1) unstable; urgency=medium
* New upstream version 1.52i
-- David Miguel Susano Pinto <carandraug+dev@gmail.com> Wed, 12 Dec 2018 17:57:38 +0000
* Fix imagej wrapper (the program that starts the Image GUI in
Debian) for Java version 10 or later. The wrapper made use of the
-d64 and -d32 options which have been deprecated for a while, did
nothing, and were removed in OpenJDK 10. See "Removal of Java
Launcher's Data Model Options -d32 and -d64" on the openjdk-10
release notes (Closes: #913747)
-- David Miguel Susano Pinto <carandraug+dev@gmail.com> Thu, 13 Dec 2018 15:40:16 +0000
imagej (1.52g-1) unstable; urgency=medium
......
......@@ -93,7 +93,6 @@ macroargs=''
# max memory allocation is 1800MB on 32bit java and 4000 on 64bit java
if [[ `uname` == 'SunOS' ]] ; then
arch='-d64'
java_path="${ij_path}/jre64/bin/java"
max_mem=`vmstat | awk 'NR == 3 {fmem=int($5 / 1024); if (fmem < 4000) {print fmem} else {print 4000}}'`
free_mem="max_mem"
......@@ -101,14 +100,12 @@ if [[ `uname` == 'SunOS' ]] ; then
if (( $mem > $default_mem || $mem < $min_mem )) ; then mem=$default_mem ; fi
elif [[ `uname` == 'Linux' ]] ; then
if [[ `uname -m` == 'x86_64' ]] ; then
arch='-d64'
java_path="${ij_path}/jre64/bin/java"
max_mem=`free | awk 'NR == 2 {fmem=int($2 / 1024); if (fmem < 4000) {print fmem} else {print 4000}}'`
free_mem=`free | awk 'NR == 3 {fmem=int($4 / 1024); if (fmem < 4000) {print fmem} else {print 4000}}'`
mem=${free_mem}/3*2
if (( $mem > $default_mem || $mem < $min_mem )) ; then mem=$default_mem ; fi
else
arch='-d32'
java_path="${ij_path}/jre/bin/java"
max_mem=`free | awk 'NR == 2 {fmem=int($2 / 1024); if (fmem < 1800) {print fmem} else {print 1800}}'`
free_mem=`free | awk 'NR == 3 {fmem=int($4 / 1024); if (fmem < 1800) {print fmem} else {print 1800}}'`
......@@ -418,9 +415,9 @@ fi
if [ "$JAVA_HOME" ] ; then
if (( $verbosity > 0 )) ; then
echo ${modules}
echo $JAVA_HOME/bin/java ${arch} -mx${mem}m ${jni} ${modules} ij.ImageJ -ijpath ${ij_user_path} -port${count} ${images} ${macrocmd} ${macroargs}
echo $JAVA_HOME/bin/java -mx${mem}m ${jni} ${modules} ij.ImageJ -ijpath ${ij_user_path} -port${count} ${images} ${macrocmd} ${macroargs}
else
eval $JAVA_HOME/bin/java ${arch} -mx${mem}m ${jni} ${modules} ij.ImageJ -ijpath ${ij_user_path} -port${count} ${images} ${macrocmd} ${macroargs}
eval $JAVA_HOME/bin/java -mx${mem}m ${jni} ${modules} ij.ImageJ -ijpath ${ij_user_path} -port${count} ${images} ${macrocmd} ${macroargs}
fi
else
echo "No JVM found to run ImageJ"
......