graphics/xcf-pixbuf-loader: Added (gdk-pixbuf2 loader for Gimp).

Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
This commit is contained in:
B. Watson 2019-12-29 11:27:03 +07:00 committed by Willy Sudiarto Raharjo
parent c5864ccde0
commit 547034bc25
6 changed files with 165 additions and 0 deletions

View file

@ -0,0 +1,7 @@
xcf-pixbuf-loader (gdk-pixbuf2 loader for Gimp image files)
XCF is the Gimp's native file format, as created by its Save command. This
loader allows applications using gdk-pixbuf2 to load .xcf files. In
particular, it works with qiv.
Note: loading large .xcf files is slow. Be patient.

View file

@ -0,0 +1,3 @@
if [ -x /usr/bin/update-gdk-pixbuf-loaders ]; then
/usr/bin/update-gdk-pixbuf-loaders >/dev/null 2>&1
fi

View file

@ -0,0 +1,42 @@
#!/bin/sh
# Create source tarball from git repo, with generated version
# number. We don't include the git history in the tarball.
# Note that this script doesn't need to be run as root. It does
# need to be able to write to the current directory it's run from.
PRGNAM=xcf-pixbuf-loader
CLONE_URL=https://github.com/StephaneDelcroix/$PRGNAM.git
set -e
GITDIR=$( mktemp -dt $PRGNAM.git.XXXXXX )
rm -rf $GITDIR
git clone $CLONE_URL $GITDIR
CWD="$( pwd )"
cd $GITDIR
VERSION=$( git log --date=format:%Y%m%d --pretty=format:%cd.%h -n1 )
rm -rf .git
find . -name .gitignore -print0 | xargs -0 rm -f
cd "$CWD"
rm -rf $PRGNAM-$VERSION $PRGNAM-$VERSION.tar.xz
mv $GITDIR $PRGNAM-$VERSION
tar cvfJ $PRGNAM-$VERSION.tar.xz $PRGNAM-$VERSION
cat <<EOF
Archive created: $PRGNAM-$VERSION.tar.xz
Update $PRGNAM.info with:
VERSION="$VERSION"
DOWNLOAD="http://urchlay.naptime.net/~urchlay/src/$PRGNAM-$VERSION.tar.xz"
MD5SUM="$( md5sum $PRGNAM-$VERSION.tar.xz | cut -d' ' -f1 )"
Don't forget to upload the new source!
EOF

View file

@ -0,0 +1,19 @@
# 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 ':' except on otherwise blank lines.
|-----handy-ruler------------------------------------------------------|
xcf-pixbuf-loader: xcf-pixbuf-loader (gdk-pixbuf2 loader for Gimp image files)
xcf-pixbuf-loader:
xcf-pixbuf-loader: XCF is the Gimp's native file format, as created by its Save
xcf-pixbuf-loader: command. This loader allows applications using gdk-pixbuf2 to load
xcf-pixbuf-loader: .xcf files. In particular, it works with qiv.
xcf-pixbuf-loader:
xcf-pixbuf-loader:
xcf-pixbuf-loader:
xcf-pixbuf-loader:
xcf-pixbuf-loader:
xcf-pixbuf-loader:

View file

@ -0,0 +1,84 @@
#!/bin/sh
# Slackware build script for xcf-pixbuf-loader
# Written by B. Watson (yalhcru@gmail.com)
# Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.
PRGNAM=xcf-pixbuf-loader
VERSION=${VERSION:-20180108.eb42b85}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
i?86) ARCH=i586 ;;
arm*) ARCH=arm ;;
*) ARCH=$( uname -m ) ;;
esac
fi
CWD=$(pwd)
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
if [ "$ARCH" = "i586" ]; then
SLKCFLAGS="-O2 -march=i586 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
else
SLKCFLAGS="-O2"
LIBDIRSUFFIX=""
fi
set -e
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
tar xvf $CWD/$PRGNAM-$VERSION.tar.xz
cd $PRGNAM-$VERSION
chown -R root:root .
find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \
\! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} \+
sh autogen.sh
MODDIR="$( pkg-config gdk-pixbuf-2.0 --variable gdk_pixbuf_moduledir )"
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
./configure \
--disable-static \
--enable-shared \
--prefix=/usr \
--libdir=$MODDIR \
--sysconfdir=/etc \
--localstatedir=/var \
--mandir=/usr/man \
--docdir=/usr/doc/$PRGNAM-$VERSION \
--build=$ARCH-slackware-linux
make
make install-strip DESTDIR=$PKG
rename libio libpixbufloader- $PKG/$MODDIR/*
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
# ChangeLog is a 0-byte placeholder.
cp -a AUTHORS COPYING NEWS README test*.xcf* $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
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.${PKGTYPE:-tgz}

View file

@ -0,0 +1,10 @@
PRGNAM="xcf-pixbuf-loader"
VERSION="20180108.eb42b85"
HOMEPAGE="https://github.com/StephaneDelcroix/xcf-pixbuf-loader"
DOWNLOAD="http://urchlay.naptime.net/~urchlay/src/xcf-pixbuf-loader-20180108.eb42b85.tar.xz"
MD5SUM="b73f994ba57edcfd25c964bfc1f3680f"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES=""
MAINTAINER="B. Watson"
EMAIL="yalhcru@gmail.com"