NetBSD Problem Report #42082

From kre@munnari.OZ.AU  Thu Sep 17 16:23:56 2009
Return-Path: <kre@munnari.OZ.AU>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
	by www.NetBSD.org (Postfix) with ESMTP id EDAAC63C2E4
	for <gnats-bugs@gnats.NetBSD.org>; Thu, 17 Sep 2009 16:23:55 +0000 (UTC)
Message-Id: <200909171623.n8HGNoxf019437@jade.coe.psu.ac.th>
Date: Thu, 17 Sep 2009 23:23:50 +0700 (ICT)
From: kre@munnari.OZ.AU
To: gnats-bugs@gnats.NetBSD.org
Subject: sysutils/p5-Sys-Utmp compilation error (NetBSD 4.0 / i386)
X-Send-Pr-Version: 3.95

>Number:         42082
>Category:       pkg
>Synopsis:       sysutils/p5-Sys-Utmp compilation error (NetBSD 4.0 / i386)
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    sno
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Sep 17 16:25:00 +0000 2009
>Closed-Date:    Fri Jul 30 07:15:59 +0000 2010
>Last-Modified:  Fri Jul 30 07:15:59 +0000 2010
>Originator:     Robert Elz
>Release:        NetBSD 4.0 / i386     pkgsrc current 2009-09-17
>Organization:
	Prince of Songkla University
>Environment:
System: NetBSD jade.coe.psu.ac.th 4.0_STABLE NetBSD 4.0_STABLE (JADE-1.696-20080517) #9: Fri May 23 18:55:13 ICT 2008 kre@jade.coe.psu.ac.th:/usr/obj/4/kernels/JADE i386
Architecture: i386
Machine: i386
>Description:
	sysutils/p5-Sys-Utmp dectalres its own utmpname() function
	which returns void.

	/usr/include/utmp.h declares utmpname() as returning int.

	Bang.

>How-To-Repeat:
	I use pkg_comp with NetBSD 4.0 release sets installed, and libkver.
	This makes a NetBSD 4.0 release environment (I don't use x* sets,
	but pkgsrc modular xorg, but that is irrelevant here).  In fact,
	with the possible exception of "4.0 release" all of this is irrelevant.

	In that environment I see ...

===> Building for p5-Sys-Utmp-1.6
cp lib/Sys/Utmp/Utent.pm blib/lib/Sys/Utmp/Utent.pm
cp lib/Sys/Utmp.pm blib/lib/Sys/Utmp.pm
/usr/pkg/bin/perl /usr/pkg/lib/perl5/5.10.0/ExtUtils/xsubpp  -typemap /usr/pkg/lib/perl5/5.10.0/ExtUtils/typemap  Utmp.xs > Utmp.xsc && mv Utmp.xsc Utmp.c
cc -c    -fno-strict-aliasing -pipe -O2  -I/usr/include     -I/usr/include    -DVERSION=\"1.6\"  -DXS_VERSION=\"1.6\" -DPIC -fPIC "-I/usr/pkg/lib/perl5/5.10.0/i386-netbsd-thread-multi/CORE"  -DNOUTFUNCS Utmp.c
Utmp.xs:60: error: conflicting types for 'utmpname'
/usr/include/utmp.h:64: error: previous declaration of 'utmpname' was here
*** Error code 1

Stop.
make: stopped in /pkg_comp/obj/pkgsrc/sysutils/p5-Sys-Utmp/4x/Sys-Utmp-1.6
*** Error code 1

Stop.
make: stopped in /usr/pkgsrc/sysutils/p5-Sys-Utmp
*** Error code 1

	Line 64 of (the NetBSD 4.0) /usr/include/utmp.h is

int utmpname(const char *);

	The error occurs with ...

static char _ut_name[] = _PATH_UTMP;

void utmpname(char *filename)
{
   strcpy(_ut_name, filename);
}

>Fix:
	Why does this not use utmpname() from libwhatever ???

>Release-Note:

>Audit-Trail:

