mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-18 22:06:04 +01:00
system/mlterm: Updated for version 2.9.4
This commit is contained in:
parent
34a3c95984
commit
967dd61c94
3 changed files with 49 additions and 13 deletions
13
system/mlterm/doinst.sh
Normal file
13
system/mlterm/doinst.sh
Normal file
|
@ -0,0 +1,13 @@
|
|||
config() {
|
||||
NEW="$1"
|
||||
OLD="$(dirname $NEW)/$(basename $NEW .new)"
|
||||
# If there's no config file by that name, mv it over:
|
||||
if [ ! -r $OLD ]; then
|
||||
mv $NEW $OLD
|
||||
elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
|
||||
# toss the redundant copy
|
||||
rm $NEW
|
||||
fi
|
||||
# Otherwise, we leave the .new copy for the admin to consider...
|
||||
}
|
||||
|
|
@ -1,27 +1,31 @@
|
|||
#!/bin/sh
|
||||
|
||||
# Slackware build script for mlterm
|
||||
# Slackware build script for mlterm
|
||||
|
||||
# Written by Marco Cecchetti (mrc.ildp@gmail.com)
|
||||
|
||||
PRGNAM=mlterm
|
||||
VERSION=${VERSION:-2.9.4}
|
||||
PRGNAM=mlterm
|
||||
VERSION=${VERSION:-2.9.4}
|
||||
ARCH=${ARCH:-i486}
|
||||
BUILD=${BUILD:-2}
|
||||
TAG=${TAG:-_SBo}
|
||||
BUILD=${BUILD:-3}
|
||||
TAG=${TAG:-_SBo}
|
||||
|
||||
FONT_ENGINE=${FONT_ENGINE:-xcore}
|
||||
|
||||
CWD=$(pwd)
|
||||
TMP=${TMP:-/tmp/SBo}
|
||||
TMP=${TMP:-/tmp/SBo}
|
||||
PKG=$TMP/package-$PRGNAM
|
||||
OUTPUT=${OUTPUT:-/tmp}
|
||||
OUTPUT=${OUTPUT:-/tmp}
|
||||
|
||||
if [ "$ARCH" = "i486" ]; then
|
||||
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
|
||||
LIBDIRSUFFIX=""
|
||||
elif [ "$ARCH" = "i686" ]; then
|
||||
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
|
||||
LIBDIRSUFFIX=""
|
||||
elif [ "$ARCH" = "x86_64" ]; then
|
||||
SLKCFLAGS="-O2 -fPIC"
|
||||
LIBDIRSUFFIX="64"
|
||||
fi
|
||||
|
||||
set -e
|
||||
|
@ -43,8 +47,10 @@ CFLAGS="$SLKCFLAGS" \
|
|||
CXXFLAGS="$SLKCFLAGS" \
|
||||
./configure \
|
||||
--prefix=/usr \
|
||||
--libdir=/usr/lib${LIBDIRSUFFIX} \
|
||||
--sysconfdir=/etc \
|
||||
--localstatedir=/var \
|
||||
--mandir=/usr/man \
|
||||
--enable-optimize-redrawing \
|
||||
--with-imagelib=gdk-pixbuf2 \
|
||||
--with-type-engines=${FONT_ENGINE} \
|
||||
|
@ -52,27 +58,42 @@ CXXFLAGS="$SLKCFLAGS" \
|
|||
--enable-fribidi \
|
||||
--enable-m17nlib \
|
||||
--disable-static \
|
||||
--build=$ARCH-slackware-linux
|
||||
--build=$ARCH-slackware-linux
|
||||
|
||||
make
|
||||
make install DESTDIR=$PKG
|
||||
|
||||
( cd $PKG
|
||||
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
|
||||
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
|
||||
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | \
|
||||
xargs strip --strip-unneeded 2> /dev/null || true
|
||||
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | \
|
||||
xargs strip --strip-unneeded 2> /dev/null
|
||||
)
|
||||
|
||||
( cd $PKG/usr/man
|
||||
find . -type f -exec gzip -9 {} \;
|
||||
for i in $(find . -type l) ; do ln -s $(readlink $i).gz $i.gz ; rm $i ; done
|
||||
for i in $( find . -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
|
||||
)
|
||||
|
||||
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
cp -a ABOUT-NLS ChangeLog LICENCE README doc/* $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
cp -a \
|
||||
ABOUT-NLS ChangeLog LICENCE README doc/* \
|
||||
$PKG/usr/doc/$PRGNAM-$VERSION
|
||||
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
|
||||
|
||||
mkdir -p $PKG/install
|
||||
cat $CWD/slack-desc > $PKG/install/slack-desc
|
||||
cat $CWD/doinst.sh > $PKG/install/doinst.sh
|
||||
|
||||
# Don't clobber config files
|
||||
( cd $PKG/etc/mlterm
|
||||
for file in \
|
||||
aafont color font key main menu taafont termcap tfont vaafont vfont xim ;
|
||||
do \
|
||||
mv $file $file.new
|
||||
echo "config etc/mlterm/${file}.new" >> $PKG/install/doinst.sh
|
||||
done
|
||||
)
|
||||
|
||||
cd $PKG
|
||||
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz
|
||||
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
|
||||
|
|
|
@ -3,6 +3,8 @@ VERSION="2.9.4"
|
|||
HOMEPAGE="http://mlterm.sourceforge.net/"
|
||||
DOWNLOAD="http://downloads.sourceforge.net/mlterm/mlterm-2.9.4.tar.gz"
|
||||
MD5SUM="67fc33f09da045f86b0d4ceebed76aac"
|
||||
DOWNLOAD_x86_64=""
|
||||
MD5SUM_x86_64=""
|
||||
MAINTAINER="Marco Cecchetti"
|
||||
EMAIL="mrc.ildp@gmail.com"
|
||||
APPROVED="rworkman"
|
||||
|
|
Loading…
Reference in a new issue