summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: b051d378904e8f98092cc2f0b17c4eda346c6ce8 (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
56
57
58
59
60
61
62
63
64
65
66
# Maintainer: seiuneko <chfsefefgesfen foxmail>
# Contributor: Jan Alexander Steffens (heftig) <heftig@archlinux.org>
# Contributor: Jan de Groot <jgc@archlinux.org>

pkgname=freetype2-wps
pkgver=2.13.3
pkgrel=1
epoch=
pkgdesc="Font rasterization library, fix fakebold render issue for Kingsoft Office (WPS Office) when freetype2>2.13.0."
url="https://www.freetype.org/"
arch=(x86_64)
license=('FTL OR GPL-2.0-or-later')
depends=(
  wps-office
)
makedepends=(
  librsvg
  libx11
  meson
  qt5-base
)
source=(
  https://download-mirror.savannah.gnu.org/releases/freetype/freetype-$pkgver.tar.xz{,.sig}
  0000-WPS-compatiblity.patch::https://gitlab.freedesktop.org/freetype/freetype/-/merge_requests/304/diffs.patch
  https://gitlab.archlinux.org/archlinux/packaging/packages/freetype2/-/raw/29bc205851a24e5bdabc6998e825aab4518eb6df/0001-Enable-table-validation-modules.patch
  https://gitlab.archlinux.org/archlinux/packaging/packages/freetype2/-/raw/29bc205851a24e5bdabc6998e825aab4518eb6df/0002-Enable-subpixel-rendering.patch
  https://gitlab.archlinux.org/archlinux/packaging/packages/freetype2/-/raw/29bc205851a24e5bdabc6998e825aab4518eb6df/0003-Enable-long-PCF-family-names.patch
)
b2sums=('f9591c6998df02b072adaf38a968e91deae8ed4d53ea0cb74d08982c4f0e48b1a98c1378a698164e4f730f07a3b0bea308a94fcc2e2b8ce9967dbf9478b599bd'
        'SKIP'
        '42e53690cae9930fdfc819ecbce578619b4bbc75faab247dc09394abaf768d58cc9b8314f5bb22e11a991611135d50bd364c1b45d1f871e26b82dbadda99657c'
        '2c148694e150b3faae9dc46ead824ae6d94cfe34f2918bc9066f45bab7e6b6f77b4d4b2fee00c3d466d866e1985132cea4a774dcf1bab95409b7cf55efff01e1'
        '9598d13eae0411878c1af8e5d875c3b1fc09f4e6649edfbbf3b0a819c4c585648521f0b30ffd1318f5106cfde9c899d3db70c8ffe36dac59f3f98b5fd7dab115'
        '66deb179d1f1f4e2e35f6d50acfbacce80595d5128f5fed8c1871838c210dbf1a7173a87dd937d64997844c8f478c8f81120f71e33b9d59d980e179d103ff31c')
validpgpkeys=(
  E30674707856409FF1948010BE6C3AAC63AD8E3F # Werner Lemberg <wl@gnu.org>
)

prepare() {
  cd freetype-$pkgver
  patch -Np1 -i ../0000-WPS-compatiblity.patch
  patch -Np1 -i ../0001-Enable-table-validation-modules.patch
  patch -Np1 -i ../0002-Enable-subpixel-rendering.patch
  patch -Np1 -i ../0003-Enable-long-PCF-family-names.patch
}

build() {
  local meson_options=(
    -D freetype2:default_library=shared
  )
  arch-meson freetype-$pkgver build "${meson_options[@]}"
  meson compile -C build
}

check() {
  meson test -C build --print-errorlogs
}

package() {
  install -Dt "$pkgdir/usr/lib/office6" -m644 build/libfreetype.so.6

  install -Dm644 freetype-$pkgver/docs/FTL.TXT \
    -t "$pkgdir/usr/share/licenses/$pkgname"
}

# vim:set sw=2 sts=-1 et: