From: Joachim Wiedorn Date: Sat, 7 May 2011 12:34:03 +0000 (+0200) Subject: Imported Upstream version 23.2 X-Git-Tag: upstream/23.2^0 X-Git-Url: https://git.rrq.au/?a=commitdiff_plain;h=0a7ead9db7967764f0d93d30f9a83c94cb6fc358;p=rrq%2Fmaintain_lilo.git Imported Upstream version 23.2 --- diff --git a/CHANGELOG b/CHANGELOG index 8f780a5..287b813 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,35 @@ +Changes for version 23.2 (09-Apr-2011) - Joachim Wiedorn + + Documentations + -------------- + - Optimize documentation generation and information. + - Reformatting mkrescue.8 manpage. (thanks to Martin E. Schauer) + - Update of lilo.conf.5 manpage and remove of OS/2 information. + + Sources + ------- + - Remove obsolete BIOS workaround from 2002 (src/second.S) + - Add information about -H option. (src/lilo.c) + - Save errno for second command. (src/device.c) + - Fix missleading error message. (src/geometry.c) + - Remove obsolete OS/2 code. (src/boot.c, src/temp.c) + - Enlarge maximum number of sectors (MAX_SETUPSECS) for + kernel setup code to 63. (src/bootsect.S, src/lilo.h) + - Fix for many small flaws in source code. (Many thanks to + Solar Designer and Vasiliy Kulikov of the openwall project). + + General + ------- + - Remove obsolete OS/2 code. (make.vars, src/Makefile) + - Optimize Makefile and src/Makefile for use of $(MAKE). + - Use mktemp utility for floppy image generation in mkrescue. + (Many thanks to Solar Designer and Vasiliy Kulikov of the + openwall project). + - Add new scripts with Makefile (already used for Debian): + * liloconfig (for creating new lilo.conf) + * lilo-uuid-diskid (convert device names to UUID/DiskID) + + Changes for version 23.1 (04-Nov-2010) - Joachim Wiedorn Documentations diff --git a/COPYING b/COPYING index af53737..0586be0 100644 --- a/COPYING +++ b/COPYING @@ -2,7 +2,7 @@ LInux LOader (LILO) program code, documentation, and auxiliary programs: Copyright 1992-1998 Werner Almesberger Copyright 1999-2007 John Coffman -Copyright 2009-2010 Joachim Wiedorn +Copyright 2009-2011 Joachim Wiedorn All rights reserved. diff --git a/Makefile b/Makefile index 442e943..e16f6bb 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,11 @@ # -*- makefile -*- +# +# Copyright 2009-2011 Joachim Wiedorn +# All rights reserved. +# +# Licensed under the terms contained in the file 'COPYING' +# in the source directory. +# # # make help @@ -10,7 +17,7 @@ help: @echo " make dosexe # DOS lilo.com utility" @echo " make diagnostic # standalone diagnostics" @echo " make alles # all above + static binary" - @echo " make docs # doc/[user,tech].[ps,dvi] docs" + @echo " make docs # doc/[user,tech].[pdf,dvi] docs" @echo " make floppy # 2 standalone bootable diagnostic floppies" @echo "" @echo " make install # install binaries++ into root directory" @@ -30,21 +37,21 @@ help: # everything needed to run, just short of installation # all: test - make -C src all - make -C images all + $(MAKE) -C src all + $(MAKE) -C images all # # everything above plus the statically linked version # alles: test - make -C src alles - make -C images all + $(MAKE) -C src alles + $(MAKE) -C images all # # documentation files # docs: - make -C doc all + $(MAKE) -C doc all # # if you have the 'bcc' compiler, then you can make the diagnostics, too @@ -61,23 +68,23 @@ floppy: test @echo before you proceed from this point. @echo "Press to continue, <^C> to abort ..." @read - @make -C src floppy1 + @$(MAKE) -C src floppy1 @echo Done. @echo @echo Remove the floppy from the drive. Label it "\"1.6\"" @echo "Press to continue, <^C> to abort ..." @read - @make -C src floppy2 + @$(MAKE) -C src floppy2 @echo Done. @echo @echo Remove the floppy from the drive. Label it "\"2.4\"" @echo diagnostic: test - make -C src diagnostic + $(MAKE) -C src diagnostic dosexe: test - make -C dos lilo + $(MAKE) -C dos lilo # # test for compilers & utilities @@ -91,42 +98,44 @@ test.img: # shorthand install, if one knows that one has the 'bcc' compiler # ins: - make -C src ins + $(MAKE) -C src ins # # normal install, but doesn't make the diagnostic binaries # install: all - make -C src install - make -C images install - make -C hooks install - make -C sample install - make -C man install - make -C dos install + $(MAKE) -C src install + $(MAKE) -C images install + $(MAKE) -C hooks install + $(MAKE) -C sample install + $(MAKE) -C scripts install + $(MAKE) -C man install + $(MAKE) -C dos install tidy: - make -C src tidy - make -C diagnose tidy - make -C dos tidy - make -C doc tidy + $(MAKE) -C src tidy + $(MAKE) -C diagnose tidy + $(MAKE) -C dos tidy + $(MAKE) -C doc tidy clean: tidy rm -f test.img - make -C src clean - make -C images clean - make -C diagnose clean - make -C dos clean - make -C doc clean + $(MAKE) -C src clean + $(MAKE) -C images clean + $(MAKE) -C diagnose clean + $(MAKE) -C dos clean + $(MAKE) -C doc clean spotless: distclean distclean: clean - make -C src distclean - make -C diagnose distclean - make -C dos distclean + $(MAKE) -C src distclean + $(MAKE) -C diagnose distclean + $(MAKE) -C dos distclean uninstall: - make -C src uninstall - make -C images uninstall - make -C hooks uninstall - make -C sample uninstall - make -C man uninstall + $(MAKE) -C src uninstall + $(MAKE) -C images uninstall + $(MAKE) -C hooks uninstall + $(MAKE) -C sample uninstall + $(MAKE) -C scripts uninstall + $(MAKE) -C man uninstall diff --git a/NEWS b/NEWS index bb51f5e..0de9b0b 100644 --- a/NEWS +++ b/NEWS @@ -3,6 +3,16 @@ NEWS about project LILO (For details see file 'CHANGELOG' in the source directory) +Version 23.2 (major and bugfix update of 23.1) + + o Many fixes in source code and fixes for some error messages. + o Remove all obsolete OS/2 code and information. + o Fix for larger kernel setup code (needed for kernel >= 2.6.36) + o Update of script 'mkrescue'. + o Update of manpages (mkrescue.8, lilo.conf.5). + o Add new scripts 'liloconfig' and 'lilo-uuid-diskid'. + + Version 23.1 (major and bugfix update of 23.0) o Many fixes of typos in sources and documentation. diff --git a/TODO b/TODO index 97e0f03..1e7dbdf 100644 --- a/TODO +++ b/TODO @@ -5,9 +5,10 @@ TODO for project LILO behaviour of 'large-memory'. * patching sources because of some warnings while compiling - with gcc 4.3.x + with gcc 4.4.x * Upgrade of all manpages. * Upgrade of all documentations. +* code cleanup. diff --git a/TOOLS b/TOOLS index 391117a..764f36d 100644 --- a/TOOLS +++ b/TOOLS @@ -1,6 +1,9 @@ -The following is a list of external tools and programs that -are used within lilo makefiles and scripts. Along with the -RPMs or DEBs they can be found in: +Needed tools for LILO sources +============================= + +The following is a list of external tools and programs which +are used within lilo makefiles. Along with the RPMs or DEBs +they can be found in: at least tested programs package version until inside @@ -16,3 +19,21 @@ gcc 3.3.5 4.4.5 gcc sharutils 4.6.3 4.9 uuencode, uudecode texlive-latex-base 2007-01 2009-11 ifpdf.sty + + + +Needed tools for installed LILO +=============================== + +The following is a list of external tools and programs which +are used within lilo scripts. Along with the RPMs or DEBs +they can be found in: + + at least tested programs +package version until inside +----------------------------------------------------------------- +perl 5.8.8 5.10.1 (general) + +perl-modules 5.8.8 5.10.1 Getopt::Std, + Pod::Usage + File::Copy diff --git a/doc/Makefile b/doc/Makefile index 88690e3..fec66b4 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -36,9 +36,6 @@ tech.pdf: tech.dvi $(PDFLATEX) tech $(PDFLATEX) tech -../doc/README: user.tex - perl t2a.pl ../doc/README || { rm -f ../doc/README; exit 1; } - html: user.ps tech.ps latex2html -split 2 -link 2 -toc_depth 2 user latex2html -split 1 -link 1 -toc_depth 1 tech diff --git a/doc/README b/doc/README index 31b5ec7..e7c2cc8 100644 --- a/doc/README +++ b/doc/README @@ -1,16 +1,3 @@ -Generating the README -===================== - -In order to (re)generate the plain ASCII documentation that is found in -lilo/README, Perl 4 or 5 must be installed on your system. -Just type - -make ../README - -to perform the conversion. Note that fairly large amounts of virtual memory -(16 MB or more) are allocated during the process. - - Printing the documentation ========================== @@ -29,28 +16,34 @@ are only necessary when processing the technical overview document. To run LaTeX just type -make + make LaTeX issues many "Overfull \hbox" warnings. They can be safely ignored. LaTeX will be run repeatedly until it stops issuing the message -LaTeX Warning: Label(s) may have changed. Rerun to get cross-references right. +LaTeX Warning: Label(s) may have changed. Rerun to get cross-references +right. + +At the end you should get the very old documentation in user.pdf and +tech.pdf. + +Generating user.README +====================== + +Use the simple tool t2a.pl for converting to ASCII formatted (old) user +documentation: + + perl t2a.pl user.README -Finally, you have to convert the device-independent file doc.dvi to -something your printer understands. The actual command to perform this -depends on your local installation. Example: +Online documentation +==================== -dvips user | lpr +The (old) documentation can also be found in the web: -(Another way is to use GhostScript. To generate HP DeskJet output by -converting the DVI file to PostScript as an intermediate step, use this -command +http://lilo.alioth.debian.org/olddoc/html/user_21-5.html +http://lilo.alioth.debian.org/olddoc/pdf/user_21-5.pdf -dvips -r1 -f1 user | gs -q -sDEVICE=deskjet -sOutputFile=/dev/lp1 - +http://lilo.alioth.debian.org/olddoc/html/tech_21-5.html +http://lilo.alioth.debian.org/olddoc/pdf/tech_21-5.pdf -gs -h lists all configured drivers.) -If you don't have access to LaTeX but if you can print PostScript, you -should get the file(s) lilo...ps.gz from the same place -where you've obtained lilo..tar.gz That file contains the -document user.tex ( = u) or tech.tex ( = t) already translated -to PostScript. +-- Joachim Wiedorn (2011) diff --git a/make.vars b/make.vars index afa1656..c38e694 100644 --- a/make.vars +++ b/make.vars @@ -1,4 +1,11 @@ ### Configuration variables for makefiles ### +# +# Copyright 2009-2011 Joachim Wiedorn +# All rights reserved. +# +# Licensed under the terms contained in the file 'COPYING' +# in the source directory. +# # NOTE: These variables can also be stored in a file /etc/lilo.defines, e.g. # -DIGNORECASE -DONE_SHOT @@ -53,8 +60,7 @@ # * REISERFS Compile support for parts of LILO on ReiserFS. # Requires header files for kernel 2.4.0test8 or later. # * REWRITE_TABLE Enable rewriting the partition table at boot time. -# * SOLO_CHAIN Assemble all chain-loader functions into 'chain.b', -# eliminating the need for 'os2_d.b'. +# * SOLO_CHAIN Assemble all chain-loader functions into 'chain.b'. # SUSPEND= Modify 'vmdefault' action if this partition type on C: drive # is marked active; (Dell suspend partition is -DSUSPEND=0x84). # USE_TMPDIR Create temporary devices in $TMPDIR if set diff --git a/man/lilo.conf.5 b/man/lilo.conf.5 index a0f5da0..c769b4d 100644 --- a/man/lilo.conf.5 +++ b/man/lilo.conf.5 @@ -16,7 +16,7 @@ .\" this software without specific prior written permission. This work .\" is provided "as is" and without any express or implied warranties. .\" -.TH LILO.CONF 5 "July 2010" +.TH LILO.CONF 5 "April 2011" .SH NAME lilo.conf \- configuration file for lilo .SH DESCRIPTION @@ -28,7 +28,7 @@ is read by the boot loader installer 'lilo' (see lilo(8)). It might look as follows: .IP .nf -# lilo.conf +# /etc/lilo.conf # # global options: boot=/dev/hda @@ -41,28 +41,29 @@ root=/dev/hda1 read-only menu-title=" John's Computer " # -# bootable kernel images: -image=/boot/zImage-1.5.99 +### bootable kernel images ### +image=/boot/vmlinuz-2.6.29-1-i386 label=try -image=/boot/zImage-1.0.9 - label=1.0.9 + initrd=/boot/initrd.img-2.6.29-1-i386 +image=/boot/vmlinuz-2.4.33-1-i386 + label=2.4.33 image=/tamu/vmlinuz label=tamu - initrd=initramdisk.img + initrd=/tamu/initrd.img root=/dev/hdb2 vga=ask # -# other operating systems: +### other operating systems ### other=/dev/hda3 - label=dos + label=PCDOS boot-as=0x80 # must be C: other=/dev/hdb1 - label=Win98 + label=WinXP boot-as=0x80 # must be C: other=/dev/hdb5 - label=os2 - loader=os2_d - table=E: # os2 sees as E: + label=oldDOS + loader=chain + table=/dev/hdb5 .fi .LP This configuration file specifies that lilo uses the Master @@ -130,17 +131,19 @@ loader, unless overridden with "install=" (see below). .sp When a bitmap file is specified as a background screen during the boot process, the color selection and layout of the text which overlays the -graphic image must be specified in one of two ways. One way, is to use -a bitmap image (*.bmp) file which has had a header written by the +graphic image must be specified in one of two ways. +.sp +One way is the use of header information in the bitmap image (*.bmp) file: +From a text file with all the information about 'bmp-colors', 'bmp-table' +and 'bmp-timer' options together with the 'bitmap' option are stored in +the special LILO header of the bitmap image file by the .BI "lilo -E" -command. If this command is used, then all of the -information specified by the 'bmp-colors', 'bmp-table', and 'bmp-timer' -options is stored in a special LILO header within the bitmap file. -Without this header, the 'bmp-' option values should be -specified in the configuration file; if not, default values are used. -Any use of the 'bmp-' options -within the configuration file overrides the values stored in the -bitmap file header. ++command. Another way works without these special header information: All ++the information about 'bmp-colors', 'bmp-table' and 'bmp-timer' options ++together with the 'bitmap' option are stored in the configuration file. ++Any use of the 'bmp-' options within the configuration file overrides ++the options stored in the bitmap file header. If lilo cannot find any of ++the 'bmp-' options, then default values are used. .TP .BI "bmp-colors=" ,,,,, Specifies the decimal values of the colors to be used for the menu display @@ -292,17 +295,17 @@ Other options include the specification of disk geometry; e.g., .fi .sp probably only useful for floppy disks and loopback devices, -since for hard disks the +because for hard disks the .BI lba32 -disk addressing option (LILO 21.2) ignores disk geometry. +disk addressing option ignores disk geometry. .sp -(22.5.8) Developers who have implemented a disk driver for a new block storage +Developers who have implemented a disk driver for a new block storage device will have to indicate to LILO the maximum number of partitions on the device. This is in addition to making all of the necessary entries for the device in the "/dev" directory (with 'mknod'). The -maximum number of partitions must be one of 63 (like an IDE disk), 31 (uncommon), 15 -(like SCSI disks -- most common value), or 7 (like one array controller). -An example specification would be: +maximum number of partitions must be one of 63 (like an IDE disk), +31 (uncommon), 15 (like SCSI disks -- most common value), or 7 +(like one array controller). An example specification would be: .sp .nf disk=/dev/userd0 @@ -341,7 +344,7 @@ This allows lilo to adjust 3D addresses in partition tables. Each partition entry contains a 3D (cylinder/head/sector) and a linear address of the first and the last sector of the partition. If a partition is not track-aligned and if certain other operating systems -(e.g. PC/MS-DOS or OS/2) are using the same disk, they may change the +(e.g. PC/MS-DOS) are using the same disk, they may change the 3D address. lilo can store its boot sector only on partitions where both address types correspond. lilo re-adjusts incorrect 3D start addresses if `fix-table' is set. @@ -813,7 +816,8 @@ select 80x50 text mode. .BR ask : stop and ask for user input (at boot time). .sp -: use the corresponding text mode. A list of available modes +: use the corresponding text mode (can specify the number in decimal +or in hex with the usual '0x' convention). A list of available modes can be obtained by booting with .I vga=ask and pressing [Enter]. @@ -837,11 +841,7 @@ By default .I chain is used. This chain loader passes partition and drive information in the boot sector it loads only to DOS on FAT12 or FAT16, Windows on FAT16 or -FAT32, or OS/2 on FAT16 or HPFS. -The alternate chain loader, -.I os2_d -passes partition and drive information unconditionally, and uses a format -suitable for OS/2 and DOS (see +FAT32. (see also .I table= below). .TP @@ -856,14 +856,9 @@ Note that /sbin/lilo must be re-run if a partition table mapped referenced with `table' is modified. .TP .BI "table=" -This is a special case for the +This option is obsolete. It were used in the special case with the obsolete .I os2_d -chain loader. It specifies the DOS drive letter for the partition -that will be booted. This is -.I mandatory -when booting OS/2 installed on -an extended partition. The drive letter may be specified with or without a -trailing colon. +chain loader. .TP .BI "change" This keyword starts a section which describes how primary partition IDs are @@ -871,7 +866,7 @@ changed, and how primary partitions are activated and deactivated. If .B change is omitted, change rules are generated as though the .I "automatic" -keyword were specified. The keyword +keyword were specified. The keyword .B change alone, without any rules following, will suppress automatic change-rules. For example, @@ -922,7 +917,7 @@ interfere with floppy disk BIOS device codes; "boot-as=" is then used as a local option to override "master-boot" as necessary. .TP .BI "master-boot" -This flag (LILO version 22.5) indicates a DOS/Windows/OS2 or other +This flag (LILO version 22.5) indicates a DOS/Windows or other system which will only boot from BIOS device 0x80, the "C:" drive, or BIOS device 0, the A: drive. When this flag is specified, if this drive is not assigned device code 0x80 or 0 by the diff --git a/man/mkrescue.8 b/man/mkrescue.8 index 8e36327..3d1776d 100644 --- a/man/mkrescue.8 +++ b/man/mkrescue.8 @@ -1,131 +1,156 @@ '\" t -.\" @(#)mkrescue.8 1.0 20011031 jrc +.\" @(#)mkrescue.8 .\" This page is part of the LILO package, which is released by .\" the author(s) under a BSD license. See the file COPYING -.\" in the LILO source directory for the License and Disclaimer. +.\" in the LILO source directory for the license and disclaimer. .\" -.\" Original version, John Coffman 2001-10-31 -.\" Updated to version 2.0 & lilo 22.5.4, John Coffman 2003-05-24 -.\" -.\" Updated to version 3.0 & lilo 22.6.1, John Coffman 2004-11-16 -.\" -.TH MKRESCUE 8 "16 Nov 2004" +.\" Original for lilo 22.1, John Coffman 2001-10-31 +.\" Updated for lilo 22.5.4, John Coffman 2003-05-24 +.\" Updated for lilo 22.6.1, John Coffman 2004-11-16 +.\" Updated for lilo 23.1, Martin Eberhard Schauer 2011-03-06 +.\" (Reformatted to better match Linux man-pages conventions) + +.TH MKRESCUE 8 "6 Mar 2011" + .SH NAME -mkrescue \- make rescue floppy +mkrescue \- make rescue floppy or CD + .SH SYNOPSIS -.LP -.B "/usr/sbin/mkrescue" -\- make a bootable rescue floppy or CD using the default kernel specified -in \fIlilo.conf\fP. +.B /sbin/mkrescue +makes a bootable rescue floppy or CD using the default kernel specified in +.IR lilo.conf . + .SH DESCRIPTION -.LP -.B mkrescue -takes its specification for the kernel from the default image specified in -\fB/etc/lilo.conf\fP. If the actual default is an \fIother=\fP specification, -then use the first \fIimage=\fP specification. -Any associated initial ramdisk (initrd=), and \fIappend=\fP -options will also be used. The root directory will be taken to be the -\fIcurrent\fP root. A bootable floppy or CD-image will be created using LILO version +\fBmkrescue\fP takes its specifation for the kernel from the default image +specified in \fI/etc/lilo.conf\fP. +If the actual default is an \fIother=\fP specification, then use the first +\fIimage=\fP specification. +Any associated initial ramdisk (\fIinitrd=\fP), and \fIappend=\fP options +will also be used. +The root directory will be taken to be the \fIcurrent\fP root. +A bootable floppy or CD-image will be created using LILO version 22.5.5 or later. -.B mkrescue -normally requires no options, unless a CD-image is desired (\fI--iso\fP). +\fBmkrescue\fP normally requires no options, unless a CD-image is desired +(\fB--iso\fP). + .SH OPTIONS -.LP + .TP -.BI "--append " -Override any \fIappend=\fP options taken from the default image. If there is -any doubt about whether the \fIlilo.conf\fP options are correct, then specify -no kernel parameters with: \fB--append ""\fP, the null string. +\fB--append\fP +Override any \fIappend=\fP options taken from the default image. +If there is any doubt about whether the \fIlilo.conf\fP +options are correct, then specify no kernel parameters by providing the +null string (\fB--append ""\fP). + .TP -.BI "--debug" -Provide verbose output of the operation of "mkrescue", pausing to allow -the setting of internal operating parameters to be viewed. "" must -be hit to proceed from these pauses. +.B --debug +Provide verbose output of the operation of +.BR mkrescue , +pausing to allow the setting of internal operating parameters to be viewed. + must be hit to proceed from these pauses. + .TP -.BI "--device " -Make the floppy on a device other than /dev/fd0. The floppy disk will -always be made to boot on BIOS device code 0x00 (A: drive), without -regard to the drive on which it is created. +\fB--device\fP +Make the floppy on a device other than \fI/dev/fd0\fP. +The floppy disk will always be made to boot on BIOS device code 0x00 (A: +drive), without regard to the drive on which it is created. + .TP -.BI "--fast" -Use a faster method of creating the boot floppy. This involves first -creating a file of "\-\-size" 1k blocks (default is 1440) -mounted using a loopback device, creating the bootable floppy, +.B --fast +Use a faster method of creating the boot floppy. +This involves first creating a file of \fB--size\fP 1k blocks (default +is 1440) mounted using a loopback device, creating the bootable floppy, then copying the entire file to the disk. + .TP -.BI "--fs [ ext2 | msdos | minix ]" +\fB--fs\fP [ \fIext2\fP | \fImsdos\fP | \fIminix\fP ] Specify the type of filesystem to create on the drive. -.B ext2 -is the default, but "msdos" and "minix" allow slightly more disk sectors -for really big kernels. +\fIext2\fP is the default, but \fImsdos\fP and \fIminix\fP allow +slightly more disk sectors for really big kernels. + .TP -.BI "--help" +.B --help Print a short usage synopsis, including a list of command options. + .TP -.BI "--image