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

# source: BLFS 8.2
TARBALL=openjpeg-$PKGVER.tar.gz
MD5SUM=6a1f8aaa1fe55d2088e3a9c942e0f698
SRC_URL=https://github.com/uclouvain/openjpeg/archive/v${PKGVER}/$TARBALL
BUNDLE=

SLACKREQ='libpng32 libtiff32 lcms2_32'
SLACKDESC="libopenjpeg2_32: libopenjpeg2_32 $PKGVER (JPEG-2000 library)  
libopenjpeg2_32:  
libopenjpeg2_32: OpenJPEG is an open-source implementation of the JPEG-2000 
libopenjpeg2_32: standard. OpenJPEG fully respects the JPEG-2000 specifications 
libopenjpeg2_32: and can compress/decompress lossless 16-bit images.  
libopenjpeg2_32: 
libopenjpeg2_32: This is version 2 of the library.
libopenjpeg2_32: This is 32-bit version of the library.
libopenjpeg2_32: 
libopenjpeg2_32: 
libopenjpeg2_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
}

### build
pkg_build() {
	CMAKEFLAGS="$CMAKEFLAGS \
		-DCMAKE_BUILD_TYPE=Release \
		-DOPENJPEG_INSTALL_LIB_DIR=$LIBDIR"
	pkg_build_cmake && pkg_build_slackdesc
	
	# extra docs
	#cd ../doc &&
	#for man in man/man?/* ; do
	#	install -v -D -m 644 $man /usr/share/$man
	#done
}


