2009-12-30 21:49:11 +00:00
|
|
|
# Template file for 'x264'
|
|
|
|
pkgname=x264
|
2014-09-29 18:14:15 +00:00
|
|
|
_snap_date=20140928
|
2009-12-30 21:49:11 +00:00
|
|
|
_snap_rev=2245
|
|
|
|
version="${_snap_date}.${_snap_rev}"
|
2014-09-29 18:14:15 +00:00
|
|
|
revision=1
|
2011-08-11 21:06:30 +00:00
|
|
|
wrksrc="x264-snapshot-${_snap_date}-${_snap_rev}-stable"
|
2013-03-24 15:26:55 +00:00
|
|
|
hostmakedepends="yasm"
|
2009-12-30 21:49:11 +00:00
|
|
|
short_desc="Free library for encoding H264/AVC video streams"
|
|
|
|
maintainer="Juan RP <xtraeme@gmail.com>"
|
2011-08-11 21:06:30 +00:00
|
|
|
homepage="http://www.videolan.org/developers/x264.html"
|
|
|
|
license="GPL-2"
|
2012-09-25 10:31:00 +00:00
|
|
|
distfiles="http://download.videolan.org/pub/videolan/x264/snapshots/x264-snapshot-${_snap_date}-${_snap_rev}-stable.tar.bz2"
|
2014-09-29 18:14:15 +00:00
|
|
|
checksum=2c30a479989c9bc98629a49208505e9c99c81e3f4b7b0fbd087dfb5395b872df
|
2009-12-30 21:49:11 +00:00
|
|
|
|
2012-01-27 10:36:57 +00:00
|
|
|
do_configure() {
|
2013-03-24 15:26:55 +00:00
|
|
|
if [ "$XBPS_TARGET_MACHINE" != "i686" -o "$XBPS_TARGET_MACHINE" != "x86_64" ]; then
|
2013-10-08 07:19:28 +00:00
|
|
|
args+=" --disable-asm"
|
2013-03-24 15:26:55 +00:00
|
|
|
fi
|
2013-04-08 23:49:27 +00:00
|
|
|
if [ "$CROSS_BUILD" ]; then
|
2013-10-08 07:19:28 +00:00
|
|
|
args+=" --host=$XBPS_CROSS_TRIPLET"
|
2013-03-24 15:26:55 +00:00
|
|
|
fi
|
2013-10-08 07:19:28 +00:00
|
|
|
./configure --prefix=/usr --disable-swscale --enable-static \
|
|
|
|
--enable-pic --enable-shared --disable-opencl ${args}
|
2011-08-11 21:06:30 +00:00
|
|
|
}
|
|
|
|
|
2012-01-27 10:36:57 +00:00
|
|
|
do_build() {
|
2011-08-11 21:06:30 +00:00
|
|
|
make ${makejobs}
|
|
|
|
}
|
|
|
|
|
2012-01-27 10:36:57 +00:00
|
|
|
do_install() {
|
2011-08-11 21:06:30 +00:00
|
|
|
make DESTDIR=${DESTDIR} \
|
|
|
|
bindir=/usr/bin libdir=/usr/lib includedir=/usr/include install
|
2013-10-08 07:19:28 +00:00
|
|
|
# Set version as x.x.0 in pkg-config file.
|
2014-09-29 18:14:15 +00:00
|
|
|
sed -i -e "s|0.142.x|0.142.0|" ${DESTDIR}/usr/lib/pkgconfig/x264.pc
|
2011-08-11 21:06:30 +00:00
|
|
|
}
|
2013-04-14 16:42:25 +00:00
|
|
|
|
|
|
|
x264-devel_package() {
|
2014-09-29 18:14:15 +00:00
|
|
|
depends="${sourcepkg}>=${version}_${revision}"
|
2013-10-08 07:19:28 +00:00
|
|
|
short_desc+=" - development files"
|
2013-04-14 16:42:25 +00:00
|
|
|
pkg_install() {
|
|
|
|
vmove usr/include
|
|
|
|
vmove usr/lib/pkgconfig
|
|
|
|
vmove "usr/lib/*.a"
|
2013-10-08 07:19:28 +00:00
|
|
|
vmove "usr/lib/*.so"
|
2013-04-14 16:42:25 +00:00
|
|
|
}
|
|
|
|
}
|