# SliTaz package receipt.

PACKED_SIZE="24.0K"
UNPACKED_SIZE="52.0K"
PACKAGE="desktop-file-utils"
VERSION="0.26"
CATEGORY="system-tools"
SHORT_DESC="Utilities for .desktop files (update-desktop-database)."
MAINTAINER="pankso@slitaz.org"
LICENSE="GPL2"
WEB_SITE="https://www.freedesktop.org/wiki/Software/desktop-file-utils/"

TARBALL="$PACKAGE-$VERSION.tar.xz"
WGET_URL="https://www.freedesktop.org/software/desktop-file-utils/releases/$TARBALL"

DEPENDS="gcc83-lib-base glib glibc-base pcre"
BUILD_DEPENDS="gcc83 glib-dev meson pkg-config"

SPLIT="desktop-file-utils-extra"

current_version()
{
	wget -O - $(dirname $WGET_URL) 2>/dev/null | \
	sed '/utils-/!d;s|.*utils-||;s|.tar.*||' | sed '$!d'
}

# Rules to configure and make the package.
compile_rules()
{
	export	CC=gcc-83
	export	CXX=g++-83

	meson	_build		\
		--prefix=/usr &&
	ninja	-C _build &&
	ninja	-C _build install
}

# Rules to gen a SliTaz package suitable for Tazpkg.
genpkg_rules()
{
	cook_copy_files update-desktop-database
}
