From 403abc707239f3b18d9f65225cab4106c7840944 Mon Sep 17 00:00:00 2001 From: Michael Wagner Date: Thu, 13 May 2010 00:36:49 +0200 Subject: network/irda-utils: Updated for version 0.9.18 --- network/irda-utils/Makefile.irnetd.diff | 11 ------ network/irda-utils/Makefile.smcinit.diff | 23 ----------- network/irda-utils/doinst.sh | 4 +- network/irda-utils/irda-utils.SlackBuild | 45 ++++++++++++++-------- network/irda-utils/irda-utils.info | 2 + network/irda-utils/patches/Makefile.irnetd.diff | 11 ++++++ network/irda-utils/patches/Makefile.smcinit.diff | 23 +++++++++++ .../irda-utils-0.9.18-fixup_io.c_include.diff | 36 +++++++++++++++++ 8 files changed, 103 insertions(+), 52 deletions(-) delete mode 100644 network/irda-utils/Makefile.irnetd.diff delete mode 100644 network/irda-utils/Makefile.smcinit.diff create mode 100644 network/irda-utils/patches/Makefile.irnetd.diff create mode 100644 network/irda-utils/patches/Makefile.smcinit.diff create mode 100644 network/irda-utils/patches/irda-utils-0.9.18-fixup_io.c_include.diff (limited to 'network') diff --git a/network/irda-utils/Makefile.irnetd.diff b/network/irda-utils/Makefile.irnetd.diff deleted file mode 100644 index eca8c5542856e..0000000000000 --- a/network/irda-utils/Makefile.irnetd.diff +++ /dev/null @@ -1,11 +0,0 @@ ---- irnetd/Makefile~ 2007-06-11 14:22:52.000000000 +0200 -+++ irnetd/Makefile 2007-06-11 14:23:14.000000000 +0200 -@@ -55,7 +55,7 @@ - - install: irnetd - $(prn_install) -- $(ECMD) install irnetd /usr/sbin/ -+ $(ECMD) install irnetd $(ROOT)/usr/sbin/ - - - clean: diff --git a/network/irda-utils/Makefile.smcinit.diff b/network/irda-utils/Makefile.smcinit.diff deleted file mode 100644 index fc2e6182ee617..0000000000000 --- a/network/irda-utils/Makefile.smcinit.diff +++ /dev/null @@ -1,23 +0,0 @@ ---- smcinit/Makefile~ 2007-06-11 21:06:06.000000000 +0200 -+++ smcinit/Makefile 2007-06-11 21:06:39.000000000 +0200 -@@ -26,17 +26,17 @@ - - smcinit: smcinit.o - $(prn_cc_o) -- $(ECMD)$(CC) -o $@ $^ $(LIBS) -lpci -+ $(ECMD)$(CC) -o $@ $^ $(LIBS) -lpci -lz - - - tosh1800-smcinit: tosh1800-smcinit.o - $(prn_cc_o) -- $(ECMD)$(CC) $(XCFLAGS) -o $@ $^ $(LIBS) -lpci -+ $(ECMD)$(CC) $(XCFLAGS) -o $@ $^ $(LIBS) -lpci -lz - - - tosh2450-smcinit: tosh2450-smcinit.o - $(prn_cc_o) -- $(ECMD)$(CC) $(XCFLAGS) -o $@ $^ $(LIBS) -lpci -+ $(ECMD)$(CC) $(XCFLAGS) -o $@ $^ $(LIBS) -lpci -lz - - - %o: %c diff --git a/network/irda-utils/doinst.sh b/network/irda-utils/doinst.sh index 871edf1d6f801..6487cd302a017 100644 --- a/network/irda-utils/doinst.sh +++ b/network/irda-utils/doinst.sh @@ -1,10 +1,10 @@ config() { NEW="$1" - OLD="`dirname $NEW`/`basename $NEW .new`" + 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 + 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... diff --git a/network/irda-utils/irda-utils.SlackBuild b/network/irda-utils/irda-utils.SlackBuild index 8df11c56c5489..2c7db59756cbd 100644 --- a/network/irda-utils/irda-utils.SlackBuild +++ b/network/irda-utils/irda-utils.SlackBuild @@ -1,5 +1,5 @@ #!/bin/sh -# + # Slackware build script for irda-utils # (C) 2007 Michael Wagner # All rights reserved. @@ -24,8 +24,9 @@ PRGNAM=irda-utils VERSION=0.9.18 ARCH=${ARCH:-i486} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} + CWD=$(pwd) TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM @@ -36,24 +37,34 @@ OUTPUT=${OUTPUT:-/tmp} # like -fno-strict-aliasing if [ "$ARCH" = "i486" ]; then SLKCFLAGS="-march=i486 -mtune=i686" + LIBDIRSUFFIX="" elif [ "$ARCH" = "i686" ]; then SLKCFLAGS="-march=i686 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" + LIBDIRSUFFIX="64" fi +set -e + rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT -cd $TMP || exit 1 +cd $TMP rm -rf $PRGNAM-$VERSION -tar -xzvf $CWD/$PRGNAM-$VERSION.tar.gz || exit 1 -cd $PRGNAM-$VERSION || exit 1 +tar -xzvf $CWD/$PRGNAM-$VERSION.tar.gz +cd $PRGNAM-$VERSION chown -R root:root . chmod -R u+w,go+r-w,a-s . # Patch irnetd's Makefile to recognize $ROOT -patch -p0 < $CWD/Makefile.irnetd.diff || exit 1 +patch -p0 < $CWD/patches/Makefile.irnetd.diff # Patch smcinit's Makefile to link libz -patch -p0 < $CWD/Makefile.smcinit.diff || exit 1 +patch -p0 < $CWD/patches/Makefile.smcinit.diff + +# io.h has moved in newer kernel includes +patch -p1 < $CWD/patches/irda-utils-0.9.18-fixup_io.c_include.diff # Now that we have declared $SLKCFLAGS, lets use it find . -name Makefile | \ @@ -65,14 +76,20 @@ while read i; do done mkdir -p $PKG/usr/bin $PKG/usr/sbin $PKG/usr/man -make || exit 1 -make install ROOT=$PKG MANDIR=$PKG/usr/man || exit 1 +make +make install ROOT=$PKG MANDIR=$PKG/usr/man ( 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 || true ) +# Use a BSD-style init script (emphasise is put on "style" ;) ) +mkdir -p $PKG/etc/rc.d && rm -rf $PKG/etc/rc.d/init.d +cat $CWD/rc.irda.new > $PKG/etc/rc.d/rc.irda.new + # Documentation is spread all over the source package; just include the README files mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION find . -name README | \ @@ -81,13 +98,9 @@ while read i; do done cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild -# Use a BSD-style init script (emphasise is put on "style" ;) ) -mkdir -p $PKG/etc/rc.d && rm -rf $PKG/etc/rc.d/init.d -cat $CWD/rc.irda.new > $PKG/etc/rc.d/rc.irda.new - mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc cat $CWD/doinst.sh > $PKG/install/doinst.sh 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} diff --git a/network/irda-utils/irda-utils.info b/network/irda-utils/irda-utils.info index c17dae69e2902..855dad088cd59 100644 --- a/network/irda-utils/irda-utils.info +++ b/network/irda-utils/irda-utils.info @@ -3,6 +3,8 @@ VERSION="0.9.18" HOMEPAGE="http://irda.sourceforge.net" DOWNLOAD="http://downloads.sourceforge.net/irda/irda-utils-0.9.18.tar.gz" MD5SUM="84dc12aa4c3f61fccb8d8919bf4079bb" +DOWNLOAD_x86_64="" +MD5SUM_x86_64="" MAINTAINER="Michael Wagner" EMAIL="lapinours@web.de" APPROVED="rworkman" diff --git a/network/irda-utils/patches/Makefile.irnetd.diff b/network/irda-utils/patches/Makefile.irnetd.diff new file mode 100644 index 0000000000000..eca8c5542856e --- /dev/null +++ b/network/irda-utils/patches/Makefile.irnetd.diff @@ -0,0 +1,11 @@ +--- irnetd/Makefile~ 2007-06-11 14:22:52.000000000 +0200 ++++ irnetd/Makefile 2007-06-11 14:23:14.000000000 +0200 +@@ -55,7 +55,7 @@ + + install: irnetd + $(prn_install) +- $(ECMD) install irnetd /usr/sbin/ ++ $(ECMD) install irnetd $(ROOT)/usr/sbin/ + + + clean: diff --git a/network/irda-utils/patches/Makefile.smcinit.diff b/network/irda-utils/patches/Makefile.smcinit.diff new file mode 100644 index 0000000000000..fc2e6182ee617 --- /dev/null +++ b/network/irda-utils/patches/Makefile.smcinit.diff @@ -0,0 +1,23 @@ +--- smcinit/Makefile~ 2007-06-11 21:06:06.000000000 +0200 ++++ smcinit/Makefile 2007-06-11 21:06:39.000000000 +0200 +@@ -26,17 +26,17 @@ + + smcinit: smcinit.o + $(prn_cc_o) +- $(ECMD)$(CC) -o $@ $^ $(LIBS) -lpci ++ $(ECMD)$(CC) -o $@ $^ $(LIBS) -lpci -lz + + + tosh1800-smcinit: tosh1800-smcinit.o + $(prn_cc_o) +- $(ECMD)$(CC) $(XCFLAGS) -o $@ $^ $(LIBS) -lpci ++ $(ECMD)$(CC) $(XCFLAGS) -o $@ $^ $(LIBS) -lpci -lz + + + tosh2450-smcinit: tosh2450-smcinit.o + $(prn_cc_o) +- $(ECMD)$(CC) $(XCFLAGS) -o $@ $^ $(LIBS) -lpci ++ $(ECMD)$(CC) $(XCFLAGS) -o $@ $^ $(LIBS) -lpci -lz + + + %o: %c diff --git a/network/irda-utils/patches/irda-utils-0.9.18-fixup_io.c_include.diff b/network/irda-utils/patches/irda-utils-0.9.18-fixup_io.c_include.diff new file mode 100644 index 0000000000000..3f82bc3a5b15c --- /dev/null +++ b/network/irda-utils/patches/irda-utils-0.9.18-fixup_io.c_include.diff @@ -0,0 +1,36 @@ +diff -Nur irda-utils-0.9.18.orig/findchip/nsc.c irda-utils-0.9.18/findchip/nsc.c +--- irda-utils-0.9.18.orig/findchip/nsc.c 2006-07-11 01:16:06.000000000 -0500 ++++ irda-utils-0.9.18/findchip/nsc.c 2009-10-14 00:22:39.372013759 -0500 +@@ -33,7 +33,7 @@ + #include + #include + #include +-#include ++#include + + #include "findchip.h" + +diff -Nur irda-utils-0.9.18.orig/findchip/smc.c irda-utils-0.9.18/findchip/smc.c +--- irda-utils-0.9.18.orig/findchip/smc.c 2006-07-11 01:16:06.000000000 -0500 ++++ irda-utils-0.9.18/findchip/smc.c 2009-10-14 00:22:42.770014109 -0500 +@@ -32,7 +32,7 @@ + #include + #include + #include +-#include ++#include + + #include "findchip.h" + +diff -Nur irda-utils-0.9.18.orig/findchip/winbond.c irda-utils-0.9.18/findchip/winbond.c +--- irda-utils-0.9.18.orig/findchip/winbond.c 2006-07-11 01:16:06.000000000 -0500 ++++ irda-utils-0.9.18/findchip/winbond.c 2009-10-14 00:22:45.938995740 -0500 +@@ -32,7 +32,7 @@ + #include + #include + #include +-#include ++#include + + #include "findchip.h" + -- cgit v1.2.3