Subject: pkg/34576: darwin xpm pkgsrc bultin buildlink failure
To: None <pkg-manager@netbsd.org, gnats-admin@netbsd.org,>
From: Darrin B.Jewell <dbj@netbsd.org>
List: pkgsrc-bugs
Date: 09/21/2006 05:05:00
>Number:         34576
>Category:       pkg
>Synopsis:       darwin xpm pkgsrc bultin buildlink failure
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Sep 21 05:05:00 +0000 2006
>Originator:     Darrin B. Jewell
>Release:        pkgsrc updated via cvs ~20060920T0040Z (in 2006Q3 freeze)
>Organization:
>Environment:

$ uname -a
Darwin Cardenio.local 8.7.1 Darwin Kernel Version 8.7.1: Wed Jun  7 16:19:56 PDT 2006; root:xnu-792.9.72.obj~2/RELEASE_I386 i386 i386

$ sw_vers
ProductName:	Mac OS X
ProductVersion:	10.4.7
BuildVersion:	8J2135a

$ gcc --version | head -1
i686-apple-darwin8-gcc-4.0.1 (GCC) 4.0.1 (Apple Computer, Inc. build 5363)

$ cat /Developer/Applications/Xcode.app/Contents/version.plist 
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>BuildVersion</key>
	<string>22</string>
	<key>CFBundleShortVersionString</key>
	<string>2.4</string>
	<key>CFBundleVersion</key>
	<string>759</string>
	<key>ProjectName</key>
	<string>DevToolsIDE</string>
	<key>SourceVersion</key>
	<string>7590000</string>
</dict>
</plist>

>Description:
Building packages that depend on xpm on darwin fail because
it does not correctly detect the builtin xpm, nor does it
correctly require the pkgsrc xpm.

Although the pkgsrc/graphics/xpm/builtin.mk file searches
the imake config file for "NormalLibXpm" this is not defined
in the darwin provided imake config file.  The following
patch unconditionally sets IS_BUILTIN.xpm=yes when building
on Darwin.

This fixes packages that depend on xpm.  However, since there
is no explicit version dependency on the builtin in existing
packages, some packages that will build successfully without
xpm (such as x11-links) need to be removed and rebuilt manually.

>How-To-Repeat:

>Fix:

--=-=-=
Content-Type: text/x-patch
Content-Disposition: attachment; filename=pkg.xpmbuildlink.diff
Content-Description: patch to detect builtin xpm for buildlink

Index: pkgsrc/graphics/xpm/builtin.mk
===================================================================
RCS file: /cvsroot/pkgsrc/graphics/xpm/builtin.mk,v
retrieving revision 1.12
diff -u -r1.12 builtin.mk
--- pkgsrc/graphics/xpm/builtin.mk	6 Apr 2006 06:22:06 -0000	1.12
+++ pkgsrc/graphics/xpm/builtin.mk	21 Sep 2006 03:48:55 -0000
@@ -23,6 +23,8 @@
 	fi
 .    elif ${OPSYS} == "IRIX"
 IS_BUILTIN.xpm=		yes
+.    elif ${OPSYS} == "Darwin"
+IS_BUILTIN.xpm=		yes
 .    else
 BUILTIN_IMAKE_CHECK:=	xpm:NormalLibXpm
 .      include "../../mk/buildlink3/imake-check.mk"

--=-=-=--

>Unformatted:
 --=-=-=