summaryrefslogtreecommitdiff
path: root/libraries/iniparser/iniparser.SlackBuild
diff options
context:
space:
mode:
authorSteven King <kingrst@gmail.com>2013-12-02 08:51:53 +0700
committerRobby Workman <rworkman@slackbuilds.org>2013-12-02 00:57:39 -0600
commit627123e8811f16fb806e8917f2db2afbf4c1b375 (patch)
tree5eaf36630b14573b4eab7242a61dee361e55be7b /libraries/iniparser/iniparser.SlackBuild
parent6c95f2d058417faaf523fed2942bdd0a0841e75f (diff)
downloadslackbuilds-627123e8811f16fb806e8917f2db2afbf4c1b375.tar.gz
libraries/iniparser: Updated for version 3.1.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org> Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
Diffstat (limited to 'libraries/iniparser/iniparser.SlackBuild')
-rw-r--r--libraries/iniparser/iniparser.SlackBuild52
1 files changed, 30 insertions, 22 deletions
diff --git a/libraries/iniparser/iniparser.SlackBuild b/libraries/iniparser/iniparser.SlackBuild
index 52f944fe00..a81eefa589 100644
--- a/libraries/iniparser/iniparser.SlackBuild
+++ b/libraries/iniparser/iniparser.SlackBuild
@@ -23,7 +23,7 @@
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
PRGNAM=iniparser
-VERSION=${VERSION:-2.17}
+VERSION=${VERSION:-3.1}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -49,6 +49,8 @@ elif [ "$ARCH" = "i686" ]; then
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
+ LDSHFLAGS="-shared -Wl,-Bsymbolic -Wl,-rpath -Wl,/usr/lib64 -Wl,-rpath,/usr/lib64"
+ LDFLAGS="-Wl,-rpath -Wl,/usr/lib64 -Wl,-rpath,/usr/lib64"
else
SLKCFLAGS="-O2"
LIBDIRSUFFIX=""
@@ -60,39 +62,45 @@ rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
-tar xvf $CWD/${PRGNAM}-$VERSION.tar.gz
+tar vxzf $CWD/${PRGNAM}-${VERSION}.tar.gz
+mv ${PRGNAM} ${PRGNAM}-${VERSION}
cd $PRGNAM-$VERSION
chown -R root:root .
find -L . \
- \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 -o -perm 511 \) \
- -exec chmod 755 {} \; -o \
- \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
- -exec chmod 644 {} \;
+ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
+ -o -perm 511 \) -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
+ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
-# Cleanup the Makefile quite a bit
-patch -p1 < $CWD/patches/fixup_Makefile.patch
+CFLAGS="$SLKCFLAGS" \
+CXFLAGS="$SLKCFLAGS" \
-make \
- CFLAGS="$SLKCFLAGS" \
- LIBDIR=/usr/lib${LIBDIRSUFFIX} \
- DOCDIR=/usr/doc/$PRGNAM-$VERSION
-
-# Install the dictionary.h include to <iniparser/>
-patch -p1 < $CWD/patches/fixup_dictionary.h_include.patch
-
-make install install-docs \
- DESTDIR=$PKG \
- CFLAGS="$SLKCFLAGS" \
- LIBDIR=/usr/lib${LIBDIRSUFFIX} \
- DOCDIR=/usr/doc/$PRGNAM-$VERSION
+make
find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+
+mkdir -p $PKG/usr/lib${LIBDIRSUFFIX}
+mkdir -p $PKG/usr/include
+
+cp -ar \
+ AUTHORS INSTALL LICENSE README html \
+ $PKG/usr/doc/$PRGNAM-$VERSION
+
+cp -a \
+ libiniparser.a libiniparser.so.0 \
+ $PKG/usr/lib${LIBDIRSUFFIX}
+
+cp -a \
+ ./src/dictionary.h ./src/iniparser.h \
+ $PKG/usr/include
+
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
-/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$(echo $VERSION | tr '-' '_')-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}