Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 15 Nov 2001 16:57:45 -0800 (PST)
From:      "Aaron D. Gifford" <agifford@infowest.com>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   kern/32021: SHOWSTOPPING FAILURE OF "make buildkernel" IN -STABLE when "MODULES_WITH_WORLD=true" in /etc/make.conf
Message-ID:  <200111160057.fAG0vjB01745@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         32021
>Category:       kern
>Synopsis:       SHOWSTOPPING FAILURE OF "make buildkernel" IN -STABLE when "MODULES_WITH_WORLD=true" in /etc/make.conf
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Nov 15 17:00:00 PST 2001
>Closed-Date:
>Last-Modified:
>Originator:     Aaron D. Gifford
>Release:        FreeBSD 4.4-STABLE
>Organization:
N/A
>Environment:
FreeBSD 4.4-STABLE #5: Wed Nov 14 17:11:37 MST 2001     root@my.host:/usr/obj/usr/src/sys/GENERIC
>Description:
Any attempt to build recent -STABLE kernels failes as follows:

--------------------------------------------------------------
>How-To-Repeat:
Try to build a -STABLE kernel on a recent -STABLE system with "MODULES_WITH_WORLD=true" in your /etc/make.conf file and you WILL encounter this problem.
>Fix:
The temporary work-around is to edit /usr/src/conf/Makefile.i386 and add the following two lines IMMEDIATELY BEFORE the ".endif" line in the ".if !defined(MODULES_WITH_WORLD) && !defined(NO_MODULES) && exists($S/modules)" section of the Makefile:

.else
cleandir:

That fixes things temporarily, but isn't a real fix, because I don't know exactly why things broke sometime in the last 2-3 weeks in the first place.
>Release-Note:
>Audit-Trail:
>Unformatted:
 >>> Kernel build for GENERIC started on Thu Nov 15 16:56:43 MST 2001
 --------------------------------------------------------------
 ===> GENERIC
 mkdir -p /usr/obj/usr/src/sys
 cd /usr/src/sys/i386/conf;  PATH=/usr/obj/usr/src/i386/usr/sbin:/usr/obj/usr/src/i386/usr/bin:/usr/obj/usr/src/i386/usr/games:/sbin:/bin:/usr/sbin:/usr/bin  config  -d /usr/obj/usr/src/sys/GENERIC GENERIC
 Don't forget to do a ``make depend''
 Kernel build directory is /usr/obj/usr/src/sys/GENERIC
 cd /usr/obj/usr/src/sys/GENERIC;  MAKEOBJDIRPREFIX=/usr/obj  COMPILER_PATH=/usr/obj/usr/src/i386/usr/libexec:/usr/obj/usr/src/i386/usr/bin  LIBRARY_PATH=/usr/obj/usr/src/i386/usr/lib:/usr/obj/usr/src/i386/usr/lib  OBJFORMAT_PATH=/usr/obj/usr/src/i386/usr /libexec  CFLAGS="-nostdinc -O -pipe -march=pentiumpro"  PERL5LIB=/usr/obj/usr/src/i386/usr/libdata/perl/5.00503  GROFF_BIN_PATH=/usr/obj/usr/src/i386/usr/bin  GROFF_FONT_PATH=/usr/obj/usr/src/i386/usr/share/groff_font  GROFF_TMAC_PATH=/usr/obj/usr/src/i 386/usr/share/tmac  DESTDIR=/usr/obj/usr/src/i386  INSTALL="sh /usr/src/tools/install.sh"  PATH=/usr/obj/usr/src/i386/usr/sbin:/usr/obj/usr/src/i386/usr/bin:/usr/obj/usr/src/i386/usr/games:/sbin:/bin:/usr/sbin:/usr/bin  OBJFORMAT_PATH=/usr/obj/usr/src/i3 86/usr/libexec:/usr/libexec MACHINE=i386 make KERNEL=kernel clean cleandir
 rm -f *.o *.so *.So *.ko *.s eddep errs  kernel kernel linterrs makelinks  setdef[01].c setdefs.h tags  vers.c
 vnode_if.c vnode_if.h aicasm aicasm_gram.c aicasm_scan.c y.tab.h  aic7xxx_seq.h aic7xxx_reg.h device_if.c device_if.h bus_if.c  bus_if.h miibus_if.c miibus_if.h power_if.c power_if.h card_if.c  card_if.h ppbus_if.c ppbus_if.h pci_if.c pci_if.h usb_if.c   usb_if.h isa_if.c isa_if.h
 make: don't know how to make cleandir. Stop
 *** Error code 2
  
 Stop in /usr/src.
 *** Error code 1
  
 Stop in /usr/src.
 
 
 
 A little digging shows that in /usr/obj/usr/src/sys/GENERIC/Makefile there is the following section:
 
 .if !defined(MODULES_WITH_WORLD) && !defined(NO_MODULES) && exists($S/modules)
 all:    modules
 depend: modules-depend
 clean:  modules-clean
 cleandepend:  modules-cleandepend
 cleandir:  modules-cleandir
 tags:  modules-tags
 install install.debug: modules-install
 reinstall reinstall.debug: modules-reinstall
 .endif
 
 That's the ONLY plase "cleandir" exists.  The problem is, the IF condition will NOT evaluate to TRUE if "MODULES_WITH_WORLD=true" in /etc/make.conf (which I always set, since I like to build my modules just once and then build a whole bunch of custom ker nels).  Thus, on my system or on any system where the .if expression isn't true in the Makefile AND the "make buildkernel" does a "make cleandir" it will FAIL with the same error as above.
 

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200111160057.fAG0vjB01745>