pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc Update adjustkernel to 1.7. Changes:



details:   https://anonhg.NetBSD.org/pkgsrc/rev/37679d7e1826
branches:  trunk
changeset: 489895:37679d7e1826
user:      hubertf <hubertf%pkgsrc.org@localhost>
date:      Mon Feb 28 00:48:52 2005 +0000

description:
Update adjustkernel to 1.7. Changes:

 * Update copyright year
 * Change syntax to not require mandatory options (think about the word!)
 * Document short options
 * Mention /var/run/dmesg.boot
 * Expand examples section a bit
 * Xref dmesg(8)
 * Document a known bug

OK'd by mjl@

diffstat:

 doc/CHANGES                                |   3 +-
 sysutils/adjustkernel/Makefile             |   4 +-
 sysutils/adjustkernel/files/adjustkernel   |  21 +++------
 sysutils/adjustkernel/files/adjustkernel.1 |  64 ++++++++++++++++++++---------
 4 files changed, 56 insertions(+), 36 deletions(-)

diffs (183 lines):

diff -r 0ee7b229b23f -r 37679d7e1826 doc/CHANGES
--- a/doc/CHANGES       Mon Feb 28 00:44:39 2005 +0000
+++ b/doc/CHANGES       Mon Feb 28 00:48:52 2005 +0000
@@ -1,4 +1,4 @@
-$NetBSD: CHANGES,v 1.9347 2005/02/28 00:44:12 wiz Exp $
+$NetBSD: CHANGES,v 1.9348 2005/02/28 00:49:41 hubertf Exp $
 
 Changes to the packages collection and infrastructure in 2005:
 
@@ -1189,3 +1189,4 @@
        Updated bash to 3.0pl16 [wiz 2005-02-27]
        Updated p5-MailTools to 1.66 [adrianp 2005-02-27]
        Updated pkg_chk to 1.56 [wiz 2005-02-28]
+       Updated adjustkernel to 1.7 [hubertf 2005-02-28]
diff -r 0ee7b229b23f -r 37679d7e1826 sysutils/adjustkernel/Makefile
--- a/sysutils/adjustkernel/Makefile    Mon Feb 28 00:44:39 2005 +0000
+++ b/sysutils/adjustkernel/Makefile    Mon Feb 28 00:48:52 2005 +0000
@@ -1,6 +1,6 @@
-# $NetBSD: Makefile,v 1.8 2004/11/03 10:49:58 hubertf Exp $
+# $NetBSD: Makefile,v 1.9 2005/02/28 00:48:52 hubertf Exp $
 
-DISTNAME=      adjustkernel-1.6
+DISTNAME=      adjustkernel-1.7
 CATEGORIES=    sysutils
 MASTER_SITES=  # empty
 DISTFILES=     # empty
diff -r 0ee7b229b23f -r 37679d7e1826 sysutils/adjustkernel/files/adjustkernel
--- a/sysutils/adjustkernel/files/adjustkernel  Mon Feb 28 00:44:39 2005 +0000
+++ b/sysutils/adjustkernel/files/adjustkernel  Mon Feb 28 00:48:52 2005 +0000
@@ -1,7 +1,8 @@
 #!/usr/pkg/bin/perl
+# $Id: adjustkernel,v 1.4 2005/02/28 00:48:52 hubertf Exp $
 #
-# Copyright (c) 2004 Hubert Feyrer <hubertf%NetBSD.org@localhost>,
-#                   Martin Laubach <mjl%NetBSD.org@localhost>
+# Copyright (c) 2004,2005 Hubert Feyrer <hubertf%NetBSD.org@localhost>,
+#                        Martin Laubach <mjl%NetBSD.org@localhost>
 # All rights reserved.
 #
 # Redistribution and use in source and binary forms, with or without
@@ -35,16 +36,6 @@
 #
 
 
-#--------------------------------------------------------------------------
-# %Id: adjustkernel,v 1.1 1999/10/15 01:21:30 feyrer Exp feyrer %
-# $Emsi: adjustkernel,v 1.4 2001/10/04 22:26:26 mjl Exp $
-#
-# Usage: adjustkernel -f GENERIC [-o outfile] [-d]
-#
-# commends out any lines that aren't found in the current kernel (dmesg)
-#
-#--------------------------------------------------------------------------
-
 use strict;
 use Getopt::Long;
 
@@ -66,9 +57,13 @@
        'mesg=s'                => \$mesg
        );
 
+$kernel = shift(@ARGV)
+    unless $kernel;
+
 ###########################################################################
 
-die "Usage: $0 [-debug] [-mesg dmesg-file] [-outfile new-config]\n\t\t[-remove] -file kernel-config\n" unless $kernel;
+die "Usage: $0 [-dmor] [--debug] [--mesg dmesg-file]\n".
+    "\t\t [--outfile new-config][--remove] kernel-config\n" unless $kernel;
 
 $| = 1 if $debug;
 
