# SliTaz package receipt.

PACKAGE="harfbuzz"
VERSION="2.7.4"
CATEGORY="system-tools"
SHORT_DESC="OpenType text shaping engine."
MAINTAINER="pankso@slitaz.org"
LICENSE="GPL2"
WEB_SITE="https://www.freedesktop.org/wiki/Software/HarfBuzz/"

TARBALL="$PACKAGE-$VERSION.tar.xz"
WGET_URL="https://github.com/harfbuzz/harfbuzz/releases/download/$VERSION/$TARBALL"

DEPENDS="freetype glib libffi pcre"
BUILD_DEPENDS="fontconfig-dev freetype-dev gobject-introspection-dev libgio-dev \
libpng-dev glib-dev pcre-dev bzip2-dev python3-setuptools icu-dev meson ninja"

# Rules to configure and make the package.
compile_rules()
{
    mkdir build && cd build
    meson setup --prefix=/usr \
	--includedir=/usr/include \
	--sysconfdir=/etc \
        --buildtype=release \
	-Dfreetype=enabled \
        -Dbenchmark=disabled \
        -Dglib=enabled \
        -Dgobject=enabled \
        -Dintrospection=enabled \
        -Dtests=disabled \
   .. && ninja && ninja install || return 1
}

# Rules to gen a SliTaz package suitable for Tazpkg.
genpkg_rules()
{
    mkdir -p $fs/usr/lib

    #cp -a $install/usr/bin        $fs/usr
    cp -a $install/usr/lib/*.so*    $fs/usr/lib
}