summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHelge Deller <deller@gmx.de>2018-01-17 16:43:22 +0100
committerHelge Deller <deller@gmx.de>2018-01-17 16:43:22 +0100
commit72be87cda667f8711fc2e17227930746b1f09852 (patch)
tree778f322ed953006eda0270b047a10856d4f05986
parenta211b16003f14bbc4b19341e4f96361ea7563f62 (diff)
downloadpalo-72be87cda667f8711fc2e17227930746b1f09852.tar.gz
Wire up help2man to create better man page
Suggested-by: Andreas Henriksson <andreas@fatal.se> Signed-off-by: Helge Deller <deller@gmx.de>
-rw-r--r--Makefile7
-rw-r--r--debian/changelog2
-rw-r--r--debian/control2
-rw-r--r--palo.8129
-rw-r--r--palo/palo.c8
-rw-r--r--palo/usage.txt9
6 files changed, 125 insertions, 32 deletions
diff --git a/Makefile b/Makefile
index 3cc1a13..8c76693 100644
--- a/Makefile
+++ b/Makefile
@@ -63,6 +63,8 @@ endif
CMDLINE = 0/vmlinux HOME=/ TERM=linux $(ROOT) $(EISAIRQ) $(CONSOLE)
+HELP2MAN := $(shell command -v help2man 2> /dev/null)
+
all: makepalo README palo.conf
README: README.html
@@ -104,7 +106,10 @@ distclean:
cd ipl && $(MAKE) distclean
cd palo && $(MAKE) distclean
-palo.8.gz: palo.8
+palo.8.gz: palo/palo palo/usage.txt
+ifdef HELP2MAN
+ help2man ./palo/palo > palo.8
+endif
gzip -9 < palo.8 > palo.8.gz
changelog.gz: debian/changelog
diff --git a/debian/changelog b/debian/changelog
index 9aeea8f..702652d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -3,6 +3,8 @@ palo (2.01) UNRELEASED; urgency=medium
[ Helge Deller ]
* Recommend instead of suggest e2fsprogs in debian control file.
(Closes: #887258)
+ * Wire up help2man to create better man page (suggested by
+ Andreas Henriksson <andreas@fatal.se>)
-- Helge Deller <deller@gmx.de> Wed, 17 Jan 2018 15:15:40 +0100
diff --git a/debian/control b/debian/control
index dc4f91e..4d8c08a 100644
--- a/debian/control
+++ b/debian/control
@@ -3,7 +3,7 @@ Section: admin
Priority: optional
Maintainer: Helge Deller <deller@gmx.de>
Uploaders:
-Build-Depends: debhelper (>= 9), lynx, gcc-hppa-linux-gnu [!hppa], libc6-dev-hppa-cross [!hppa]
+Build-Depends: debhelper (>= 9), lynx, gcc-hppa-linux-gnu [!hppa], libc6-dev-hppa-cross [!hppa], help2man
Standards-Version: 3.9.5
Homepage: http://git.kernel.org/cgit/linux/kernel/git/deller/palo.git
Vcs-Browser: http://git.kernel.org/cgit/linux/kernel/git/deller/palo.git
diff --git a/palo.8 b/palo.8
index 8391aab..7362621 100644
--- a/palo.8
+++ b/palo.8
@@ -1,25 +1,108 @@
-.\" Hey, EMACS: -*- nroff -*-
-.\" First parameter, NAME, should be all caps
-.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
-.\" other parameters are allowed: see man(7), man(1)
-.TH PALO 8 "January 18, 2001"
-.\" Please adjust this date whenever revising the manpage.
-.\"
-.\" Some roff macros, for reference:
-.\" .nh disable hyphenation
-.\" .hy enable hyphenation
-.\" .ad l left justify
-.\" .ad b justify to both left and right margins
-.\" .nf disable filling
-.\" .fi enable filling
-.\" .br insert line break
-.\" .sp <n> insert n+1 empty lines
-.\" for manpage-specific macros, see man(7)
+.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.47.5.
+.TH PALO "1" "January 2018" "palo version 2.00" "User Commands"
.SH NAME
-palo \- hppa/palinux Linux boot media management (think lilo)
+palo \- manual page for palo version 2.00
.SH SYNOPSIS
-.B palo --help
-.P
-See /usr/share/doc/palo for further documentation
-.SH FILES
-/etc/palo.conf
+.B palo
+[\fI\,options\/\fR]
+.SH DESCRIPTION
+palo version 2.00
+.TP
+\-?, \fB\-\-help\fR
+Print this information
+.HP
+\fB\-c\fR, \fB\-\-commandline\fR=\fI\,default\/\fR kernel command line
+.IP
+Maximum 1023 characters.
+.HP
+\fB\-k\fR, \fB\-\-recoverykernel\fR=\fI\,path\/\fR to recovery kernel (perhaps \fI\,/boot/vmlinux\/\fP)
+.HP
+\fB\-b\fR, \fB\-\-bootloader\fR=\fI\,path\/\fR to boot loader (usually \fI\,/usr/share/palo/iplboot\/\fP)
+.HP
+\fB\-r\fR, \fB\-\-ramdisk\fR=\fI\,path\/\fR to initial ramdisk image
+.HP
+\fB\-I\fR, \fB\-\-init\-partitioned\fR=\fI\,partitioned\/\fR device or file
+.IP
+Initialize a pre\-partitioned device, usually a hard disk.
+The partition table is not modified. Requires only \fB\-c\fR and \fB\-b\fR
+though \fB\-k\fR is customary and prudent.
+.HP
+\fB\-U\fR, \fB\-\-update\-partitioned\fR=\fI\,partitioned\/\fR device or file
+.IP
+Update a pre\-partitioned device, usually a hard disk.
+The partition table is not modified. Usually used to
+modify the default kernel command line (\fB\-c\fR).
+.HP
+\fB\-s\fR, \fB\-\-init\-tape\fR=\fI\,file\/\fR
+.IP
+Initialize an unpartitioned file which can be copied to
+tape, disk, or used as a bootp image. Requires \fB\-c\fR, \fB\-b\fR, \fB\-k\fR.
+.HP
+\fB\-C\fR, \fB\-\-init\-cdrom\fR=\fI\,iso\-image\-file\/\fR
+.IP
+Convert an ISO image already containing a kernel, boot loader,
+and optionally a ramdisk, into a PA\-RISC bootable image.
+Requires \fB\-c\fR, \fB\-b\fR, \fB\-k\fR, and optionally \fB\-r\fR. The files named on
+the palo command line must have EXACTLY the same contents as
+those already in the ISO image.
+.HP
+\fB\-f\fR, \fB\-\-configfile\fR=\fI\,path\/\fR to config file
+.IP
+Each line in the named configuration file is added
+as a separate argument to the beginning of the palo
+command line arguments (thus command\-line options
+override config file options).
+.IP
+Short or long options can be used with long options
+peferred for readability in the configuration file.
+WARNING: No quotations or other shell syntax is understood,
+so use
+.IP
+\fB\-\-commandline\fR=\fI\,a\/\fR b c
+.TP
+not
+\fB\-\-commandline=\fR'a b c'.
+.TP
+The short\-option config file form of the above is:
+\fB\-c\fR
+a b c
+.IP
+Blank lines and lines beginning with # are ignored.
+Whitespace at the beginning and ends of lines is discarded.
+.TP
+When \fB\-f\fR is not specified, palo tries \fI\,/etc/palo.conf\/\fP.
+Use
+.IP
+\fB\-\-configfile=\fR/dev/null to avoid configuration files or
+warnings when \fI\,/etc/palo.conf\/\fP is missing.
+.HP
+\fB\-v\fR, \fB\-\-verbose\fR
+.IP
+Provide more verbose information when running palo
+.HP
+\fB\-e\fR, \fB\-\-format\-as\fR=\fI\,type\/\fR
+.IP
+This is only for partitioned media. Format the palo
+partition as an ext2 (type == 2) or ext3 (type == 3)
+partition. With this option, you cannot specify any
+parameters, kernels or ramdisks to be loaded into
+the palo partition
+.PP
+\&'palo' with no arguments whatsoever is equivalent to 'palo \fB\-f\fR \fI\,/etc/palo\/\fP.conf'.
+.PP
+When more than one of \fB\-I\fR, \fB\-U\fR, \fB\-s\fR and \fB\-C\fR are used, only the
+last one is effective.
+.PP
+http://www.parisc\-linux.org \- Wed, 17 Jan 2018 15:15:40 +0100
+.SH "SEE ALSO"
+The full documentation for
+.B palo
+is maintained as a Texinfo manual. If the
+.B info
+and
+.B palo
+programs are properly installed at your site, the command
+.IP
+.B info palo
+.PP
+should give you access to the complete manual.
diff --git a/palo/palo.c b/palo/palo.c
index 8de20c6..68b85cf 100644
--- a/palo/palo.c
+++ b/palo/palo.c
@@ -687,6 +687,7 @@ static struct option Longopts[] =
{"init-cdrom", 1, 0, 'C'},
{"verbose", 0, 0, 'v'},
{"help", 0, 0, '?'},
+ {"version", 0, 0, 'V'},
{0, 0, 0, 0}
};
# define GETOPT(argc, argv, optstring) \
@@ -728,8 +729,7 @@ main(int argc, char *argv[])
assert((unsigned long)&f.ipl_addr - (unsigned long)&f == 0xf0);
}
- fputs("palo version " PALOVERSION " ", stdout);
- puts(bld_info);
+ fputs("palo version " PALOVERSION "\n", stdout);
/* do we have a -f? */
while ((c = GETOPT(argc, argv, gargs)) != EOF)
@@ -741,6 +741,10 @@ main(int argc, char *argv[])
break;
case '?':
error(0, argv[0]);
+ break;
+ case 'V':
+ puts(bld_info);
+ return 0;
}
}
diff --git a/palo/usage.txt b/palo/usage.txt
index a0f9dee..893316a 100644
--- a/palo/usage.txt
+++ b/palo/usage.txt
@@ -1,5 +1,4 @@
Usage: palo [options]
- (if an option is repeated, the last instance of it takes precedence)
-?, --help Print this information
-c, --commandline=default kernel command line
Maximum 1023 characters.
@@ -49,12 +48,12 @@ Usage: palo [options]
-v, --verbose
Provide more verbose information when running palo
-e, --format-as=type
- This is only for partitioned media: Format the palo
+ This is only for partitioned media. Format the palo
partition as an ext2 (type == 2) or ext3 (type == 3)
- partition. With this option, you cannot specify
- any parameters, kernels or ramdisks to be loaded into
+ partition. With this option, you cannot specify any
+ parameters, kernels or ramdisks to be loaded into
the palo partition
-
+
'palo' with no arguments whatsoever is equivalent to 'palo -f /etc/palo.conf'.