Responsible-Changed-From-To: pkg-manager->sno
Responsible-Changed-By: obache@NetBSD.org
Responsible-Changed-When: Fri, 18 Sep 2009 11:23:11 +0000
Responsible-Changed-Why:
Over to importer.


From: Jens Rehsack <rehsack@googlemail.com>
To: gnats-bugs@NetBSD.org
Cc: pkg-manager@netbsd.org, pkgsrc-bugs@netbsd.org, 
 gnats-admin@netbsd.org, obache@NetBSD.org, kre@munnari.OZ.AU
Subject: Re: pkg/42082 (sysutils/p5-Sys-Utmp compilation error (NetBSD 4.0
 / i386))
Date: Sat, 19 Sep 2009 14:19:52 +0000

 obache@NetBSD.org wrote:
 > Synopsis: sysutils/p5-Sys-Utmp compilation error (NetBSD 4.0 / i386)
 > 
 > Responsible-Changed-From-To: pkg-manager->sno
 > Responsible-Changed-By: obache@NetBSD.org
 > Responsible-Changed-When: Fri, 18 Sep 2009 11:23:11 +0000
 > Responsible-Changed-Why:
 > Over to importer.

 I opened a ticket for the perl module
 (https://rt.cpan.org/Ticket/Display.html?id=49837) - if I find the time I'll
 create a patch and apply it.

 Jens

State-Changed-From-To: open->feedback
State-Changed-By: sno@NetBSD.org
State-Changed-When: Mon, 19 Jul 2010 12:36:46 +0000
State-Changed-Why:
I applied some patches and could compile it on NetBSD.
Please approve if this fixes it on NetBSD 4.0, too.

A test if it still works on Linux or AIX would be great, too.


From: Jens Rehsack <sno@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/42082 CVS commit: pkgsrc/sysutils/p5-Sys-Utmp
Date: Mon, 19 Jul 2010 12:32:24 +0000

 Module Name:	pkgsrc
 Committed By:	sno
 Date:		Mon Jul 19 12:32:24 UTC 2010

 Modified Files:
 	pkgsrc/sysutils/p5-Sys-Utmp: Makefile distinfo
 	pkgsrc/sysutils/p5-Sys-Utmp/patches: patch-aa
 Added Files:
 	pkgsrc/sysutils/p5-Sys-Utmp/patches: patch-ab

 Log Message:
 Updating sysutils/p5-Sys-Utmp from 1.6 to 1.6nb1 to remark some fixes:

 - Fix Utmp.xs to compile on NetBSD (fixes PR pkg/42082)
 - Apply patch from RT#52369 (FreeBSD 7.2: compilation error and host support)
   see https://rt.cpan.org/Ticket/Display.html?id=52369


 To generate a diff of this commit:
 cvs rdiff -u -r1.1.1.1 -r1.2 pkgsrc/sysutils/p5-Sys-Utmp/Makefile \
     pkgsrc/sysutils/p5-Sys-Utmp/distinfo
 cvs rdiff -u -r1.1.1.1 -r1.2 pkgsrc/sysutils/p5-Sys-Utmp/patches/patch-aa
 cvs rdiff -u -r0 -r1.1 pkgsrc/sysutils/p5-Sys-Utmp/patches/patch-ab

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

From: Robert Elz <kre@munnari.OZ.AU>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/42082 (sysutils/p5-Sys-Utmp compilation error (NetBSD 4.0 / i386))
Date: Tue, 20 Jul 2010 16:04:40 +0700

     Date:        Mon, 19 Jul 2010 12:36:47 +0000 (UTC)
     From:        sno@NetBSD.org
     Message-ID:  <20100719123647.5FA3C63BAE5@www.NetBSD.org>

   | I applied some patches and could compile it on NetBSD.
   | Please approve if this fixes it on NetBSD 4.0, too.

 Well, yes, and no - that is, when I first tried ...

 ===> Patching for p5-Sys-Utmp-1.6nb1
 => Applying pkgsrc patches for p5-Sys-Utmp-1.6nb1
 **************************************
 Ignoring patch file /usr/pkgsrc/sysutils/p5-Sys-Utmp/patches/patch-aa: invalid checksum
 **************************************
 ERROR: Patching failed due to modified or broken patch file(s):
 ERROR: 	/usr/pkgsrc/sysutils/p5-Sys-Utmp/patches/patch-aa
 *** Error code 1

 Stop.

 After fixing the broken checksum ("make distinfo"), it all worked fine however,
 so just update the distinfo file (my guess is that it fails with the modified
 rcsid after the modified patch-aa was chacked in) and all looks OK.

 Sorry, I can't test on Linux of AIX.

 kre

From: Jens Rehsack <rehsack@googlemail.com>
To: gnats-bugs@NetBSD.org
Cc: Robert Elz <kre@munnari.OZ.AU>, gnats-admin@netbsd.org, 
 pkgsrc-bugs@netbsd.org
Subject: Re: pkg/42082 (sysutils/p5-Sys-Utmp compilation error (NetBSD 4.0
 / i386))
Date: Wed, 21 Jul 2010 09:13:18 +0000

 On 07/20/10 09:10, Robert Elz wrote:
 > The following reply was made to PR pkg/42082; it has been noted by GNATS.
 >
 > From: Robert Elz<kre@munnari.OZ.AU>
 > To: gnats-bugs@NetBSD.org
 > Cc:
 > Subject: Re: pkg/42082 (sysutils/p5-Sys-Utmp compilation error (NetBSD 4.0 / i386))
 > Date: Tue, 20 Jul 2010 16:04:40 +0700
 >
 >       Date:        Mon, 19 Jul 2010 12:36:47 +0000 (UTC)
 >       From:        sno@NetBSD.org
 >       Message-ID:<20100719123647.5FA3C63BAE5@www.NetBSD.org>
 >
 >     | I applied some patches and could compile it on NetBSD.
 >     | Please approve if this fixes it on NetBSD 4.0, too.
 >
 >   Well, yes, and no - that is, when I first tried ...
 >
 >   ===>  Patching for p5-Sys-Utmp-1.6nb1
 >   =>  Applying pkgsrc patches for p5-Sys-Utmp-1.6nb1
 >   **************************************
 >   Ignoring patch file /usr/pkgsrc/sysutils/p5-Sys-Utmp/patches/patch-aa: invalid checksum
 >   **************************************
 >   ERROR: Patching failed due to modified or broken patch file(s):
 >   ERROR: 	/usr/pkgsrc/sysutils/p5-Sys-Utmp/patches/patch-aa
 >   *** Error code 1
 >
 >   Stop.
 >
 >   After fixing the broken checksum ("make distinfo"), it all worked fine however,
 >   so just update the distinfo file (my guess is that it fails with the modified
 >   rcsid after the modified patch-aa was chacked in) and all looks OK.

 Thanks for the response. Fixed and committed. Can you please verify?

 >   Sorry, I can't test on Linux of AIX.

 Jens

From: Robert Elz <kre@munnari.OZ.AU>
To: Jens Rehsack <rehsack@googlemail.com>
Cc: gnats-bugs@NetBSD.org
Subject: Re: pkg/42082 (sysutils/p5-Sys-Utmp compilation error (NetBSD 4.0 / i386))
Date: Wed, 21 Jul 2010 17:23:08 +0700

     Date:        Wed, 21 Jul 2010 09:13:18 +0000
     From:        Jens Rehsack <rehsack@googlemail.com>
     Message-ID:  <4C46BA2E.8000207@netbsd.org>

   | Thanks for the response. Fixed and committed. Can you please verify?

 Yes, that's fine - ignore my earlier (private) message - you must have done
 the checkin a while ago, as it had arrived on my system already.

 kre

State-Changed-From-To: feedback->closed
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Fri, 30 Jul 2010 07:15:59 +0000
State-Changed-Why:
confirmed fixed, thanks


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.