IGNOREPATH=/etc:/home:/var:/dev:/boot:/root:/tmp:/usr/local:/bin:/sbin:/mnt:/usr/src STRIPLIB=y STRIPBIN=y VERSION=3.3.11 PROGNAME="db3 $VERSION" DESC="\ db3 (Berkeley database library version 3) \n\ \n\ The Berkeley Database (Berkeley DB) library provides embedded database \n\ support for both traditional and client/server applications. \n\ \n\ This package should be installed if compatibility is needed with \n\ databases created with the Berkeley DB version 3. \n\ \n\ This library used to be part of the glibc package." BUILD=1 MAINTAINER="Mark Post " SOURCE=http://www.sleepycat.com/download/index.shtml PKGNAME=db3-$VERSION-s390-$BUILD TAG=REC compile() { tar -yxvf $CWD/db-$VERSION.tar.bz2 cd db-$VERSION/ zcat $CWD/patch.3.3.11.1.gz | patch -p0 --verbose chown -R root.root . find . -perm 775 | xargs chmod 755 find . -perm 444 | xargs chmod 644 cd dist ./configure --prefix=/usr \ --enable-compat185 \ --enable-shared \ --enable-rpc \ --build=s390-slackware-linux \ --host=s390-slackware-linux \ --target=s390-slackware-linux make } install() { make install prefix=/package-db3/usr docdir=/package-db3/usr/doc/db-3.3.11/ cd .. rm -rf /package-db3/usr/doc/db-$VERSION/* cp -a LICENSE README /package-db3/usr/doc/db-$VERSION rm -rf /package-db3/usr/doc/db-$VERSION/api_c/ cat << EOF > /package-db3/usr/doc/db-$VERSION/README-DOCS For a ton of additional documentation (too large to include here) on writing source code that uses libdb3, please see the source tarball db-$VERSION.tar.bz2, which can be found in the Slackware source tree in source/l/db3/, or on Sleepycat's web site: http://www.sleepycat.com. EOF ( cd /package-db3/usr/include mkdir db3 mv *.h db3/ ln -sf db3/db.h db.h ) mkdir /package-db3/lib mv /package-db3/usr/lib/libdb-3.3.so /package-db3/lib/ ( cd /package-db3/usr/lib rm -rf libdb-3.3.so ; ln -sf /lib/libdb-3.3.so libdb-3.3.so rm -rf libdb-3.a ; ln -sf libdb-3.3.a libdb-3.a rm -rf libdb.a ; ln -sf libdb-3.3.a libdb.a ) } attributes() { chown -R root.bin $PKG/package-db3/usr/bin/ chmod 755 $PKG/package-db3/usr/bin/* \ $PKG/package-db3/lib/* } special() { cd $PKG mv package-db3/* ./ rmdir package-db3 cd $CTL cat $CWD/slack-desc > slack-desc sed -e 's%package-db3/%%g' doinst.sh > doinst.sh.new cat doinst.sh.new > doinst.sh rm doinst.sh.new }