diff options
Diffstat (limited to 'source.local/l/cairo/cairo.SlackBuild')
-rwxr-xr-x | source.local/l/cairo/cairo.SlackBuild | 83 |
1 files changed, 44 insertions, 39 deletions
diff --git a/source.local/l/cairo/cairo.SlackBuild b/source.local/l/cairo/cairo.SlackBuild index 34a507d..004470a 100755 --- a/source.local/l/cairo/cairo.SlackBuild +++ b/source.local/l/cairo/cairo.SlackBuild @@ -1,6 +1,6 @@ #!/bin/sh -# Copyright 2008, 2009, 2010, 2011 Patrick J. Volkerding, Sebeka, MN, USA +# Copyright 2008, 2009, 2010, 2011, 2013 Patrick J. Volkerding, Sebeka, MN, USA # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -20,42 +20,43 @@ # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# Modified 2012 by Eric Hameleers <alien at slackware.com> for ARM port. +# Modified 2013 by Eric Hameleers <alien at slackware.com> for ARM port. PKGNAM=cairo -VERSION=1.10.2 -BUILD=${BUILD:-2} +VERSION=${VERSION:-1.12.14} +BUILD=${BUILD:-1} NUMJOBS=${NUMJOBS:-" -j7 "} -# Automatically determine the architecture we're building on: -MARCH=$( uname -m ) -if [ -z "$ARCH" ]; then - case "$MARCH" in - i?86) export ARCH=i486 ;; - armv7hl) export ARCH=$MARCH ;; - arm*) export ARCH=arm ;; - # Unless $ARCH is already set, use uname -m for all other archs: - *) export ARCH=$MARCH ;; - esac -fi - -if [ "$ARCH" = "i486" ]; then - SLKCFLAGS="-O2 -march=i486 -mtune=i686" - LIBDIRSUFFIX="" -elif [ "$ARCH" = "s390" ]; then - SLKCFLAGS="-O2" - LIBDIRSUFFIX="" -elif [ "$ARCH" = "x86_64" ]; then - SLKCFLAGS="-O2 -fPIC" - LIBDIRSUFFIX="64" -elif [ "$ARCH" = "armv7hl" ]; then - SLKCFLAGS="-O2 -march=armv7-a -mfpu=vfpv3-d16" - LIBDIRSUFFIX="" +if [ -e $CWD/machine.conf ]; then + . $CWD/machine.conf ] +elif [ -e /etc/slackbuild/machine.conf ]; then + . /etc/slackbuild/machine.conf ] else - SLKCFLAGS="-O2" - LIBDIRSUFFIX="" + # Automatically determine the architecture we're building on: + if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) export ARCH=i486 ;; + arm*) export ARCH=arm ;; + # Unless $ARCH is already set, use uname -m for all other archs: + *) export ARCH=$( uname -m ) ;; + esac + fi + # Set CFLAGS/CXXFLAGS and LIBDIRSUFFIX: + if [ "$ARCH" = "i486" ]; then + SLKCFLAGS="-O2 -march=i486 -mtune=i686" + LIBDIRSUFFIX="" + elif [ "$ARCH" = "s390" ]; then + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" + elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" + LIBDIRSUFFIX="64" + else + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" + fi fi case "$ARCH" in @@ -80,10 +81,6 @@ find . \ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ -exec chmod 644 {} \; -# Thanks to Ubuntu for this, but I found it at Gentoo's bugtracker -# http://bugs.gentoo.org/show_bug.cgi?id=336696 -zcat $CWD/cairo-1.10.0-buggy_gradients.patch.gz | patch -p1 || exit 1 - CFLAGS="$SLKCFLAGS" \ ./configure \ --prefix=/usr \ @@ -96,21 +93,22 @@ CFLAGS="$SLKCFLAGS" \ --disable-win32 \ --disable-trace \ --enable-xlib \ - --enable-freetype \ + --enable-xcb \ + --enable-xcb-shm \ + --enable-xlib-xcb \ --enable-ps \ --enable-pdf \ --enable-svg \ --enable-tee \ --enable-gobject \ + --enable-xml \ --build=$TARGET + # None of these are 'stable' yet... # --enable-qt \ # --enable-gl \ # --enable-drm \ -# --enable-xcb \ -# --enable-xlib-xcb \ -# --enable-xcb-drm \ -# --enable-drm-xr \ + # Skipping this, because it causes a dependency on the specific # version of binutils installed at compile time: # --enable-trace @@ -127,6 +125,13 @@ cp -a \ $PKG/usr/doc/$PKGNAM-$VERSION ( cd $PKG/usr/doc/$PKGNAM-$VERSION ; ln -sf /usr/share/gtk-doc/html/cairo html ) +# We do not need the entire NEWS file. +if [ -r NEWS ]; then + DOCSDIR=$(echo $PKG/usr/doc/*-$VERSION) + cat NEWS | head -n 1000 > $DOCSDIR/NEWS + touch -r NEWS $DOCSDIR/NEWS +fi + mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc |