From owner-freebsd-current Tue May 16 09:47:59 1995 Return-Path: current-owner Received: (from majordom@localhost) by freefall.cdrom.com (8.6.10/8.6.6) id JAA14184 for current-outgoing; Tue, 16 May 1995 09:47:59 -0700 Received: from halloran-eldar.lcs.mit.edu (halloran-eldar.lcs.mit.edu [18.26.0.159]) by freefall.cdrom.com (8.6.10/8.6.6) with SMTP id JAA14173 for ; Tue, 16 May 1995 09:47:47 -0700 Received: by halloran-eldar.lcs.mit.edu; (5.65/1.1.3.6) id AA20148; Tue, 16 May 1995 12:47:13 -0400 Date: Tue, 16 May 1995 12:47:13 -0400 From: Garrett Wollman Message-Id: <9505161647.AA20148@halloran-eldar.lcs.mit.edu> To: Michael Enkelis Cc: current@FreeBSD.org Subject: New "config" program In-Reply-To: References: Sender: current-owner@FreeBSD.org Precedence: bulk < said: > A side note. What about a automatic make "depend" like SUN does? > you could have a -n switch to disable this feature. It would be far less obnoxious to have a shell script that handled all aspects of kernel generation. The only part of this that doesn't work is the automatic generation of a new kernel from GENERIC: #!/bin/sh doclean=true autoinstall=false kernelname='' for arg; do case $arg in -n*) doclean=false;; -i*) autoinstall=true;; -*) usage;; *) kernelname=$arg;; esac done if [ -z "$kernelname" ]; then kernelname=`hostname -s | tr a-z A-Z` fi cd /sys/`uname -m`/conf if [ ! -e $kernelname ]; then echo "$0: kernel configuration file $kernelname does not exist" echo -n 'Create one from GENERIC [n]?' if read ans && expr $ans : 'y*' >/dev/null; then sed '/^#SED0/,$d' < GENERIC > $kernelname lsdev -c >> $kernelname echo '#SED0' >> $kernelname sed '1,/^#SED0/d' < GENERIC >> $kernelname else exit 1 fi fi set -e config -n $kernelname cd /sys/compile/$kernelname if $doclean; then make clean fi make depend make all if $autoinstall; then make install fi exit 0