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

# source: james
TARBALL=libgd-$PKGVER.tar.xz
MD5SUM=8d8d6a6189513ecee6e893b1fb109bf8
SRC_URL=https://github.com/libgd/libgd/releases/download/gd-$PKGVER/$TARBALL
BUNDLE=

SLACKREQ='libpng32 freetype2_32 fontconfig32 libjpeg-turbo32 libXpm32 libvpx32 libtiff32' # 
SLACKDESC="libgd32: libgd32 $PKGVER (Graphics library)  
libgd32:  
libgd32: GD is an open source code library for the dynamic creation of images by 
libgd32: programmers. GD is written in C, and wrappers are available for Perl, 
libgd32: PHP and other languages. GD creates PNG, JPEG, GIF, WebP, XPM, BMP 
libgd32: images, among other formats. GD is commonly used to generate charts, 
libgd32: graphics, thumbnails, and most anything else, on the fly. While not 
libgd32: restricted to use on the web, the most common applications of GD 
libgd32: involve website development.  
libgd32: 
libgd32: This contains 32-bit version of the library.
"

### default pkg_download
### default pkg_prepare
### package - only collect the libraries
pkg_package() {
	rm -rf bin sbin usr/bin usr/sbin usr/include usr/share
	mkdir -p usr/bin &&
	mv -v tmp/*-config-32 usr/bin
}

### build
pkg_build() {
	CONFFLAGS="$CONFFLAGS --disable-static"
	pkg_build_autoconf &&
	pkg_build_slackdesc &&
	
	# multilib
	mv -v /usr/bin/gdlib-config /tmp/gdlib-config-32
}
