diffstat for live-build-5.0~a11 live-build-5.0~a11 changelog | 209 +++++++++++++++++++++++++++ patches/01_win32-loader-path.patch | 11 + patches/02_fix-resolvconf-truncate.patch | 26 +++ patches/03_syslinux-append-union.patch | 15 + patches/04_tanglu-mode.patch | 186 ++++++++++++++++++++++++ patches/05_add-efi-support.patch | 223 +++++++++++++++++++++++++++++ patches/06_add-casper.patch | 233 +++++++++++++++++++++++++++++++ patches/07_add-gfxboot.patch | 114 +++++++++++++++ patches/series | 7 rules | 3 10 files changed, 1027 insertions(+) diff -Nru live-build-5.0~a11/debian/changelog live-build-5.0~a11/debian/changelog --- live-build-5.0~a11/debian/changelog 2015-08-23 08:58:09.000000000 +0000 +++ live-build-5.0~a11/debian/changelog 2015-11-16 03:27:10.000000000 +0000 @@ -1,3 +1,58 @@ +live-build (5.0~a11-1tanglu6) staging; urgency=medium + + * Simplify all patches and make them a bit less Tanglu-specific + - This might help others to use them as well. + + -- Matthias Klumpp Mon, 16 Nov 2015 14:26:24 +0100 + +live-build (5.0~a11-1tanglu5) staging; urgency=medium + + * Fix gfxboot splash and adapt it dynamically. + * Substitude more varaibles in isolinux config. + * Make basic EFI support available on the live-cds + - It took a lot of time and work, but now that beast + is finally here. + + -- Matthias Klumpp Tue, 10 Nov 2015 21:48:56 +0100 + +live-build (5.0~a11-1tanglu4) staging; urgency=medium + + * Fix another case of the initramfs getting incomplete when + building with Casper. + + -- Matthias Klumpp Tue, 10 Nov 2015 18:02:56 +0100 + +live-build (5.0~a11-1tanglu3) staging; urgency=medium + + * 07_add-gfxboot.patch: Allow using gfxboot + * Make Casper load the right OverlayFS kernel module + * Don't make build process fail with EFI + * Fix numerous smaller quirks in the build scripts + + -- Matthias Klumpp Tue, 10 Nov 2015 10:50:00 +0100 + +live-build (5.0~a11-1tanglu2) staging; urgency=medium + + * Enable EFI support again. + * 06_add-casper.patch: Add support for building with casper. + + -- Matthias Klumpp Tue, 10 Nov 2015 10:02:26 +0100 + +live-build (5.0~a11-1tanglu1) staging; urgency=medium + + * Merge with Debian unstable + * Refresh patches: + - win32-loader-path.patch: Search for win32-loader in the right + location (when not performing a chroot build) + - fix-resolvconf-truncate.patch: Ensure host resolv.conf doesn't + get truncated if chroot/etc/resolv.conf is a working symlink to the + host resolv.conf + - syslinux-append-union.patch: Use OverlayFS by default + - tanglu-mode.patch: Add support for Tanglu + - add-efi-support.patch: Add support for UEFI (disabled for now) + + -- Matthias Klumpp Tue, 29 Sep 2015 21:40:06 +0200 + live-build (5.0~a11-1) unstable; urgency=low [ Daniel Baumann ] @@ -34,6 +89,44 @@ -- Daniel Baumann Mon, 10 Aug 2015 19:35:24 +0200 +live-build (5.0~a9-1tanglu4) staging; urgency=medium + + * Remove the efi lines in rules with 05_add-efi-support.patch disabled + + -- Philip Muškovac Sun, 12 Jul 2015 21:00:24 +0000 + +live-build (5.0~a9-1tanglu3) staging; urgency=medium + + * Fix 04_tanglu-mode.patch, in the defaults don't mark tanglu as a + derivate, causes duplicate sources entries as we also override the + list generation. + * Disable 05_add-efi-support.patch for the release, it's not ready yet. + + -- Philip Muškovac Sun, 12 Jul 2015 19:15:08 +0000 + +live-build (5.0~a9-1tanglu2) staging; urgency=medium + + * Make EFI support work again + + -- Matthias Klumpp Tue, 16 Jun 2015 22:28:10 +0200 + +live-build (5.0~a9-1tanglu1) staging; urgency=medium + + * Merge with Debian unstable + * Refresh patches: + - win32-loader-path.patch: Search for win32-loader in the right + location (when not performing a chroot build) + - fix-resolvconf-truncate.patch: Ensure host resolv.conf doesn't + get truncated if chroot/etc/resolv.conf is a working symlink to the + host resolv.conf + - remove_elilo_on_i386.patch: Remove elilo from the required + packages on i386. It's gone from Tanglu. + - tanglu-mode.patch: Add support for Tanglu + - add-efi-support.patch: Add support for UEFI + - syslinux-append-union.patch: Use OverlayFS by default + + -- Matthias Klumpp Mon, 15 Jun 2015 14:14:41 +0200 + live-build (5.0~a9-1) unstable; urgency=low * Splitting non-live specific hooks into their own subdirectory within @@ -126,6 +219,41 @@ -- Daniel Baumann Sun, 26 Apr 2015 20:20:53 +0200 +live-build (5.0~a3-1tanglu4) staging; urgency=medium + + * Fix UEFI support patch + * Recommend syslinux-efi + + -- Matthias Klumpp Sat, 13 Jun 2015 21:48:04 +0200 + +live-build (5.0~a3-1tanglu3) staging; urgency=medium + + * 06_syslinux-append-union.patch: Set union= argument if the + union filesystem we want to use is not aufs. + + -- Matthias Klumpp Tue, 17 Feb 2015 22:34:00 +0100 + +live-build (5.0~a3-1tanglu2) staging; urgency=medium + + * Make OverlayFS the default unionfs for Tanglu + + -- Matthias Klumpp Sat, 14 Feb 2015 14:05:42 +0100 + +live-build (5.0~a3-1tanglu1) staging; urgency=medium + + * Merge with Debian experimental, remaining changes: + - win32-loader-path.patch: Search for win32-loader in the right + location (when not performing a chroot build) + - fix-resolvconf-truncate.patch: Ensure host resolv.conf doesn't + get truncated if chroot/etc/resolv.conf is a working symlink to the + host resolv.conf + - remove_elilo_on_i386.diff: Remove elilo from the required + packages on i386. It's gone from bartholomea + - tanglu-mode.patch: Add support for Tanglu + - add-efi-support.patch: Add support for UEFI + + -- Matthias Klumpp Thu, 12 Feb 2015 21:36:08 +0100 + live-build (5.0~a3-1) experimental; urgency=low [ Daniel Baumann ] @@ -249,6 +377,31 @@ -- Daniel Baumann Wed, 10 Dec 2014 08:23:55 +0100 +live-build (4.0.3-1tanglu2) staging; urgency=medium + + * Add x permission to binary_efi script + * Detect the right architecture in EFI script + * Refresh patches + + -- Matthias Klumpp Thu, 27 Nov 2014 10:46:48 +0100 + +live-build (4.0.3-1tanglu1) staging; urgency=medium + + * Merge with Debian unstable, remaining changes: + - win32-loader-path.patch: Search for win32-loader in the right + location (when not performing a chroot build) + - fix-resolvconf-truncate.patch: Ensure host resolv.conf doesn't + get truncated if chroot/etc/resolv.conf is a working symlink to the + host resolv.conf + - fix-isolinux-install.patch: Make sure isolinux is installed if + it's used as bootloader + - remove_elilo_on_i386.diff: Remove elilo from the required + packages on i386. It's gone from bartholomea + - tanglu-mode.patch: Add support for Tanglu + - add-efi-support.patch: Add support for UEFI + + -- Matthias Klumpp Wed, 26 Nov 2014 19:38:50 +0100 + live-build (4.0.3-1) unstable; urgency=low [ Richard Nelson ] @@ -324,6 +477,50 @@ -- Daniel Baumann Thu, 24 Jul 2014 05:05:17 +0200 +live-build (4.0~alpha38-1tanglu6) staging; urgency=medium + + * Set some defaults for Tanglu + + -- Matthias Klumpp Mon, 24 Nov 2014 22:28:50 +0100 + +live-build (4.0~alpha38-1tanglu5) staging; urgency=medium + + * Add Tanglu mode + * {binary|source}_disk: Add support for Tanglu + + -- Matthias Klumpp Mon, 24 Nov 2014 14:12:38 +0100 + +live-build (4.0~alpha38-1tanglu4) staging; urgency=medium + + * Add 05_remove_elilo_on_i386.diff to remove elilo from the required + packages on i386. It's gone from bartholomea + + -- Philip Muškovac Sat, 08 Nov 2014 21:40:24 +0100 + +live-build (4.0~alpha38-1tanglu3) staging; urgency=medium + + * Add 04_fix-isolinux-install.patch to make sure isolinux is installed if + it's used as bootloader + + -- Philip Muškovac Tue, 08 Jul 2014 01:35:35 +0200 + +live-build (4.0~alpha38-1tanglu2) staging; urgency=medium + + * Cherry pick 6cfcbbb as upstream_6cfcbbb.diff to fix syslinux 6 support + + -- Philip Muškovac Mon, 30 Jun 2014 22:42:53 +0200 + +live-build (4.0~alpha38-1tanglu1) staging; urgency=medium + + * Merge with debian unstable, remaining changes: + - Add 03_fix-resolvconf-truncate.patch so the host resolv.conf doesn't + get truncated if chroot/etc/resolv.conf is a working symlink to the host + resolv.conf + - Add 02_win32-loader-path.patch: Search for win32-loader in the right + location (when not performing a chroot build) + + -- Philip Muškovac Sat, 28 Jun 2014 21:55:19 +0200 + live-build (4.0~alpha38-1) unstable; urgency=low [ Daniel Baumann ] @@ -351,6 +548,17 @@ -- Daniel Baumann Wed, 25 Jun 2014 21:04:46 +0200 +live-build (4.0~alpha37-1tanglu1) staging; urgency=low + + * Merge with debian unstable, remaining changes: + - Add 03_fix-resolvconf-truncate.patch so the host resolv.conf doesn't + get truncated if chroot/etc/resolv.conf is a working symlink to the host + resolv.conf + - Add 02_win32-loader-path.patch: Search for win32-loader in the right + location (when not performing a chroot build) + + -- Valentin OVD Mon, 09 Jun 2014 12:01:35 +0200 + live-build (4.0~alpha37-1) unstable; urgency=low * Updating default boot parameters for live-config 4.x. @@ -6434,3 +6642,4 @@ * Initial release. -- Daniel Baumann Mon, 17 Jul 2006 00:00:00 +0200 + diff -Nru live-build-5.0~a11/debian/patches/01_win32-loader-path.patch live-build-5.0~a11/debian/patches/01_win32-loader-path.patch --- live-build-5.0~a11/debian/patches/01_win32-loader-path.patch 1970-01-01 00:00:00.000000000 +0000 +++ live-build-5.0~a11/debian/patches/01_win32-loader-path.patch 2015-09-29 19:40:03.000000000 +0000 @@ -0,0 +1,11 @@ +--- a/scripts/build/binary_win32-loader ++++ b/scripts/build/binary_win32-loader +@@ -69,7 +69,7 @@ + # Copying win32-loader + cp -r chroot/usr/share/win32/* binary + else +- cp -r usr/share/win32/* binary ++ cp -r /usr/share/win32/* binary + fi + + mv binary/win32-loader.exe binary/setup.exe diff -Nru live-build-5.0~a11/debian/patches/02_fix-resolvconf-truncate.patch live-build-5.0~a11/debian/patches/02_fix-resolvconf-truncate.patch --- live-build-5.0~a11/debian/patches/02_fix-resolvconf-truncate.patch 1970-01-01 00:00:00.000000000 +0000 +++ live-build-5.0~a11/debian/patches/02_fix-resolvconf-truncate.patch 2014-11-27 00:47:46.000000000 +0000 @@ -0,0 +1,26 @@ +--- a/scripts/build/chroot_resolv ++++ b/scripts/build/chroot_resolv +@@ -40,7 +40,11 @@ + # Creating lock file + Create_lockfile .lock + +- if [ -e chroot/etc/resolv.conf ] ++ if [ -L chroot/etc/resolv.conf ] ++ then ++ # Move resolv.conf aside if it's a symlink (likely resolvconf) ++ mv chroot/etc/resolv.conf chroot/etc/resolv.conf.orig ++ elif [ -e chroot/etc/resolv.conf ] + then + # Save resolv file or symlink + mv chroot/etc/resolv.conf chroot/etc/resolv.conf.orig +@@ -51,10 +55,6 @@ + # If you want to have a custom resolv.conf, please + # overwrite it with normal local_includes mechanism. + Truncate chroot/etc/resolv.conf.orig +- elif [ -L chroot/etc/resolv.conf ] +- then +- # Move resolv.conf aside if it's a symlink (likely resolvconf) +- mv chroot/etc/resolv.conf chroot/etc/resolv.conf.orig + fi + + if [ -f /etc/resolv.conf ] diff -Nru live-build-5.0~a11/debian/patches/03_syslinux-append-union.patch live-build-5.0~a11/debian/patches/03_syslinux-append-union.patch --- live-build-5.0~a11/debian/patches/03_syslinux-append-union.patch 1970-01-01 00:00:00.000000000 +0000 +++ live-build-5.0~a11/debian/patches/03_syslinux-append-union.patch 2015-06-15 11:40:56.000000000 +0000 @@ -0,0 +1,15 @@ +--- a/scripts/build/binary_syslinux ++++ b/scripts/build/binary_syslinux +@@ -179,6 +179,12 @@ + ;; + esac + ++# Setting boot parameters ++if [ "${LB_UNION_FILESYSTEM}" != "aufs" ] ++then ++ LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} union=${LB_UNION_FILESYSTEM}" ++fi ++ + # Configuring files + if [ -e "${_TARGET}/live.cfg.in" ] + then diff -Nru live-build-5.0~a11/debian/patches/04_tanglu-mode.patch live-build-5.0~a11/debian/patches/04_tanglu-mode.patch --- live-build-5.0~a11/debian/patches/04_tanglu-mode.patch 1970-01-01 00:00:00.000000000 +0000 +++ live-build-5.0~a11/debian/patches/04_tanglu-mode.patch 2015-09-29 19:39:53.000000000 +0000 @@ -0,0 +1,186 @@ +Description: Add Tanglu mode + * {binary|source}_disk: Add support for Tanglu +Author: Matthias Klumpp + +--- +The information above should follow the Patch Tagging Guidelines, please +checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here +are templates for supplementary fields that you might want to add: + +Origin: , +Bug: +Bug-Debian: https://bugs.debian.org/ +Bug-Ubuntu: https://launchpad.net/bugs/ +Forwarded: +Reviewed-By: +Last-Update: + +--- a/scripts/build/binary_disk ++++ b/scripts/build/binary_disk +@@ -66,6 +66,12 @@ + TRACE="project/trace/ftp-master.debian.org" + ;; + ++ tanglu) ++ TITLE="Tanglu" ++ STRING="Build ${ARCHITECTURE}" ++ TRACE="" ++ ;; ++ + progress-linux) + TITLE="Progress Linux" + STRING="${VERSION} (${DISTRIBUTION}) - ${ARCHITECTURE}" +--- a/scripts/build/binary_syslinux ++++ b/scripts/build/binary_syslinux +@@ -265,6 +265,10 @@ + _PROJECT="Progress Linux" + ;; + ++ tanglu) ++ _PROJECT="Tanglu" ++ ;; ++ + *) + _PROJECT="Debian GNU/Linux" + ;; +--- a/scripts/build/chroot_archives ++++ b/scripts/build/chroot_archives +@@ -91,7 +91,7 @@ + if [ "${LB_SECURITY}" = "true" ] + then + case "${LB_MODE}" in +- debian|progress-linux) ++ debian|tanglu|progress-linux) + case "${LB_PARENT_DISTRIBUTION}" in + sid) + +@@ -580,7 +580,7 @@ + if [ "${LB_SECURITY}" = "true" ] + then + case "${LB_MODE}" in +- debian|progress-linux) ++ debian|tanglu|progress-linux) + case "${LB_PARENT_DISTRIBUTION}" in + sid) + +--- a/scripts/build/source_disk ++++ b/scripts/build/source_disk +@@ -66,6 +66,12 @@ + TRACE="project/trace/ftp-master.debian.org" + ;; + ++ tanglu) ++ TITLE="Tanglu" ++ STRING="Build ${ARCHITECTURE}" ++ TRACE="" ++ ;; ++ + progress-linux) + TITLE="Progress Linux" + STRING="${VERSION} (${DISTRIBUTION}) - ${ARCHITECTURE}" +--- a/scripts/build/bootstrap_archives ++++ b/scripts/build/bootstrap_archives +@@ -90,7 +90,7 @@ + if [ "${LB_SECURITY}" = "true" ] + then + case "${LB_MODE}" in +- debian|progress-linux) ++ debian|tanglu|progress-linux) + case "${LB_PARENT_DISTRIBUTION}" in + sid) + +--- a/functions/defaults.sh ++++ b/functions/defaults.sh +@@ -98,7 +98,7 @@ + _DISTRIBUTOR="$(lsb_release -is | tr "[A-Z]" "[a-z]")" + + case "${_DISTRIBUTOR}" in +- debian|progress-linux) ++ debian|progress-linux|tanglu) + LB_MODE="${LB_MODE:-${_DISTRIBUTOR}}" + ;; + +@@ -123,6 +123,11 @@ + LB_DERIVATIVE_IS_BASED_ON="debian" + ;; + ++ tanglu) ++ LB_DISTRIBUTION="${LB_DISTRIBUTION:-chromodoris}" ++ LB_DERIVATIVE="false" ++ ;; ++ + *) + LB_DISTRIBUTION="${LB_DISTRIBUTION:-stretch}" + LB_DERIVATIVE="false" +@@ -246,6 +251,18 @@ + esac + ;; + ++ tanglu) ++ case "${LB_SYSTEM}" in ++ live) ++ LB_INITSYSTEM="${LB_INITSYSTEM:-systemd}" ++ ;; ++ ++ normal) ++ LB_INITSYSTEM="${LB_INITSYSTEM:-none}" ++ ;; ++ esac ++ ;; ++ + *) + case "${LB_SYSTEM}" in + live) +@@ -330,6 +347,11 @@ + LB_PARENT_MIRROR_BOOTSTRAP="${LB_PARENT_MIRROR_BOOTSTRAP:-${LB_MIRROR_BOOTSTRAP}}" + ;; + ++ tanglu) ++ LB_MIRROR_BOOTSTRAP="${LB_MIRROR_BOOTSTRAP:-http://archive.tanglu.org/tanglu/}" ++ LB_PARENT_MIRROR_BOOTSTRAP="${LB_PARENT_MIRROR_BOOTSTRAP:-${LB_MIRROR_BOOTSTRAP}}" ++ ;; ++ + progress-linux) + LB_PARENT_MIRROR_BOOTSTRAP="${LB_PARENT_MIRROR_BOOTSTRAP:-http://ftp.debian.org/debian/}" + LB_MIRROR_BOOTSTRAP="${LB_MIRROR_BOOTSTRAP:-http://cdn.archive.progress-linux.org/packages/}" +@@ -363,6 +385,11 @@ + LB_PARENT_MIRROR_BINARY="${LB_PARENT_MIRROR_BINARY:-http://ftp.debian.org/debian/}" + LB_MIRROR_BINARY="${LB_MIRROR_BINARY:-${LB_MIRROR_CHROOT}}" + ;; ++ ++ tanglu) ++ LB_PARENT_MIRROR_BINARY="${LB_PARENT_MIRROR_BINARY:-http://archive.tanglu.org/tanglu/}" ++ LB_MIRROR_BINARY="${LB_MIRROR_BINARY:-${LB_MIRROR_CHROOT}}" ++ ;; + esac + + # Setting security mirror which ends up in the image +@@ -396,7 +423,16 @@ + LB_CHROOT_FILESYSTEM="${LB_CHROOT_FILESYSTEM:-squashfs}" + + # Setting union filesystem +- LB_UNION_FILESYSTEM="${LB_UNION_FILESYSTEM:-aufs}" ++ case "${LB_MODE}" in ++ tanglu) ++ LB_UNION_FILESYSTEM="overlay" ++ ;; ++ ++ *) ++ LB_UNION_FILESYSTEM="${LB_UNION_FILESYSTEM:-aufs}" ++ ;; ++ esac ++ + + # Setting interactive shell/X11/Xnest + LB_INTERACTIVE="${LB_INTERACTIVE:-false}" +@@ -654,6 +690,10 @@ + progress-linux) + LB_ISO_APPLICATION="${LB_ISO_APPLICATION:-Progress Linux}" + ;; ++ ++ tanglu) ++ LB_ISO_APPLICATION="${LB_ISO_APPLICATION:-Tanglu Live}" ++ ;; + esac + + # Set iso preparer diff -Nru live-build-5.0~a11/debian/patches/05_add-efi-support.patch live-build-5.0~a11/debian/patches/05_add-efi-support.patch --- live-build-5.0~a11/debian/patches/05_add-efi-support.patch 1970-01-01 00:00:00.000000000 +0000 +++ live-build-5.0~a11/debian/patches/05_add-efi-support.patch 2015-11-15 15:49:44.000000000 +0000 @@ -0,0 +1,223 @@ +Description: Add EFI support to the Tanglu images + Some of this code is taken from the debian-cd suites of Ubuntu and Debian, + some inspiration was also taken from Gaudenz Steinlin's and + Raphael Hertzog's patches for EFI support. +Author: Matthias Klumpp +Origin: vendor +Forwarded: no + +--- a/scripts/build/binary ++++ b/scripts/build/binary +@@ -68,6 +68,9 @@ + lb binary_win32-loader ${@} + lb binary_includes ${@} + lb binary_hooks ${@} ++lb binary_efi ${@} # After includes/hooks because it copies in efi.img ++ # files that can be overriden by binary_includes and ++ # modified by binary_hooks + lb binary_checksums ${@} + + if [ "${LB_BUILD_WITH_CHROOT}" != "true" ] +--- /dev/null ++++ b/scripts/build/binary_efi +@@ -0,0 +1,131 @@ ++#!/bin/sh ++ ++## live-build(7) - System Build Scripts ++## Copyright (C) 2015 Matthias Klumpp ++## ++## This program comes with ABSOLUTELY NO WARRANTY; for details see COPYING. ++## This is free software, and you are welcome to redistribute it ++## under certain conditions; see COPYING for details. ++ ++set -e ++ ++# Including common functions ++[ -e "${LIVE_BUILD}/scripts/build.sh" ] && . "${LIVE_BUILD}/scripts/build.sh" || . /usr/lib/live/build.sh ++ ++# Setting static variables ++DESCRIPTION="$(Echo 'prepares and installs EFI support into binary')" ++HELP="" ++USAGE="${PROGRAM} [--force]" ++ ++Arguments "${@}" ++ ++# Reading configuration files ++Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source ++Set_defaults ++ ++case "${LB_ARCHITECTURES}" in ++ amd64) ++ _EFI_TYPE=efi64 ++ ;; ++ i386) ++ echo "WARNING: We don't support EFI on ${LB_ARCHITECTURES} yet." >&2 ++ exit 0 ++ ;; ++ *) ++ echo "ERROR: can't provide EFI boot support to architecture ${LB_ARCHITECTURES}" >&2 ++ exit 1 ++ ;; ++esac ++ ++Echo_message "Begin preparing EFI support..." ++ ++# Requiring stage file ++Require_stagefile .build/config .build/bootstrap ++ ++# Checking stage file ++Check_stagefile .build/binary_efi ++ ++# Checking lock file ++Check_lockfile .lock ++ ++# Creating lock file ++Create_lockfile .lock ++ ++# Check architecture ++Check_architectures amd64 i386 ++Check_crossarchitectures ++ ++# Check d-i configuration, we need it here ++case "${LB_DEBIAN_INSTALLER}" in ++ true|cdrom|netinst|netboot|businesscard|live) ++ ;; ++ ++ false) ++ exit 0 ++ ;; ++ ++ *) ++ Echo_error "debian-installer flavour %s not supported." "${LB_DEBIAN_INSTALLER}" ++ exit 1 ++ ;; ++esac ++ ++# Checking depends ++case "${LB_BUILD_WITH_CHROOT}" in ++ true) ++ Check_package chroot /usr/bin/mcopy mtools ++ ;; ++ ++ false) ++ if [ ! -e /usr/bin/mcopy ] ++ then ++ # mtools ++ Echo_error "/usr/bin/mcopy - no such file." ++ exit 1 ++ fi ++ ;; ++esac ++ ++# Restoring cache ++Restore_cache cache/packages.binary ++ ++# Installing depends ++Install_package ++ ++# Now get the EFI bits from d-i ++_CDINFO="${LB_MIRROR_DEBIAN_INSTALLER}/dists/${LB_DEBIAN_INSTALLER_DISTRIBUTION}/main/installer-${LB_ARCHITECTURES}/current/images/cdrom/debian-cd_info.tar.gz" ++ ++rm -rf binary/boot-tmp/ ++rm -rf binary/boot/grub ++mkdir -p binary/boot/ ++mkdir -p binary/boot-tmp/ ++(cd binary/boot-tmp/ && wget -nv $_CDINFO) ++(cd binary/boot-tmp/ && tar -xzvf debian-cd_info.tar.gz) ++mv binary/boot-tmp/grub "binary/boot/" ++rm -rf binary/boot-tmp/ ++ ++# Move GRUB files to the right place. ++mkdir -p binary/EFI/BOOT ++mcopy -n -i binary/boot/grub/efi.img ::EFI/BOOT/BOOTx64.EFI binary/EFI/BOOT/BOOTx64.EFI ++mcopy -n -i binary/boot/grub/efi.img ::EFI/BOOT/grubx64.efi binary/EFI/BOOT/grubx64.efi || true ++ ++if [ -e "binary/isolinux/grub-efi.cfg" ] ++then ++ rm -f binary/boot/grub/grub.cfg ++ mv binary/isolinux/grub-efi.cfg binary/boot/grub/grub.cfg ++else ++ sed -i '/^menuentry/Q' binary/boot/grub/grub.cfg ++fi ++ ++case "${LB_BUILD_WITH_CHROOT}" in ++ true) ++ # Saving cache ++ Save_cache cache/packages.binary ++ ++ # Removing depends ++ Remove_package ++ ;; ++esac ++ ++# Creating stage file ++Create_stagefile .build/binary_efi +--- a/scripts/build/binary_iso ++++ b/scripts/build/binary_iso +@@ -144,6 +144,32 @@ + ;; + esac + ++if [ -e binary/EFI/BOOT/BOOTx64.EFI ]; ++then ++ XORRISO_VER=$(xorriso --version 2>&1 | awk ' ++ /^xorriso version/ { ++ split($4, ver, ".") ++ print ver[1]*10000+ver[2]*100+ver[3] ++ }') ++ # Ugh - different code here depending on the version of xorriso we've got ++ if [ $XORRISO_VER -le 10202 ] ; then ++ # 1.2.2 shipping in Wheezy ++ # Tell xorriso to create a secondary ElTorito boot record for the ++ # EFI bootloader ++ XORRISO_OPTIONS="${XORRISO_OPTIONS} -eltorito-alt-boot --efi-boot boot/grub/efi.img" ++ # Add the efi image as a FAT partition too, so our CD image will ++ # also boot on a USB key (like isohybrid, just implemented ++ # differently) ++ XORRISO_OPTIONS="${XORRISO_OPTIONS} -append_partition 2 0x01 boot/grub/efi.img" ++ ++ elif [ $XORRISO_VER -gt 10202 ] ; then ++ XORRISO_OPTIONS="${XORRISO_OPTIONS} -eltorito-alt-boot -e boot/grub/efi.img -no-emul-boot" ++ XORRISO_OPTIONS="${XORRISO_OPTIONS} -isohybrid-gpt-basdat -isohybrid-apm-hfsplus" ++ fi ++else ++ Echo "No EFI boot code to include in the ISO" ++fi ++ + #if [ "${LB_DEBIAN_INSTALLER}" != "live" ] + #then + # XORRISO_OPTIONS="${XORRISO_OPTIONS} -m ${XORRISO_EXCLUDE}" +--- a/scripts/build/installer_debian-installer ++++ b/scripts/build/installer_debian-installer +@@ -314,9 +314,11 @@ + mv chroot/var/lib/dpkg/status chroot/var/lib/dpkg/status.tmp + touch chroot/var/lib/dpkg/status + ++ DI_EXTRA_PACKAGES="" + case "${LB_ARCHITECTURES}" in + amd64) + DI_REQ_PACKAGES="lilo grub-pc" ++ DI_EXTRA_PACKAGES="grub-efi" + DI_PACKAGES="${DI_REQ_PACKAGES} linux-image-amd64" + ;; + +@@ -414,6 +416,9 @@ + + # Download .debs of the required packages + Chroot chroot ${_LB_APT_COMMAND} install ${DI_PACKAGES} ${DI_FIRMWARE_PACKAGES} ${DI_REQ_PACKAGES} ++ # reset cache, so we can download conflicting packages ++ Chroot chroot rm -f /binary.deb/*.bin ++ Chroot chroot ${_LB_APT_COMMAND} install ${DI_EXTRA_PACKAGES} + + # Drop the packages already installed that d-i doesn't explicitely need + _REMAINING_PACKAGES="$(echo ${DI_FIRMWARE_PACKAGES} ${DI_REQ_PACKAGES} | sed -e 's# #|#g')" +@@ -426,6 +431,9 @@ + else + # Download .debs of the required packages + Chroot chroot ${_LB_APT_COMMAND} install ${DI_PACKAGES} ${DI_FIRMWARE_PACKAGES} ++ # reset cache, so we can download conflicting packages ++ Chroot chroot rm -f /binary.deb/*.bin ++ Chroot chroot ${_LB_APT_COMMAND} install ${DI_EXTRA_PACKAGES} + fi + + # Revert dpkg status file diff -Nru live-build-5.0~a11/debian/patches/06_add-casper.patch live-build-5.0~a11/debian/patches/06_add-casper.patch --- live-build-5.0~a11/debian/patches/06_add-casper.patch 1970-01-01 00:00:00.000000000 +0000 +++ live-build-5.0~a11/debian/patches/06_add-casper.patch 2015-11-15 01:42:41.000000000 +0000 @@ -0,0 +1,233 @@ +From: Matthias Klumpp +Date: Mon, 9 Nov 2015 20:24:42 +0100 +Subject: Add support for Casper + This was dropped previously, with no replacement. + We use casper in Tanglu, so we need to re-add support for it. + +--- a/functions/defaults.sh ++++ b/functions/defaults.sh +@@ -227,7 +227,15 @@ + # Setting initramfs hook + case "${LB_SYSTEM}" in + live) +- LB_INITRAMFS="${LB_INITRAMFS:-live-boot}" ++ case "${LB_MODE}" in ++ ubuntu) ++ LB_INITRAMFS="${LB_INITRAMFS:-casper}" ++ ;; ++ ++ *) ++ LB_INITRAMFS="${LB_INITRAMFS:-live-boot}" ++ ;; ++ esac + ;; + + normal) +@@ -640,6 +648,11 @@ + LB_BOOTAPPEND_LIVE_FAILSAFE="${LB_BOOTAPPEND_LIVE_FAILSAFE:-boot=live components memtest noapic noapm nodma nomce nolapic nomodeset nosmp nosplash vga=normal}" + ;; + ++ casper) ++ LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE:-boot=casper quiet splash}" ++ LB_BOOTAPPEND_LIVE_FAILSAFE="${LB_BOOTAPPEND_LIVE_FAILSAFE:-boot=casper memtest noapic noapm nodma nomce nolapic nomodeset nosmp nosplash vga=normal}" ++ ;; ++ + none) + LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE:-quiet splash}" + LB_BOOTAPPEND_LIVE_FAILSAFE="${LB_BOOTAPPEND_LIVE_FAILSAFE:-memtest noapic noapm nodma nomce nolapic nomodeset nosmp nosplash vga=normal}" +--- a/scripts/build/binary_disk ++++ b/scripts/build/binary_disk +@@ -103,6 +103,40 @@ + esac + fi + ++case "${LB_INITRAMFS}" in ++ casper) ++ for INITRD in binary/casper/initrd.img* ++ do ++ mkdir -p binary/uuid ++ cd binary/uuid ++ ++ case "${LB_INITRAMFS_COMPRESSION}" in ++ gzip) ++ zcat "../../${INITRD}" | cpio --quiet -id conf/uuid.conf ++ ;; ++ ++ bzip2) ++ bzcat "../../${INITRD}" | cpio --quiet -id conf/uuid.conf ++ ;; ++ ++ lzma) ++ lzcat -S "" "../../${INITRD}" | cpio --quiet -id conf/uuid.conf ++ ;; ++ esac ++ ++ if [ -e conf/uuid.conf ] ++ then ++ mv conf/uuid.conf "../.disk/casper-uuid${INITRD#binary/casper/initrd.img}" ++ else ++ Echo_warning "Failed to find casper uuid.conf in '${INITRD}'" ++ fi ++ ++ cd ${OLDPWD} ++ rm -rf binary/uuid ++ done ++ ;; ++esac ++ + case "${LB_DEBIAN_INSTALLER}" in + cdrom) + echo "main" > binary/.disk/base_components +--- a/scripts/build/binary_grub-pc ++++ b/scripts/build/binary_grub-pc +@@ -103,6 +103,10 @@ + fi + + case "${LB_INITRAMFS}" in ++ casper) ++ INITFS="casper" ++ ;; ++ + live-boot) + INITFS="live" + ;; +@@ -116,6 +120,10 @@ + case "${LIVE_IMAGE_TYPE}" in + iso*|tar) + case "${LB_INITRAMFS}" in ++ casper) ++ DESTDIR_LIVE="binary/casper" ++ ;; ++ + live-boot) + DESTDIR_LIVE="binary/live" + ;; +--- a/scripts/build/binary_linux-image ++++ b/scripts/build/binary_linux-image +@@ -44,6 +44,10 @@ + Create_lockfile .lock + + case "${LB_INITRAMFS}" in ++ casper) ++ DESTDIR="binary/casper" ++ ;; ++ + live-boot) + DESTDIR="binary/live" + ;; +@@ -65,6 +69,25 @@ + + Check_multiarchitectures + ++case "${LB_INITRAMFS}" in ++ casper) ++ Check_package chroot /usr/share/initramfs-tools/hooks/casper casper ++ ++ rm .lock ++ lb chroot_proc remove ${@} ++ ++ # FIXME: Building the initramfs with /proc mounted wrecks it for some reason, ++ # so we regenerate it here properly. ++ # This issue still needs some further investigation. ++ Chroot chroot "CASPER_GENERATE_UUID=1 update-initramfs -k all -t -u" ++ ++ lb chroot_proc install ${@} ++ touch .lock ++ ++ Remove_package ++ ;; ++esac ++ + # Creating directory + mkdir -p "${DESTDIR}" + +--- a/scripts/build/binary_manifest ++++ b/scripts/build/binary_manifest +@@ -44,6 +44,11 @@ + Create_lockfile .lock + + case "${LB_INITRAMFS}" in ++ casper) ++ INITFS="casper" ++ SUFFIX="manifest" ++ ;; ++ + live-boot) + INITFS="live" + SUFFIX="packages" +--- a/scripts/build/binary_memtest ++++ b/scripts/build/binary_memtest +@@ -80,6 +80,10 @@ + + # Setting destination directory + case "${LB_INITRAMFS}" in ++ casper) ++ DESTDIR="binary/casper" ++ ;; ++ + live-boot) + DESTDIR="binary/live" + ;; +--- a/scripts/build/binary_rootfs ++++ b/scripts/build/binary_rootfs +@@ -49,6 +49,10 @@ + esac + + case "${LB_INITRAMFS}" in ++ casper) ++ INITFS="casper" ++ ;; ++ + live-boot) + INITFS="live" + ;; +--- a/scripts/build/binary_syslinux ++++ b/scripts/build/binary_syslinux +@@ -48,6 +48,10 @@ + Check_crossarchitectures + + case "${LB_INITRAMFS}" in ++ casper) ++ _INITRAMFS="casper" ++ ;; ++ + *) + _INITRAMFS="live" + ;; +--- a/scripts/build/chroot_hacks ++++ b/scripts/build/chroot_hacks +@@ -65,6 +65,10 @@ + + # Update initramfs (always, because of udev rules in initrd) + case "${LB_INITRAMFS}" in ++ casper) ++ UPDATE_INITRAMFS_OPTIONS="CASPER_GENERATE_UUID=1" ++ ;; ++ + live-boot) + #UPDATE_INITRAMFS_OPTIONS="LIVE_GENERATE_UUID=1" + ;; +@@ -100,6 +104,10 @@ + esac + + case "${LB_INITRAMFS}" in ++ casper) ++ ID="999" ++ ;; ++ + live-boot) + ID="1000" + ;; +--- a/scripts/build/config ++++ b/scripts/build/config +@@ -1338,6 +1338,10 @@ + mkdir -p config/package-lists + + case "${LB_INITRAMFS}" in ++ casper) ++ echo "casper" > config/package-lists/live.list.chroot ++ ;; ++ + live-boot) + echo "live-boot" > config/package-lists/live.list.chroot + echo "live-config" >> config/package-lists/live.list.chroot diff -Nru live-build-5.0~a11/debian/patches/07_add-gfxboot.patch live-build-5.0~a11/debian/patches/07_add-gfxboot.patch --- live-build-5.0~a11/debian/patches/07_add-gfxboot.patch 1970-01-01 00:00:00.000000000 +0000 +++ live-build-5.0~a11/debian/patches/07_add-gfxboot.patch 2015-11-15 15:55:51.000000000 +0000 @@ -0,0 +1,114 @@ +Description: Add support for gfxboot to syslinux for Tanglu + Thanks to Ubuntu for the loading-from-outside-the-bootlogo-archive fix, + that is included in this patch. +Author: Matthias Klumpp +Origin: vendor +Forwarded: no +--- a/scripts/build/binary_syslinux ++++ b/scripts/build/binary_syslinux +@@ -130,6 +130,14 @@ + then + Check_package chroot /usr/bin/rsvg-convert librsvg2-bin + fi ++ ++ case "${LB_MODE}" in ++ tanglu) ++ Check_package chroot /usr/bin/gm graphicsmagick ++ Check_package chroot /usr/share/gfxboot-theme-tanglu/current/bootlogo.tar.gz gfxboot-theme-tanglu ++ ;; ++ esac ++ + ;; + + false) +@@ -174,12 +182,30 @@ + Chroot chroot cp -aL /root/$(basename ${_SOURCE}) /root/$(basename ${_SOURCE}).tmp > /dev/null 2>&1 || true + cp -a chroot/root/$(basename ${_SOURCE}).tmp/* ${_TARGET} + rm -rf chroot/root/$(basename ${_SOURCE}) chroot/root/$(basename ${_SOURCE}).tmp ++ ++ case "${LB_MODE}" in ++ tanglu) ++ Chroot chroot "mkdir -p /root/$(basename ${_SOURCE}).tmp" ++ Chroot chroot "tar -xzf /usr/share/gfxboot-theme-tanglu/current/bootlogo.tar.gz -C /root/$(basename ${_SOURCE}).tmp" ++ mkdir -p ${_TARGET}/gfx ++ mv "chroot/root/$(basename ${_SOURCE}).tmp"/* ${_TARGET}/gfx ++ rm -rf "chroot/root/$(basename ${_SOURCE}).tmp" ++ ;; ++ esac ++ + ;; + + false) + mkdir -p ${_TARGET} + + cp -aL ${_SOURCE}/* ${_TARGET} > /dev/null 2>&1 || true ++ ++ case "${LB_MODE}" in ++ tanglu) ++ tar -xzf /usr/share/gfxboot-theme-tanglu/current/bootlogo.tar.gz -C ${_TARGET}/gfx ++ ;; ++ esac ++ + ;; + esac + +@@ -291,6 +317,8 @@ + -e "s|@PARENT_DISTRIBUTION@|${LB_PARENT_DISTRIBUTION}|g" \ + -e "s|@VERSION@|${_VERSION}|g" \ + -e "s|@ARCHITECTURE@|${_ARCHITECTURE}|g" \ ++ -e "s|@LINUX@|/${_INITRAMFS}/vmlinuz|g" \ ++ -e "s|@INITRD@|/${_INITRAMFS}/initrd.img|g" \ + -e "s|@DATE@|${_DATE}|g" \ + -e "s|@YEAR@|${_YEAR}|g" \ + -e "s|@MONTH@|${_MONTH}|g" \ +@@ -312,13 +340,13 @@ + case "${LB_BUILD_WITH_CHROOT}" in + true) + cp "${_TARGET}/splash.svg" chroot +- Chroot chroot "rsvg-convert --format png --height 480 --width 640 splash.svg -o splash.png" ++ Chroot chroot "rsvg-convert --width 640 --height 480 splash.svg -o splash.png" + mv chroot/splash.png "${_TARGET}" + rm -f chroot/splash.svg + ;; + + false) +- rsvg-convert --format png --height 480 --width 640 "${_TARGET}/splash.svg" -o "${_TARGET}/splash.png" ++ rsvg-convert --format png --width 640 --height 480 "${_TARGET}/splash.svg" -o "${_TARGET}/splash.png" + ;; + esac + +@@ -337,6 +365,34 @@ + ;; + esac + ++case "${LB_MODE}" in ++ tanglu) ++ # override background ++ if [ -e "${_TARGET}/gfx/back.jpg" ] ++ then ++ rm -f ${_TARGET}/gfx/back.jpg ++ gm convert "${_TARGET}/splash.png" "${_TARGET}/gfx/back.jpg" ++ fi ++ ++ # Hack around the removal of support in gfxboot for reading from outside ++ # the bootlogo archive. This makes customisation harder and is not ideal. ++ tmpdir="$(mktemp -d)" ++ (cd "$tmpdir" && cpio -i) < ${_TARGET}/gfx/bootlogo ++ cp -a -f ${_TARGET}/gfx/*.fnt \ ++ ${_TARGET}/gfx/*.hlp \ ++ ${_TARGET}/gfx/*.jpg \ ++ ${_TARGET}/gfx/*.pcx \ ++ ${_TARGET}/gfx/*.tr \ ++ ${_TARGET}/gfx/*.cfg \ ++ $(test -e ${_TARGET}/gfx/lang && echo ${_TARGET}/gfx/lang) \ ++ ${_TARGET}/gfx/langlist \ ++ "$tmpdir/" || true ++ (cd "$tmpdir" && ls -1 | cpio --quiet -o) > ${_TARGET}/bootlogo ++ rm -rf "$tmpdir" ++ rm -rf ${_TARGET}/gfx ++ ;; ++esac ++ + case "${LB_BUILD_WITH_CHROOT}" in + true) + # Saving cache diff -Nru live-build-5.0~a11/debian/patches/series live-build-5.0~a11/debian/patches/series --- live-build-5.0~a11/debian/patches/series 1970-01-01 00:00:00.000000000 +0000 +++ live-build-5.0~a11/debian/patches/series 2015-11-15 01:18:57.000000000 +0000 @@ -0,0 +1,7 @@ +01_win32-loader-path.patch +02_fix-resolvconf-truncate.patch +03_syslinux-append-union.patch +04_tanglu-mode.patch +05_add-efi-support.patch +06_add-casper.patch +07_add-gfxboot.patch diff -Nru live-build-5.0~a11/debian/rules live-build-5.0~a11/debian/rules --- live-build-5.0~a11/debian/rules 2015-08-19 15:54:43.000000000 +0000 +++ live-build-5.0~a11/debian/rules 2015-11-10 22:22:49.000000000 +0000 @@ -4,6 +4,9 @@ dh ${@} --parallel override_dh_auto_install: + # correct permissions on the new EFI script + -chmod 755 scripts/build/binary_efi + dh_auto_install -- DESTDIR=debian/live-build # Removing unused files