#!/bin/sh VERSION=4.5.55 ARCH=i386 BUILD=6 echo "We need GLIB, but DO NOT have GNOME around..." echo "You need a 'clean' box. ;)" sleep 7 PKG=/tmp/package-mc rm -rf $PKG mkdir -p $PKG/usr CWD=`pwd` cd /tmp tar xzvf $CWD/mc-$VERSION.tar.gz cd mc-$VERSION zcat $CWD/mc.shadow.diff.gz | patch -p1 --verbose --backup --suffix=.orig -E zcat $CWD/fish.time.diff.gz | patch -p1 --verbose --backup --suffix=.orig -E # ( cd vfs/samba ; zcat $CWD/samba.codepages.diff.gz | patch -p0 ) # This patch should fix the --enable-charset feature: zcat $CWD/mc.andrew-cvs.diff.gz | patch -p1 --verbose --backup --suffix=.orig -E # Using --with-included-slang seems to be the magic incantation that builds # a clean, small mc like days of yore CFLAGS="-O2 -march=i386 -mcpu=i686" ./configure \ --prefix=/usr \ --sysconfdir=/etc \ --localstatedir=/var \ --enable-largefile \ --enable-mcserv-install \ --enable-charset \ --with-gpm-mouse=/usr \ --with-ext2undel \ --with-x=no \ --with-vfs \ --with-included-slang \ --without-debug \ i386-slackware-linux # Removed due to bug reports. Does anyone use this feature? # Will it be missed? complain to: volkerdi@slackware.com # --with-samba make make DESTDIR=$PKG install mkdir -p $PKG/etc/profile.d mv $PKG/usr/lib/mc/bin/mc.csh $PKG/etc/profile.d/mc.csh # This version is broken, but we'll move and then replace it: mv $PKG/usr/lib/mc/bin/mc.sh $PKG/etc/profile.d/mc.sh zcat $CWD/mc.sh.gz > $PKG/etc/profile.d/mc.sh strip $PKG/usr/bin/mc $PKG/usr/lib/mc/bin/cons.saver $PKG/usr/bin/mcmfmt $PKG/usr/bin/mcserv chown -R root.bin $PKG/usr/bin gzip -9 $PKG/usr/man/man1/*.1 $PKG/usr/man/man8/*.8 mkdir -p $PKG/usr/doc/mc-$VERSION cp -a FAQ COPYING NEWS README $PKG/usr/doc/mc-$VERSION chown -R root.root $PKG/usr/doc/mc-$VERSION chmod 644 $PKG/usr/doc/mc-$VERSION/* mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc # Build package: cd $PKG makepkg -l y -c n ../mc-$VERSION-$ARCH-$BUILD.tgz