diff -r 0ee7b229b23f -r 37679d7e1826 sysutils/adjustkernel/files/adjustkernel.1
--- a/sysutils/adjustkernel/files/adjustkernel.1        Mon Feb 28 00:44:39 2005 +0000
+++ b/sysutils/adjustkernel/files/adjustkernel.1        Mon Feb 28 00:48:52 2005 +0000
@@ -1,5 +1,5 @@
 .\"     $Emsi: adjustkernel.1,v 1.1 2002/03/01 01:25:37 mjl Exp $
-.\"    $NetBSD: adjustkernel.1,v 1.4 2004/11/03 10:49:58 hubertf Exp $
+.\"    $NetBSD: adjustkernel.1,v 1.5 2005/02/28 00:48:52 hubertf Exp $
 .\"
 .\" Copyright (c) 2004 Hubert Feyrer <hubertf%NetBSD.org@localhost>,
 .\"                 Martin Laubach <mjl%NetBSD.org@localhost>
@@ -34,41 +34,45 @@
 .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 .\" POSSIBILITY OF SUCH DAMAGE.
 .\"
-.Dd November 3, 2004
+.Dd February 27, 2005
 .Dt ADJUSTKERNEL 1
 .Sh NAME
 .Nm adjustkernel
 .Nd generate kernel config from dmesg
 .Sh SYNOPSIS
 .Nm adjustkernel
-.Op Fl debug
-.Op Fl mesg Ar dmesg-file
-.Op Fl outfile Ar new-config
-.Op Fl remove
-.Fl file Ar source-config
+.Op Fl dmor
+.Op Fl -debug
+.Op Fl -mesg Ar dmesg-file
+.Op Fl -outfile Ar new-config
+.Op Fl -remove
+.Ar kernel-config
 .Sh DESCRIPTION
 .Nm
 generates a new kernel configuration file from the
-current dmesg output and the current kernel config file.
+current dmesg output and the current kernel config file,
+.Ar kernel-config .
 .Pp
 The generation can be customized by using the following options:
 .Bl -tag -width 22n -compact
-.It Fl debug
+.It Fl d , Fl -debug
 be verbose and generate noise (mainly useful for debugging).
-.It Fl file Ar source-config
-read the currently booted kernel from source-config.
-This option is mandatory.
-.It Fl outfile Ar new-config
+.It Fl o Ar new-config , Fl -outfile Ar new-config
 saves the newly generated config file to
 .Ar new-config ;
 otherwise the new config will be written to stdout.
-.It Fl mesg Ar dmesg-file
+.It Fl m Ar dmesg-file , Fl -mesg Ar dmesg-file
 read the dmesg data from
 .Ar dmesg-file ,
 defaults to calling
 .Pa /sbin/dmesg
 and using its output.
-.It Fl remove
+See
+.Pa /var/run/dmesg.boot
+for an alternative snapshot from
+right after the system booted, but which may not include
+any removable components added later.
+.It Fl r , Fl -remove
 causes the tool to remove entries in the config file instead
 of commenting them out.
 .El
@@ -76,15 +80,35 @@
 Note that options can be shortened, as long as they can be
 unambigously distinguished.
 .Sh EXAMPLES
-To generate a new kernel config after having booted a
-GENERIC kernel,
+To generate a new kernel config
+.Pa MYCONFIG
+after having booted a
+GENERIC kernel, run:
 .Bd -literal
-adjustkernel -f GENERIC -o MYKERNEL
+$ cd /usr/src/sys/arch/`uname -m`/conf
+$ adjustkernel GENERIC >MYCONFIG
+.Ed
+.Pp
+To see what could be stripped off the currently-running kernel,
+assuming it was built with the
+.Dq INCLUDE_CONFIG_FILE
+option, use something like:
+.Bd -literal
+$ config -x >MYKERNEL
+$ adjustkernel -r MYKERNEL | diff -u MYKERNEL - | more
 .Ed
 .Sh SEE ALSO
-.Xr options 4
+.Xr options 4 ,
+.Xr dmesg 8
 .Sh AUTHORS
 Originally created by Hubert Feyrer <hubert%feyrer.de@localhost>,
 later hacked in shape and packetized by Martin J. Laubach <mjl%netbsd.org@localhost>.
 .Sh BUGS
-On thursdays.
+Essential lines
+.Dq atabus* at ata? ,
+.Dq atabus* at atapi?
+and
+.Dq scsibus* at scsi?
+are removed as they aren't listed in
+.Xr dmesg 8
+output.



Home | Main Index | Thread Index | Old Index