Browse Source

xap/imagej: Added.

slackware-14.2
Damien Goutte-Gattat 12 years ago
parent
commit
4b86da6fd9
6 changed files with 144 additions and 0 deletions
  1. +3
    -0
      xap/imagej/doinst.sh
  2. +114
    -0
      xap/imagej/imagej.SlackBuild
  3. +9
    -0
      xap/imagej/imagej.desktop
  4. +2
    -0
      xap/imagej/run.sh
  5. +4
    -0
      xap/imagej/sha1sums
  6. +12
    -0
      xap/imagej/slack-desc

+ 3
- 0
xap/imagej/doinst.sh View File

@ -0,0 +1,3 @@
if [ -x /usr/bin/update-desktop-database ]; then
/usr/bin/update-desktop-database -q usr/share/applications
fi

+ 114
- 0
xap/imagej/imagej.SlackBuild View File

@ -0,0 +1,114 @@
#!/bin/bash
# Build script for Slackware
# Damien Goutte-Gattat "gouttegd" < damien.goutte-gattat at e.ujf-grenoble.fr >
#
# Redistribution and use of this script, with or without modifications, is
# permitted provided that the following conditions are met:
#
# 1. Redistributions of this script must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
# Latest ImageJ distribution is available at:
# http://rsb.info.nih.gov/ij/
# Source packages infos
IMAGEJ="ij140.zip"
IMAGEJ_URL="http://rsb.info.nih.gov/ij/download/zips/$IMAGEJ"
MBFPLUG="mbf-plugins.zip"
MBFPLUG_URL="http://rsb.info.nih.gov/ij/plugins/download/$MBF_PLUG"
LSMPLUG="LSM_Toolbox.jar"
LSMPLUG_URL="http://image-archive.org/fileadmin/user_upload/files_/$LSMPLUG"
IJDOCS="ij-docs.zip"
IJDOCS_URL="http://rsb.info.nih.gov/ij/download/docs/$IJDOCS"
# Built package infos
NAMETGZ=${NAMETGZ:-imagej}
VERSION=${VERSION:-1.40}
BUILD=${BUILD:-2GGD}
ARCH=${ARCH:-i486}
TARGET=${TARGET:-i486}
# Directories
TMP=${TMP:-/tmp}
OUT=${OUT:-$TMP/build}
PKG=${PKG:-$OUT/$NAMETGZ}
CWD=$(pwd)
set -e # Quit if a command returns non-zero
# Sanity checks
if [ $UID -eq 0 ]; then
echo "You should NOT run this script as ROOT!"
exit 1
fi
if [ ! -d $TMP ]; then
echo "$TMP does not exist or is not a directory!"
exit 1
fi
# Get and verify the archives
if [ ! -r $IMAGEJ ]; then
wget "$IMAGEJ_URL"
fi
if [ ! -r $MBFPLUG ]; then
wget "$MBFPLUG_URL"
fi
if [ ! -r $LSMPLUG ]; then
wget "$LSMPLUG_URL"
fi
if [ ! -r $IJDOCS ]; then
wget "$IJDOCS_URL"
fi
sha1sum -c sha1sums
# Install ImageJ
mkdir -p $PKG/opt
unzip -q $IMAGEJ -d $PKG/opt
rm -rf $PKG/opt/ImageJ/{ImageJ.exe,README.html,ImageJ.app,run,plugins}
# Install additional plugins
unzip -q $MBFPLUG -d $PKG/opt/ImageJ
rm -rf $PKG/opt/ImageJ/__MACOSX "$PKG/opt/ImageJ/plugins/ Help"
rm -rf $PKG/opt/ImageJ/plugins/source
cp $LSMPLUG $PKG/opt/ImageJ/plugins
# Install the documentation
unzip -q $IJDOCS -d $PKG/opt/ImageJ
mv $PKG/opt/ImageJ/ij-docs $PKG/opt/ImageJ/docs
rm -rf $PKG/opt/ImageJ/__MACOSX
# Sanitize permissions
find $PKG/opt/ImageJ -type f -print0 | xargs -0 chmod 644
find $PKG/opt/ImageJ -type d -print0 | xargs -0 chmod 755
# Copy the launching script, slack-desc, desktop and doinst.sh files
mkdir -p $PKG/usr/bin $PKG/usr/share/applications $PKG/install
install -m 755 run.sh $PKG/usr/bin/imagej
install -m 644 imagej.desktop $PKG/usr/share/applications
install -m 644 slack-desc $PKG/install/slack-desc
install -m 755 doinst.sh $PKG/install/doinst.sh
# Package the tree
cd $PKG
mkdir -p $OUT
PACKAGING="
chown root:root . -R
/sbin/makepkg -l y -c n $OUT/$NAMETGZ-$VERSION-$ARCH-$BUILD.tgz
rm -rf $PKG
"
if type -p fakeroot ; then
echo "$PACKAGING" | fakeroot
else
su -c "$PACKAGING"
fi

+ 9
- 0
xap/imagej/imagej.desktop View File

@ -0,0 +1,9 @@
[Desktop Entry]
Name=ImageJ
Comment=Image Analysis Program
Exec=imagej
Terminal=false
Type=Application
Categories=GNOME;GTK;Qt;KDE;Science
StartupNotify=false
GenericName=Image Analysis Program

+ 2
- 0
xap/imagej/run.sh View File

@ -0,0 +1,2 @@
#!/bin/sh
java -Dplugins.dir=/opt/ImageJ -jar /opt/ImageJ/ij.jar

+ 4
- 0
xap/imagej/sha1sums View File

@ -0,0 +1,4 @@
581d21b7403fbe9ac986cc022db1b2b92ba9ff1f ij140.zip
a608580c9e587e6570a8bd01199320cc798c3bb4 ij-docs.zip
10e0a6860c736a0977b1dd0c1d03ddeaf2fa21a3 mbf-plugins.zip
53e5f5d0d4359abd33ebab0667ed2a3d0e5acc95 LSM_Toolbox.jar

+ 12
- 0
xap/imagej/slack-desc View File

@ -0,0 +1,12 @@
|-----handy-ruler------------------------------------------------------|
imagej: imagej (Image processing and analysis in Java)
imagej:
imagej: ImageJ is a public domain Java image processing program inspired by
imagej: NIH Image for the Macintosh. It can display, edit, analyze, process,
imagej: save and print 8-bit, 16-bit and 32-bit images. It can read many
imagej: image formats including TIFF, GIF, JPEG, BMP, DICOM, FITS and
imagej: "raw". It supports "stacks", a series of images that share a single
imagej: window.
imagej:
imagej: This package includes plugins for microscopy analysis.
imagej:

Loading…
Cancel
Save