### this file is sourced not run
PKGVER=1.8
PKGBUILD=1
PKGARCH=x86_64

# source: post BLFS 7.8 2015-01-06
TARBALL=x265_$PKGVER.tar.gz
MD5SUM=8b7ef9bc0b5bd26965d05a4508effeed
SRC_URL=https://bitbucket.org/multicoreware/x265/downloads/$TARBALL
BUNDLE=

SLACKREQ=''
SLACKDESC="libx265: libx265 $PKGVER (H.264 codec)  
libx265:  
libx265: x265 package provides a library for encoding video streams into 
libx265: the H.265/HEVC format. 
libx265: 
libx265: 
libx265: 
libx265: 
libx265: 
libx265: 
libx265:
"

### default pkg_download
### prepare
pkg_prepare() {
	pkg_prepare_default &&
	cd tmp/x265* &&
	patch -Np1 -i ../../tmp/pkg/x265_1.8-enable_static-1.patch
}

### default pkg_package
### build
pkg_build() {
	cd /tmp/x265* &&
	mkdir bld &&
	cd bld &&
	cmake -DCMAKE_INSTALL_PREFIX=/usr \
		  -DENABLE_STATIC=OFF         \
		  -DLIB_INSTALL_DIR=$LIBDIR   \
		  ../source                   &&
	make $MAKEFLAGS &&
	make install &&
	pkg_build_slackdesc
	
}
