# New ports collection makefile for:	Gnometoaster
# Date created:		28 Aug 1999
# Whom:			Will Andrews <andrews@technologist.com>
#
# $FreeBSD$
#

PORTNAME=	gnometoaster
PORTVERSION=	0.4
CATEGORIES=	sysutils
MASTER_SITES=	ftp://ftp.server51.freshmeat.net/pub/gnometoaster/archive/
DISTNAME=	gtoaster
EXTRACT_SUFX=	.tgz

MAINTAINER=	andrews@technologist.com

.if defined(WITH_GNOME)
LIB_DEPENDS=	gnomeui.3:${PORTSDIR}/x11/gnomelibs
.endif
RUN_DEPENDS=	${LOCALBASE}/bin/cdrecord:${PORTSDIR}/sysutils/cdrecord \
		${LOCALBASE}/bin/mkisofs:${PORTSDIR}/sysutils/mkisofs \
		${LOCALBASE}/bin/mkhybrid:${PORTSDIR}/sysutils/mkhybrid12 \
		${LOCALBASE}/bin/sox:${PORTSDIR}/audio/sox \
		${LOCALBASE}/bin/mpg123:${PORTSDIR}/audio/mpg123

GTK_CONFIG?=	${X11BASE}/bin/gtk12-config
GLIB_CONFIG?=	${LOCALBASE}/bin/glib12-config
USE_X_PREFIX=	yes
GNU_CONFIGURE=	yes
.if defined(WITH_GNOME)
CONFIGURE_ARGS=	--with-gtk-prefix=${PREFIX} --with-gnome
.else
CONFIGURE_ARGS=	--with-gtk-prefix=${PREFIX} --without-gnome
.endif
CONFIGURE_ENV=	GTK_CONFIG="${GTK_CONFIG}"
USE_GMAKE=	yes
MAKE_ENV=	GTK_CONFIG="${GTK_CONFIG}" GLIB_CONFIG="${GLIB_CONFIG}"

pre-install:
	@${MKDIR} ${PREFIX}/share/gnometoaster/Documentation

do-install:
	@${INSTALL_PROGRAM} ${WRKSRC}/gtoaster ${PREFIX}/bin
.if !defined(NOPORTDOCS)
	@${INSTALL_DATA} ${WRKSRC}/AUTHORS ${PREFIX}/share/gnometoaster
	@${INSTALL_DATA} ${WRKSRC}/COPYING ${PREFIX}/share/gnometoaster
	@${INSTALL_DATA} ${WRKSRC}/ChangeLog ${PREFIX}/share/gnometoaster
	@${INSTALL_DATA} ${WRKSRC}/NEWS ${PREFIX}/share/gnometoaster
	@${INSTALL_DATA} ${WRKSRC}/README ${PREFIX}/share/gnometoaster
	@${INSTALL_DATA} ${WRKSRC}/TODO ${PREFIX}/share/gnometoaster
	@${INSTALL_DATA} ${WRKSRC}/Documentation/gt-doc-1.html ${PREFIX}/share/gnometoaster/Documentation
	@${INSTALL_DATA} ${WRKSRC}/Documentation/gt-doc-2.html ${PREFIX}/share/gnometoaster/Documentation
	@${INSTALL_DATA} ${WRKSRC}/Documentation/gt-doc-3.html ${PREFIX}/share/gnometoaster/Documentation
	@${INSTALL_DATA} ${WRKSRC}/Documentation/gt-doc-4.html ${PREFIX}/share/gnometoaster/Documentation
	@${INSTALL_DATA} ${WRKSRC}/Documentation/gt-doc-5.html ${PREFIX}/share/gnometoaster/Documentation
	@${INSTALL_DATA} ${WRKSRC}/Documentation/gt-doc.html ${PREFIX}/share/gnometoaster/Documentation
	@${INSTALL_DATA} ${WRKSRC}/Documentation/gt-doc.sgml ${PREFIX}/share/gnometoaster/Documentation
	@${INSTALL_DATA} ${WRKSRC}/Documentation/gt-doc.txt ${PREFIX}/share/gnometoaster/Documentation
.endif

.include <bsd.port.mk>
