From c70626b1d2115ebb05a099b4ad5b7d00ac8dcff1 Mon Sep 17 00:00:00 2001 From: Kern Sibbald Date: Thu, 29 Sep 2005 08:54:20 +0000 Subject: [PATCH] Update --- rescue/autoconf/configure.in | 5 +++- rescue/configure | 9 +++++-- rescue/linux/cdrom/makebinaries | 44 +++++++++++++++++++++++++-------- rescue/linux/cdrom/makeinitrd | 2 +- rescue/linux/cdrom/makekernel | 3 ++- rescue/version.h | 6 ++--- 6 files changed, 51 insertions(+), 18 deletions(-) diff --git a/rescue/autoconf/configure.in b/rescue/autoconf/configure.in index 9099786..f0a3d0d 100644 --- a/rescue/autoconf/configure.in +++ b/rescue/autoconf/configure.in @@ -148,6 +148,10 @@ AC_ARG_WITH(bacula, ] ) +if test x${bacula} = x; then + AC_MSG_ERROR(Missing --with-bacula=PATH) +fi + AC_SUBST(bacula) @@ -254,7 +258,6 @@ AC_OUTPUT([ \ autoconf/Make.common \ Makefile \ linux/Makefile \ - linux/floppy/Makefile \ linux/cdrom/Makefile \ linux/cdrom/bacula/Makefile \ linux/cdrom/cdtree/boot/isolinux/boot.msg \ diff --git a/rescue/configure b/rescue/configure index 26ae9f9..d091256 100755 --- a/rescue/configure +++ b/rescue/configure @@ -2336,6 +2336,12 @@ if test "${with_bacula+set}" = set; then fi; +if test x${bacula} = x; then + { { echo "$as_me:$LINENO: error: Missing --with-bacula=PATH" >&5 +echo "$as_me: error: Missing --with-bacula=PATH" >&2;} + { (exit 1); exit 1; }; } +fi + @@ -2437,7 +2443,7 @@ MCOMMON=./autoconf/Make.common - ac_config_files="$ac_config_files autoconf/Make.common Makefile linux/Makefile linux/floppy/Makefile linux/cdrom/Makefile linux/cdrom/bacula/Makefile linux/cdrom/cdtree/boot/isolinux/boot.msg freebsd/Makefile solaris/Makefile $PFILES" + ac_config_files="$ac_config_files autoconf/Make.common Makefile linux/Makefile linux/cdrom/Makefile linux/cdrom/bacula/Makefile linux/cdrom/cdtree/boot/isolinux/boot.msg freebsd/Makefile solaris/Makefile $PFILES" ac_config_commands="$ac_config_commands default" cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure @@ -2996,7 +3002,6 @@ do "autoconf/Make.common" ) CONFIG_FILES="$CONFIG_FILES autoconf/Make.common" ;; "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;; "linux/Makefile" ) CONFIG_FILES="$CONFIG_FILES linux/Makefile" ;; - "linux/floppy/Makefile" ) CONFIG_FILES="$CONFIG_FILES linux/floppy/Makefile" ;; "linux/cdrom/Makefile" ) CONFIG_FILES="$CONFIG_FILES linux/cdrom/Makefile" ;; "linux/cdrom/bacula/Makefile" ) CONFIG_FILES="$CONFIG_FILES linux/cdrom/bacula/Makefile" ;; "linux/cdrom/cdtree/boot/isolinux/boot.msg" ) CONFIG_FILES="$CONFIG_FILES linux/cdrom/cdtree/boot/isolinux/boot.msg" ;; diff --git a/rescue/linux/cdrom/makebinaries b/rescue/linux/cdrom/makebinaries index f026ffb..dbaaf06 100755 --- a/rescue/linux/cdrom/makebinaries +++ b/rescue/linux/cdrom/makebinaries @@ -10,7 +10,7 @@ R=roottree PATH="/sbin:/bin:/usr/sbin:/usr/bin:$PATH" - +# Cleanup and make necessary directories rm -rf $R/sbin mkdir -p $R/etc $R/initrd $R/lib $R/mnt $R/mnt/cdrom mkdir -p $R/proc $R/root $R/sbin $R/tmp $R/var @@ -25,12 +25,30 @@ cd $R ln -sf sbin bin cd $TOPDIR +# +# Some users have a different shell for root, so be +# sure to add it to the rootsbin list. Note, the shell may +# be copied twice, but it is not worth the effort to run uniq +# here. +# +TMPFILE=`mktemp -t bin.XXXXXXXXXX` +if [ $? != 0 ]; then + echo "Could not make temp file" + exit 1 +fi +cat rootsbin.list >${TMPFILE} +command=`grep ^root: /etc/passwd | cut -d ':' -f 7` +command=`basename $command` +if [ x$command != "xbash" ] ; then + echo "roottree/sbin/$command" >>${TMPFILE} +fi + echo "Building root /sbin. Some Could not find messages are normal ..." -for file in `cat rootsbin.list` ; do +for file in `cat ${TMPFILE}` ; do command=`basename $file` fullfile=`which $command 2> /dev/null` if [ x$fullfile != x ] ; then -# echo "updating $command in roottree with $fullfile" + echo "updating $command in roottree with $fullfile" cp -fpd $fullfile $file if [ $? != 0 ] ; then echo "Update failed." @@ -42,6 +60,8 @@ for file in `cat rootsbin.list` ; do rm -f $file fi done +rm -f ${TMPFILE} + cd roottree/sbin ln -sf halt reboot cd $TOPDIR @@ -62,20 +82,24 @@ for lib in `find roottree/sbin/ -type f -exec ldd {} \; | awk '{print $3}' | sor fi fi done -cp -fp /lib/ld-linux.so.2 roottree/lib/ +# +# Wouldn't you know, there is one so that is critical to have or +# nothing will load on 2.6 kernels. +# +cp -fp /lib/ld-linux.so.* roottree/lib/ strip `find roottree/lib/ -maxdepth 1 -type f` 2>/dev/null +# +# Get a bunch of stuff from /etc +# +echo "Building /etc ..." cp -p /etc/services roottree/etc/ if [ $? != 0 ] ; then echo "Update failed." exit 1 fi -# -# Get a bunch of stuff from /etc -# -echo "Building /etc ..." for file in `cat rootetc.list` ; do if [ -e $file ] ; then cp -fp $file roottree/etc/ @@ -124,8 +148,8 @@ fi # # Pull a few files needed by PAM # -if [ -e /lib/libnss_files.so.1 ] ; then +if [ -f /lib/libnss_files.so.1 ] ; then cp -fp /lib/libnss_files.so.1 roottree/lib/ fi -cp -fp /lib/libnss_files.so.2 roottree/lib/ +cp -fp /lib/libnss_files.so.* roottree/lib/ cp -a /lib/security roottree/lib/ diff --git a/rescue/linux/cdrom/makeinitrd b/rescue/linux/cdrom/makeinitrd index 6209a12..2474cf9 100755 --- a/rescue/linux/cdrom/makeinitrd +++ b/rescue/linux/cdrom/makeinitrd @@ -4,6 +4,7 @@ TOPDIR=`pwd` mkdir -p /mnt/loop1 /mnt/loop2 +# # we need to set aside a few loop devices. I chose (in reverse order of their appearance) # -- loop1 for the boot image # -- loop2 for the RAM disk image @@ -75,7 +76,6 @@ rm -f cdtree/boot/isolinux/initrd.img # and gzip our RAM disk image and put it in the right place. gzip -9 -c root >cdtree/boot/isolinux/initrd.img -# gzip -9 < root >cdtree/boot/isolinux/initrd.img if [ $? != 0 ] ; then echo "Build failed" exit 1 diff --git a/rescue/linux/cdrom/makekernel b/rescue/linux/cdrom/makekernel index bc0f3c8..3bf2224 100755 --- a/rescue/linux/cdrom/makekernel +++ b/rescue/linux/cdrom/makekernel @@ -22,7 +22,8 @@ echo "Updating modules in root RAM disk" rm -rf roottree/lib/modules mkdir -p roottree/lib/modules cp -af /lib/modules/$KERNEL/ roottree/lib/modules/ -# clean up just a bit + +# clean up just a bit removing stuff we do not support rm -rf roottree/lib/modules/$KERNEL/build rm -rf roottree/lib/modules/$KERNEL/kernel/drivers/bluetooth rm -rf roottree/lib/modules/$KERNEL/kernel/drivers/pcmcia diff --git a/rescue/version.h b/rescue/version.h index 9e9a022..13000b0 100644 --- a/rescue/version.h +++ b/rescue/version.h @@ -1,5 +1,5 @@ /* */ #undef VERSION -#define VERSION "1.8.0" -#define BDATE "30 August 2005" -#define LSMDATE "30Aug05" +#define VERSION "1.8.1" +#define BDATE "28 September 2005" +#define LSMDATE "28Sep05" -- 2.39.5