Browse Source

gnome/libsigc++: Added.

slackware-14.2
Damien Goutte-Gattat 13 years ago
parent
commit
6919fd6e3f
  1. 1
      gnome/libsigc++/libsigc++-2.2.2.tar.bz2.sha1
  2. 155
      gnome/libsigc++/libsigc++.SlackBuild
  3. 20
      gnome/libsigc++/slack-desc

1
gnome/libsigc++/libsigc++-2.2.2.tar.bz2.sha1

@ -0,0 +1 @@
e1d6446222410bf8d707c6d371101a6eb36e9121 ./libsigc++-2.2.2.tar.bz2

155
gnome/libsigc++/libsigc++.SlackBuild

@ -0,0 +1,155 @@
#! /bin/sh
#
# by: H4kTeUr - http://www.slackbuilds.net < h4kteur at slackbuilds dot net >
# Copyright 2007, 2008 H4kTeUr. All rights reserved.
#
# Redistribution and use of this software, with or without modification, is
# permitted provided that the following conditions are met:
#
# 1. Redistributions of this software must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
# Latest libsigc++ sourcecode is available at http://libsigc.sourceforge.net
set -e
CWD=$(pwd)
TMP=${TMP:-/tmp}
PKG=${PKG:-$TMP/package-libsigc++}
OUT=${OUT:-$TMP/build}
# version on the tarball
VERSION=${VERSION:-2.2.2}
# version used in the source directory to cd into
DIRVER=${DIRVER:-2.2.2}
# version used for the Slackware package
PKGVER=${PKGVER:-2.2.2}
# target
ARCH=${ARCH:-i486}
TARGET=${TARGET:-i486}
BUILD=${BUILD:-1_SBn}
# set tarball download link
SOURCE=${SOURCE:-ftp://ftp.gnome.org/pub/gnome/sources/libsigc++/2.2/libsigc++-$VERSION.tar.bz2}
ARCHIVE=$(basename $SOURCE)
# sanity checks
if [ "$(id -u)" = "0" ]; then
echo "Do not run this SlackBuild as ROOT !"
exit 1
fi
if [ ! -d $TMP ]; then
mkdir -p $TMP
fi
# download the tarball if it's not found
if [ ! -r $ARCHIVE ]; then
echo "Downloading $ARCHIVE..."
rm -f $ARCHIVE.part
wget -vc $SOURCE -O $ARCHIVE.part
mv $ARCHIVE.part $ARCHIVE
fi
# check SHA1 sums
if [ -r $ARCHIVE.sha1 ]; then
sha1sum -c $ARCHIVE.sha1
else
echo "$ARCHIVE.sha1 SHA1 sums not found !"
exit 1
fi
if [ "$ARCH" = "i386" ]; then
SLKCFLAGS="-O2 -march=i386 -mcpu=i686"
elif [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2"
fi
# cleanup
rm -rf $PKG
mkdir -p $PKG
# extraction
cd $TMP
rm -rf libsigc++-$DIRVER
tar -xvf $CWD/libsigc++-$VERSION.tar.bz2
cd libsigc++-$DIRVER
# make sure ownerships and permissions are sane
chmod -R a-s,u+rw,go-w+r .
# configure
CFLAGS=$SLKCFLAGS \
CXXFLAGS=$SLKCFLAGS \
./configure \
--prefix=/usr \
--sysconfdir=/etc \
--localstatedir=/var \
--enable-static=no \
--build=$TARGET-slackware-linux
# build and install
make -j3
make DESTDIR=$PKG install
# strip binaries
echo "Stripping binaries..."
find $PKG -type f | xargs file | grep "shared object" | cut -f 1 -d : | \
xargs strip --strip-unneeded 2> /dev/null || \
echo "No shared objects to strip..."
# add a documentation directory
echo "Adding documentation package..."
mkdir -p $PKG/usr/doc/libsigc++-$PKGVER
install -p -m 644 \
AUTHORS ChangeLog COPYING INSTALL NEWS README TODO \
$PKG/usr/doc/libsigc++-$PKGVER
# adjust docs to traditional Slackware location
mv $PKG/usr/share/doc/libsigc-2.0/docs $PKG/usr/doc/libsigc++-$VERSION
rm -rf $PKG/usr/share
# build the package
mkdir -p $PKG/install
if [ -r $CWD/slack-desc ]; then
install -m 644 $CWD/slack-desc $PKG/install
fi
if [ -r $CWD/doinst.sh ]; then
install -m 755 $CWD/doinst.sh $PKG/install
fi
cd $PKG
PACKAGING="
chown -R root.root .
find . -perm 664 -exec chmod 644 {} \;
find . -perm 777 -exec chmod 755 {} \;
mkdir -p $OUT
rm -f $OUT/libsigc++-$PKGVER-$ARCH-$BUILD.tgz
/sbin/makepkg -l y -c n $OUT/libsigc++-$PKGVER-$ARCH-$BUILD.tgz
rm -rf $PKG
rm -rf $TMP/libsigc++-$DIRVER
"
if [ "$(which fakeroot 2> /dev/null)" ]; then
echo "$PACKAGING" | fakeroot
else
su -c "$PACKAGING"
fi
exit 0

20
gnome/libsigc++/slack-desc

@ -0,0 +1,20 @@
# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description. Line
# up the first '|' above the ':' following the base package name, and the '|'
# on the right side marks the last column you can put a character in. You must
# make exactly 11 lines for the formatting to be correct. It's also
# customary to leave one space after the ':'.
|-----handy-ruler------------------------------------------------------|
libsigc++: libsigc++ (The Typesafe Callback Framework for C++)
libsigc++:
libsigc++: libsigc++ implements a typesafe callback system for standard C++.
libsigc++: It allows you to define signals and to connect those signals to
libsigc++: any callback function, either global or a member function,
libsigc++: regardless of whether it is static or virtual.
libsigc++:
libsigc++: libsigc++ is used by gtkmm to wrap the GTK+ signal system. It does
libsigc++: not depend on GTK or gtkmm.
libsigc++:
libsigc++:
Loading…
Cancel
Save