Subject: pkg/17300: bbrun doesn't compile with xpkgwedge
To: None <>
From: None <kre@munnari.OZ.AU>
List: netbsd-bugs
Date: 06/17/2002 15:01:39
>Number:         17300
>Category:       pkg
>Synopsis:       bbrun doesn't compile with xpkgwedge
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Jun 17 08:10:00 PDT 2002
>Originator:     Robert Elz
>Release:        NetBSD 1.6A pkgsrc of 2002-06-16
	Prince of Songkla University
System: NetBSD 1.6A NetBSD 1.6A (FUCHSIA) #11: Wed May 29 12:50:36 UTC 2002 i386
Architecture: i386
Machine: i386
	wm/bbrun doesn't compile with xpkgwedge installed
	install xpkgwedge, then xpm using xpkgwedge, then attempt
	to compile bbrun

	wait for ...

===> Building for bbrun-1.3
gcc -c -O2 -Wall bbrun.c -o bbrun.o `/usr/obj/pkg/wm/bbrun/work.i386/.buildlink/bin/gtk-config --cflags`
bbrun.c:5: X11/xpm.h: No such file or directory
gmake: *** [bbrun.o] Error 1
*** Error code 2

	Apply the patch below to bbrun/Makefile, and then replace
	patches-aa with the version given below the Makefile patch
	(put back the $NetBSD$ line that this patch lacks...)
	Regenerate distinfo.

pkgsrc Makefile change - this just adds the x11 buildink

--- Makefile.orig	Wed Jun 12 00:36:21 2002
+++ Makefile	Mon Jun 17 07:14:58 2002
@@ -11,6 +11,7 @@
 COMMENT=	run utility for BlackBox
 USE_GMAKE=		yes
@@ -18,6 +19,7 @@
 	${INSTALL_DATA_DIR} ${PREFIX}/share/doc/bbrun
+.include "../../mk/"
 .include "../../graphics/xpm/"
 .include "../../x11/gtk/"
 .include "../../mk/"

And the replacement patches/patch-aa - this just changes a couple of
lines (CFLAGS, LIBS) from CFLAGS= (etc) to CFLAGS+= so all the work
done by the buildlink stuff isn't being ignored...

--- Makefile.orig	Wed Feb  6 20:05:51 2002
+++ Makefile	Mon Jun 17 07:16:33 2002
@@ -1,6 +1,6 @@
 CC     = gcc
-LIBS   = -lXpm `gtk-config --libs`
-CFLAGS = `gtk-config --cflags`
+LIBS   += -lXpm `${GTK_CONFIG} --libs`
+CFLAGS += `${GTK_CONFIG} --cflags`
 OBJS   = bbrun.o \
          ../wmgeneral/wmgeneral.o \
          ../wmgeneral/misc.o \
@@ -8,6 +8,8 @@
 	$(CC) -c -O2 -Wall $< -o $*.o $(CFLAGS)
+all: bbrun
 bbrun: $(OBJS)
 	$(CC) -Wall -g -o bbrun $^ $(LIBS)