# Maintainer: PktSurf <smlinux@pktsurf.in>
app=harfbuzz
version=7.3.0
build=1sml
homepage="https://www.freedesktop.org/wiki/Software/HarfBuzz"
download="https://github.com/harfbuzz/harfbuzz/archive/refs/tags/$version.tar.gz"
desc="OpenType text shaping engine"
requires="glib python3 icu pixman fontconfig libxcb libxext cairo gobject-introspection graphite2"

prepbuilddir() {
  mkandenterbuilddir
  rm -rf $app-$version

  tar xf $srcdir/$app-$version.tar.?z*
  cd $app-$version
  fixbuilddirpermissions
}

build() {
  mkdir -p smbuild && cd smbuild
  meson .. \
    --prefix=/ \
    -Dgraphite2=enabled

  ninja
  DESTDIR="$pkg" ninja install

  cp ../COPYING $pkgdocs/

  mkfinalpkg
}

sha512sums="
29865c2d973f5251706cf428824ea30a6fc09086146afecca7ffd5927d2c0c9818639238249757bee064b4ddcc919d7b43bef058405811427b24e96fda94a789  harfbuzz-7.3.0.tar.lz
"