Subject: pkg/29723: xpm builtin detection is problematic on Solaris
To: None <,,>
From: None <>
List: pkgsrc-bugs
Date: 03/17/2005 05:25:00
>Number:         29723
>Category:       pkg
>Synopsis:       xpm builtin detection is problematic on Solaris
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Thu Mar 17 05:25:00 +0000 2005
>Originator:     Simon Kuhn
>Release:        pkgsrc-current
Case Western Reserve University
SunOS reducto 5.9 Generic_117171-13 sun4u sparc SUNW,Sun-Fire-V240 Solaris

xpm is included in Solaris 9, and the pkgsrc xpm package detects this. Dependent packages fail to buildlink however.
Build a package that depends on xpm, such as emacs.

===> Required package xpm>=3.4knb2: NOT found
===> Verifying package for ../../graphics/xpm
===> xpm is part of your X11 distribution
===> Returning to build of emacs-21.4a
===> Creating toolchain wrappers for emacs-21.4a
xpm is not installed; can't buildlink files.
Force the pkgsrc xpm package to be built. Comment out 

#.if !empty(IS_BUILTIN.xpm:M[yY][eE][sS])
#PKG_SKIP_REASON= "${PKGBASE} is part of your X11 distribution"

to ignore the builtin detection.

In order to build xpm with gcc on Solaris, the following lines in /usr/local/lib/X11/config/site.def must be uncommented:

#ifndef HasGcc2
#define HasGcc2 YES

#ifndef HasCplusplus
#define HasCplusplus YES

It would be nice if this was documented somewhere (I stumbled upon it), or if somehow pkgsrc enabled these imake defs automatically when using gcc (I have no idea how).