Subject: pkg/17688: Split chat/xchat, with and without GNOME support
To: None <gnats-bugs@gnats.netbsd.org>
From: Julio Merino <jmmv@hispabsd.org>
List: netbsd-bugs
Date: 07/23/2002 13:33:28
>Number:         17688
>Category:       pkg
>Synopsis:       Split chat/xchat, with and without GNOME support
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Tue Jul 23 04:32:00 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     Julio Merino
>Release:        NetBSD 1.6D
>Organization:
	
>Environment:
	
	
System: NetBSD darkstar.local 1.6D NetBSD 1.6D (DARKSTAR) #0: Mon Jul 22 12:44:12 CEST 2002 jmmv@darkstar.local:/var/build/kernel/DARKSTAR i386
Architecture: i386
Machine: i386
>Description:
	The current package chat/xchat is always built with gnome-core. This
	is often undesirable, as gnome-core is a huge package and xchat can
	work perfectly without it. I mean, on some small systems, xchat can
	be of use if it does not use gnome-core; xchat becomes faster and
	smaller. Although, if you are running GNOME, you will obviously want
	xchat with support for it.

	The following patches split chat/xchat into chat/xchat (only with
	GTK support) and chat/xchat-gnome (with GNOME support).

	The patch also adds a Socks variable, as an addition to the current
	package which contains variables for inet6 and SSL.
>How-To-Repeat:
	
>Fix:
	The fix is composed of various parts. I'll explain each in turn.

	The following Makefile is the only file to be placed inside the
	new directory chat/xchat-gnome:

# $NetBSD$

.include "../xchat/Makefile.common"

PKGNAME=	${DISTNAME:S/-/-gnome-/}
CONFLICTS+=	xchat-[0-9]*
COMMENT+=	and GNOME libraries

CONFIGURE_ARGS+=	--enable-panel

.include "../../graphics/gdk-pixbuf-gnome/buildlink.mk"
.include "../../x11/gnome-core/buildlink.mk"
.include "../../mk/x11.buildlink.mk"
.include "../../mk/bsd.pkg.mk"



	This is the Makefile.common, to be placed inside chat/xchat:

# $NetBSD$

DISTNAME=	xchat-1.8.9
CATEGORIES=	chat x11
MASTER_SITES=	${HOMEPAGE}files/source/1.8/
EXTRACT_SUFX=	.tar.bz2

MAINTAINER=	tron@netbsd.org
HOMEPAGE=	http://xchat.org/
COMMENT=	X11 (X Window System) IRC client, using the GTK+ toolkit

DISTINFO_FILE=  ${.CURDIR}/../xchat/distinfo
FILESDIR=       ${.CURDIR}/../xchat/files
PATCHDIR=       ${.CURDIR}/../xchat/patches
PKGDIR=         ${.CURDIR}/../xchat
PLIST_SRC=      ${.CURDIR}/../xchat/PLIST

USE_GMAKE=	YES
USE_PERL5=	YES
USE_X11BASE=	YES
GNU_CONFIGURE=	YES
CONFIGURE_ENV+=	ac_cv_lib_intl_bindtextdomain='yes'
CONFIGURE_ENV+=	pythonpath=${PYTHONBIN}
MAKE_ENV+=	PKGLOCALEDIR="${PKGLOCALEDIR}"
BUILD_USES_MSGFMT=	YES

BUILD_DEFS+=	USE_INET6 USE_SOCKS

.include "../../mk/bsd.prefs.mk"

# IPv6 support
.if defined(USE_INET6) && ${USE_INET6} == YES
CONFIGURE_ARGS+=	--enable-ipv6
.endif

# SSL support
.if defined(XCHAT_USE_SSL) && ${XCHAT_USE_SSL} == "YES"
.include "../../security/openssl/buildlink.mk"
CONFIGURE_ARGS+=	--enable-openssl=${BUILDLINK_DIR}
.endif

# Socks support
.if defined(USE_SOCKS) && ${USE_SOCKS} == YES
CONFIGURE_ARGS+=	--enable-socks
.endif

post-install:
	${INSTALL_DATA_DIR} ${PREFIX}/share/doc/xchat
	${INSTALL_DATA} ${WRKSRC}/doc/*.html ${PREFIX}/share/doc/xchat

.include "../../devel/glib/buildlink.mk"
.include "../../lang/perl5/buildlink.mk"



	And this is the patch to be applied to chat/xchat, to modify the
	current Makefile.

Index: Makefile
===================================================================
RCS file: /pub/NetBSD-CVS/pkgsrc/chat/xchat/Makefile,v
retrieving revision 1.22
diff -u -r1.22 Makefile
--- Makefile	2002/06/06 11:25:52	1.22
+++ Makefile	2002/07/23 11:27:35
@@ -1,44 +1,15 @@
 # $NetBSD: Makefile,v 1.22 2002/06/06 11:25:52 manu Exp $
 
-DISTNAME=	xchat-1.8.9
-CATEGORIES=	chat x11 gnome
-MASTER_SITES=	${HOMEPAGE}files/source/1.8/
-EXTRACT_SUFX=	.tar.bz2
+.include "Makefile.common"
 
-MAINTAINER=	tron@netbsd.org
-HOMEPAGE=	http://xchat.org/
-COMMENT=	X11 (X Window System) IRC client, using the GTK+ toolkit
+PKGREVISION=	1
 
-USE_GMAKE=	YES
-USE_PERL5=	YES
-USE_X11BASE=	YES
-GNU_CONFIGURE=	YES
-CONFIGURE_ENV+=	ac_cv_lib_intl_bindtextdomain='yes'
-CONFIGURE_ENV+=	pythonpath=${PYTHONBIN}
-MAKE_ENV+=	PKGLOCALEDIR="${PKGLOCALEDIR}"
-BUILD_USES_MSGFMT=	YES
+CONFIGURE_ARGS+=	--disable-gnome
+CONFIGURE_ARGS+=	--disable-zvt
 
-BUILD_DEFS+=	USE_INET6
+CONFLICTS+=		xchat-gnome-[0-9]*
 
-.include "../../mk/bsd.prefs.mk"
-
-CONFIGURE_ARGS+=	--enable-panel
-
-# IPv6 support
-.if defined(USE_INET6) && ${USE_INET6} == YES
-CONFIGURE_ARGS+=	--enable-ipv6
-.endif
-
-# SSL support
-.if defined(XCHAT_USE_SSL) && ${XCHAT_USE_SSL} == "YES"
-.include "../../security/openssl/buildlink.mk"
-CONFIGURE_ARGS+=	--enable-openssl=${BUILDLINK_DIR}
-.endif
-
-post-install:
-	${INSTALL_DATA_DIR} ${PREFIX}/share/doc/xchat
-	${INSTALL_DATA} ${WRKSRC}/doc/*.html ${PREFIX}/share/doc/xchat
-
-.include "../../lang/python/application.buildlink.mk"
-.include "../../x11/gnome-core/buildlink.mk"
+.include "../../graphics/gdk-pixbuf/buildlink.mk"
+.include "../../x11/gtk/buildlink.mk"
+.include "../../mk/x11.buildlink.mk"
 .include "../../mk/bsd.pkg.mk"
>Release-Note:
>Audit-Trail:
>Unformatted: