### this file is sourced not run
PKGVER=2.2.5
PKGBUILD=1
PKGARCH=i686

# source: BL# This package is in LFS but not in CLFS. So we treat it like BLFS
# except that the source is already in the bundle tarball
# so we treat it like an external (ie BLFS) package
TARBALL=expat-$PKGVER.tar.bz2
MD5SUM=789e297f547980fc9ecc036f9a070d49
BUNDLE=fatdog-base-8.2.tar
SRC_URL=http://distro.ibiblio.org/fatdog/source/800/$BUNDLE

SLACKREQ=
SLACKDESC="expat32: expat32 $PKGVER (XML stream parser library)  
expat32:  
expat32: The Expat package contains a stream oriented C library for parsing XML. 
expat32:  
expat32: This is the 32-bit version of the library.
expat32: 
expat32: 
expat32: 
expat32: 
expat32: 
expat32: 
"

### override download for LFS sources
# $1-src-dir $2-tarball 
pkg_download() {
	echo downloading $BUNDLE for $TARBALL
	wget -P $1 $SRC_URL
	tar -xf $1/$BUNDLE --strip-components=1 -C $1 
	rm $1/$BUNDLE
}

### default pkg_prepare
### package - only collect the libraries
pkg_package() {
	rm -rf bin sbin usr/bin usr/sbin usr/include usr/share
}

### build
pkg_build() {
	CONFFLAGS="$CONFFLAGS --disable-static"
	pkg_build_autoconf && pkg_build_slackdesc &&
	install -v -m755 -d /usr/share/doc/expat-$PKGVER &&
	install -v -m644 doc/*.{html,png,css} /usr/share/doc/expat-$PKGVER
}


