# Description: Simple library for font loading and glyph rasterization using FontConfig, FreeType and pixman.
# URL: https://codeberg.org/dnkl/fcft
# Maintainer: Tim Biermann, tbier at posteo dot de
# Depends on: fontconfig scdoc tllist utf8proc wayland-protocols xorg-libpixman
# Optional: harfbuzz

name=fcft
version=3.3.3
release=1
source=(https://codeberg.org/dnkl/fcft/archive/$version.tar.gz)
renames=($name-$version.tar.gz)

build() {
  prt-get isinst harfbuzz && PKGMK_FCFT+=' -D grapheme-shaping=enabled -D run-shaping=enabled'

  meson setup $name build $PKGMK_FCFT \
    --prefix=/usr \
    --buildtype=plain \
    --wrap-mode nodownload \
    -D b_lto=true \
    -D b_pie=true
  meson compile -C build
  DESTDIR=$PKG meson install -C build

  rm -r $PKG/usr/share/doc
}
