pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkg/42274: 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:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Nov 06 03:05:00 +0000 2009
>Originator:     Steven Drake
>Release:        pkgsrc-2009Q3
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.
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}.

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...

The following makefile should show the problem, change the MAKE variable to
the correct path for bmake and run "gmake"!

--- Cut here --

.PHONY: World Makefiles
        gmake Makefiles

        for i in . ;\
        do \
                echo "making Makefiles in $$i" ;\
                ${MAKE} ${MFLAGS} ONESUBDIR=$$i $$i/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.

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/"
+.if defined(IMAKE_TOOLS) && !empty(IMAKE_TOOLS:Mgmake)
+USE_TOOLS+=    gmake
        ${CP} ${FILESDIR}/host.def ${WRKSRC}
        ${CP} ${FILESDIR}/xorgsite.def ${WRKSRC}

  1: Linux - will work for fish.
  2: The Linux penguin - looks stuffed to the brim with herring.
  ( make your own conclusions )

Home | Main Index | Thread Index | Old Index