aboutsummaryrefslogtreecommitdiff
path: root/system/splix/splix.SlackBuild
diff options
context:
space:
mode:
authorIskar Enev <iskar.enev[@]gmail.com>2010-05-12 17:46:02 +0200
committerRobby Workman <rworkman@slackbuilds.org>2010-05-12 17:46:02 +0200
commitaf24e12ffc381cc670630ac5ed3d0437b3201f6f (patch)
treeeb6c72014dc8ebe3894847e9225344d1cdd83833 /system/splix/splix.SlackBuild
parent38ecf19e26be907e7205e22bd868723a48f9c9e1 (diff)
system/splix: Updated for version 2.0.0
Diffstat (limited to 'system/splix/splix.SlackBuild')
-rw-r--r--system/splix/splix.SlackBuild37
1 files changed, 24 insertions, 13 deletions
diff --git a/system/splix/splix.SlackBuild b/system/splix/splix.SlackBuild
index 3bc19027b8931..5672e06973b79 100644
--- a/system/splix/splix.SlackBuild
+++ b/system/splix/splix.SlackBuild
@@ -4,7 +4,7 @@
# Written by Iskar Enev <iskar.enev[@]gmail.com>
PRGNAM=splix
-VERSION=1.1.1
+VERSION=2.0.0
ARCH=${ARCH:-i486}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -16,13 +16,16 @@ OUTPUT=${OUTPUT:-/tmp}
CUPSCFLAGS=$(cups-config --cflags)
CUPSLDFLAGS=$(cups-config --ldflags)
-CUPSFILTER=$(cups-config --serverbin)/filter
-CUPSMODEL=$(cups-config --datadir)/model
+CUPSLIBS=$(cups-config --libs)
+CUPSSERVERBIN=$(cups-config --serverbin)
+CUPSDATADIR=$(cups-config --datadir)
if [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
fi
# Whether or not to use JBIG (see README)
@@ -40,21 +43,29 @@ cd $PRGNAM-$VERSION
chown -R root:root .
chmod -R u+w,go+r-w,a-s .
-# Add DESTDIR support to the Makefile
-patch -p1 < $CWD/Makefile-DESTDIR.diff
+sed -i "s%\`cups-config --cflags\`%$CUPSCFLAGS%" module.mk
+sed -i "s%\`cups-config --ldflags\`%$CUPSLDFLAGS%" module.mk
+sed -i "s%\`cups-config --libs\`%$CUPSLIBS%" module.mk
+sed -i "s%\`cups-config --serverbin\`%$CUPSSERVERBIN%" module.mk
+sed -i "s%\`cups-config --datadir\`%$CUPSDATADIR%" module.mk
-sed -i "s%CXXFLAGS := -O2 \`cups-config --cflags\` %CXXFLAGS := $SLKCFLAGS $CUPSCFLAGS%" Makefile
-sed -i "s%LDFLAGS := \`cups-config --ldflags\`%LDFLAGS := $CUPSLDFLAGS%" Makefile
+make \
+ V=1 \
+ DISABLE_JBIG=$NO_JBIG \
+ OPTIM_CFLAGS="$SLKCFLAGS" \
+ OPTIM_CXXFLAGS="$SLKCFLAGS"
-mkdir -p $PKG$CUPSFILTER
-mkdir -p $PKG$CUPSMODEL
+mkdir -p ${PKG}${CUPSSERVERBIN}/filter ${PKG}${CUPSDATADIR}/model
-make DISABLE_JBIG=$NO_JBIG
-make install DISABLE_JBIG=$NO_JBIG DESTDIR=$PKG
+make install \
+ DISABLE_JBIG=$NO_JBIG \
+ DESTDIR=$PKG
( cd $PKG
- 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
+ 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
)
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION