From f4c7269fec565a611ef66bc3520abe848db7621d Mon Sep 17 00:00:00 2001
From: Vincent Batts <vbatts@hashbangbash.com>
Date: Tue, 11 May 2010 22:23:25 +0200
Subject: libraries/barry: Updated for version 0.14

---
 libraries/barry/barry.SlackBuild | 40 +++++++++++++++++++++++++++-------------
 1 file changed, 27 insertions(+), 13 deletions(-)

(limited to 'libraries/barry/barry.SlackBuild')

diff --git a/libraries/barry/barry.SlackBuild b/libraries/barry/barry.SlackBuild
index 142ad54fc8..3484fda22a 100644
--- a/libraries/barry/barry.SlackBuild
+++ b/libraries/barry/barry.SlackBuild
@@ -7,17 +7,30 @@
 ## http://sourceforge.net/projects/barry/
 ##
 ## Written by "Vincent Batts <vbatts@batts.mine.nu>"
+##
+## opensync consideration added thanks
+##   to "Heinz Wiesinger <HMWiesinger@gmx.at>"
 
-VERSION=0.11
+PKGNAME=barry
+VERSION=0.14
 ARCH=${ARCH:-i486}
-BUILD=${BUILD:-3}
+BUILD=${BUILD:-1}
 TAG=${TAG:-_SBo}
 
 CWD=$(pwd)
 TMP=${TMP:-/tmp/SBo}
-PKG=$TMP/package-barry
+PKG=$TMP/package-$PKGNAME
 OUTPUT=${OUTPUT:-/tmp}
 
+# Enable opensync-plugin
+OPENSYNC=${OPENSYNC:-no}
+
+if [ "$OPENSYNC" = "no" ]; then
+  opensync_opt="dis"
+else
+  opensync_opt="en"
+fi
+
 if [ "$ARCH" = "i486" ]; then
   SLKCFLAGS="-O2 -march=i486 -mtune=i686"
 elif [ "$ARCH" = "i686" ]; then
@@ -31,9 +44,9 @@ fi
 rm -rf $PKG
 mkdir -p $TMP $PKG $OUTPUT
 cd $TMP
-rm -rf barry-$VERSION
-tar xvf $CWD/barry-$VERSION.tar.bz2
-cd barry-$VERSION
+rm -rf $PKGNAME-$VERSION
+tar xvf $CWD/$PKGNAME-$VERSION.tar.bz2
+cd $PKGNAME-$VERSION
 chown -R root:root .
 chmod -R a-s,u+rw,go+r-w .
 
@@ -42,7 +55,8 @@ CXXFLAGS="$SLKCFLAGS" \
 ./configure \
   --prefix=/usr \
   --mandir=/usr/man \
-  --build=i486-slackware-linux
+  --${opensync_opt}able-opensync-plugin \
+  --build=$ARCH-slackware-linux
 
 make || exit 1
 make install DESTDIR=$PKG || exit 1
@@ -54,20 +68,20 @@ make install DESTDIR=$PKG || exit 1
 
 gzip -9 $PKG/usr/man/man?/*.?
 
-mkdir -p $PKG/usr/doc/barry-$VERSION
-cp -a README INSTALL TODO COPYING AUTHORS NEWS ChangeLog \
-  $PKG/usr/doc/barry-$VERSION
+mkdir -p $PKG/usr/doc/$PKGNAME-$VERSION
+cp -a README TODO COPYING AUTHORS NEWS ChangeLog \
+  $PKG/usr/doc/$PKGNAME-$VERSION
 
 mkdir -p $PKG/etc/udev/rules.d/
-cp -a udev/10-blackberry.rules udev/99-barry-perms \
+cp -a udev/10-blackberry.rules udev/99-$PKGNAME-perms \
   $PKG/etc/udev/rules.d/
 
 mkdir -p $PKG/etc/modprobe.d
-echo "blacklist berry-charge" > $PKG/etc/modprobe.d/barry.new
+echo "blacklist berry-charge" > $PKG/etc/modprobe.d/$PKGNAME.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/barry-$VERSION-$ARCH-$BUILD$TAG.tgz
+/sbin/makepkg -l y -c n $OUTPUT/$PKGNAME-$VERSION-$ARCH-${BUILD}${TAG}.tgz
-- 
cgit v1.2.3