Add hurd-i386 cdrom and pxe support.

suites/ascii
Samuel Thibault 14 years ago
parent de21b5a4df
commit ae88d31463
  1. 0
      build/boot/hurd/grub-hurd-cdrom.cfg
  2. 69
      build/boot/hurd/grub-hurd-pxe.cfg
  3. 5
      build/config/hurd-i386.cfg
  4. 8
      build/config/hurd-i386/cdrom.cfg
  5. 3
      build/config/hurd-i386/netboot.cfg
  6. 61
      build/config/hurd.cfg
  7. 16
      build/pkg-lists/cdrom/hurd-i386.cfg
  8. 3
      debian/changelog

@ -0,0 +1,69 @@
set timeout=-1
if loadfont $prefix/font.pf2 ; then
set gfxmode=640x480
insmod vbe
insmod gfxterm
terminal_output gfxterm
fi
insmod png
if background_image $prefix/splash.png ; then
set color_normal=white/black
set color_highlight=black/white
else
set menu_color_normal=cyan/blue
set menu_color_highlight=white/blue
fi
menuentry "Default install" {
echo "Loading ..."
multiboot $prefix/gnumach.gz root=gunzip:device:rd0 TERM=mach-color
module --nounzip /boot/initrd.gz initrd '$(ramdisk-create)'
module $prefix/ext2fs.static ext2fs \
--multiboot-command-line='${kernel-command-line}' \
--host-priv-port='${host-port}' \
--device-master-port='${device-port}' \
--exec-server-task='${exec-task}' -T typed '${root}' \
'$(task-create)' '$(task-resume)'
module $prefix/ld.so.1 exec /hurd/exec '$(exec-task=task-create)'
}
menuentry "Pseudo-graphical install" {
echo "Loading ..."
multiboot $prefix/gnumach.gz root=gunzip:device:rd0
module --nounzip /boot/initrd.gz initrd '$(ramdisk-create)'
module $prefix/ext2fs.static ext2fs \
--multiboot-command-line='${kernel-command-line}' \
--host-priv-port='${host-port}' \
--device-master-port='${device-port}' \
--exec-server-task='${exec-task}' -T typed '${root}' \
'$(task-create)' '$(task-resume)'
module $prefix/ld.so.1 exec /hurd/exec '$(exec-task=task-create)'
}
menuentry "Automated install" {
echo "Loading ..."
multiboot $prefix/gnumach.gz root=gunzip:device:rd0 auto=true priority=critical TERM=mach-color
module --nounzip /boot/initrd.gz initrd '$(ramdisk-create)'
module $prefix/ext2fs.static ext2fs \
--multiboot-command-line='${kernel-command-line}' \
--host-priv-port='${host-port}' \
--device-master-port='${device-port}' \
--exec-server-task='${exec-task}' -T typed '${root}' \
'$(task-create)' '$(task-resume)'
module $prefix/ld.so.1 exec /hurd/exec '$(exec-task=task-create)'
}
menuentry "Expert install" {
echo "Loading ..."
multiboot $prefix/gnumach.gz root=gunzip:device:rd0 priority=low TERM=mach-color
module --nounzip /boot/initrd.gz initrd '$(ramdisk-create)'
module $prefix/ext2fs.static ext2fs \
--multiboot-command-line='${kernel-command-line}' \
--host-priv-port='${host-port}' \
--device-master-port='${device-port}' \
--exec-server-task='${exec-task}' -T typed '${root}' \
'$(task-create)' '$(task-resume)'
module $prefix/ld.so.1 exec /hurd/exec '$(exec-task=task-create)'
}

@ -1,4 +1,4 @@
MEDIUM_SUPPORTED = netboot netboot-xen
MEDIUM_SUPPORTED = cdrom netboot netboot-xen
MEDIUM_SUPPORTED_EXTRA = monolithic
# The version of the kernel to use.
@ -12,7 +12,4 @@ KERNELIMAGEVERSION = $(KERNELVERSION)
# The codename of the Debian release that should be installed by default.
DEBIAN_RELEASE = unstable
# GRUB configuration file
GRUB_CFG=boot/hurd/grub-hurd-i386.cfg
include config/hurd.cfg

