### this file is sourced not run
# source: step

# Build [1] master commit or [2] official release

pkgname=gtkdialog_doc # for SLACKDESC
repo=gtkdialog

# # [1] Master commit
# hash=8c23050b0d91befdb2a400e66601733dc5a0b69f
# MD5SUM=59d3337aedccd900a913dc0fec4b2358

# PKGVER=0.8.4.20220216
# TARBALL=$repo-$hash.tar.gz
# SRC_URL=https://github.com/puppylinux-woof-CE/$repo/archive/$hash.tar.gz

# [2] Official release

MD5SUM=e71164e439515f530c7e48f25b5b10a4
PKGVER=0.8.5
TARBALL=$pkgname-$PKGVER.tar.gz
SRC_URL=https://github.com/puppylinux-woof-CE/$repo/archive/refs/tags/$PKGVER.tar.gz

# --- common ---

PKGARCH=noarch
PKGBUILD=1
BUNDLE=

SLACKSUG='gtkdialog_gtk2 gtkdialog_gtk3'
SLACKDESC="$pkgname: $pkgname $PKGVER (documentation and examples)
$pkgname:
$pkgname: Gtkdialog is a small utility for fast and easy GUI building. It can create
$pkgname: dialog boxes for almost any interpreted and compiled programs.
$pkgname: This package only supplies documentation and examples.
$pkgname:
$pkgname: License: GNU GPL2
$pkgname:
$pkgname:
$pkgname
$pkgname:
"

### default pkg_download
### prepare
# pkg_prepare() {
# 	pkg_prepare_default &&
# 	cd tmp/gtkdialog* &&
# 	# pretend this is already version 0.8.5 so that fatdog scripts that
# 	# rely on new gtkdialog features can check the version number
# 	patch -Np0 -i ../pkg/gtkdialog_bump_version.patch
# }
### default pkg_package
### build
pkg_build() {
	cd /tmp/gtkdialog*

	NOCONFIGURE=1 ./autogen.sh &&
	CONFFLAGS="$CONFFLAGS --enable-maintainer-mode" &&
	./configure $CONFFLAGS &&

	# install docs, references, and examples
	make $MAKEINSTALLFLAGS install-html install-info install-man &&
	cp -a doc/reference /usr/share/doc/gtkdialog &&
	cp -a examples /usr/share/doc/gtkdialog &&
	mv /usr/share/doc/gtkdialog /usr/share/doc/gtkdialog-0.8.5 &&

	pkg_build_slackdesc
}

# vim:ft=sh:

