NetBSD Problem Report #50039

From www@NetBSD.org  Wed Jul  8 07:10:41 2015
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [149.20.53.66])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client CN "mail.netbsd.org", Issuer "Postmaster NetBSD.org" (verified OK))
	by mollari.NetBSD.org (Postfix) with ESMTPS id D51F4A5B2E
	for <gnats-bugs@gnats.NetBSD.org>; Wed,  8 Jul 2015 07:10:40 +0000 (UTC)
Message-Id: <20150708071039.7617AA6554@mollari.NetBSD.org>
Date: Wed,  8 Jul 2015 07:10:39 +0000 (UTC)
From: joern.clausen@uni-bielefeld.de
Reply-To: joern.clausen@uni-bielefeld.de
To: gnats-bugs@NetBSD.org
Subject: erroneous dependency of print/xpdf on libXp
X-Send-Pr-Version: www-1.0

>Number:         50039
>Category:       pkg
>Synopsis:       erroneous dependency of print/xpdf on libXp
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Jul 08 07:15:00 +0000 2015
>Last-Modified:  Thu Jul 09 17:00:01 +0000 2015
>Originator:     Joern Clausen
>Release:        
>Organization:
University of Bielefeld
>Environment:
Solaris 11.2/i86
>Description:
Compiling print/xpdf on Solaris 11.2 fails with

===> Creating toolchain wrappers for xpdf-3.04nb1
ERROR: libXp>=1.0.0 is not installed; can't buildlink files.
*** Error code 1

I can't see any dependency on libXp in Makefile, but there is one on libXpm.

After commenting out

MAKE_ENV+=             SED=${SED:Q} ECHO=${ECHO:Q}

from the Makefile, the package is built without requiring libXp.

NB: Without this change, and after installing libXp manually, xpdf builds, but no dependency on libXp is shown, neither during build nor afterwards (pkg_info -n xpdf).
>How-To-Repeat:

>Fix:

>Audit-Trail:
From: Thomas Klausner <wiz@NetBSD.org>
To: NetBSD bugtracking <gnats-bugs@NetBSD.org>
Cc: 
Subject: Re: pkg/50039: erroneous dependency of print/xpdf on libXp
Date: Wed, 8 Jul 2015 10:21:23 +0200

 On Wed, Jul 08, 2015 at 07:15:00AM +0000, joern.clausen@uni-bielefeld.de wrote:
 > ===> Creating toolchain wrappers for xpdf-3.04nb1
 > ERROR: libXp>=1.0.0 is not installed; can't buildlink files.
 > *** Error code 1

 This usually happens when the buildlink3.mk for a package contains
 libXp/buildlink3.mk, but the package doesn't actually depend on it.

 Can you check, e.g. with 'make show-buildlink3', where libXp is pulled in?

 I just tried on NetBSD with modular x.org, but couldn't reproduce the problem.


 > I can't see any dependency on libXp in Makefile, but there is one on libXpm.
 > 
 > After commenting out
 > 
 > MAKE_ENV+=             SED=${SED:Q} ECHO=${ECHO:Q}
 > 
 > from the Makefile, the package is built without requiring libXp.

 It doesn't make sense to me that this change should change anything.

  Thomas

From: =?ISO-8859-15?Q?J=F6rn_Clausen?= <joern.clausen@uni-bielefeld.de>
To: gnats-bugs@NetBSD.org
Cc: Thomas Klausner <wiz@NetBSD.org>, pkg-manager@NetBSD.org,
 gnats-admin@NetBSD.org, pkgsrc-bugs@NetBSD.org