@ -0,0 +1,8 @@
MEDIA_TYPE = CD-ROM
TARGET = $(INITRD) $(KERNEL) $(DEBIAN_CD_INFO)
EXTRANAME = $(MEDIUM)/
MANIFEST-KERNEL = "kernel for use with mkisofs to build a CD"
MANIFEST-INITRD = "initrd for use with mkisofs to build a CD"
MANIFEST-DEBIAN_CD_INFO = "mkisofs config files for CD"

@ -1,6 +1,7 @@
MEDIA_TYPE = netboot image
NETBOOT_DIR_TARGETS = pkg-lists/kernel-module-udebs $(TEMP_INITRD) $(TEMP_KERNEL)
NETBOOT_DIR_TARGETS = $(TEMP_INITRD) $(TEMP_KERNEL)
NETBOOT_DIR_LINKS = grub2pxe
TARGET = $(NETBOOT_DIR) $(NETBOOT_TAR) $(MINIISO)
EXTRANAME = $(MEDIUM)/

@ -25,6 +25,16 @@ SPLASH_PNG=boot/common/pics/spacefun-grub.png
# The font to load in GRUB
GRUB_FONT=/usr/share/grub/ascii.pf2
# GRUB configuration files
GRUB_CFG_CDROM=boot/hurd/grub-hurd-cdrom.cfg
GRUB_CFG_PXE=boot/hurd/grub-hurd-pxe.cfg
# GRUB modules
GRUB_MODDIR=/usr/lib/grub/i386-pc
GRUB_MODULES=cpuid echo gfxterm minicmd normal png vbe
GRUB_MODULES_PXE=pxe pxecmd
GRUB_MODULES_CDROM=biosdisk chain iso9660
# Location for Xen example configuration.
XENCFG = $(SOME_DEST)/$(EXTRANAME)xm-debian.cfg
@ -36,6 +46,29 @@ MKLIBS = mklibs-copy
arch_boot_screens:
arch_tree:
# genisoimage CD info directory, including grub and configuration files
# Note that the configuration is extensively manipulated by debian-cd to
# support all the available CD/DVD variants.
.PHONY: arch_cd_info_dir
arch_cd_info_dir:
-rm -f $(TEMP_CD_INFO_DIR)/*
mkdir -p $(TEMP_CD_INFO_DIR)
mkdir -p $(TEMP_CD_INFO_DIR)/boot/grub
sed -e "s/@ARCH@/$(ARCH)/g" $(GRUB_CFG_CDROM) \
> $(TEMP_CD_INFO_DIR)/boot/grub/grub.cfg
if [ -n "$(GRUB_FONT)" ] ; then \
cp $(GRUB_FONT) $(TEMP_CD_INFO_DIR)/boot/grub/font.pf2; \
fi
if [ -n "$(SPLASH_PNG)" ]; then \
cp $(SPLASH_PNG) $(TEMP_CD_INFO_DIR)/boot/grub/splash.png; \
fi
grub-mkimage -O i386-pc -o $(TEMP_CD_INFO_DIR)/boot/grub/core.img $(GRUB_MODULES) $(GRUB_MODULES_CDROM)
cat $(GRUB_MODDIR)/cdboot.img $(TEMP_CD_INFO_DIR)/boot/grub/core.img \
> $(TEMP_CD_INFO_DIR)/boot/grub/grub_eltorito
rm $(TEMP_CD_INFO_DIR)/boot/grub/core.img
# Miniature CD image using GRUB, with only an initrd, no udebs or debs.
.PHONY: arch_miniiso
arch_miniiso: $(TEMP_INITRD) $(TEMP_KERNEL) $(TREE)
@ -46,7 +79,8 @@ arch_miniiso: $(TEMP_INITRD) $(TEMP_KERNEL) $(TREE)
cp $(TEMP_KERNEL) $(TEMP_CD_TREE)/boot/kernel/
cp /lib/ld.so.1 $(TEMP_CD_TREE)/boot/kernel/
cp $(TEMP_INITRD) $(TEMP_CD_TREE)/boot/initrd.gz
cp $(GRUB_CFG) $(TEMP_CD_TREE)/boot/grub/grub.cfg
sed -e "s/@ARCH@/$(ARCH)/g" $(GRUB_CFG_CDROM) \
> $(TEMP_CD_TREE)/boot/grub/grub.cfg
if [ -n "$(GRUB_FONT)" ] ; then \
cp $(GRUB_FONT) $(TEMP_CD_TREE)/boot/grub/font.pf2; \
fi
@ -63,6 +97,31 @@ arch_netboot_dir:
mkdir -p $(TEMP_NETBOOT_DIR)/$(NETBOOT_PATH)
cp $(TEMP_INITRD) $(TEMP_NETBOOT_DIR)/$(NETBOOT_PATH)
cp $(TEMP_KERNEL) $(TEMP_NETBOOT_DIR)/$(NETBOOT_PATH)
sed -e "s/@ARCH@/$(ARCH)/g" $(GRUB_CFG_PXE) \
> $(TEMP_NETBOOT_DIR)/$(NETBOOT_PATH)/grub.cfg
if [ -n "$(GRUB_FONT)" ] ; then \
cp $(GRUB_FONT) $(TEMP_NETBOOT_DIR)/$(NETBOOT_PATH)/font.pf2; \
fi
if [ -n "$(SPLASH_PNG)" ]; then \
cp $(SPLASH_PNG) $(TEMP_NETBOOT_DIR)/$(NETBOOT_PATH)/splash.png; \
fi
# Generate grub2pxe
grub-mkimage -O i386-pc --prefix="(pxe)/$(NETBOOT_PATH)" \
-o $(TEMP_NETBOOT_DIR)/core.img \
$(GRUB_MODULES) $(GRUB_MODULES_PXE)
# workaround a gPXE bug
sed -i -e 's/\x02\xb0\xad\x1b/\x03\xb0\xad\x1b/' $(TEMP_NETBOOT_DIR)/core.img
cat $(GRUB_MODDIR)/pxeboot.img $(TEMP_NETBOOT_DIR)/core.img \
> $(TEMP_NETBOOT_DIR)/$(NETBOOT_PATH)/grub2pxe
rm $(TEMP_NETBOOT_DIR)/core.img
# This symlink is not strictly required, but it allows more usual
# dhcp server setups to work without modification.
rm -f $(TEMP_NETBOOT_DIR)/grub2pxe
ln -sf $(NETBOOT_PATH)/grub2pxe $(TEMP_NETBOOT_DIR)/grub2pxe
.PHONY: xen_config
xen_config: $(TEMP_INITRD)

@ -0,0 +1,16 @@
# These are broken and/or irrelevant on Hurd for now
clock-setup -
partman-auto-raid -
partman-ext3 -
partman-jfs -
partman-md -
partman-xfs -
partman-btrfs -
# FIXME: ufsutils-udeb is uninstallable
partman-ufs -
rescue-mode -
libbsd0-udeb -
rdate-udeb -
tzsetup-udeb -
bogl-bterm-udeb -

3
debian/changelog vendored

@ -10,7 +10,8 @@ debian-installer (2011xxxx) UNRELEASED; urgency=low
* Stick gnumach kernel versioning to Debian style.
* Add hurd-i386 Xen netboot image support
* Hack hurd-i386 netboot image size to have some room for downloaded udebs.
* Enable netcfg, now having working DHCP support.
* Enable netcfg on hurd-i386, now having working DHCP support.
* Add hurd-i386 cdrom and pxe support, inspired from kfreebsd.
[ Joey Hess ]
* Initial changes to target wheezy.

Loading…
Cancel
Save