IGNOREPATH=/home:/var:/dev:/boot:/root:/tmp:/usr/local:/bin:/sbin:/mnt:/usr/src
STRIPLIB=y
STRIPBIN=y

VERSION=2.3.1
PROGNAME="GNOME Print $VERSION"
DESC="\
libgnomeprint                                                        \n\
                                                                     \n\
Libgnomeprint is the non-gui part of the printing libraries for GNOME\n\
applications."

BUILD=1
MAINTAINER="Mark Post <mark.post@eds.com>"
SOURCE=ftp://ftp.gnome.org/pub/GNOME/stable/sources/
PKGNAME=libgnomeprint-$VERSION-s390-$BUILD
TAG=OPT

compile() {
   tar -yxvf $CWD/libgnomeprint-$VERSION.tar.bz2
   cd libgnomeprint-$VERSION
   chown -R root.root .
   find . -perm 666 -exec chmod 644 {} \;
   find . -perm 664 -exec chmod 644 {} \;
   CFLAGS=-O2 \
   ./configure --prefix=/usr \
               --disable-static \
               --sysconfdir=/etc \
               --localstatedir=/var/lib \
               --build=s390-slackware-linux \
               --host=s390-slackware-linux \
               --target=s390-slackware-linux
   make
}

install() {
   make install DESTDIR=/package-libgnomeprint

   mkdir -p /package-libgnomeprint/usr/doc/libgnomeprint-$VERSION
   cp -a AUTHORS COPYING* NEWS README \
       /package-libgnomeprint/usr/doc/libgnomeprint-$VERSION
}

attributes() {
   chown -R root.bin $PKG/package-libgnomeprint/usr/bin/
}

special() {
   cd $PKG
   mv package-libgnomeprint/* ./
   rmdir package-libgnomeprint/

   cd $CTL
   cat $CWD/slack-desc > slack-desc

   sed -e 's%package-libgnomeprint/%%g' doinst.sh > doinst.sh.new
   cat doinst.sh.new > doinst.sh
   rm doinst.sh.new
}

