core/harfbuzz/PKGBUILD

59 lines
1.5 KiB
Bash
Raw Normal View History

2015-12-17 18:29:35 +08:00
pkgbase=(harfbuzz)
pkgname=(harfbuzz harfbuzz-icu)
2016-03-15 08:00:20 +08:00
pkgver=1.2.3
pkgrel=2
2015-12-17 18:29:35 +08:00
pkgdesc="OpenType text shaping engine"
arch=(x86_64)
url="http://www.freedesktop.org/wiki/Software/HarfBuzz"
2015-12-17 18:29:35 +08:00
license=(MIT)
2016-03-15 08:00:20 +08:00
makedepends=(glib2 freetype2 graphite cairo icu gobject-introspection gtk-doc ragel)
2015-12-17 18:29:35 +08:00
source=(http://www.freedesktop.org/software/harfbuzz/release/${pkgbase}-${pkgver}.tar.bz2)
2016-03-15 08:00:20 +08:00
sha256sums=('8216d2404aaab7fde87be0365a90d64aa6c55928e104557cfcb37b54a096cb8c')
2015-12-17 18:29:35 +08:00
prepare() {
mkdir path
ln -s /usr/bin/python2 path/python
cd $pkgbase-$pkgver
2016-03-15 08:00:20 +08:00
NOCONFIGURE=1 ./autogen.sh
2015-12-17 18:29:35 +08:00
}
2015-12-17 18:29:35 +08:00
build() {
cd $pkgbase-$pkgver
2016-03-15 08:00:20 +08:00
CFLAGS+=' -DNDEBUG'
CXXFLAGS+=' -DNDEBUG'
./configure --prefix=/usr \
2015-12-17 18:29:35 +08:00
--with-glib --with-freetype --with-cairo --with-icu --with-graphite2 \
2016-03-15 08:00:20 +08:00
--with-gobject --enable-doc
make
}
2015-12-17 18:29:35 +08:00
check() {
cd $pkgbase-$pkgver
2016-03-15 08:00:20 +08:00
PATH="$srcdir/path:$PATH" make check
2015-12-17 18:29:35 +08:00
}
package_harfbuzz() {
depends=(glib2 graphite)
2015-12-17 18:29:35 +08:00
optdepends=('cairo: hb-view program')
cd $pkgbase-$pkgver
make DESTDIR="$pkgdir" install
install -Dm644 COPYING "$pkgdir/usr/share/licenses/harfbuzz/COPYING"
# Split harfbuzz-icu
mkdir -p ../hb-icu/usr/{include/harfbuzz,lib/pkgconfig}; cd ../hb-icu
mv "$pkgdir"/usr/lib/libharfbuzz-icu* ./usr/lib
mv "$pkgdir"/usr/lib/pkgconfig/harfbuzz-icu.pc ./usr/lib/pkgconfig
mv "$pkgdir"/usr/include/harfbuzz/hb-icu.h ./usr/include/harfbuzz
}
package_harfbuzz-icu(){
pkgdesc="$pkgdesc (ICU integration)"
depends=(harfbuzz icu)
mv hb-icu/* "$pkgdir"
2015-12-17 18:29:35 +08:00
install -Dm644 $pkgbase-$pkgver/COPYING "$pkgdir/usr/share/licenses/harfbuzz-icu/COPYING"
}