Subject: misc/7180: PR + FIX for snap_kern target in etc/Makefile
To: None <gnats-bugs@gnats.netbsd.org>
From: David Forbes <david@flossy.u-net.com>
List: netbsd-bugs
Date: 03/17/1999 19:57:09
>Number: 7180
>Category: misc
>Synopsis: PR + FIX for snap_kern target in etc/Makefile
>Confidential: no
>Severity: serious
>Priority: low
>Responsible: misc-bug-people (Misc Bug People)
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Mar 17 12:05:01 1999
>Last-Modified:
>Originator: David Forbes
>Organization:
>Release: 13th March 1999
>Environment:
System: NetBSD crowley.our-flat.net 1.3K NetBSD 1.3K (CROWLEY) #2: Tue Mar 16 10:25:59 GMT 1999 david@crowley.our-flat.net:/usr/home/david/netbsd-current/src/sys/arch/arm32/compile/CROWLEY arm32
>Description:
make snap_kern (as called by make snapshot) in src/etc will fail if the
kernel produced is not called "netbsd", then the gzip stage in the Makefile
will fail. Or if more than one kernel is produced, then only the one called
"netbsd" will be picked up.
Currently, this affects four config files distributed in -current (three
pmax and one arm32).
Whilst this isn't a big problem and doesn't affect most people it makes
sense to fix it, since we have the capability to output several kernels from
one configuration. (It is trivial to fix, too.)
>How-To-Repeat:
Do a "make snap_kern" in src/etc, with EXTRA_KERNELS=SHARK on arm32.
(I discovered it making an arm32 snapshot.)
>Fix:
Apply the following patch to src/etc/Makefile:
*** - Wed Mar 17 19:44:50 1999
--- src/etc/Makefile Wed Mar 17 19:08:51 1999
***************
*** 267,284 ****
.endif
cd ${KERNOBJDIR}/GENERIC && \
${MAKE} depend && ${MAKE} ${_J} && \
! tar cf - netbsd |\
gzip -c -9 > ${RELEASEDIR}/binary/sets/kern.tgz
.for kernel in ${EXTRA_KERNELS}
cd ${KERNCONFDIR} && config \
-b ${KERNOBJDIR}/${kernel} -s ${KERNSRCDIR} ${kernel}
.ifndef UPDATE
cd ${KERNOBJDIR}/${kernel} && ${MAKE} clean
.endif
cd ${KERNOBJDIR}/${kernel} && \
${MAKE} depend && ${MAKE} ${_J} && \
! gzip -c -9 < netbsd > \
! ${RELEASEDIR}/binary/kernel/netbsd.${kernel}.gz
.endfor # EXTRA_KERNELS
.endif # RELEASEDIR check
--- 267,292 ----
.endif
cd ${KERNOBJDIR}/GENERIC && \
${MAKE} depend && ${MAKE} ${_J} && \
! tar cf - `awk '$$1=="config" {print $$2}' \
! ${KERNCONFDIR}/GENERIC` |\
gzip -c -9 > ${RELEASEDIR}/binary/sets/kern.tgz
.for kernel in ${EXTRA_KERNELS}
cd ${KERNCONFDIR} && config \
-b ${KERNOBJDIR}/${kernel} -s ${KERNSRCDIR} ${kernel}
+
+
.ifndef UPDATE
cd ${KERNOBJDIR}/${kernel} && ${MAKE} clean
.endif
+
cd ${KERNOBJDIR}/${kernel} && \
${MAKE} depend && ${MAKE} ${_J} && \
! for kconf in `awk '$$1=="config" {print $$2}' \
! ${KERNCONFDIR}/${kernel}` ; { \
! gzip -c -9 < $${kconf} > \
! ${RELEASEDIR}/binary/kernel/$${kconf}.${kernel}.gz ; }
!
!
.endfor # EXTRA_KERNELS
.endif # RELEASEDIR check
>Audit-Trail:
>Unformatted: