CWD=$(pwd) TMP=${TMP:-/tmp} PKG=$TMP/package-xine-lib rm -rf $PKG mkdir -p $PKG/usr # Version on the tarball VERSION=1.1.11.1 # Version used in the source directory to cd into DIRVER=1.1.11.1 # Version used for the Slackware package PKGVER=1.1.11.1 # I would use "-march=i486 -mtune=i686" here as usual, but with XINE it's all or nothing. # I'd rather have it work well for the i686/Athlon crowd than suck for everyone. ARCH=${ARCH:-i686} TARGET=${TARGET:-$ARCH-pc-linux-gnu} BUILD=3_slack10.2 cd $TMP rm -rf xine-lib-$VERSION tar xjvf $CWD/xine-lib-$VERSION.tar.bz2 || exit 1 cd xine-lib-$DIRVER zcat $CWD/xine-lib.demux_qt.diff.gz | patch -p1 --verbose || exit 1 zcat $CWD/xine-lib.embl.diff.gz | patch -p1 --verbose || exit 1 chown -R root:root . find . -perm 664 -exec chmod 644 {} \; find . -perm 777 -exec chmod 755 {} \; XINE_BUILD=$TARGET \ ./configure \ --prefix=/usr \ --mandir=/usr/man \ --disable-nosefart \ --without-speex \ --with-w32-path=/usr/lib/codecs make -j4 || exit 1 make install DESTDIR=$PKG mkdir -p $PKG/usr/lib/codecs ( cd $PKG find . | xargs file | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded ) for manpagedir in $PKG/usr/man/man? ; do if [ -d $manpagedir ]; then ( cd $manpagedir ; gzip -9 *.? ) fi done mkdir -p $PKG/usr/doc/xine-lib-$VERSION cp -a \ ABOUT-NLS AUTHORS COPYING CREDITS NEWS README TODO \ doc/README* \ doc/faq/faq.txt \ doc/hackersguide \ $PKG/usr/doc/xine-lib-$VERSION # redundant rm -rf $PKG/usr/share/doc rm $PKG/usr/doc/xine-lib-$VERSION/hackersguide/Makefile* rm $PKG/usr/doc/xine-lib-$VERSION/hackersguide/*sgml rm $PKG/usr/doc/xine-lib-$VERSION/hackersguide/*fig rm -rf $PKG/usr/doc/xine-lib-$VERSION/man mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc cd $TMP/package-xine-lib makepkg -l y -c n ../xine-lib-$PKGVER-$ARCH-$BUILD.tgz