NetBSD Problem Report #51694
From www@NetBSD.org Wed Dec 7 02:30:21 2016
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
(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 A85B67A2E5
for <gnats-bugs@gnats.NetBSD.org>; Wed, 7 Dec 2016 02:30:21 +0000 (UTC)
Message-Id: <20161207023018.6E6A37A366@mollari.NetBSD.org>
Date: Wed, 7 Dec 2016 02:30:18 +0000 (UTC)
From: davshao@gmail.com
Reply-To: davshao@gmail.com
To: gnats-bugs@NetBSD.org
Subject: lang/guile20 FreeBSD PLIST variable incorrect because of library naming convention
X-Send-Pr-Version: www-1.0
>Number: 51694
>Category: pkg
>Synopsis: lang/guile20 FreeBSD PLIST variable incorrect because of library naming convention
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: pkg-manager
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Dec 07 02:35:00 +0000 2016
>Closed-Date: Sat Jun 03 18:26:55 +0000 2017
>Last-Modified: Sat Jun 03 18:26:55 +0000 2017
>Originator: David Shao
>Release: current pkgsrc
>Organization:
>Environment:
FreeBSD xxxxxx.xxx 11.0-RELEASE-p2 FreeBSD 11.0-RELEASE-p2 #0: Mon Oct 24 06:55:27 UTC 2016 root@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64
>Description:
lang/guile20 does not build on FreeBSD because of a PLIST variable that is supposed to reflect the value of a library name. guile20 wants to know the name of the actual libguile object file library so it can construct another file in the PLIST:
lib/libguile-2.0.${GUILE_LIBNAME}-gdb.scm
But on FreeBSD, neither of the choices for GUILE_LIBNAME set in the Makefile reflect FreeBSD's naming convention for libraries:
ls -la /usr/pkg/lib | grep libguile-2.0
-rw-r--r-- 1 root wheel 9427052 Dec 6 01:34 libguile-2.0.a
-rwxr-xr-x 1 root wheel 1086 Dec 6 01:34 libguile-2.0.la
lrwxr-xr-x 1 root wheel 18 Dec 6 01:34 libguile-2.0.so -> libguile-2.0.so.30
-rwxr-xr-x 1 root wheel 5886812 Dec 6 01:34 libguile-2.0.so.30
-rw-r--r-- 1 root wheel 7793 Dec 6 01:34 libguile-2.0.so.30-gdb.scm
Here the value of 30 seems to come from guile-2.0.12's script file GUILE-VERSION:
LIBGUILE_INTERFACE_CURRENT=30
LIBGUILE_INTERFACE_REVISION=0
LIBGUILE_INTERFACE_AGE=8
Currently the lang/guile20 Makefile assumes that if the platform isn't Darwin, the library name is constructed by subtracting 8 from 30 to get 22 and then forming the string:
so.22.0.8
whereas FreeBSD merely takes the 30 to form
so.30
Incidentally is there a good place for pkgsrc maintainers to document where exactly these magic numbers particular to a port come from, perhaps in the port itself? It might save some time for the next person ...
>How-To-Repeat:
>Fix:
diff -Nur lang/guile20/Makefile lang/guile20.new/Makefile
--- lang/guile20/Makefile 2016-09-28 02:04:41.000000000 -0700
+++ lang/guile20.new/Makefile 2016-12-06 01:17:30.153649000 -0800
@@ -50,6 +50,7 @@
OPSYSVARS+= GUILE_LIBNAME
GUILE_LIBNAME.Darwin= a
+GUILE_LIBNAME.FreeBSD= so.30
GUILE_LIBNAME.*= so.22.8.0
PLIST_SUBST+= GUILE_LIBNAME=${GUILE_LIBNAME}
>Release-Note:
>Audit-Trail:
From: "Maya Rashish" <maya@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/51694 CVS commit: pkgsrc/lang/guile20
Date: Wed, 7 Dec 2016 19:05:48 +0000
Module Name: pkgsrc
Committed By: maya
Date: Wed Dec 7 19:05:48 UTC 2016
Modified Files:
pkgsrc/lang/guile20: Makefile
Log Message:
guile20: fix PLIST for FreeBSD, which for some reason uses a different
soname.
From David Shao in PR pkg/51694
To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 pkgsrc/lang/guile20/Makefile
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
From: coypu@SDF.ORG
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/51694: lang/guile20 FreeBSD PLIST variable incorrect because
of library naming convention
Date: Wed, 7 Dec 2016 19:26:21 +0000
I think the difference may be coming per-OS from config.rpath.
should figure out why, but it's no reason to leave the build broken
From: coypu@SDF.ORG
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: pkg/51694: lang/guile20 FreeBSD PLIST variable incorrect because
of library naming convention
Date: Wed, 7 Dec 2016 19:36:55 +0000
Does removing these lines of config.rpath help?
freebsd[123]*)
library_names_spec='$libname$shrext$versuffix' ;;
(lines 535-536)
From: David Holland <dholland-pbugs@netbsd.org>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/51694: lang/guile20 FreeBSD PLIST variable incorrect because
of library naming convention
Date: Wed, 4 Jan 2017 18:11:20 +0000
On Wed, Dec 07, 2016 at 02:35:00AM +0000, davshao@gmail.com wrote:
> Incidentally is there a good place for pkgsrc maintainers to
> document where exactly these magic numbers particular to a port
> come from, perhaps in the port itself? It might save some time for
> the next person ...
Not really, probably the best bet is a comment in the makefile.
--
David A. Holland
dholland@netbsd.org
State-Changed-From-To: open->closed
State-Changed-By: maya@NetBSD.org
State-Changed-When: Sat, 03 Jun 2017 18:26:55 +0000
State-Changed-Why:
Issue apparently fixed upstream as someone removed the workaround to re-fix the build. (maybe they updated config.rpath)
>Unformatted:
(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.