#!/bin/sh CWD=`pwd` TMP=/tmp PKG=$TMP/package-wireless-tools VERSION=29 ARCH=alpha BUILD=1 rm -rf $PKG mkdir -p $PKG ( cd $TMP rm -rf wireless_tools.$VERSION tar xzf $CWD/wireless_tools.$VERSION.tar.gz cd wireless_tools.$VERSION chown -R root.root . zcat $CWD/diff.gz | patch -p0 --verbose || exit 1 zcat $CWD/wireless_tools.nowhine.diff.gz | patch -p1 --verbose || exit 1 zcat $CWD/wireless_tools.static.diff.gz | patch -p1 --verbose || exit 1 make || exit 1 # iwredir looks pretty useless strip ifrename iwconfig iwevent iwgetid iwlist iwpriv iwspy 2> /dev/null mkdir -p $PKG/usr/sbin cp -a ifrename iwconfig iwevent iwgetid iwlist iwpriv iwspy $PKG/usr/sbin chown -R root.bin $PKG/usr/sbin chmod 755 $PKG/usr/sbin/* # The library seems to be used by kdenetwork, but since the .soname in the shared library # doesn't seem to be forward-thinking we'll leave that out still: mkdir -p $PKG/usr/lib cp -a libiw.a $PKG/usr/lib mkdir -p $PKG/usr/include cp -a iwlib.h wireless.h $PKG/usr/include chmod 644 $PKG/usr/include/*.h mkdir -p $PKG/usr/man/man{5,7,8} cat iftab.5 | gzip -9c > $PKG/usr/man/man5/iftab.5.gz cat wireless.7 | gzip -9c > $PKG/usr/man/man7/wireless.7.gz for file in *.8 ; do cat $file | gzip -9c > $PKG/usr/man/man8/$file.gz done mkdir -p $PKG/usr/doc/wireless-tools-$VERSION cp -a CHANGELOG.h COPYING INSTALL PCMCIA.txt README $PKG/usr/doc/wireless-tools-$VERSION chmod 644 $PKG/usr/doc/wireless-tools-$VERSION/* # Add init scripts from Eric Hameleers: mkdir -p $PKG/etc/rc.d zcat $CWD/rc.wireless.gz > $PKG/etc/rc.d/rc.wireless chmod 755 $PKG/etc/rc.d/rc.wireless # This might contain a secret key, so we'll use chmod 600: zcat $CWD/rc.wireless.conf.gz > $PKG/etc/rc.d/rc.wireless.conf.new chmod 600 $PKG/etc/rc.d/rc.wireless.conf.new mkdir $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc zcat $CWD/doinst.sh.gz > $PKG/install/doinst.sh cd $PKG makepkg -l y -c n $TMP/wireless-tools-$VERSION-$ARCH-$BUILD.tgz ) 2>&1 | tee $TMP/wireless.build.log