861ac185a6
```sh git grep -l '^patch_args=-Np0' "srcpkgs/$1*/template" | while read template; do for p in ${template%/template}/patches/*; do sed -i ' \,^[+-][+-][+-] /dev/null,b /^[*-]\+ [0-9]\+\(,[0-9]\+\)\? [*-]\+$/b s,^[*][*][*] ,&a/, /^--- /{ s,\(^--- \)\(./\)*,\1a/, s,[.][Oo][Rr][Ii][Gg]\([ /]\),\1, s/[.][Oo][Rr][Ii][Gg]$// s/[.]patched[.]\([^.]\)/.\1/ h } /^+++ -/{ g s/^--- a/+++ b/ b } s,\(^+++ \)\(./\)*,\1b/, ' "$p" done sed -i '/^patch_args=/d' $template done ```
42 lines
1.4 KiB
Bash
42 lines
1.4 KiB
Bash
# Template file for 'libimobiledevice'
|
|
pkgname=libimobiledevice
|
|
version=1.3.0
|
|
revision=2
|
|
build_style=gnu-configure
|
|
hostmakedepends="automake libtool pkgconf python3-Cython"
|
|
makedepends="python3-devel libglib-devel openssl-devel
|
|
libusb-devel libplist-devel libusbmuxd-devel"
|
|
short_desc="Library to communicate with Apple devices"
|
|
maintainer="Orphaned <orphan@voidlinux.org>"
|
|
license="LGPL-2.1-only"
|
|
homepage="https://libimobiledevice.org"
|
|
changelog="https://raw.githubusercontent.com/libimobiledevice/libimobiledevice/master/NEWS"
|
|
distfiles="https://github.com/libimobiledevice/libimobiledevice/archive/${version}.tar.gz"
|
|
checksum=acbfb73eabee162e64c0d9de207d71c0a5f47c40cd5ad32a5097f734328ce10a
|
|
|
|
if [ "$CROSS_BUILD" ]; then
|
|
configure_args="ac_cv_sys_file_offset_bits=yes ac_cv_sys_large_file=yes"
|
|
fi
|
|
|
|
post_patch() {
|
|
# LibreSSL does not provide this function
|
|
vsed -e '/SSL_CTX_set_security_level/d' -i src/idevice.c
|
|
vsed -e 's,-L$(libdir),,g' -i cython/Makefile.am
|
|
}
|
|
|
|
pre_configure() {
|
|
export PYTHON_CPPFLAGS="-I${XBPS_CROSS_BASE}/${py3_inc}"
|
|
export PYTHON_LDFLAGS="-L${XBPS_CROSS_BASE}/usr/lib -lpython${py3_ver}"
|
|
autoreconf -fi
|
|
}
|
|
|
|
libimobiledevice-devel_package() {
|
|
short_desc+=" - development files"
|
|
depends="${makedepends} ${sourcepkg}>=${version}_${revision}"
|
|
pkg_install() {
|
|
vmove usr/include
|
|
vmove usr/lib/*.a
|
|
vmove usr/lib/*.so
|
|
vmove usr/lib/pkgconfig
|
|
}
|
|
}
|