|
From: <ow...@us...> - 2008-01-16 14:37:09
|
Revision: 1010
http://ipcop.svn.sourceforge.net/ipcop/?rev=1010&view=rev
Author: owes
Date: 2008-01-16 06:37:13 -0800 (Wed, 16 Jan 2008)
Log Message:
-----------
rename root and root-extra to root-1 and root-2
init script asks for root-1 and root-2 instead of installer
move some files between root-1 and root-2
Modified Paths:
--------------
ipcop/trunk/config/install/init-mini-initramfs
ipcop/trunk/lfs/initramfs
ipcop/trunk/src/installer/installer.c
Modified: ipcop/trunk/config/install/init-mini-initramfs
===================================================================
--- ipcop/trunk/config/install/init-mini-initramfs 2008-01-15 21:13:46 UTC (rev 1009)
+++ ipcop/trunk/config/install/init-mini-initramfs 2008-01-16 14:37:13 UTC (rev 1010)
@@ -201,7 +201,7 @@
esac
fi
-echo "Insert the root.img floppy and press Enter"
+echo "Insert the root-1.img floppy and press Enter"
read ANSWER
echo -n "Mounting /initramfs as tmpfs ... "
@@ -217,10 +217,16 @@
fi
# DEBUG -- need to add error checking for the line below
-echo -n "Loading root initramfs ... "
+echo -n "Loading root-1 initramfs ... "
cd /initramfs && cat /dev/fd0 | zcat -d | cpio -i
-echo "Done"
+echo "Insert the root-2.img floppy and press Enter"
+read ANSWER
+
+# DEBUG -- need to add error checking for the line below
+echo -n "Loading root-2 initramfs ... "
+cd /initramfs && cat /dev/fd0 | zcat -d | cpio -i
+
# Unmont /proc in preparation for run-init
umount /proc
Modified: ipcop/trunk/lfs/initramfs
===================================================================
--- ipcop/trunk/lfs/initramfs 2008-01-15 21:13:46 UTC (rev 1009)
+++ ipcop/trunk/lfs/initramfs 2008-01-16 14:37:13 UTC (rev 1010)
@@ -346,7 +346,7 @@
# Sparcs don't need boot floppies, so skip the floppy and mini-initramfs sections
ifneq "$(MACHINE)" "sparc"
#################################################################################################
- # START of root floppy section #
+ # START of root-1 floppy section #
#################################################################################################
# Create the floppy root directory in /tmp
@@ -374,11 +374,9 @@
# Empty out /etc/modules.conf because the mini-initramfs has only very few kernel modules
cat /dev/null > $(FLOPPY_ROOT_DIR)/etc/modules.conf
- # Now copy only those libraries we need to the floppy root directory
+ # Copy libraries
mkdir -p $(FLOPPY_ROOT_DIR)/lib
- for lib in `ldd $(FLOPPY_ROOT_DIR)/bin/installer | awk '{print $$1}' | grep -v linux-gate`; do \
- cp -a $(INITRAMFS_DIR)/lib/$$(basename $$lib) $(FLOPPY_ROOT_DIR)/lib/; \
- done
+ cp -a $(INITRAMFS_DIR)/lib/*.so.* $(FLOPPY_ROOT_DIR)/lib/
# Copy the udev helpers into the floppy root directory
cp -a $(INITRAMFS_DIR)/lib/udev $(FLOPPY_ROOT_DIR)/lib/
@@ -403,76 +401,50 @@
$(INITRAMFS_DIR)/lib/modules/$(KVER)/kernel/fs/jbd \
$(FLOPPY_ROOT_DIR)/lib/modules/$(KVER)/kernel/fs/
- # Copy some extra binaries
+ # Copy some extra binaries
mkdir -p $(FLOPPY_ROOT_DIR)/usr
cp -a $(INITRAMFS_DIR)/usr/bin $(FLOPPY_ROOT_DIR)/usr/
- # Now copy the extra libraries we need for the extra binaries
- mkdir -p $(FLOPPY_ROOT_DIR)/usr/lib
+ # Copy the installer i18n messages
+ mkdir -p $(FLOPPY_ROOT_DIR)/usr/share
+ cp -a $(INITRAMFS_DIR)/usr/share/locale $(FLOPPY_ROOT_DIR)/usr/share/
- # Copy the locale archive
- mkdir -p $(FLOPPY_ROOT_DIR)/usr/lib/locale
- cp -a /usr/lib/locale/locale-archive $(FLOPPY_ROOT_DIR)/usr/lib/locale/locale-archive
-
- # Copy some final files
- mkdir -p $(FLOPPY_ROOT_DIR)/usr/share
- for directory in kbd terminfo; do \
- cp -a /$(INITRAMFS_DIR)/usr/share/$$directory $(FLOPPY_ROOT_DIR)/usr/share/; \
- done
-
ifneq "$(MACHINE)" "ppc"
# Now create a cpio archive of the root floppy
cd $(FLOPPY_ROOT_DIR) && find . | cpio -o -H newc | gzip -9 > \
- $(INSTALLER_DIR)/images/$(SNAME)-$(VERSION)-root.img
+ $(INSTALLER_DIR)/images/$(SNAME)-$(VERSION)-root-1.img
else
# For ppc, we're using an ext2 initrd image
- dd if=/dev/zero of=/tmp/$(SNAME)-$(VERSION)-root.img bs=1024k count=20 && \
- mkfs.ext2 -F -m 0 /tmp/$(SNAME)-$(VERSION)-root.img && \
+ dd if=/dev/zero of=/tmp/$(SNAME)-$(VERSION)-root-1.img bs=1024k count=20 && \
+ mkfs.ext2 -F -m 0 /tmp/$(SNAME)-$(VERSION)-root-1.img && \
for i in `seq 0 7`; do \
if (! losetup /dev/loop$${i} >/dev/null 2>&1 ); then \
LOOPDEV="/dev/loop$${i}"; \
break; \
fi; \
done; \
- losetup $$LOOPDEV /tmp/$(SNAME)-$(VERSION)-root.img && \
+ losetup $$LOOPDEV /tmp/$(SNAME)-$(VERSION)-root-1.img && \
mkdir -p /tmp/temp-root && \
mount -t ext2 $$LOOPDEV /tmp/temp-root && \
cp -a $(FLOPPY_ROOT_DIR)/* /tmp/temp-root/ && \
umount /tmp/temp-root && \
losetup -d $$LOOPDEV && \
- gzip -9c /tmp/$(SNAME)-$(VERSION)-root.img > $(INSTALLER_DIR)/images/$(SNAME)-$(VERSION)-root.img && \
- rm -fr /tmp/temp-root /tmp/$(SNAME)-$(VERSION)-root.img
+ gzip -9c /tmp/$(SNAME)-$(VERSION)-root-1.img > $(INSTALLER_DIR)/images/$(SNAME)-$(VERSION)-root-1.img && \
+ rm -fr /tmp/temp-root /tmp/$(SNAME)-$(VERSION)-root-1.img
endif
# Clean and prepare for the root-extra floppy
rm -fr $(FLOPPY_ROOT_DIR)/*
#################################################################################################
- # END of root floppy section #
+ # END of root-1 floppy section #
#################################################################################################
#################################################################################################
- # START of root-extra floppy section #
+ # START of root-2 floppy section #
#################################################################################################
# Just a stupid flag file
- touch $(FLOPPY_ROOT_DIR)/FLOPPYXTRA
+ touch $(FLOPPY_ROOT_DIR)/FLOPPY2
- # Copy the installer i18n messages
- mkdir -p $(FLOPPY_ROOT_DIR)/usr/share
- cp -a $(INITRAMFS_DIR)/usr/share/locale $(FLOPPY_ROOT_DIR)/usr/share/
-
- # Copy some final files
- mkdir -p $(FLOPPY_ROOT_DIR)/usr/share
- for directory in discover; do \
- cp -a /$(INITRAMFS_DIR)/usr/share/$$directory $(FLOPPY_ROOT_DIR)/usr/share/; \
- done
-
- # And remove those libraries that are already included on the first root floppy
- mkdir -p $(FLOPPY_ROOT_DIR)/usr/lib
- cp -a $(INITRAMFS_DIR)/lib/*.so.* $(FLOPPY_ROOT_DIR)/usr/lib/
- for lib in `ldd $(INITRAMFS_DIR)/bin/installer | awk '{print $$1}' | grep -v linux-gate`; do \
- rm -f $(FLOPPY_ROOT_DIR)/usr/lib/$$(basename $$lib); \
- done
-
# Create the kernel modules directory
mkdir -p $(FLOPPY_ROOT_DIR)/lib/modules/$(KVER)/kernel/drivers
@@ -503,10 +475,19 @@
cp -a $(INITRAMFS_DIR)/lib/modules/$(KVER)/kernel/drivers/usb \
$(INITRAMFS_DIR)/lib/modules/$(KVER)/kernel/drivers/hid \
$(FLOPPY_ROOT_DIR)/lib/modules/$(KVER)/kernel/drivers/
+ # Copy the locale archive
+ mkdir -p $(FLOPPY_ROOT_DIR)/usr/lib/locale
+ cp -a /usr/lib/locale/locale-archive $(FLOPPY_ROOT_DIR)/usr/lib/locale/locale-archive
+ # Copy some final files
+ mkdir -p $(FLOPPY_ROOT_DIR)/usr/share
+ for directory in discover kbd terminfo; do \
+ cp -a /$(INITRAMFS_DIR)/usr/share/$$directory $(FLOPPY_ROOT_DIR)/usr/share/; \
+ done
+
# Now create a cpio archive of the extra root floppy
cd $(FLOPPY_ROOT_DIR) && find . | cpio -o -H newc | gzip -9 > \
- $(INSTALLER_DIR)/images/$(SNAME)-$(VERSION)-root-extra.img
+ $(INSTALLER_DIR)/images/$(SNAME)-$(VERSION)-root-2.img
# Clean and prepare for the scsi drivers floppy
rm -fr $(FLOPPY_ROOT_DIR)/*
Modified: ipcop/trunk/src/installer/installer.c
===================================================================
--- ipcop/trunk/src/installer/installer.c 2008-01-15 21:13:46 UTC (rev 1009)
+++ ipcop/trunk/src/installer/installer.c 2008-01-16 14:37:13 UTC (rev 1010)
@@ -382,9 +382,6 @@
read_kv_from_line(&kv, line);
}
- newtInit();
- newtCls();
-
/* Determine boot medium */
if ( access("/CDROMBOOT", 0) != -1 )
{
@@ -397,13 +394,6 @@
/* boot + root floppy */
medium_boot = floppy;
fprintf(flog, "Boot is floppy\n");
-
- while ( access("/FLOPPYXTRA", 0) )
- {
- /* Lets try and get the root-extra floppy */
- newtWinMessage(get_title(), "OK", "Insert the root-extra.img floppy and press Enter");
- mysystem("cd / && cat /dev/fd0 | gzip -dc | cpio -i");
- }
}
else
{
@@ -416,6 +406,9 @@
/* usbcore, ehci_hcd, ohci_hcd, uhci_hcd, usbhid */
+ newtInit();
+ newtCls();
+
/* first things first, installer language */
handlelanguage(kv);
/* Starting here we have a language selected, use ipcop_gettext to get translated texts */
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|