Subject: Re: pkg/50039: erroneous dependency of print/xpdf on libXp
Date: Wed, 08 Jul 2015 11:08:35 +0200

 >   Can you check, e.g. with 'make show-buildlink3', where libXp is pulled in?

 $ bmake show-buildlink3
 freetype2
      bzip2
      zlib
 libXpm
      x11-links
      xproto
 x11-links

 (with unmodified Makefile!)

 >   >  After commenting out
 >   >
 >   >  MAKE_ENV+=             SED=${SED:Q} ECHO=${ECHO:Q}
 >   >
 >   >  from the Makefile, the package is built without requiring libXp.
 >
 >   It doesn't make sense to me that this change should change anything.

 Something mangling the dependencies hits a bug/feature in Solaris sed 
 (or is it pkgsrc's gsed? or echo/gecho?) that shortens libXpm to libXp? 
 And this piece of code seems to be used only in the toolchain wrapper 
 phase, but not when the actual dependencies are resolved or recorded 
 while installing the package. Here is more context from the build:

 => Tool dependency nbpatch-[0-9]*: found nbpatch-20100124
 => Build dependency kbproto>=1.0.2: found kbproto-1.0.7
 => Build dependency xproto>=7.0.9: found xproto-7.0.28
 => Build dependency xcb-proto>=1.4: found xcb-proto-1.11
 => Build dependency xextproto>=7.0: found xextproto-7.3.0
 => Build dependency inputproto>=1.4: found inputproto-2.3.1
 => Build dependency printproto>=1.0.3: found printproto-1.0.5
 => Build dependency renderproto>=0.9.3nb1: found renderproto-0.11.1
 => Full dependency urw-fonts-[0-9]*: found urw-fonts-1.0.7pre44
 => Full dependency poppler-utils-[0-9]*: found poppler-utils-0.32.0
 => Full dependency freetype2>=2.4.11: found freetype2-2.5.5
 => Full dependency libXpm>=3.5.4.2: found libXpm-3.5.11
 => Full dependency lesstif>=0.95.2nb4: found lesstif-0.95.2nb5
 ===> Overriding tools for xpdf-3.04nb1
 ===> Extracting for xpdf-3.04nb1
 ===> Patching for xpdf-3.04nb1
 => Applying pkgsrc patches for xpdf-3.04nb1
 => Substituting "paths" in doc/sample-xpdfrc doc/xpdf.1 doc/xpdfrc.5
 ===> Creating toolchain wrappers for xpdf-3.04nb1
 ERROR: libXp>=1.0.0 is not installed; can't buildlink files.
 *** Error code 1

 OTOH: trussing the build process shows, that in both cases (i.e. with 
 the line in Makefile intact and commented out) only /usr/gnu/bin/sed is 
 ever executed, no other sed is used. And this happens way before the 
 build process fails. And "echo" is never executed before the build 
 breaks. Okay, now I am puzzled...

 -- 
 Jörn Clausen
 Plattformen & Serverdienste
 Hochschulrechenzentrum

 Universität Bielefeld
 Universitätsstraße 25
 33615 Bielefeld
 Telefon: +49 521 106-12601
 E-Mail: joern.clausen@uni-bielefeld.de

 http://www.uni-bielefeld.de/hrz

From: =?ISO-8859-15?Q?J=F6rn_Clausen?= <joern.clausen@uni-bielefeld.de>
To: gnats-bugs@NetBSD.org
Cc: Thomas Klausner <wiz@NetBSD.org>, pkg-manager@NetBSD.org,
 gnats-admin@NetBSD.org, pkgsrc-bugs@NetBSD.org
Subject: Re: pkg/50039: erroneous dependency of print/xpdf on libXp
Date: Wed, 08 Jul 2015 12:01:06 +0200

 Maybe pkgsrc isn't so wrong after all:

 $ ldd /usr/pkg/bin/xpdf
 [...]
          -lXp.6 => /usr/pkg/lib/libXp.so.6
 [...]
          -lXpm.4 => /usr/pkg/lib/libXpm.so.4
 [...]

 And this is on NetBSD. The same is true on Solaris, i.e. the xpdf there 
 is now showing an unresolved dependency:

 $ ldd /opt/pkg-hrz/head/bin/xpdf
 [...]
          libXp.so.6 =>    (file not found)
 [...]

 So the fix is probably to make x11/libXp an explicit requirement in 
 print/xpdf.

 -- 
 Jörn Clausen
 Plattformen & Serverdienste
 Hochschulrechenzentrum

 Universität Bielefeld
 Universitätsstraße 25
 33615 Bielefeld
 Telefon: +49 521 106-12601
 E-Mail: joern.clausen@uni-bielefeld.de

 http://www.uni-bielefeld.de/hrz

From: Patrick Welche <prlw1@cam.ac.uk>
To: =?iso-8859-1?Q?J=F6rn?= Clausen <joern.clausen@uni-bielefeld.de>
Cc: gnats-bugs@NetBSD.org, Thomas Klausner <wiz@NetBSD.org>,
	pkg-manager@NetBSD.org, gnats-admin@NetBSD.org,
	pkgsrc-bugs@NetBSD.org
Subject: Re: pkg/50039: erroneous dependency of print/xpdf on libXp
Date: Wed, 8 Jul 2015 14:22:04 +0100

 On Wed, Jul 08, 2015 at 12:01:06PM +0200, Jrn Clausen wrote:
 > Maybe pkgsrc isn't so wrong after all:
 > 
 > $ ldd /usr/pkg/bin/xpdf
 > [...]
 >         -lXp.6 => /usr/pkg/lib/libXp.so.6
 > [...]
 >         -lXpm.4 => /usr/pkg/lib/libXpm.so.4
 > [...]
 > 
 > And this is on NetBSD. The same is true on Solaris, i.e. the xpdf there is
 > now showing an unresolved dependency:
 > 
 > $ ldd /opt/pkg-hrz/head/bin/xpdf
 > [...]
 >         libXp.so.6 =>    (file not found)
 > [...]
 > 
 > So the fix is probably to make x11/libXp an explicit requirement in
 > print/xpdf.

 and just to confuse even more, on my -current/amd64 laptop:

 # ldd /usr/pkg/bin/xpdf | grep libXp
         -lXpm.5 => /usr/X11R7/lib/libXpm.so.5
 #

 (native xsrc rather than modular)

From: David Holland <dholland-pbugs@netbsd.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/50039: erroneous dependency of print/xpdf on libXp
Date: Thu, 9 Jul 2015 16:56:10 +0000

 On Wed, Jul 08, 2015 at 10:05:00AM +0000, J?rn Clausen wrote:
  >  $ ldd /opt/pkg-hrz/head/bin/xpdf
  >  [...]
  >           libXp.so.6 =>    (file not found)
  >  [...]
  >  
  >  So the fix is probably to make x11/libXp an explicit requirement in 
  >  print/xpdf.

 libXp is deprecated, so it's probably better to patch it out of xpdf.

 (it doesn't appear in my xpdf on netbsd with native X either, fwiw)

 -- 
 David A. Holland
 dholland@netbsd.org

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2014 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.