NetBSD Problem Report #42274
From sdrake@xnet.co.nz Fri Nov 6 03:00:20 2009
Return-Path: <sdrake@xnet.co.nz>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
by www.NetBSD.org (Postfix) with ESMTP id 4DD9D63B844
for <gnats-bugs@gnats.netbsd.org>; Fri, 6 Nov 2009 03:00:20 +0000 (UTC)
Message-Id: <alpine.LNX.2.00.0911061553150.23438@vqena.qenxr.bet.am>
Date: Fri, 6 Nov 2009 15:54:44 +1300 (NZDT)
From: Steven Drake <sdrake@xnet.co.nz>
To: gnats-bugs@gnats.netbsd.org
Subject: xorg-cf-files and gmake
>Number: 42274
>Category: pkg
>Synopsis: xorg-cf-files and gmake
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: pkg-manager
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Fri Nov 06 03:05:00 +0000 2009
>Closed-Date: Wed Mar 17 10:09:10 +0000 2010
>Last-Modified: Thu Mar 18 22:50:02 +0000 2010
>Originator: Steven Drake
>Release: pkgsrc-2009Q3
>Organization:
>Environment:
System: Linux idran 2.6.30 #2 PREEMPT Sun Aug 9 18:32:44 NZST 2009 i686 pentium4 i386 GNU/Linux
Architecture: pentium4
Machine: i686
C library: GNU C Library stable release version 2.10.1, by Roland McGrath et al.
>Description:
This bug does not affect xorg-cf-files, but will affect some packages that
have USE_IMAKE=yes set and on platforms with IMAKE_MAKE?=${GMAKE}.
Eg:
make[1]: Entering directory `/tmp/obj_pkgsrc/net/tightvnc/work/vnc_unixsrc'
making Makefiles in libvncauth...
mv -f Makefile Makefile.bak
usage: bmake [-BeikNnqrstWX] [-D variable] [-d flags] [-f makefile]
[-I directory] [-J private] [-j max_jobs] [-m directory] [-T file]
[-V variable] [variable=value] [target ...]
make[1]: [Makefiles] Error 2 (ignored)
make[1]: Leaving directory `/tmp/obj_pkgsrc/net/tightvnc/work/vnc_unixsrc'
make depend
make[1]: Entering directory `/tmp/obj_pkgsrc/net/tightvnc/work/vnc_unixsrc'
depending in ./libvncauth...
>How-To-Repeat:
The following makefile should show the problem, change the MAKE variable to
the correct path for bmake and run "gmake"!
--- Cut here --
MAKE=/usr/pkg/bin/bmake
.PHONY: World Makefiles
World:
gmake Makefiles
Makefiles:
for i in . ;\
do \
echo "making Makefiles in $$i" ;\
${MAKE} ${MFLAGS} ONESUBDIR=$$i $$i/makefile ;\
done
$(ONESUBDIR)/makefile:
@echo "Yippy it worked!"
--- End here --
The problem is the first gmake sets MAKELEVEL, the second gmake (World target)
sees this and acts as if it had been given the '-w', printing the line
"gmake[1]: Entering directory [...]", but it also adds '-w' to MFLAGS.
>Fix:
The following patch fixes the problem.
Index: pkgsrc/x11/xorg-cf-files/Makefile
===================================================================
--- pkgsrc.orig/x11/xorg-cf-files/Makefile
+++ pkgsrc/x11/xorg-cf-files/Makefile
@@ -16,6 +16,12 @@ PKG_DESTDIR_SUPPORT= user-destdir
GNU_CONFIGURE= yes
USE_TOOLS+= pkg-config
+.include "../../mk/bsd.prefs.mk"
+
+.if defined(IMAKE_TOOLS) && !empty(IMAKE_TOOLS:Mgmake)
+USE_TOOLS+= gmake
+.endif
+
post-extract:
${CP} ${FILESDIR}/host.def ${WRKSRC}
${CP} ${FILESDIR}/xorgsite.def ${WRKSRC}
--
Steven
1: Linux - will work for fish.
2: The Linux penguin - looks stuffed to the brim with herring.
( make your own conclusions )
>Release-Note:
>Audit-Trail:
From: Steven Drake <sbd@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/42274 CVS commit: pkgsrc/x11/xorg-cf-files
Date: Wed, 17 Mar 2010 09:53:08 +0000
Module Name: pkgsrc
Committed By: sbd
Date: Wed Mar 17 09:53:08 UTC 2010
Modified Files:
pkgsrc/x11/xorg-cf-files: Makefile
Log Message:
With platforms that set IMAKE_MAKE?=${GMAKE} x11/xorg-cf-files needs to be
built with gmake. From PR pkg/42274
Bump PKGREVISION.
To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 pkgsrc/x11/xorg-cf-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->closed
State-Changed-By: sbd@NetBSD.org
State-Changed-When: Wed, 17 Mar 2010 10:09:10 +0000
State-Changed-Why:
Commited patch.
From: Joerg Sonnenberger <joerg@britannica.bec.de>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: PR/42274 CVS commit: pkgsrc/x11/xorg-cf-files
Date: Wed, 17 Mar 2010 15:07:03 +0100
On Wed, Mar 17, 2010 at 09:55:02AM +0000, Steven Drake wrote:
> Modified Files:
> pkgsrc/x11/xorg-cf-files: Makefile
>
> Log Message:
> With platforms that set IMAKE_MAKE?=${GMAKE} x11/xorg-cf-files needs to be
> built with gmake. From PR pkg/42274
>
> Bump PKGREVISION.
Should have objected earlier, but the files are setup for dealing with
normal make, not with gmake. As such I disagree with this change.
The IMAKE_MAKE default should be restricted to X11_TYPE=native.
Joerg
From: Thomas Klausner <wiz@NetBSD.org>
To: Joerg Sonnenberger <joerg@britannica.bec.de>
Cc: NetBSD bugtracking <gnats-bugs@NetBSD.org>
Subject: Re: PR/42274 CVS commit: pkgsrc/x11/xorg-cf-files
Date: Wed, 17 Mar 2010 15:34:26 +0100
On Wed, Mar 17, 2010 at 02:10:07PM +0000, Joerg Sonnenberger wrote:
> Should have objected earlier, but the files are setup for dealing with
> normal make, not with gmake. As such I disagree with this change.
> The IMAKE_MAKE default should be restricted to X11_TYPE=native.
Do you have a diff? I don't understand your explanation well enough to
derive one...
Thomas
From: Joerg Sonnenberger <joerg@britannica.bec.de>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: PR/42274 CVS commit: pkgsrc/x11/xorg-cf-files
Date: Wed, 17 Mar 2010 16:16:24 +0100
--VbJkn9YxBvnuCH5J
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
On Wed, Mar 17, 2010 at 02:40:04PM +0000, Thomas Klausner wrote:
> The following reply was made to PR pkg/42274; it has been noted by GNATS.
>
> From: Thomas Klausner <wiz@NetBSD.org>
> To: Joerg Sonnenberger <joerg@britannica.bec.de>
> Cc: NetBSD bugtracking <gnats-bugs@NetBSD.org>
> Subject: Re: PR/42274 CVS commit: pkgsrc/x11/xorg-cf-files
> Date: Wed, 17 Mar 2010 15:34:26 +0100
>
> On Wed, Mar 17, 2010 at 02:10:07PM +0000, Joerg Sonnenberger wrote:
> > Should have objected earlier, but the files are setup for dealing with
> > normal make, not with gmake. As such I disagree with this change.
> > The IMAKE_MAKE default should be restricted to X11_TYPE=native.
>
> Do you have a diff? I don't understand your explanation well enough to
> derive one...
Attached.
Joerg
--VbJkn9YxBvnuCH5J
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="imake-make.diff"
Index: tools/make.mk
===================================================================
RCS file: /home/joerg/repo/netbsd/pkgsrc/mk/tools/make.mk,v
retrieving revision 1.13
diff -u -p -r1.13 make.mk
--- tools/make.mk 17 Jul 2005 21:36:24 -0000 1.13
+++ tools/make.mk 17 Mar 2010 15:15:49 -0000
@@ -49,7 +49,7 @@
# Define MAKE_PROGRAM to be the "make" used to build the package.
.if !empty(_USE_TOOLS:Mgmake)
MAKE_PROGRAM= ${GMAKE}
-.elif !empty(_USE_TOOLS:Mimake) && defined(IMAKE_MAKE)
+.elif !empty(_USE_TOOLS:Mimake) && defined(IMAKE_MAKE) && ${X11_TYPE} == "native"
MAKE_PROGRAM= ${IMAKE_MAKE}
.else
MAKE_PROGRAM= ${MAKE}
--VbJkn9YxBvnuCH5J--
From: Steven Drake <sbd@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/42274 CVS commit: pkgsrc/x11/xorg-cf-files
Date: Thu, 18 Mar 2010 22:42:23 +0000
Module Name: pkgsrc
Committed By: sbd
Date: Thu Mar 18 22:42:23 UTC 2010
Modified Files:
pkgsrc/x11/xorg-cf-files: Makefile
Log Message:
Revert last commit, will use a change to pkgsrc/mk/platform/Linux.mk to
fix PR 42274.
Bump PKGREVISION.
OK wiz@
To generate a diff of this commit:
cvs rdiff -u -r1.13 -r1.14 pkgsrc/x11/xorg-cf-files/Makefile
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
From: Steven Drake <sbd@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/42274 CVS commit: pkgsrc/mk/platform
Date: Thu, 18 Mar 2010 22:46:02 +0000
Module Name: pkgsrc
Committed By: sbd
Date: Thu Mar 18 22:46:01 UTC 2010
Modified Files:
pkgsrc/mk/platform: Linux.mk
Log Message:
imake should only ever use gmake if ${X11_TYPE}==native. Pointed out by joerg@
Fixes PR 42274
OK wiz@
To generate a diff of this commit:
cvs rdiff -u -r1.36 -r1.37 pkgsrc/mk/platform/Linux.mk
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
>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.