### this file is sourced not run
PKGNAME=mtm
PKGVER=1.2.0
PKGBUILD=1
PKGARCH=x86_64

# source: JakeSFR
TARBALL=${PKGNAME}-${PKGVER}.tar.gz
MD5SUM=1ce1a412e0e1b810c1eb039c47e37dc4
SRC_URL=https://github.com/deadpixi/mtm/archive/${PKGVER}.tar.gz
BUNDLE=

SLACKDESC="${PKGNAME}: ${PKGNAME} ${PKGVER} (Micro Terminal Multiplexer)  
${PKGNAME}:  
${PKGNAME}: mtm is the Micro Terminal Multiplexer, a terminal multiplexer.
${PKGNAME}: There are only a few commands, two of which are hardly ever used.
${PKGNAME}: There are no modes, no dozens of commands, no crazy feature list.
${PKGNAME}: mtm emulates a classic ANSI text terminal.
${PKGNAME}: That means it should work out of the box on essentially
${PKGNAME}: all terminfo/termcap-based systems (even pretty old ones),
${PKGNAME}: without needing to install a new termcap entry.
${PKGNAME}: 
${PKGNAME}: https://github.com/deadpixi/mtm
"

SLACKINSTALL=''
SLACKREQ='libncurses'

### default pkg_download
### prepare
pkg_prepare() {
	pkg_prepare_default &&

	cd tmp/${PKGNAME}* &&
	sed -i 's#NCURSESW_INCLUDE_H <ncursesw/curses.h>#NCURSESW_INCLUDE_H <curses.h>#' config.def.h &&
	
	true
}
### default pkg_package
### build
pkg_build() {

	export DESTDIR=/usr MANDIR=/usr/share/man/man1

	cd /tmp/${PKGNAME}* &&

	make ${MAKEFLAGS}  &&
	make ${MAKEFLAGS} install &&

	pkg_build_slackdesc &&

	true
}
 