NetBSD Problem Report #44415
From hf@spg.tu-darmstadt.de Wed Jan 19 11:15:23 2011
Return-Path: <hf@spg.tu-darmstadt.de>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
by www.NetBSD.org (Postfix) with ESMTP id ACB7463B883
for <gnats-bugs@gnats.NetBSD.org>; Wed, 19 Jan 2011 11:15:23 +0000 (UTC)
Message-Id: <201101191115.p0JBFGRO008944@venediger.nt.e-technik.tu-darmstadt.de>
Date: Wed, 19 Jan 2011 12:15:16 +0100 (CET)
From: Hauke Fath <hf@spg.tu-darmstadt.de>
Reply-To: Hauke Fath <hf@spg.tu-darmstadt.de>
To: gnats-bugs@gnats.NetBSD.org
Cc: Hauke Fath <hf@spg.tu-darmstadt.de>
Subject: pkgtools/rpm2pkg install(8) problem
X-Send-Pr-Version: 3.95
>Number: 44415
>Category: pkg
>Synopsis: pkgtools/rpm2pkg install(8) problem
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: tron
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Jan 19 11:20:00 +0000 2011
>Closed-Date: Wed Jan 19 16:28:42 +0000 2011
>Last-Modified: Wed Jan 19 16:40:02 +0000 2011
>Originator: Hauke Fath
>Release: NetBSD 5.1_STABLE
>Organization:
--
/~\ The ASCII Ribbon Campaign Hauke Fath
\ / No HTML/RTF in email Institut für Nachrichtentechnik
X No Word docs in email TU Darmstadt
/ \ Respect for open standards Ruf +49-6151-16-3281
>Environment:
System: NetBSD venediger 5.1_STABLE NetBSD 5.1_STABLE (VENEDIGER) #0: Wed Dec 22 14:43:08 CET 2010 hf@Hochstuhl:/var/obj/netbsd-builds/5/i386/sys/arch/i386/compile/VENEDIGER i386
Architecture: i386
Machine: i386
>Description:
Attempting to install rpm2pkg fails when group information is
provided externally, e.g. from NIS:
[...]
# format work/rpm2pkg.cat8
nroff -mandoc /usr/src/pkgsrc/pkgtools/rpm2pkg/files/rpm2pkg.8 > rpm2pkg.cat8.tmp && mv rpm2pkg.cat8.tmp rpm2pkg.cat8
=> Unwrapping files-to-be-installed.
===> Installing for rpm2pkg-3.2.0
=> Generating pre-install file lists
=> Creating installation directories
# install /var/obj/pkgsrc/pkgtools/rpm2pkg/work/.destdir/usr/pkg/sbin/rpm2pkg
/usr/bin/install -N /usr/src/etc -c -r -o hf -g spgmit -m 755 -s rpm2pkg /var/obj/pkgsrc/pkgtools/rpm2pkg/work/.destdir/usr/pkg/sbin/rpm2pkg
install: unknown group spgmit
*** Error code 1
Stop.
make: stopped in /var/obj/pkgsrc/pkgtools/rpm2pkg/work
*** Error code 1
The tool's Makefile includes the system <bsd.prog.mk>, which
through <bsd.own.mk> sets up install(8) to use the netbsd
source distribution's group file ("-N /usr/src/etc" above)
instead of the system's group information.
>How-To-Repeat:
Build and install rpm2pkg from an unprivileged user account
whose credentials are provided by e.g. NIS.
>Fix:
Maybe set the <bsd.own.mk> NEED_OWN_INSTALL_TARGET variable
accordingly?
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: pkg-manager->tron
Responsible-Changed-By: hauke@NetBSD.org
Responsible-Changed-When: Wed, 19 Jan 2011 11:32:05 +0000
Responsible-Changed-Why:
Over to maintainer.
From: Joerg Sonnenberger <joerg@britannica.bec.de>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/44415: pkgtools/rpm2pkg install(8) problem
Date: Wed, 19 Jan 2011 12:38:43 +0100
> The tool's Makefile includes the system <bsd.prog.mk>, which
> through <bsd.own.mk> sets up install(8) to use the netbsd
> source distribution's group file ("-N /usr/src/etc" above)
> instead of the system's group information.
What's your mk.conf. This smells a lot like a problem with your
configuration and not so much like a problem with pkgsrc.
Joerg
From: "Matthias Scheler" <tron@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/44415 CVS commit: pkgsrc/pkgtools/rpm2pkg/files
Date: Wed, 19 Jan 2011 11:49:18 +0000
Module Name: pkgsrc
Committed By: tron
Date: Wed Jan 19 11:49:18 UTC 2011
Modified Files:
pkgsrc/pkgtools/rpm2pkg/files: Makefile
Log Message:
Set "NEED_OWN_INSTALL_TARGET" to get unpriviliged installation under
NetBSD to work. This should fix PR pkg/44415 by Hauke Fath.
To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 pkgsrc/pkgtools/rpm2pkg/files/Makefile
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
State-Changed-From-To: open->feedback
State-Changed-By: tron@NetBSD.org
State-Changed-When: Wed, 19 Jan 2011 11:57:01 +0000
State-Changed-Why:
The build should work now. Can you please try again?
From: Hauke Fath <hf@spg.tu-darmstadt.de>
To: gnats-bugs@NetBSD.org
Cc: tron@NetBSD.org
Subject: Re: pkg/44415 (pkgtools/rpm2pkg install(8) problem)
Date: Wed, 19 Jan 2011 13:38:52 +0100
At 11:57 Uhr +0000 19.01.2011, tron@NetBSD.org wrote:
>State-Changed-Why:
>The build should work now. Can you please try again?
No change, unfortunately:
[hf@bounce] /<3>pkgtools/rpm2pkg > env MAKECONV=/dev/null make install
===> Installing for rpm2pkg-3.2.0
=> Generating pre-install file lists
=> Creating installation directories
# install
/var/obj/pkgsrc/pkgtools/rpm2pkg/work/.destdir/usr/pkg/sbin/rpm2pkg
/usr/bin/install -N /usr/src/etc -c -r -o hf -g spgmit -m 755 -s rpm2pkg
/var/obj/pkgsrc/pkgtools/rpm2pkg/work/.destdir/usr/pkg/sbin/rpm2pkg
install: unknown group spgmit
*** Error code 1
Stop.
make: stopped in /var/obj/pkgsrc/pkgtools/rpm2pkg/work
*** Error code 1
--
The ASCII Ribbon Campaign Hauke Fath
() No HTML/RTF in email Institut für Nachrichtentechnik
/\ No Word docs in email TU Darmstadt
Respect for open standards Ruf +49-6151-16-3281
From: Hauke Fath <hf@spg.tu-darmstadt.de>
To: gnats-bugs@NetBSD.org
Cc: tron@NetBSD.org
Subject: Re: pkg/44415 (pkgtools/rpm2pkg install(8) problem)
Date: Wed, 19 Jan 2011 13:53:46 +0100
At 11:57 Uhr +0000 19.01.2011, tron@NetBSD.org wrote:
>State-Changed-Why:
>The build should work now. Can you please try again?
Interesting enough, the problem only shows up when NetBSD src is present.
When I only nfs mount pkgsrc, 'make install' uses the system auth database,
as intended.
Now which incantation of 'make -d' will show me where it decides to go for
the NetBSD src/etc/{passwd,group}?
hauke
--
The ASCII Ribbon Campaign Hauke Fath
() No HTML/RTF in email Institut für Nachrichtentechnik
/\ No Word docs in email TU Darmstadt
Respect for open standards Ruf +49-6151-16-3281
From: Matthias Scheler <tron@NetBSD.org>
To: Hauke Fath <hf@spg.tu-darmstadt.de>
Cc: NetBSD GNATS <gnats-bugs@NetBSD.org>
Subject: Re: pkg/44415 (pkgtools/rpm2pkg install(8) problem)
Date: Wed, 19 Jan 2011 13:11:26 +0000
On Wed, Jan 19, 2011 at 01:38:52PM +0100, Hauke Fath wrote:
> At 11:57 Uhr +0000 19.01.2011, tron@NetBSD.org wrote:
> >State-Changed-Why:
> >The build should work now. Can you please try again?
>
> No change, unfortunately:
>
> [hf@bounce] /<3>pkgtools/rpm2pkg > env MAKECONV=/dev/null make install
> ===> Installing for rpm2pkg-3.2.0
> => Generating pre-install file lists
> => Creating installation directories
> # install
> /var/obj/pkgsrc/pkgtools/rpm2pkg/work/.destdir/usr/pkg/sbin/rpm2pkg
> /usr/bin/install -N /usr/src/etc -c -r -o hf -g spgmit -m 755 -s rpm2pkg
> /var/obj/pkgsrc/pkgtools/rpm2pkg/work/.destdir/usr/pkg/sbin/rpm2pkg
> install: unknown group spgmit
> *** Error code 1
>
> Stop.
> make: stopped in /var/obj/pkgsrc/pkgtools/rpm2pkg/work
> *** Error code 1
It does The Right Thing(TM) on my system:
===> Installing for rpm2pkg-3.2.0
=> Generating pre-install file lists
=> Creating installation directories
# install /src/NetBSD-current/pkgsrc/pkgtools/rpm2pkg/work.colwyn/.destdir/usr/pkg/sbin/rpm2pkg
/usr/bin/install -c -r -o tron -g shadows -m 755 -s rpm2pkg /src/NetBSD-current/pkgsrc/pkgtools/rpm2pkg/work.colwyn/.destdir/usr/pkg/sbin/rpm2pkg
# install /src/NetBSD-current/pkgsrc/pkgtools/rpm2pkg/work.colwyn/.destdir/usr/pkg/man/cat8/rpm2pkg.0
/usr/bin/install -c -r -o tron -g shadows -m 644 rpm2pkg.cat8 /src/NetBSD-current/pkgsrc/pkgtools/rpm2pkg/work.colwyn/.destdir/usr/pkg/man/cat8/rpm2pkg.0
# install /src/NetBSD-current/pkgsrc/pkgtools/rpm2pkg/work.colwyn/.destdir/usr/pkg/man/man8/rpm2pkg.8
/usr/bin/install -c -r -o tron -g shadows -m 644 /src/NetBSD-current/pkgsrc/pkgtools/rpm2pkg/files/rpm2pkg.8 /src/NetBSD-current/pkgsrc/pkgtools/rpm2pkg/work.colwyn/.destdir/usr/pkg/man/man8/rpm2pkg.8
And neither the user "tron" nor the group "shadows" come from "/usr/src/etc"
which exists on this machine.
Please provide you "/etc/mk.conf" as requested by Joerg Sonnenberger.
Kind regards
--
Matthias Scheler http://zhadum.org.uk/
From: Hauke Fath <hf@spg.tu-darmstadt.de>
To: gnats-bugs@NetBSD.org
Cc: tron@NetBSD.org
Subject: Re: pkg/44415 (pkgtools/rpm2pkg install(8) problem)
Date: Wed, 19 Jan 2011 15:22:19 +0100 (CET)
# $Id: mk.conf,v 1.16 2010/12/22 15:59:10 hf Exp hf $
#
# make(1) config file
# Packages
.ifdef BSD_PKG_MK
# Since unionfs behaves increasingly dodgy, use a read-only
# source tree, optionally mounted on /usr/src.
# Keep distfiles locally, though, to avoid writing to internal
# servers share.
LOCALBASE = /usr/pkg
PKGSRCDIR = /usr/src/pkgsrc
WRKOBJDIR = /var/obj/pkgsrc
DISTDIR = ${WRKOBJDIR}/pkg-distfiles
PACKAGES = ${WRKOBJDIR}/packages
PKG_SYSCONFBASE = /etc/pkg
#CLEANDEPENDS = yes
# For pkg_rolling-replace & friends
ALLOW_VULNERABLE_PACKAGES = yes
ACCEPTABLE_LICENSES= shareware no-commercial-use no-profit
ACCEPTABLE_LICENSES+= jdk-license
ACCEPTABLE_LICENSES+= sendmail-license
APACHE_USER = httpd
APACHE_GROUP = httpd
MYSQL_USER = mysql
MYSQL_GROUP = mysql
PGUSER = pgsql
PGGROUP = pgsql
PGHOME = /home/${PGUSER}
GNATS_USER = gnats
GNATS_GROUP = gnats
PKG_OPTIONS.maildrop = -authlib
# Do not pull in all of LaTeX just for docs!
PKG_OPTIONS.pari = -doc -gmp -x11
PKGVULNDIR = /var/db/pkg
# Be compatible to previous version and documentation
MAILMAN_CGIEXT = # empty
MAILMAN_CGIGROUP = ${APACHE_GROUP}
# daemon, changed from 31 = guest
MAILMAN_MAILGROUP = 1
# Enforce upgrade
PHP_VERSION_DEFAULT = 53
.if exists(${LOCALBASE}/bin/sudo)
SU_CMD= ${LOCALBASE}/bin/sudo /bin/sh -c
.endif
PKG_DEVELOPER = 1
.else
# pkgsrc namespace intrusion!
.endif
# devel/cpuflags
.sinclude "/usr/pkg/share/mk/cpuflags.mk"
From: Hauke Fath <hf@spg.tu-darmstadt.de>
To: Matthias Scheler <tron@NetBSD.org>
Cc: NetBSD GNATS <gnats-bugs@NetBSD.org>
Subject: Re: pkg/44415 (pkgtools/rpm2pkg install(8) problem)
Date: Wed, 19 Jan 2011 16:55:53 +0100
At 13:11 Uhr +0000 19.01.2011, Matthias Scheler wrote:
>Please provide you "/etc/mk.conf" as requested by Joerg Sonnenberger.
The following patch does the trick:
Index: Makefile
===================================================================
RCS file: /cvsroot/pkgsrc/pkgtools/rpm2pkg/files/Makefile,v
retrieving revision 1.2
diff -u -u -r1.2 Makefile
--- Makefile 19 Jan 2011 11:49:18 -0000 1.2
+++ Makefile 19 Jan 2011 15:51:59 -0000
@@ -9,6 +9,8 @@
LDADD= -lbz2 -llzma -lz
WARNS= 4
+# See <bsd.own.mk>
+INSTPRIV= # empty
NEED_OWN_INSTALL_TARGET= yes
#CFLAGS+= -g
-- the system <bsd.*.mk> framework needs to be told that it is not supposed
to use the NetBSD src tree even if it's there, which is... hard. It might
be easier to just use a plain Makefile without reference to the BSD make
framework.
hauke
--
The ASCII Ribbon Campaign Hauke Fath
() No HTML/RTF in email Institut für Nachrichtentechnik
/\ No Word docs in email TU Darmstadt
Respect for open standards Ruf +49-6151-16-3281
From: Joerg Sonnenberger <joerg@britannica.bec.de>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/44415 (pkgtools/rpm2pkg install(8) problem)
Date: Wed, 19 Jan 2011 17:17:54 +0100
On Wed, Jan 19, 2011 at 02:25:07PM +0000, Hauke Fath wrote:
> .else
>
> # pkgsrc namespace intrusion!
>
> .endif
Is this the actual content of mk.conf or not? Since Makefiles of
packages naturally don't get the BSD_PKG_MK...
Joerg
From: "Matthias Scheler" <tron@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/44415 CVS commit: pkgsrc/pkgtools/rpm2pkg
Date: Wed, 19 Jan 2011 16:23:02 +0000
Module Name: pkgsrc
Committed By: tron
Date: Wed Jan 19 16:23:02 UTC 2011
Modified Files:
pkgsrc/pkgtools/rpm2pkg: Makefile PLIST
pkgsrc/pkgtools/rpm2pkg/files: Makefile
Log Message:
Update "rpm2pkg" package to version 3.2.1:
- Go back to manual installation to avoid problems on unprivileged
NetBSD installation. This fixes PR pkg/44415 by Hauke Fath.
- Don't install "rpm2pkg.cat8" any more as it is not really useful.
To generate a diff of this commit:
cvs rdiff -u -r1.56 -r1.57 pkgsrc/pkgtools/rpm2pkg/Makefile
cvs rdiff -u -r1.2 -r1.3 pkgsrc/pkgtools/rpm2pkg/PLIST
cvs rdiff -u -r1.2 -r1.3 pkgsrc/pkgtools/rpm2pkg/files/Makefile
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
State-Changed-From-To: feedback->closed
State-Changed-By: tron@NetBSD.org
State-Changed-When: Wed, 19 Jan 2011 16:28:42 +0000
State-Changed-Why:
The problem is fixed in version 3.2.1 of the "rpm2pkg" package.
From: Hauke Fath <hf@spg.tu-darmstadt.de>
To: gnats-bugs@NetBSD.org
Cc: tron@NetBSD.org, Joerg Sonnenberger <joerg@britannica.bec.de>
Subject: Re: pkg/44415 (pkgtools/rpm2pkg install(8) problem)
Date: Wed, 19 Jan 2011 17:35:30 +0100
At 16:20 Uhr +0000 19.01.2011, Joerg Sonnenberger wrote:
>The following reply was made to PR pkg/44415; it has been noted by GNATS.
>
>From: Joerg Sonnenberger <joerg@britannica.bec.de>
>To: gnats-bugs@NetBSD.org
>Cc:
>Subject: Re: pkg/44415 (pkgtools/rpm2pkg install(8) problem)
>Date: Wed, 19 Jan 2011 17:17:54 +0100
>
> On Wed, Jan 19, 2011 at 02:25:07PM +0000, Hauke Fath wrote:
> > .else
> >
> > # pkgsrc namespace intrusion!
> >
> > .endif
>
> Is this the actual content of mk.conf or not?
...as produced by a 'cat /etc/mk.conf | mail -s ...', yes.
> Since Makefiles of packages naturally don't get the BSD_PKG_MK...
Well, they're not supposed to, are they? The pkgsrc Makefile sets any make
variables needed, and the package Makefile takes it from there. Of course,
when the latter imports a second framework behind the back of the former,
things start to get interesting...
hauke
--
The ASCII Ribbon Campaign Hauke Fath
() No HTML/RTF in email Institut für Nachrichtentechnik
/\ No Word docs in email TU Darmstadt
Respect for open standards Ruf +49-6151-16-3281
>Unformatted:
(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.