NetBSD Problem Report #40995

From apb@cequrux.com  Wed Mar 11 12:46:29 2009
Return-Path: <apb@cequrux.com>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
	by www.NetBSD.org (Postfix) with ESMTP id 5DA9763BE42
	for <gnats-bugs@gnats.NetBSD.org>; Wed, 11 Mar 2009 12:46:29 +0000 (UTC)
Message-Id: <20090311124308.CF682E94505@apb-laptoy.apb.alt.za>
Date: Wed, 11 Mar 2009 12:43:08 +0000 (UTC)
From: apb@cequrux.com
Reply-To: apb@cequrux.com
To: gnats-bugs@gnats.NetBSD.org
Subject: libnids needs glib and gthread
X-Send-Pr-Version: 3.95

>Number:         40995
>Category:       pkg
>Synopsis:       libnids needs glib and gthread
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Mar 11 12:50:00 +0000 2009
>Closed-Date:    Thu Jun 18 06:21:16 +0000 2015
>Last-Modified:  Thu Jun 18 06:21:16 +0000 2015
>Originator:     Alan Barrett
>Release:        NetBSD 5.99.7
>Organization:
Not much
>Environment:
System: NetBSD 5.99.7 i386
>Description:
	The net/libnids package installs only a static library. 
	Programs that link against ilbnids need

		-lnids -lglib-2.0 -lghtread-2.0

        but there appears to be no mechanism for informing such programs
        of that fact.

        For example, the security/dsniff-nox11 package won't build,
        complaining about several undefined symbols that are referenced
        by libnids, and provided by libglib02.0 and libghtread-2.0.

>How-To-Repeat:
	Try to build security/dsniff-nox11

>Fix:
        Unknown.  Perhaps convert libnids to use libtool and to provide
        a shared library with appropriate dependency information?

        A workaround is to patch the Makefile in
        security/dsniff-nox11/work/dsniff-2.3/Makefile (after "make
        configure" has created the Makefile, but before proceeding to
        the rest of the build), changing the LIBNIDS line to:

	NIDSLIB = -L/usr/pkg/lib -lnids -lglib-2.0 -lgthread-2.0

        However, this is clearly the wrong solution, since it would have
        to be integrated into the configure script and repeated for
        every package that uses libnids.

>Release-Note:

>Audit-Trail:
From: "OBATA Akio" <obache@netbsd.org>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: pkg/40995: libnids needs glib and gthread
Date: Sun, 31 May 2009 07:20:27 +0900

 On Wed, 11 Mar 2009 21:50:00 +0900, <apb@cequrux.com> wrote:

 > 	The net/libnids package installs only a static library.
 > 	Programs that link against ilbnids need
 >
 > 		-lnids -lglib-2.0 -lghtread-2.0

 Now, allowed glib to be disabled.
 Then, it is depend on whether libnids was built with glib option or not.

 > 	NIDSLIB = -L/usr/pkg/lib -lnids -lglib-2.0 -lgthread-2.0
 >
 >         However, this is clearly the wrong solution, since it would have
 >         to be integrated into the configure script and repeated for
 >         every package that uses libnids.

 Putting follwing lines in net/libnids/buildlink3.mk may help to resolve this issue.
 But it must be conditional, as said in above.

 BUILDLINK_DEPMETHOD.glib2?=   build
 .include "../../devel/glib2/buildlink3.mk"
 BUILDLINK_TRANSFORM+=	l:nids:nids:glib-2.0:gthread-2.0

 -- 
 "Of course I love NetBSD":-)
 OBATA Akio / obache@NetBSD.org

State-Changed-From-To: open->closed
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Thu, 18 Jun 2015 06:21:16 +0000
State-Changed-Why:
Fixed by tnn in -r1.7 of libnids/bl3.mk, in November 2009.


>Unformatted:

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-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.