blob: 72b913b6156573d3c3c8ce2d5b1881d03ea6cd7e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
# Maintainer: Astro Benzene <universebenzene at sina dot com>
# Maintainer: TimeTrap <844177178 at qq dot com>
# Maintainer: Levente Polyak <anthraxx at archlinux dot org>
# Contributor: Eric BĂ©langer <eric at archlinux dot org>
pkgname=libtiff5
_pkgname=tiff
pkgver=4.4.0
pkgrel=2
pkgdesc='Library for manipulation of TIFF images'
arch=('x86_64' 'aarch64')
url="http://www.simplesystems.org/libtiff"
license=('custom')
depends=('glibc'
'libjpeg-turbo'
'xz'
'zlib'
'zstd')
source=("https://download.osgeo.org/libtiff/tiff-${pkgver}.tar.gz"
# fix CVE-2022-2056 / CVE-2022-2057 / CVE-2022-2058: https://bugs.archlinux.org/task/75360
"${pkgname}-4.4.0-fpe_tiffcrop.patch::https://gitlab.com/libtiff/libtiff/-/commit/dd1bcc7abb26094e93636e85520f0d8f81ab0fab.patch"
# fix CVE-2022-34526: https://bugs.archlinux.org/task/75608
"${pkgname}-4.4.0-CVE-2022-34526.patch::https://gitlab.com/libtiff/libtiff/-/commit/275735d0354e39c0ac1dc3c0db2120d6f31d1990.patch")
sha256sums=('917223b37538959aca3b790d2d73aa6e626b688e02dcda272aec24c2f498abed'
'049875c6eddef8d0d653ad069fea7483f7b9b1dc2aad8780784301fb3e34b561'
'10220d1eecc00f830a1814c0b74388e68c4f0a38ec173038d6e5e8a6ad3cc97f')
prepare() {
cd ${_pkgname}-${pkgver}
# apply patch from the source array (should be a pacman feature)
local src
for src in "${source[@]}"; do
src="${src%%::*}"
src="${src##*/}"
[[ $src = *.patch ]] || continue
echo "Applying patch $src..."
patch -Np1 < "../$src"
done
}
build() {
cd ${_pkgname}-${pkgver}
./configure \
--prefix='/usr'
make
}
package() {
cd ${_pkgname}-${pkgver}
make DESTDIR="${pkgdir}" install
rm -rf "${pkgdir}"/usr/{bin,include,lib/{pkgconfig,libtiff{,xx}.{a,so}},share}
install -Dm644 COPYRIGHT -t "${pkgdir}"/usr/share/licenses/${pkgname}
}
|