summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorkfg2017-04-14 12:48:18 +0200
committerkfg2017-04-14 12:48:18 +0200
commit7cc9b2215b80fb3a0679c9368ba28f7ed06b608a (patch)
tree2079c4c75bd8e64e1df777f53745fe0907a7a5b9
parentdb13725d98c228d81ff832924768da9a77e34b20 (diff)
downloadaur-7cc9b2215b80fb3a0679c9368ba28f7ed06b608a.tar.gz
keep EXEs
-rw-r--r--.SRCINFO4
-rw-r--r--PKGBUILD62
2 files changed, 54 insertions, 12 deletions
diff --git a/.SRCINFO b/.SRCINFO
index ae90539d13f..d53aca13147 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,9 +1,9 @@
# Generated by mksrcinfo v8
-# Thu Apr 13 20:46:52 UTC 2017
+# Fri Apr 14 10:48:10 UTC 2017
pkgbase = mingw-w64-x265
pkgdesc = Open Source H265/HEVC video encoder (mingw-w64)
pkgver = 2.3
- pkgrel = 1
+ pkgrel = 2
url = https://bitbucket.org/multicoreware/x265
arch = any
license = GPL
diff --git a/PKGBUILD b/PKGBUILD
index b098c90e216..1a1c29a4d93 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=mingw-w64-x265
pkgver=2.3
-pkgrel=1
+pkgrel=2
pkgdesc='Open Source H265/HEVC video encoder (mingw-w64)'
arch=('any')
url='https://bitbucket.org/multicoreware/x265'
@@ -23,23 +23,65 @@ prepare() {
build() {
for _arch in ${_architectures}; do
- mkdir -p "${srcdir}"/build-${_arch} && cd "${srcdir}"/build-${_arch}
-
unset LDFLAGS CPPFLAGS
- ${_arch}-cmake \
- -DLIB_INSTALL_DIR="lib" \
- -DENABLE_SHARED='TRUE' \
- -DENABLE_CLI='FALSE' \
- "${srcdir}"/x265_${pkgver}/source
- make
+
+ if [[ ${_arch} == x86_64-w64-mingw32 ]]; then
+ mkdir -p "${srcdir}"/build-12-${_arch} && cd "${srcdir}"/build-12-${_arch}
+
+ ${_arch}-cmake \
+ -DLIB_INSTALL_DIR="lib" \
+ -DHIGH_BIT_DEPTH='TRUE' \
+ -DMAIN12='TRUE' \
+ -DEXPORT_C_API='FALSE' \
+ -DENABLE_CLI='FALSE' \
+ -DENABLE_SHARED='FALSE' \
+ "${srcdir}"/x265_${pkgver}/source
+ make
+
+ mkdir -p "${srcdir}"/build-10-${_arch} && cd "${srcdir}"/build-10-${_arch}
+
+ ${_arch}-cmake \
+ -DLIB_INSTALL_DIR="lib" \
+ -DHIGH_BIT_DEPTH='TRUE' \
+ -DEXPORT_C_API='FALSE' \
+ -DENABLE_CLI='FALSE' \
+ -DENABLE_SHARED='FALSE' \
+ "${srcdir}"/x265_${pkgver}/source
+ make
+
+ mkdir -p "${srcdir}"/build-8-${_arch} && cd "${srcdir}"/build-8-${_arch}
+
+ ln -s ../build-10-${_arch}/libx265.a libx265_main10.a
+ ln -s ../build-12-${_arch}/libx265.a libx265_main12.a
+
+ ${_arch}-cmake \
+ -DLIB_INSTALL_DIR="lib" \
+ -DENABLE_SHARED='TRUE' \
+ -DEXTRA_LIB='x265_main10.a;x265_main12.a' \
+ -DEXTRA_LINK_FLAGS='-L.' \
+ -DLINKED_10BIT='TRUE' \
+ -DLINKED_12BIT='TRUE' \
+ -DENABLE_CLI='TRUE' \
+ "${srcdir}"/x265_${pkgver}/source
+ make
+ else
+ mkdir -p "${srcdir}"/build-8-${_arch} && cd "${srcdir}"/build-8-${_arch}
+ ${_arch}-cmake \
+ -DLIB_INSTALL_DIR="lib" \
+ -DENABLE_SHARED='TRUE' \
+ -DENABLE_CLI='TRUE' \
+ "${srcdir}"/x265_${pkgver}/source
+ make
+ fi
done
}
package() {
for _arch in ${_architectures}; do
- cd "${srcdir}"/build-${_arch}
+ cd "${srcdir}"/build-8-${_arch}
make DESTDIR="$pkgdir" install
+ ${_arch}-strip -s "${pkgdir}"/usr/${_arch}/bin/*.exe
${_arch}-strip -x -g "${pkgdir}"/usr/${_arch}/bin/*.dll
${_arch}-strip -g "${pkgdir}"/usr/${_arch}/lib/*.a
done