From bkoenig@cs.tu-berlin.de  Tue Feb 21 16:41:29 2006
Return-Path: <bkoenig@cs.tu-berlin.de>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 4A5B816A420
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 21 Feb 2006 16:41:29 +0000 (GMT)
	(envelope-from bkoenig@cs.tu-berlin.de)
Received: from efacilitas.de (smtp.efacilitas.de [85.10.196.108])
	by mx1.FreeBSD.org (Postfix) with ESMTP id D34FD43D46
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 21 Feb 2006 16:41:28 +0000 (GMT)
	(envelope-from bkoenig@cs.tu-berlin.de)
Received: from eurystheus.local (port-212-202-169-72.dynamic.qsc.de [212.202.169.72])
	by efacilitas.de (Postfix) with ESMTP id 47C364C48A
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 21 Feb 2006 17:51:41 +0100 (CET)
Received: from hoppel.local (eurystheus.local [192.168.1.67])
	by eurystheus.local (Postfix) with SMTP id 2376C5285F
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 21 Feb 2006 16:45:51 +0100 (CET)
Received: by hoppel.local (sSMTP sendmail emulation); Tue, 21 Feb 2006 16:45:50 +0100
Message-Id: <20060221154551.2376C5285F@eurystheus.local>
Date: Tue, 21 Feb 2006 16:45:50 +0100
From: "Bjrn Knig" <bkoenig@cs.tu-berlin.de>
Reply-To: Bjrn Knig <bkoenig@cs.tu-berlin.de>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: loader(8): prevent *.4th files and friends from being installed if NO_FORTH is defined
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         93661
>Category:       misc
>Synopsis:       [patch] loader(8): prevent *.4th files and friends from being installed if NO_FORTH is defined
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Feb 21 16:50:03 GMT 2006
>Closed-Date:    
>Last-Modified:  Tue Feb 21 20:31:08 GMT 2006
>Originator:     Bjrn Knig
>Release:        
>Organization:
>Environment:
>Description:
	The loader makes use of NO_FORTH resp. BOOT_FORTH variables that
	are intended for building loader without Forth support. In this case 
	you don't need several files, e.g. /boot/*.4th, device.hints and
	other.

	The patch below let the loader Makefile and kern.post.mk take
	BOOT_FORTH into account. Note that it affects i386 only. The
	changes still need to be applied to other platforms.

>How-To-Repeat:
>Fix:

--- BOOT_FORTH-2006022101.diff begins here ---
--- src/sys.orig/boot/i386/loader/Makefile	Sun Oct 30 06:41:42 2005
+++ src/sys/boot/i386/loader/Makefile	Tue Feb 21 16:10:12 2006
@@ -71,15 +71,18 @@
 loader.help: help.common help.i386
 	cat ${.ALLSRC} | awk -f ${.CURDIR}/../../common/merge_help.awk > ${.TARGET}
 
-.PATH: ${.CURDIR}/../../forth 
-FILES=	loader loader.help loader.4th support.4th loader.conf
-FILES+= screen.4th frames.4th beastie.4th
+FILES=	loader loader.help
 # XXX INSTALLFLAGS_loader= -b
 FILESMODE_loader= ${BINMODE} -b
+.if defined(BOOT_FORTH)
+.PATH: ${.CURDIR}/../../forth 
+FILES+=	loader.4th support.4th loader.conf
+FILES+= screen.4th frames.4th beastie.4th
 FILESDIR_loader.conf=	/boot/defaults
 
 .if !exists(${DESTDIR}/boot/loader.rc)
 FILES+=	loader.rc
+.endif
 .endif
 
 # XXX crt0.o needs to be first for pxeboot(8) to work
--- src/sys.orig/conf/kern.post.mk	Tue Feb  7 14:37:26 2006
+++ src/sys/conf/kern.post.mk	Tue Feb 21 16:11:40 2006
@@ -192,6 +192,7 @@
 
 .if ${MACHINE_ARCH} != "ia64"
 .if exists(${DESTDIR}/boot)
+.if defined(BOOT_FORTH)
 kernel-install-check:
 	@if [ ! -f ${DESTDIR}/boot/device.hints ] ; then \
 		echo "You must set up a ${DESTDIR}/boot/device.hints file first." ; \
@@ -203,6 +204,7 @@
 	fi
 
 kernel-install: kernel-install-check
+.endif
 .endif
 .endif
 
--- BOOT_FORTH-2006022101.diff ends here ---


>Release-Note:
>Audit-Trail:
>Unformatted:
