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

# source: BLFS 11.3
TARBALL=lcms2-$PKGVER.tar.gz
MD5SUM=7f7baa3e605c961b9301135105ee9a34
SRC_URL=https://github.com/mm2/Little-CMS/releases/download/lcms$PKGVER/$TARBALL
BUNDLE=

SLACKREQ='libjpeg-turbo32 libtiff32'
SLACKDESC="lcms2_32: lcms2_32 $PKGVER (Color management engine)  
lcms2_32:  
lcms2_32: The Little Color Management System is a small-footprint color 
lcms2_32: management engine, with special focus on accuracy and performance. It 
lcms2_32: uses the International Color Consortium standard (ICC), which is the 
lcms2_32: modern standard for color management.  
lcms2_32: 
lcms2_32: This contains 32-bit version of the library.
lcms2_32: 
lcms2_32: 
lcms2_32:
"

### 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 etc
}

### build
pkg_build() {
	cd /tmp/lcms* &&

	# BLFS 11.3: uptream patch to unbreak colord
	sed '/BufferSize < TagSize/,+1 s/goto Error/TagSize = BufferSize/' \
		-i src/cmsio0.c &&

	CONFFLAGS="$CONFFLAGS --disable-static" &&
	pkg_build_autoconf && pkg_build_slackdesc
}


