summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorGonzalo Exequiel Pedone2024-03-19 01:41:14 -0300
committerGonzalo Exequiel Pedone2024-03-19 01:41:14 -0300
commit13841a888f824ec27e65c815ddc06c8e4974a118 (patch)
treee1093c362956408b519ecb43b5cf300257600b08
parent2ebac5731ebae361025378498940052b8cc2b531 (diff)
downloadaur-android-aarch64-x264.tar.gz
Package updated.
-rw-r--r--.SRCINFO10
-rw-r--r--.gitignore2
-rw-r--r--0001-Fix-soname.patch (renamed from soname.patch)0
-rw-r--r--0002-Remove-lpthread.patch14
-rw-r--r--0003-Do-not-replace-ftell-and-fseek.patch20
-rw-r--r--PKGBUILD32
6 files changed, 63 insertions, 15 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 59d2cc38f2e2..8e8c1b1565ce 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -7,8 +7,8 @@ pkgbase = android-aarch64-x264
groups = android-x264
license = GPL
makedepends = android-configure
+ makedepends = yasm
makedepends = git
- makedepends = nasm
depends = android-ndk
depends = android-aarch64-ffmpeg
depends = android-aarch64-l-smash
@@ -17,8 +17,12 @@ pkgbase = android-aarch64-x264
options = staticlibs
options = !emptydirs
source = git+https://code.videolan.org/videolan/x264.git#commit=72db437770fd1ce3961f624dd57a8e75ff65ae0b
- source = soname.patch
- md5sums = SKIP
+ source = 0001-Fix-soname.patch
+ source = 0002-Remove-lpthread.patch
+ source = 0003-Do-not-replace-ftell-and-fseek.patch
md5sums = SKIP
+ md5sums = e8322f7da77816cd721183ed42f8a1bc
+ md5sums = ef45412614fcd0fe1a186672fcbbf47d
+ md5sums = 8114198c19f2abd3503af34030604225
pkgname = android-aarch64-x264
diff --git a/.gitignore b/.gitignore
index 47731b2e7117..b98085e0ab41 100644
--- a/.gitignore
+++ b/.gitignore
@@ -3,3 +3,5 @@ src
*.tar.xz
*.tar.gz
*.tar.bz2
+*.tar.zst
+x264
diff --git a/soname.patch b/0001-Fix-soname.patch
index ee2139d7a785..ee2139d7a785 100644
--- a/soname.patch
+++ b/0001-Fix-soname.patch
diff --git a/0002-Remove-lpthread.patch b/0002-Remove-lpthread.patch
new file mode 100644
index 000000000000..67cbab5fce13
--- /dev/null
+++ b/0002-Remove-lpthread.patch
@@ -0,0 +1,14 @@
+--- a/configure
++++ b/configure
+@@ -1049,9 +1049,9 @@
+ cc_check pthread.h -lc "pthread_create(0,0,0,0);" && thread="posix" && libpthread="-lc"
+ ;;
+ *)
+- if cc_check pthread.h -lpthread "pthread_create(0,0,0,0);" ; then
++ if cc_check pthread.h "" "pthread_create(0,0,0,0);" ; then
+ thread="posix"
+- libpthread="-lpthread"
++ libpthread=""
+ else
+ cc_check pthread.h "" "pthread_create(0,0,0,0);" && thread="posix" && libpthread=""
+ fi
diff --git a/0003-Do-not-replace-ftell-and-fseek.patch b/0003-Do-not-replace-ftell-and-fseek.patch
new file mode 100644
index 000000000000..691514907a2c
--- /dev/null
+++ b/0003-Do-not-replace-ftell-and-fseek.patch
@@ -0,0 +1,20 @@
+--- a/configure
++++ b/configure
+@@ -1289,17 +1289,6 @@
+ cc_check '' -fno-zero-initialized-in-bss && CFLAGS="$CFLAGS -fno-zero-initialized-in-bss"
+ fi
+
+-if cc_check "stdio.h" "" "fseeko(stdin,0,0);" ; then
+- define fseek fseeko
+- define ftell ftello
+-elif cc_check "stdio.h" "" "fseeko64(stdin,0,0);" ; then
+- define fseek fseeko64
+- define ftell ftello64
+-elif cc_check "stdio.h" "" "_fseeki64(stdin,0,0);" ; then
+- define fseek _fseeki64
+- define ftell _ftelli64
+-fi
+-
+ if cc_check '' -Wshadow ; then
+ CFLAGS="-Wshadow $CFLAGS"
+ fi
diff --git a/PKGBUILD b/PKGBUILD
index 77d150aefc23..6ce9a0b4c15e 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,43 +1,51 @@
# Maintainer: Gonzalo Exequiel Pedone <hipersayan DOT x AT gmail DOT com>
+# Contributor: Martchus <martchus@gmx.net>
# Contributor: Karl-Felix Glatzer <karl.glatzer@gmx.de>
_android_arch=aarch64
pkgname=android-${_android_arch}-x264
pkgver=157.r72db4377
+_commit=72db437770fd1ce3961f624dd57a8e75ff65ae0b
pkgrel=2
arch=('any')
pkgdesc='Free library for encoding H264/AVC video streams (android)'
license=('GPL')
url='https://www.videolan.org/developers/x264.html'
+groups=('android-x264')
depends=('android-ndk'
"android-${_android_arch}-ffmpeg"
"android-${_android_arch}-l-smash")
-groups=(android-x264)
+makedepends=('android-configure'
+ 'yasm'
+ 'git')
options=(!strip !buildflags staticlibs !emptydirs)
-makedepends=('android-configure' 'git' 'nasm')
-_commit=72db437770fd1ce3961f624dd57a8e75ff65ae0b
source=("git+https://code.videolan.org/videolan/x264.git#commit=${_commit}"
- 'soname.patch')
+ '0001-Fix-soname.patch'
+ '0002-Remove-lpthread.patch'
+ '0003-Do-not-replace-ftell-and-fseek.patch')
md5sums=('SKIP'
- 'SKIP')
+ 'e8322f7da77816cd721183ed42f8a1bc'
+ 'ef45412614fcd0fe1a186672fcbbf47d'
+ '8114198c19f2abd3503af34030604225')
pkgver() {
- cd "${srcdir}"/x264
+ cd "${srcdir}/x264"
local _ver=$(grep '#define X264_BUILD' x264.h | cut -d' ' -f3)
local _rev=$(git rev-parse --short HEAD)
echo ${_ver}.r${_rev}
}
prepare() {
- cd "${srcdir}"/x264
- patch -Np1 -i ../soname.patch
+ cd "${srcdir}/x264"
+ patch -Np1 -i ../0001-Fix-soname.patch
+ patch -Np1 -i ../0002-Remove-lpthread.patch
+ patch -Np1 -i ../0003-Do-not-replace-ftell-and-fseek.patch
}
build() {
- cd "${srcdir}"/x264
+ cd "${srcdir}/x264"
source android-env ${_android_arch}
- unset LDFLAGS CPPFLAGS
configue_opts="
--disable-cli
@@ -64,10 +72,10 @@ build() {
}
package() {
- cd "${srcdir}"/x264
+ cd "${srcdir}/x264"
source android-env ${_android_arch}
make DESTDIR="$pkgdir" install
${ANDROID_STRIP} -g --strip-unneeded "${pkgdir}"/${ANDROID_PREFIX_LIB}/*.so
- ${ANDROID_STRIP} -g "$pkgdir"/${ANDROID_PREFIX_LIB}/*.a
+ ${ANDROID_STRIP} -g "$pkgdir"/${ANDROID_PREFIX_LIB}/*.a || true
}