Updating internal variables from lh to lb scheme, should be the last piece to finish the live-helper to live-build rename.
This commit is contained in:
parent
ec77afa94f
commit
493c4488bf
202
cgi/cgi
202
cgi/cgi
|
@ -9,7 +9,7 @@
|
|||
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Reading defaults
|
||||
if [ -r /etc/default/live-build.cgi ]
|
||||
|
@ -37,9 +37,9 @@ cat "${_TEMPLATES}"/header.html
|
|||
if [ -z "${QUERY_STRING}" ]
|
||||
then
|
||||
# Sending html form
|
||||
sed -e "s#LH_MIRROR_BOOTSTRAP#${LH_MIRROR_BOOTSTRAP}#" \
|
||||
-e "s#LH_MIRROR_BINARY_SECURITY#${LH_MIRROR_BINARY_SECURITY}#" \
|
||||
-e "s#LH_MIRROR_BINARY#${LH_MIRROR_BINARY}#" \
|
||||
sed -e "s#LB_MIRROR_BOOTSTRAP#${LB_MIRROR_BOOTSTRAP}#" \
|
||||
-e "s#LB_MIRROR_BINARY_SECURITY#${LB_MIRROR_BINARY_SECURITY}#" \
|
||||
-e "s#LB_MIRROR_BINARY#${LB_MIRROR_BINARY}#" \
|
||||
-e "s/VERSION/${VERSION}/" \
|
||||
-e "s/DATE/`date +%Y%m%d-%H:%M`/" \
|
||||
"${_TEMPLATES}"/form.html
|
||||
|
@ -62,45 +62,45 @@ else
|
|||
_EMAIL=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])email=[-0-9a-zA-Z._@]+' | cut -f 2 -d '=' | head -n1)
|
||||
|
||||
# Standard options
|
||||
LH_BINARY_IMAGES=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])binary_images=[-a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_DISTRIBUTION=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])distribution=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_PACKAGES_LISTS=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])packages_lists=[-0-9a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_TASKS=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])tasks=[-0-9a-zA-Z. _]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_PACKAGES=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])packages=[-0-9a-zA-Z. _]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_BINARY_IMAGES=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])binary_images=[-a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_DISTRIBUTION=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])distribution=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_PACKAGES_LISTS=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])packages_lists=[-0-9a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_TASKS=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])tasks=[-0-9a-zA-Z. _]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_PACKAGES=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])packages=[-0-9a-zA-Z. _]+' | cut -f 2 -d '=' | head -n1)
|
||||
|
||||
# Advanced bootstrap options
|
||||
LH_ARCHITECTURE=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])architecture=[0-9a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_BOOTSTRAP_FLAVOUR=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])bootstrap_flavour=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_MIRROR_BOOTSTRAP=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])mirror_bootstrap=[-0-9a-zA-Z.~:/_]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_MIRROR_BINARY=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])mirror_binary=[-0-9a-zA-Z.~:/_]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_MIRROR_BINARY_SECURITY=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])mirror_binary_security=[-0-9a-zA-Z.~:/_]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_ARCHIVE_AREAS=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])archive_areas=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_ARCHITECTURE=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])architecture=[0-9a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_BOOTSTRAP_FLAVOUR=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])bootstrap_flavour=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_MIRROR_BOOTSTRAP=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])mirror_bootstrap=[-0-9a-zA-Z.~:/_]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_MIRROR_BINARY=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])mirror_binary=[-0-9a-zA-Z.~:/_]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_MIRROR_BINARY_SECURITY=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])mirror_binary_security=[-0-9a-zA-Z.~:/_]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_ARCHIVE_AREAS=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])archive_areas=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
|
||||
# Advanced chroot options
|
||||
LH_CHROOT_FILESYSTEM=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])chroot_filesystem=[0-9a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_LINUX_FLAVOURS=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])linux_flavours=[-0-9a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_SECURITY=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])security=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_SYMLINKS=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])symlinks=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_SYSVINIT=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])sysvinit=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_CHROOT_FILESYSTEM=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])chroot_filesystem=[0-9a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_LINUX_FLAVOURS=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])linux_flavours=[-0-9a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_SECURITY=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])security=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_SYMLINKS=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])symlinks=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_SYSVINIT=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])sysvinit=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
|
||||
# Advanced binary options
|
||||
LH_BINARY_INDICES=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])binary_indices=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_BOOTAPPEND_INSTALL=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])bootappend_install=[-0-9a-zA-Z. _+=:/]+' | cut -f2- -d '=' | head -n1)
|
||||
LH_BOOTAPPEND_LIVE=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])bootappend_live=[-0-9a-zA-Z. _+=:/]+' | cut -f2- -d '=' | head -n1)
|
||||
LH_BOOTLOADER=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])bootloader=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_DEBIAN_INSTALLER=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])debian_installer=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_ENCRYPTION=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])encryption=[0-9a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_ISO_APPLICATION=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])iso_application=[-0-9a-zA-Z. ~;:/_]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_ISO_PREPARER=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])iso_preparer=[-0-9a-zA-Z. ~;:/_]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_ISO_PUBLISHER=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])iso_publisher=[-0-9a-zA-Z. ~;:/_@]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_ISO_VOLUME=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])iso_volume=[-0-9a-zA-Z. ~;:/_]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_MEMTEST=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])memtest=[0-9a-z+]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_NET_ROOT_PATH=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])net_path=[-0-9a-zA-Z._/]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_NET_ROOT_SERVER=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])net_server=[0-9.]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_BINARY_INDICES=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])binary_indices=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_BOOTAPPEND_INSTALL=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])bootappend_install=[-0-9a-zA-Z. _+=:/]+' | cut -f2- -d '=' | head -n1)
|
||||
LB_BOOTAPPEND_LIVE=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])bootappend_live=[-0-9a-zA-Z. _+=:/]+' | cut -f2- -d '=' | head -n1)
|
||||
LB_BOOTLOADER=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])bootloader=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_DEBIAN_INSTALLER=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])debian_installer=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_ENCRYPTION=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])encryption=[0-9a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_ISO_APPLICATION=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])iso_application=[-0-9a-zA-Z. ~;:/_]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_ISO_PREPARER=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])iso_preparer=[-0-9a-zA-Z. ~;:/_]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_ISO_PUBLISHER=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])iso_publisher=[-0-9a-zA-Z. ~;:/_@]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_ISO_VOLUME=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])iso_volume=[-0-9a-zA-Z. ~;:/_]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_MEMTEST=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])memtest=[0-9a-z+]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_NET_ROOT_PATH=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])net_path=[-0-9a-zA-Z._/]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_NET_ROOT_SERVER=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])net_server=[0-9.]+' | cut -f 2 -d '=' | head -n1)
|
||||
|
||||
# Advanced source options
|
||||
LH_SOURCE=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])source=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LH_SOURCE_IMAGES=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])source_images=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_SOURCE=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])source=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
LB_SOURCE_IMAGES=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])source_images=[a-z]+' | cut -f 2 -d '=' | head -n1)
|
||||
|
||||
# Unofficial options
|
||||
_CUSTOM_BOOTSTRAP=$(echo "${QUERY_STRING}" | grep -oE '(^|[?&])custom_bootstrap=[-0-9a-zA-Z.~:/_]+' | cut -f 2 -d '=' | head -n1)
|
||||
|
@ -113,9 +113,9 @@ else
|
|||
then
|
||||
echo "<h2><div style='color: red;'>Error: No email address specified.</div></h2>"
|
||||
|
||||
sed -e "s#LH_MIRROR_BOOTSTRAP#${LH_MIRROR_BOOTSTRAP}#" \
|
||||
-e "s#LH_MIRROR_BINARY_SECURITY#${LH_MIRROR_BINARY_SECURITY}#" \
|
||||
-e "s#LH_MIRROR_BINARY#${LH_MIRROR_BINARY}#" \
|
||||
sed -e "s#LB_MIRROR_BOOTSTRAP#${LB_MIRROR_BOOTSTRAP}#" \
|
||||
-e "s#LB_MIRROR_BINARY_SECURITY#${LB_MIRROR_BINARY_SECURITY}#" \
|
||||
-e "s#LB_MIRROR_BINARY#${LB_MIRROR_BINARY}#" \
|
||||
-e "s/VERSION/${VERSION}/" \
|
||||
-e "s/DATE/`date +%Y%m%d-%H:%M`/" \
|
||||
"${_TEMPLATES}"/form.html
|
||||
|
@ -131,38 +131,38 @@ else
|
|||
# Note: On each string remember to use a delimeter that is not in the string.
|
||||
sed -e "s/BUILD/${_BUILD}/g" \
|
||||
-e "s/EMAIL/${_EMAIL}/" \
|
||||
-e "s/LH_BINARY_IMAGES/${LH_BINARY_IMAGES}/" \
|
||||
-e "s/LH_DISTRIBUTION/${LH_DISTRIBUTION}/" \
|
||||
-e "s/LH_PACKAGES_LISTS/${LH_PACKAGES_LISTS}/" \
|
||||
-e "s/LH_TASKS/${LH_TASKS}/" \
|
||||
-e "s/LH_PACKAGES/${LH_PACKAGES}/" \
|
||||
-e "s/LH_ARCHITECTURE/${LH_ARCHITECTURE}/" \
|
||||
-e "s/LH_BOOTSTRAP_FLAVOUR/${LH_BOOTSTRAP_FLAVOUR}/" \
|
||||
-e "s#LH_MIRROR_BOOTSTRAP#${LH_MIRROR_BOOTSTRAP}#" \
|
||||
-e "s#LH_MIRROR_BINARY_SECURITY#${LH_MIRROR_BINARY_SECURITY}#" \
|
||||
-e "s#LH_MIRROR_BINARY#${LH_MIRROR_BINARY}#" \
|
||||
-e "s/LH_ARCHIVE_AREAS/${LH_ARCHIVE_AREAS}/" \
|
||||
-e "s/LH_CHROOT_FILESYSTEM/${LH_CHROOT_FILESYSTEM}/" \
|
||||
-e "s/LH_LINUX_FLAVOURS/${LH_LINUX_FLAVOURS}/" \
|
||||
-e "s/LH_SECURITY/${LH_SECURITY}/" \
|
||||
-e "s/LH_SYMLINKS/${LH_SYMLINKS}/" \
|
||||
-e "s/LH_SYSVINIT/${LH_SYSVINIT}/" \
|
||||
-e "s/LH_BINARY_INDICES/${LH_BINARY_INDICES}/" \
|
||||
-e "s#LH_BOOTAPPEND_INSTALL#${LH_BOOTAPPEND_INSTALL}#" \
|
||||
-e "s#LH_BOOTAPPEND_LIVE#${LH_BOOTAPPEND_LIVE}#" \
|
||||
-e "s/LH_BOOTLOADER/${LH_BOOTLOADER}/" \
|
||||
-e "s/LH_DEBIAN_INSTALLER/${LH_DEBIAN_INSTALLER}/" \
|
||||
-e "s/LH_ENCRYPTION/${LH_ENCRYPTION}/" \
|
||||
-e "s#LH_ISO_APPLICATION#${LH_ISO_APPLICATION}#" \
|
||||
-e "s#LH_ISO_PREPARER#${LH_ISO_PREPARER}#" \
|
||||
-e "s#LH_ISO_PUBLISHER#${LH_ISO_PUBLISHER}#" \
|
||||
-e "s#LH_ISO_VOLUME#${LH_ISO_VOLUME}#" \
|
||||
-e "s/LH_MEMTEST/${LH_MEMTEST}/" \
|
||||
-e "s#LH_NET_ROOT_PATH#${LH_NET_ROOT_PATH}#" \
|
||||
-e "s/LH_NET_ROOT_SERVER/${LH_NET_ROOT_SERVER}/" \
|
||||
-e "s/LB_BINARY_IMAGES/${LB_BINARY_IMAGES}/" \
|
||||
-e "s/LB_DISTRIBUTION/${LB_DISTRIBUTION}/" \
|
||||
-e "s/LB_PACKAGES_LISTS/${LB_PACKAGES_LISTS}/" \
|
||||
-e "s/LB_TASKS/${LB_TASKS}/" \
|
||||
-e "s/LB_PACKAGES/${LB_PACKAGES}/" \
|
||||
-e "s/LB_ARCHITECTURE/${LB_ARCHITECTURE}/" \
|
||||
-e "s/LB_BOOTSTRAP_FLAVOUR/${LB_BOOTSTRAP_FLAVOUR}/" \
|
||||
-e "s#LB_MIRROR_BOOTSTRAP#${LB_MIRROR_BOOTSTRAP}#" \
|
||||
-e "s#LB_MIRROR_BINARY_SECURITY#${LB_MIRROR_BINARY_SECURITY}#" \
|
||||
-e "s#LB_MIRROR_BINARY#${LB_MIRROR_BINARY}#" \
|
||||
-e "s/LB_ARCHIVE_AREAS/${LB_ARCHIVE_AREAS}/" \
|
||||
-e "s/LB_CHROOT_FILESYSTEM/${LB_CHROOT_FILESYSTEM}/" \
|
||||
-e "s/LB_LINUX_FLAVOURS/${LB_LINUX_FLAVOURS}/" \
|
||||
-e "s/LB_SECURITY/${LB_SECURITY}/" \
|
||||
-e "s/LB_SYMLINKS/${LB_SYMLINKS}/" \
|
||||
-e "s/LB_SYSVINIT/${LB_SYSVINIT}/" \
|
||||
-e "s/LB_BINARY_INDICES/${LB_BINARY_INDICES}/" \
|
||||
-e "s#LB_BOOTAPPEND_INSTALL#${LB_BOOTAPPEND_INSTALL}#" \
|
||||
-e "s#LB_BOOTAPPEND_LIVE#${LB_BOOTAPPEND_LIVE}#" \
|
||||
-e "s/LB_BOOTLOADER/${LB_BOOTLOADER}/" \
|
||||
-e "s/LB_DEBIAN_INSTALLER/${LB_DEBIAN_INSTALLER}/" \
|
||||
-e "s/LB_ENCRYPTION/${LB_ENCRYPTION}/" \
|
||||
-e "s#LB_ISO_APPLICATION#${LB_ISO_APPLICATION}#" \
|
||||
-e "s#LB_ISO_PREPARER#${LB_ISO_PREPARER}#" \
|
||||
-e "s#LB_ISO_PUBLISHER#${LB_ISO_PUBLISHER}#" \
|
||||
-e "s#LB_ISO_VOLUME#${LB_ISO_VOLUME}#" \
|
||||
-e "s/LB_MEMTEST/${LB_MEMTEST}/" \
|
||||
-e "s#LB_NET_ROOT_PATH#${LB_NET_ROOT_PATH}#" \
|
||||
-e "s/LB_NET_ROOT_SERVER/${LB_NET_ROOT_SERVER}/" \
|
||||
-e "s#SERVER#${_SERVER}#g" \
|
||||
-e "s/LH_SOURCE_IMAGES/${LH_SOURCE_IMAGES}/" \
|
||||
-e "s/LH_SOURCE/${LH_SOURCE}/" \
|
||||
-e "s/LB_SOURCE_IMAGES/${LB_SOURCE_IMAGES}/" \
|
||||
-e "s/LB_SOURCE/${LB_SOURCE}/" \
|
||||
-e "s#CUSTOM_BOOTSTRAP#${_CUSTOM_BOOTSTRAP}#" \
|
||||
-e "s#CUSTOM_BINARY#${_CUSTOM_BINARY}#" \
|
||||
"${_TEMPLATES}"/build.html
|
||||
|
@ -181,55 +181,55 @@ _EMAIL="${_EMAIL}"
|
|||
REMOTE_ADDR="${REMOTE_ADDR}"
|
||||
|
||||
# Standard options
|
||||
LH_BINARY_IMAGES="${LH_BINARY_IMAGES}"
|
||||
LH_DISTRIBUTION="${LH_DISTRIBUTION}"
|
||||
LH_PACKAGES_LISTS="${LH_PACKAGES_LISTS}"
|
||||
LH_TASKS="${LH_TASKS}"
|
||||
LH_PACKAGES="${LH_PACKAGES}"
|
||||
LB_BINARY_IMAGES="${LB_BINARY_IMAGES}"
|
||||
LB_DISTRIBUTION="${LB_DISTRIBUTION}"
|
||||
LB_PACKAGES_LISTS="${LB_PACKAGES_LISTS}"
|
||||
LB_TASKS="${LB_TASKS}"
|
||||
LB_PACKAGES="${LB_PACKAGES}"
|
||||
|
||||
# Advanced bootstrap options
|
||||
LH_ARCHITECTURE="${LH_ARCHITECTURE}"
|
||||
LH_MIRROR_BOOTSTRAP="${LH_MIRROR_BOOTSTRAP}"
|
||||
LH_MIRROR_BINARY_SECURITY="${LH_MIRROR_BINARY_SECURITY}"
|
||||
LH_MIRROR_BINARY="${LH_MIRROR_BINARY}"
|
||||
LH_ARCHIVE_AREAS="${LH_ARCHIVE_AREAS}"
|
||||
LB_ARCHITECTURE="${LB_ARCHITECTURE}"
|
||||
LB_MIRROR_BOOTSTRAP="${LB_MIRROR_BOOTSTRAP}"
|
||||
LB_MIRROR_BINARY_SECURITY="${LB_MIRROR_BINARY_SECURITY}"
|
||||
LB_MIRROR_BINARY="${LB_MIRROR_BINARY}"
|
||||
LB_ARCHIVE_AREAS="${LB_ARCHIVE_AREAS}"
|
||||
|
||||
# Advanced chroot options
|
||||
LH_CHROOT_FILESYSTEM="${LH_CHROOT_FILESYSTEM}"
|
||||
LH_LINUX_FLAVOURS="${LH_LINUX_FLAVOURS}"
|
||||
LH_SECURITY="${LH_SECURITY}"
|
||||
LH_SYMLINKS="${LH_SYMLINKS}"
|
||||
LH_SYSVINIT="${LH_SYSVINIT}"
|
||||
LB_CHROOT_FILESYSTEM="${LB_CHROOT_FILESYSTEM}"
|
||||
LB_LINUX_FLAVOURS="${LB_LINUX_FLAVOURS}"
|
||||
LB_SECURITY="${LB_SECURITY}"
|
||||
LB_SYMLINKS="${LB_SYMLINKS}"
|
||||
LB_SYSVINIT="${LB_SYSVINIT}"
|
||||
|
||||
# Advanced binary options
|
||||
LH_BINARY_INDICES="${LH_BINARY_INDICES}"
|
||||
LH_BOOTAPPEND_INSTALL="${LH_BOOTAPPEND_INSTALL}"
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE}"
|
||||
LH_BOOTLOADER="${LH_BOOTLOADER}"
|
||||
LH_DEBIAN_INSTALLER="${LH_DEBIAN_INSTALLER}"
|
||||
LH_ENCRYPTION="${LH_ENCRYPTION}"
|
||||
LH_ISO_APPLICATION="${LH_ISO_APPLICATION}"
|
||||
LH_ISO_PREPARER="${LH_ISO_PREPARER}"
|
||||
LH_ISO_PUBLISHER="${LH_ISO_PUBLISHER}"
|
||||
LH_ISO_VOLUME="${LH_ISO_VOLUME}"
|
||||
LH_MEMTEST="${LH_MEMTEST}"
|
||||
LH_NET_ROOT_PATH="${LH_NET_ROOT_PATH}"
|
||||
LH_NET_ROOT_SERVER="${LH_NET_ROOT_SERVER}"
|
||||
LB_BINARY_INDICES="${LB_BINARY_INDICES}"
|
||||
LB_BOOTAPPEND_INSTALL="${LB_BOOTAPPEND_INSTALL}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE}"
|
||||
LB_BOOTLOADER="${LB_BOOTLOADER}"
|
||||
LB_DEBIAN_INSTALLER="${LB_DEBIAN_INSTALLER}"
|
||||
LB_ENCRYPTION="${LB_ENCRYPTION}"
|
||||
LB_ISO_APPLICATION="${LB_ISO_APPLICATION}"
|
||||
LB_ISO_PREPARER="${LB_ISO_PREPARER}"
|
||||
LB_ISO_PUBLISHER="${LB_ISO_PUBLISHER}"
|
||||
LB_ISO_VOLUME="${LB_ISO_VOLUME}"
|
||||
LB_MEMTEST="${LB_MEMTEST}"
|
||||
LB_NET_ROOT_PATH="${LB_NET_ROOT_PATH}"
|
||||
LB_NET_ROOT_SERVER="${LB_NET_ROOT_SERVER}"
|
||||
|
||||
# Advanced source options
|
||||
LH_SOURCE_IMAGES="${LH_SOURCE_IMAGES}"
|
||||
LH_SOURCE="${LH_SOURCE}"
|
||||
LB_SOURCE_IMAGES="${LB_SOURCE_IMAGES}"
|
||||
LB_SOURCE="${LB_SOURCE}"
|
||||
|
||||
# Unofficial options
|
||||
_CUSTOM_BOOTSTRAP="${_CUSTOM_BOOTSTRAP}"
|
||||
_CUSTOM_BINARY="${_CUSTOM_BINARY}"
|
||||
|
||||
# Other
|
||||
LH_REPOSITORIES="${LH_REPOSITORIES}"
|
||||
LB_REPOSITORIES="${LB_REPOSITORIES}"
|
||||
EOF
|
||||
|
||||
echo "$(date +%b\ %d\ %H:%M:%S) ${HOSTNAME} live-build.cgi: add web build (${_BUILD}) from ${REMOTE_ADDR}." >> /var/log/live
|
||||
echo "$(date +%b\ %d\ %H:%M:%S) ${HOSTNAME} live-build.cgi: options ${_BUILD} |email ${_EMAIL}|binary_images ${LH_BINARY_IMAGES}|distribution ${LH_DISTRIBUTION}|packages_lists ${LH_PACKAGES_LISTS}|tasks ${LH_TASKS}|packages ${LH_PACKAGES}|architecture ${LH_ARCHITECTURE}|mirror_bootstrap_security ${LH_MIRROR_BOOTSTRAP}|mirror_bootstrap ${LH_MIRROR_BOOTSTRAP}|mirror_binary_security ${LH_MIRROR_BINARY_SECURITY}|mirror_binary ${LH_MIRROR_BINARY}|archive_areas ${LH_ARCHIVE_AREAS}|chroot_filesystem ${LH_CHROOT_FILESYSTEM}|linux_flavours ${LH_LINUX_FLAVOURS}|security ${LH_SECURITY}|symlinks ${LH_SYMLINKS}|sysvinit ${LH_SYSVINIT}|binary_indices ${LH_BINARY_INDICES}|bootappend_install ${LH_BOOTAPPEND_INSTALL}|bootappend_live ${LH_BOOTAPPEND_LIVE}|bootloader ${LH_BOOTLOADER}|debian_installer ${LH_DEBIAN_INSTALLER}|encryption ${LH_ENCRYPTION}|iso_application ${LH_ISO_APPLICATION}|iso_preparer ${LH_ISO_PREPARER}|iso_publisher ${LH_ISO_PUBLISHER}|iso_volume ${LH_ISO_VOLUME}|memtest ${LH_MEMTEST}|net_path ${LH_NET_ROOT_PATH}|net_server ${LH_NET_ROOT_SERVER}|source_images ${LH_SOURCE_IMAGES}|source ${LH_SOURCE}|custom_bootstrap ${_CUSTOM_BOOTSTRAP}|custom_binary ${_CUSTOM_BINARY}\n" >> /var/log/live
|
||||
echo "$(date +%b\ %d\ %H:%M:%S) ${HOSTNAME} live-build.cgi: options ${_BUILD} |email ${_EMAIL}|binary_images ${LB_BINARY_IMAGES}|distribution ${LB_DISTRIBUTION}|packages_lists ${LB_PACKAGES_LISTS}|tasks ${LB_TASKS}|packages ${LB_PACKAGES}|architecture ${LB_ARCHITECTURE}|mirror_bootstrap_security ${LB_MIRROR_BOOTSTRAP}|mirror_bootstrap ${LB_MIRROR_BOOTSTRAP}|mirror_binary_security ${LB_MIRROR_BINARY_SECURITY}|mirror_binary ${LB_MIRROR_BINARY}|archive_areas ${LB_ARCHIVE_AREAS}|chroot_filesystem ${LB_CHROOT_FILESYSTEM}|linux_flavours ${LB_LINUX_FLAVOURS}|security ${LB_SECURITY}|symlinks ${LB_SYMLINKS}|sysvinit ${LB_SYSVINIT}|binary_indices ${LB_BINARY_INDICES}|bootappend_install ${LB_BOOTAPPEND_INSTALL}|bootappend_live ${LB_BOOTAPPEND_LIVE}|bootloader ${LB_BOOTLOADER}|debian_installer ${LB_DEBIAN_INSTALLER}|encryption ${LB_ENCRYPTION}|iso_application ${LB_ISO_APPLICATION}|iso_preparer ${LB_ISO_PREPARER}|iso_publisher ${LB_ISO_PUBLISHER}|iso_volume ${LB_ISO_VOLUME}|memtest ${LB_MEMTEST}|net_path ${LB_NET_ROOT_PATH}|net_server ${LB_NET_ROOT_SERVER}|source_images ${LB_SOURCE_IMAGES}|source ${LB_SOURCE}|custom_bootstrap ${_CUSTOM_BOOTSTRAP}|custom_binary ${_CUSTOM_BINARY}\n" >> /var/log/live
|
||||
fi
|
||||
|
||||
sed -e "s/VERSION/${VERSION}/" "${_TEMPLATES}"/footer.html
|
||||
|
|
14
cgi/cron
14
cgi/cron
|
@ -9,7 +9,7 @@
|
|||
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Reading defaults
|
||||
if [ -r /etc/default/live-build.cgi ]
|
||||
|
@ -66,10 +66,10 @@ then
|
|||
_EMAIL=`awk -F\" '/^_EMAIL=/{print $2}' ${_FILE}`
|
||||
# Pull in the remote address, atchitecture, and distribution
|
||||
_REMOTE_ADDR=`awk -F\" '/^REMOTE_ADDR=/{print $2}' ${_FILE}`
|
||||
_LH_ARCHITECTURE=`awk -F\" '/^LH_ARCHITECTURE=/{print $2}' ${_FILE}`
|
||||
_LH_DISTRIBUTION=`awk -F\" '/^LH_DISTRIBUTION=/{print $2}' ${_FILE}`
|
||||
_LH_PACKAGES_LISTS=`awk -F\" '/^LH_PACKAGES_LISTS=/{print $2}' ${_FILE}`
|
||||
_LH_PACKAGES=`awk -F\" '/^LH_PACKAGES=/{print $2}' ${_FILE}`
|
||||
_LB_ARCHITECTURE=`awk -F\" '/^LB_ARCHITECTURE=/{print $2}' ${_FILE}`
|
||||
_LB_DISTRIBUTION=`awk -F\" '/^LB_DISTRIBUTION=/{print $2}' ${_FILE}`
|
||||
_LB_PACKAGES_LISTS=`awk -F\" '/^LB_PACKAGES_LISTS=/{print $2}' ${_FILE}`
|
||||
_LB_PACKAGES=`awk -F\" '/^LB_PACKAGES=/{print $2}' ${_FILE}`
|
||||
# Pull in the custom bootstrap
|
||||
_CUSTOM_BOOTSTRAP=`awk -F\" '/^_CUSTOM_BOOTSTRAP=/{print $2}' ${_FILE}`
|
||||
# Pull in the custom binary
|
||||
|
@ -112,10 +112,10 @@ then
|
|||
if [ "${_ERRORCONFIG}" -eq "0" ] && [ "${_ERRORBUILD}" -eq "0" ]
|
||||
then
|
||||
_STATUS="maybe-successful"
|
||||
echo "${_REMOTE_ADDR} - - `date +[%d/%b/%Y:%H:%m:%S\ %z]` \"${_BUILD} ${_LH_ARCHITECTURE}/${_LH_DISTRIBUTION}/${_LH_PACKAGES_LISTS}/${_LH_PACKAGES}\" 200 - \"-\" \"\"">>/var/log/live-cgi.builds
|
||||
echo "${_REMOTE_ADDR} - - `date +[%d/%b/%Y:%H:%m:%S\ %z]` \"${_BUILD} ${_LB_ARCHITECTURE}/${_LB_DISTRIBUTION}/${_LB_PACKAGES_LISTS}/${_LB_PACKAGES}\" 200 - \"-\" \"\"">>/var/log/live-cgi.builds
|
||||
else
|
||||
_STATUS="maybe-failed"
|
||||
echo "${_REMOTE_ADDR} - - `date +[%d/%b/%Y:%H:%m:%S\ %z]` \"${_BUILD} ${_LH_ARCHITECTURE}/${_LH_DISTRIBUTION}/${_LH_PACKAGES_LISTS}/${_LH_PACKAGES}\" 404 - \"-\" \"\"">>/var/log/live-cgi.builds
|
||||
echo "${_REMOTE_ADDR} - - `date +[%d/%b/%Y:%H:%m:%S\ %z]` \"${_BUILD} ${_LB_ARCHITECTURE}/${_LB_DISTRIBUTION}/${_LB_PACKAGES_LISTS}/${_LB_PACKAGES}\" 404 - \"-\" \"\"">>/var/log/live-cgi.builds
|
||||
fi
|
||||
|
||||
sed -e "s/BUILD/${_BUILD}/g" \
|
||||
|
|
|
@ -10,8 +10,8 @@ _DESTDIR="/srv/debian-live/build/www"
|
|||
_TEMPLATES="/usr/share/live/build/templates/cgi/${_MODE}"
|
||||
_TEMPDIR="/srv/debian-live/build/tmp"
|
||||
|
||||
LH_MIRROR_BOOTSTRAP="http://ftp.de.debian.org/debian/"
|
||||
LH_MIRROR_BINARY="http://ftp.debian.org/debian/"
|
||||
LH_MIRROR_BINARY_SECURITY="http://security.debian.org/"
|
||||
LB_MIRROR_BOOTSTRAP="http://ftp.de.debian.org/debian/"
|
||||
LB_MIRROR_BINARY="http://ftp.debian.org/debian/"
|
||||
LB_MIRROR_BINARY_SECURITY="http://security.debian.org/"
|
||||
|
||||
_SERVER="http://live.debian.net/build"
|
||||
|
|
|
@ -15,7 +15,7 @@ Check_architecture ()
|
|||
|
||||
for ARCHITECTURE in ${ARCHITECTURES}
|
||||
do
|
||||
if [ "$(echo ${LH_ARCHITECTURE} | grep ${ARCHITECTURE})" ]
|
||||
if [ "$(echo ${LB_ARCHITECTURE} | grep ${ARCHITECTURE})" ]
|
||||
then
|
||||
VALID="true"
|
||||
break
|
||||
|
@ -57,13 +57,13 @@ Check_crossarchitecture ()
|
|||
|
||||
Check_multiarchitecture ()
|
||||
{
|
||||
if [ "$(echo ${LH_ARCHITECTURE} | wc -w)" -gt "1" ]
|
||||
if [ "$(echo ${LB_ARCHITECTURE} | wc -w)" -gt "1" ]
|
||||
then
|
||||
# First, only support multiarch on iso
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
iso*)
|
||||
# Assemble multi-arch
|
||||
case "${LH_CURRENT_ARCHITECTURE}" in
|
||||
case "${LB_CURRENT_ARCHITECTURE}" in
|
||||
amd64)
|
||||
DESTDIR="${DESTDIR}.amd"
|
||||
DESTDIR_LIVE="${DESTDIR_LIVE}.amd"
|
||||
|
|
|
@ -12,7 +12,7 @@ Restore_cache ()
|
|||
{
|
||||
DIRECTORY="${1}"
|
||||
|
||||
if [ "${LH_CACHE}" = "true" ] && [ "${LH_CACHE_PACKAGES}" = "true" ]
|
||||
if [ "${LB_CACHE}" = "true" ] && [ "${LB_CACHE_PACKAGES}" = "true" ]
|
||||
then
|
||||
if [ -d "${DIRECTORY}" ]
|
||||
then
|
||||
|
@ -33,7 +33,7 @@ Save_cache ()
|
|||
{
|
||||
DIRECTORY="${1}"
|
||||
|
||||
if [ "${LH_CACHE}" = "true" ] && [ "${LH_CACHE_PACKAGES}" = "true" ]
|
||||
if [ "${LB_CACHE}" = "true" ] && [ "${LB_CACHE_PACKAGES}" = "true" ]
|
||||
then
|
||||
# Cleaning current cache
|
||||
Chroot chroot "apt-get autoclean"
|
||||
|
|
|
@ -16,12 +16,12 @@ Chroot ()
|
|||
# Executing commands in chroot
|
||||
Echo_debug "Executing: %s" "${COMMANDS}"
|
||||
|
||||
if [ "${LH_USE_FAKEROOT}" != "true" ]
|
||||
if [ "${LB_USE_FAKEROOT}" != "true" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} /usr/sbin/chroot "${CHROOT}" /usr/bin/env -i HOME="/root" PATH="/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin" TERM="${TERM}" ftp_proxy="${LH_APT_FTP_PROXY}" http_proxy="${LH_APT_HTTP_PROXY}" DEBIAN_FRONTEND="${LH_DEBCONF_FRONTEND}" DEBIAN_PRIORITY="${LH_DEBCONF_PRIORITY}" DEBCONF_NOWARNINGS="${LH_DEBCONF_NOWARNINGS}" XORG_CONFIG="custom" ${COMMANDS}
|
||||
${LB_ROOT_COMMAND} /usr/sbin/chroot "${CHROOT}" /usr/bin/env -i HOME="/root" PATH="/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin" TERM="${TERM}" ftp_proxy="${LB_APT_FTP_PROXY}" http_proxy="${LB_APT_HTTP_PROXY}" DEBIAN_FRONTEND="${LB_DEBCONF_FRONTEND}" DEBIAN_PRIORITY="${LB_DEBCONF_PRIORITY}" DEBCONF_NOWARNINGS="${LB_DEBCONF_NOWARNINGS}" XORG_CONFIG="custom" ${COMMANDS}
|
||||
else
|
||||
# Building with fakeroot/fakechroot
|
||||
${LH_ROOT_COMMAND} /usr/sbin/chroot "${CHROOT}" ${COMMANDS}
|
||||
${LB_ROOT_COMMAND} /usr/sbin/chroot "${CHROOT}" ${COMMANDS}
|
||||
fi
|
||||
|
||||
return "${?}"
|
||||
|
|
|
@ -10,13 +10,13 @@
|
|||
|
||||
Get_conffiles ()
|
||||
{
|
||||
if [ -n "${LH_CONFIG}" ]
|
||||
if [ -n "${LB_CONFIG}" ]
|
||||
then
|
||||
FILES="${LH_CONFIG}"
|
||||
FILES="${LB_CONFIG}"
|
||||
else
|
||||
for FILE in ${@}
|
||||
do
|
||||
FILES="${FILES} ${FILE} ${FILE}.${LH_ARCHITECTURE} ${FILE}.${DISTRIBUTION}"
|
||||
FILES="${FILES} ${FILE} ${FILE}.${LB_ARCHITECTURE} ${FILE}.${DISTRIBUTION}"
|
||||
FILES="${FILES} config/$(echo ${PROGRAM} | sed -e 's|^lh_||')"
|
||||
FILES="${FILES} config/$(echo ${PROGRAM} | sed -e 's|^lh_||').${ARCHITECTURE}"
|
||||
FILES="${FILES} config/$(echo ${PROGRAM} | sed -e 's|^lh_||').${DISTRIBUTION}"
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -238,7 +238,7 @@ Echo_file ()
|
|||
|
||||
Echo_breakage ()
|
||||
{
|
||||
case "${LH_DISTRIBUTION}" in
|
||||
case "${LB_DISTRIBUTION}" in
|
||||
sid|unstable)
|
||||
Echo_message "If the following stage fails, the most likely cause of the problem is with your mirror configuration, a caching proxy or the sid distribution."
|
||||
;;
|
||||
|
|
|
@ -14,9 +14,9 @@ Losetup ()
|
|||
FILE="${2}"
|
||||
PARTITION="${3:-1}"
|
||||
|
||||
${LH_ROOT_COMMAND} ${LH_LOSETUP} "${DEVICE}" "${FILE}"
|
||||
FDISK_OUT="$(${LH_FDISK} -l -u ${DEVICE} 2>&1)"
|
||||
${LH_ROOT_COMMAND} ${LH_LOSETUP} -d "${DEVICE}"
|
||||
${LB_ROOT_COMMAND} ${LB_LOSETUP} "${DEVICE}" "${FILE}"
|
||||
FDISK_OUT="$(${LB_FDISK} -l -u ${DEVICE} 2>&1)"
|
||||
${LB_ROOT_COMMAND} ${LB_LOSETUP} -d "${DEVICE}"
|
||||
|
||||
LOOPDEVICE="$(echo ${DEVICE}p${PARTITION})"
|
||||
|
||||
|
@ -24,14 +24,14 @@ Losetup ()
|
|||
then
|
||||
Echo_message "Mounting %s with offset 0" "${DEVICE}"
|
||||
|
||||
${LH_ROOT_COMMAND} ${LH_LOSETUP} "${DEVICE}" "${FILE}"
|
||||
${LB_ROOT_COMMAND} ${LB_LOSETUP} "${DEVICE}" "${FILE}"
|
||||
else
|
||||
SECTORS="$(echo "$FDISK_OUT" | sed -ne "s|^$LOOPDEVICE[ *]*\([0-9]*\).*|\1|p")"
|
||||
OFFSET="$(expr ${SECTORS} '*' 512)"
|
||||
|
||||
Echo_message "Mounting %s with offset %s" "${DEVICE}" "${OFFSET}"
|
||||
|
||||
${LH_ROOT_COMMAND} ${LH_LOSETUP} -o "${OFFSET}" "${DEVICE}" "${FILE}"
|
||||
${LB_ROOT_COMMAND} ${LB_LOSETUP} -o "${OFFSET}" "${DEVICE}" "${FILE}"
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@ Check_package ()
|
|||
|
||||
case "${INSTALL_STATUS}" in
|
||||
1)
|
||||
_LH_PACKAGES="${_LH_PACKAGES} ${PACKAGE}"
|
||||
_LB_PACKAGES="${_LB_PACKAGES} ${PACKAGE}"
|
||||
;;
|
||||
|
||||
2)
|
||||
|
@ -29,15 +29,15 @@ Check_package ()
|
|||
|
||||
Install_package ()
|
||||
{
|
||||
if [ -n "${_LH_PACKAGES}" ] && [ "${LH_BUILD_WITH_CHROOT}" != "false" ]
|
||||
if [ -n "${_LB_PACKAGES}" ] && [ "${LB_BUILD_WITH_CHROOT}" != "false" ]
|
||||
then
|
||||
case "${LH_APT}" in
|
||||
case "${LB_APT}" in
|
||||
apt|apt-get)
|
||||
Chroot chroot "apt-get install -o APT::Install-Recommends=false ${APT_OPTIONS} ${_LH_PACKAGES}"
|
||||
Chroot chroot "apt-get install -o APT::Install-Recommends=false ${APT_OPTIONS} ${_LB_PACKAGES}"
|
||||
;;
|
||||
|
||||
aptitude)
|
||||
Chroot chroot "aptitude install --without-recommends ${APTITUDE_OPTIONS} ${_LH_PACKAGES}"
|
||||
Chroot chroot "aptitude install --without-recommends ${APTITUDE_OPTIONS} ${_LB_PACKAGES}"
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
@ -45,15 +45,15 @@ Install_package ()
|
|||
|
||||
Remove_package ()
|
||||
{
|
||||
if [ -n "${_LH_PACKAGES}" ] && [ "${LH_BUILD_WITH_CHROOT}" != "false" ]
|
||||
if [ -n "${_LB_PACKAGES}" ] && [ "${LB_BUILD_WITH_CHROOT}" != "false" ]
|
||||
then
|
||||
case "${LH_APT}" in
|
||||
case "${LB_APT}" in
|
||||
apt|apt-get)
|
||||
Chroot chroot "apt-get remove --purge ${APT_OPTIONS} ${_LH_PACKAGES}"
|
||||
Chroot chroot "apt-get remove --purge ${APT_OPTIONS} ${_LB_PACKAGES}"
|
||||
;;
|
||||
|
||||
aptitude)
|
||||
Chroot chroot "aptitude purge ${APTITUDE_OPTIONS} ${_LH_PACKAGES}"
|
||||
Chroot chroot "aptitude purge ${APTITUDE_OPTIONS} ${_LB_PACKAGES}"
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
@ -69,7 +69,7 @@ Check_installed ()
|
|||
FILE="${1}"
|
||||
PACKAGE="${2}"
|
||||
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
if Chroot chroot "dpkg-query -s ${PACKAGE}" 2> /dev/null | grep -qs "Status: install"
|
||||
then
|
||||
|
|
|
@ -10,89 +10,89 @@
|
|||
|
||||
Expand_packagelist ()
|
||||
{
|
||||
_LH_EXPAND_QUEUE="$(basename "${1}")"
|
||||
_LB_EXPAND_QUEUE="$(basename "${1}")"
|
||||
|
||||
shift
|
||||
|
||||
while [ -n "${_LH_EXPAND_QUEUE}" ]
|
||||
while [ -n "${_LB_EXPAND_QUEUE}" ]
|
||||
do
|
||||
_LH_LIST_NAME="$(echo ${_LH_EXPAND_QUEUE} | cut -d" " -f1)"
|
||||
_LH_EXPAND_QUEUE="$(echo ${_LH_EXPAND_QUEUE} | cut -s -d" " -f2-)"
|
||||
_LH_LIST_LOCATION=""
|
||||
_LH_NESTED=0
|
||||
_LH_ENABLED=1
|
||||
_LB_LIST_NAME="$(echo ${_LB_EXPAND_QUEUE} | cut -d" " -f1)"
|
||||
_LB_EXPAND_QUEUE="$(echo ${_LB_EXPAND_QUEUE} | cut -s -d" " -f2-)"
|
||||
_LB_LIST_LOCATION=""
|
||||
_LB_NESTED=0
|
||||
_LB_ENABLED=1
|
||||
|
||||
for _LH_SEARCH_PATH in ${@} "${LH_BASE:-/usr/share/live/build}/lists"
|
||||
for _LB_SEARCH_PATH in ${@} "${LB_BASE:-/usr/share/live/build}/lists"
|
||||
do
|
||||
if [ -e "${_LH_SEARCH_PATH}/${_LH_LIST_NAME}" ]
|
||||
if [ -e "${_LB_SEARCH_PATH}/${_LB_LIST_NAME}" ]
|
||||
then
|
||||
_LH_LIST_LOCATION="${_LH_SEARCH_PATH}/${_LH_LIST_NAME}"
|
||||
_LB_LIST_LOCATION="${_LB_SEARCH_PATH}/${_LB_LIST_NAME}"
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
if [ -z "${_LH_LIST_LOCATION}" ]
|
||||
if [ -z "${_LB_LIST_LOCATION}" ]
|
||||
then
|
||||
echo "W: Unknown package list '${_LH_LIST_NAME}'" >&2
|
||||
echo "W: Unknown package list '${_LB_LIST_NAME}'" >&2
|
||||
continue
|
||||
fi
|
||||
|
||||
while read _LH_LINE
|
||||
while read _LB_LINE
|
||||
do
|
||||
case "${_LH_LINE}" in
|
||||
case "${_LB_LINE}" in
|
||||
\#if\ *)
|
||||
if [ ${_LH_NESTED} -eq 1 ]
|
||||
if [ ${_LB_NESTED} -eq 1 ]
|
||||
then
|
||||
echo "E: Nesting conditionals is not supported" >&2
|
||||
exit 1
|
||||
fi
|
||||
_LH_NESTED=1
|
||||
_LB_NESTED=1
|
||||
|
||||
_LH_NEEDLE="$(echo "${_LH_LINE}" | cut -d' ' -f3-)"
|
||||
_LH_HAYSTACK="$(eval "echo \$LH_$(echo "${_LH_LINE}" | cut -d' ' -f2)")"
|
||||
_LB_NEEDLE="$(echo "${_LB_LINE}" | cut -d' ' -f3-)"
|
||||
_LB_HAYSTACK="$(eval "echo \$LB_$(echo "${_LB_LINE}" | cut -d' ' -f2)")"
|
||||
|
||||
_LH_ENABLED=0
|
||||
for _LH_NEEDLE_PART in ${_LH_NEEDLE}
|
||||
_LB_ENABLED=0
|
||||
for _LB_NEEDLE_PART in ${_LB_NEEDLE}
|
||||
do
|
||||
for _LH_HAYSTACK_PART in ${_LH_HAYSTACK}
|
||||
for _LB_HAYSTACK_PART in ${_LB_HAYSTACK}
|
||||
do
|
||||
if [ "${_LH_NEEDLE_PART}" = "${_LH_HAYSTACK_PART}" ]
|
||||
if [ "${_LB_NEEDLE_PART}" = "${_LB_HAYSTACK_PART}" ]
|
||||
then
|
||||
_LH_ENABLED=1
|
||||
_LB_ENABLED=1
|
||||
fi
|
||||
done
|
||||
done
|
||||
;;
|
||||
|
||||
\#endif*)
|
||||
_LH_NESTED=0
|
||||
_LH_ENABLED=1
|
||||
_LB_NESTED=0
|
||||
_LB_ENABLED=1
|
||||
;;
|
||||
|
||||
\#*)
|
||||
if [ ${_LH_ENABLED} -ne 1 ]
|
||||
if [ ${_LB_ENABLED} -ne 1 ]
|
||||
then
|
||||
continue
|
||||
fi
|
||||
|
||||
# Find includes
|
||||
_LH_INCLUDES="$(echo "${_LH_LINE}" | sed -n \
|
||||
_LB_INCLUDES="$(echo "${_LB_LINE}" | sed -n \
|
||||
-e 's|^#<include> \([^ ]*\)|\1|gp' \
|
||||
-e 's|^#include <\([^ ]*\)>|\1|gp')"
|
||||
|
||||
# Add to queue
|
||||
_LH_EXPAND_QUEUE="$(echo ${_LH_EXPAND_QUEUE} ${_LH_INCLUDES} |
|
||||
_LB_EXPAND_QUEUE="$(echo ${_LB_EXPAND_QUEUE} ${_LB_INCLUDES} |
|
||||
sed -e 's|[ ]*$||' -e 's|^[ ]*||')"
|
||||
;;
|
||||
|
||||
*)
|
||||
if [ ${_LH_ENABLED} -eq 1 ]
|
||||
if [ ${_LB_ENABLED} -eq 1 ]
|
||||
then
|
||||
echo "${_LH_LINE}"
|
||||
echo "${_LB_LINE}"
|
||||
fi
|
||||
;;
|
||||
|
||||
esac
|
||||
done < "${_LH_LIST_LOCATION}"
|
||||
done < "${_LB_LIST_LOCATION}"
|
||||
done
|
||||
}
|
||||
|
|
|
@ -15,11 +15,11 @@ Check_templates ()
|
|||
if [ -d "config/templates/${PACKAGE}" ]
|
||||
then
|
||||
TEMPLATES="config/templates/${PACKAGE}"
|
||||
elif [ -d "${LH_TEMPLATES}/${PACKAGE}" ]
|
||||
elif [ -d "${LB_TEMPLATES}/${PACKAGE}" ]
|
||||
then
|
||||
TEMPLATES="${LH_TEMPLATES}/${PACKAGE}"
|
||||
TEMPLATES="${LB_TEMPLATES}/${PACKAGE}"
|
||||
else
|
||||
Echo_error "%s templates not accessible in %s nor config/templates" "${PACKAGE}" "${LH_TEMPLATES}"
|
||||
Echo_error "%s templates not accessible in %s nor config/templates" "${PACKAGE}" "${LB_TEMPLATES}"
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
Apt ()
|
||||
{
|
||||
case "${LH_APT}" in
|
||||
case "${LB_APT}" in
|
||||
apt|apt-get)
|
||||
Chroot chroot apt-get ${APT_OPTIONS} ${@}
|
||||
;;
|
||||
|
|
|
@ -685,8 +685,8 @@ defines if win32\-loader should be included in the binary image or not.
|
|||
.\" FIXME
|
||||
.\" FIXME
|
||||
All command line switches can also be specified through the corresponding
|
||||
environment variable. Environment variables are name LH_FOO, means,
|
||||
e.g. \-\-apt\-ftp\-proxy becomes LH_APT_FTP_PROXY. However, this generally
|
||||
environment variable. Environment variables are name LB_FOO, means,
|
||||
e.g. \-\-apt\-ftp\-proxy becomes LB_APT_FTP_PROXY. However, this generally
|
||||
should not be used.
|
||||
|
||||
.SH DATEIEN
|
||||
|
@ -695,7 +695,7 @@ should not be used.
|
|||
.IP \fB/etc/default/live\-build\fP 4
|
||||
.\" FIXME
|
||||
An optional, global configuration file for \fBlb config\fP variables. It is
|
||||
useful to specify a few system wide defaults, like LH_MIRROR_BOOTSTRAP. This
|
||||
useful to specify a few system wide defaults, like LB_MIRROR_BOOTSTRAP. This
|
||||
feature can be false by specifying the \fB\-\-ignore\-system\-defaults\fP option.
|
||||
|
||||
.SH "SIEHE AUCH"
|
||||
|
|
|
@ -422,14 +422,14 @@ defines if win32\-loader should be included in the binary image or not.
|
|||
|
||||
.SH ENVIRONMENT
|
||||
.\" FIXME
|
||||
All command line switches can also be specified through the corresponding environment variable. Environment variables are name LH_FOO, means, e.g. \-\-apt\-ftp\-proxy becomes LH_APT_FTP_PROXY. However, this generally should not be used.
|
||||
All command line switches can also be specified through the corresponding environment variable. Environment variables are name LB_FOO, means, e.g. \-\-apt\-ftp\-proxy becomes LB_APT_FTP_PROXY. However, this generally should not be used.
|
||||
.\" FIXME
|
||||
|
||||
.SH FILES
|
||||
.\" FIXME
|
||||
.IP "\fBauto/config\fR" 4
|
||||
.IP "\fB/etc/default/live\-build\fR" 4
|
||||
An optional, global configuration file for \fBlb config\fR variables. It is useful to specify a few system wide defaults, like LH_MIRROR_BOOTSTRAP. This feature can be false by specifying the \fB\-\-ignore\-system\-defaults\fR option.
|
||||
An optional, global configuration file for \fBlb config\fR variables. It is useful to specify a few system wide defaults, like LB_MIRROR_BOOTSTRAP. This feature can be false by specifying the \fB\-\-ignore\-system\-defaults\fR option.
|
||||
.\" FIXME
|
||||
|
||||
.SH SEE ALSO
|
||||
|
|
|
@ -2666,8 +2666,8 @@ msgstr ""
|
|||
#: en/lb_config.1:427
|
||||
msgid ""
|
||||
"All command line switches can also be specified through the corresponding "
|
||||
"environment variable. Environment variables are name LH_FOO, means, e.g. --"
|
||||
"apt-ftp-proxy becomes LH_APT_FTP_PROXY. However, this generally should not "
|
||||
"environment variable. Environment variables are name LB_FOO, means, e.g. --"
|
||||
"apt-ftp-proxy becomes LB_APT_FTP_PROXY. However, this generally should not "
|
||||
"be used."
|
||||
msgstr ""
|
||||
|
||||
|
@ -2689,6 +2689,6 @@ msgstr "B</etc/default/live-build>"
|
|||
#: en/lb_config.1:434
|
||||
msgid ""
|
||||
"An optional, global configuration file for B<lb config> variables. It is "
|
||||
"useful to specify a few system wide defaults, like LH_MIRROR_BOOTSTRAP. This "
|
||||
"useful to specify a few system wide defaults, like LB_MIRROR_BOOTSTRAP. This "
|
||||
"feature can be false by specifying the B<--ignore-system-defaults> option."
|
||||
msgstr ""
|
||||
|
|
|
@ -2652,8 +2652,8 @@ msgstr ""
|
|||
#: en/lb_config.1:427
|
||||
msgid ""
|
||||
"All command line switches can also be specified through the corresponding "
|
||||
"environment variable. Environment variables are name LH_FOO, means, e.g. --"
|
||||
"apt-ftp-proxy becomes LH_APT_FTP_PROXY. However, this generally should not "
|
||||
"environment variable. Environment variables are name LB_FOO, means, e.g. --"
|
||||
"apt-ftp-proxy becomes LB_APT_FTP_PROXY. However, this generally should not "
|
||||
"be used."
|
||||
msgstr ""
|
||||
|
||||
|
@ -2675,6 +2675,6 @@ msgstr ""
|
|||
#: en/lb_config.1:434
|
||||
msgid ""
|
||||
"An optional, global configuration file for B<lb config> variables. It is "
|
||||
"useful to specify a few system wide defaults, like LH_MIRROR_BOOTSTRAP. This "
|
||||
"useful to specify a few system wide defaults, like LB_MIRROR_BOOTSTRAP. This "
|
||||
"feature can be false by specifying the B<--ignore-system-defaults> option."
|
||||
msgstr ""
|
||||
|
|
|
@ -334,8 +334,8 @@ msgstr ""
|
|||
|
||||
#: ../helpers/lh_binary_debian-installer:467
|
||||
msgid ""
|
||||
"You selected values of LH_CACHE, LH_CACHE_PACKAGES, LH_CACHE_STAGES and "
|
||||
"LH_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being "
|
||||
"You selected values of LB_CACHE, LB_CACHE_PACKAGES, LB_CACHE_STAGES and "
|
||||
"LB_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being "
|
||||
"cached - these are required when integrating the Debian Installer."
|
||||
msgstr ""
|
||||
|
||||
|
@ -1034,13 +1034,13 @@ msgstr ""
|
|||
msgid ""
|
||||
"You have placed some preseeding files into config/binary_debian-installer "
|
||||
"but you didn't specify the default preseeding file through "
|
||||
"LH_DEBIAN_INSTALLER_PRESEEDFILE. This means that debian-installer will not "
|
||||
"LB_DEBIAN_INSTALLER_PRESEEDFILE. This means that debian-installer will not "
|
||||
"take up a preseeding file by default."
|
||||
msgstr ""
|
||||
|
||||
#: ../functions/defaults.sh:769
|
||||
msgid ""
|
||||
"You selected LH_DISTRIBUTION='etch' and LH_INITRAMFS='live-initramfs' This "
|
||||
"You selected LB_DISTRIBUTION='etch' and LB_INITRAMFS='live-initramfs' This "
|
||||
"is a possible unsafe configuration as live-initramfs is not part of the etch "
|
||||
"distribution. Either make sure that live-initramfs is installable (e.g. "
|
||||
"through setting up etch-backports repository as third-party source or "
|
||||
|
@ -1050,7 +1050,7 @@ msgstr ""
|
|||
|
||||
#: ../functions/defaults.sh:775
|
||||
msgid ""
|
||||
"You selected LH_DISTRIBUTION='etch' and LH_UNION_FILESYSTEM='aufs' This is a "
|
||||
"You selected LB_DISTRIBUTION='etch' and LB_UNION_FILESYSTEM='aufs' This is a "
|
||||
"possible unsafe configuration as aufs is not part of the etch distribution. "
|
||||
"Either make sure that aufs modules for your kernel are installable (e.g. "
|
||||
"through setting up etch-backports repository as third-party source or "
|
||||
|
@ -1059,20 +1059,20 @@ msgid ""
|
|||
msgstr ""
|
||||
|
||||
#: ../functions/defaults.sh:785
|
||||
msgid "You selected LH_PACKAGES_LISTS='%s' and LH_APT='aptitude'"
|
||||
msgid "You selected LB_PACKAGES_LISTS='%s' and LB_APT='aptitude'"
|
||||
msgstr ""
|
||||
|
||||
#: ../functions/defaults.sh:794
|
||||
msgid ""
|
||||
"You have selected values of LH_CACHE, LH_CACHE_PACKAGES, LH_CACHE_STAGES an "
|
||||
"dLH_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being "
|
||||
"You have selected values of LB_CACHE, LB_CACHE_PACKAGES, LB_CACHE_STAGES an "
|
||||
"dLB_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being "
|
||||
"cached. This is a possible unsafe configuration as the bootstrap packages "
|
||||
"are re-used when integrating the Debian Installer."
|
||||
msgstr ""
|
||||
|
||||
#: ../functions/defaults.sh:805
|
||||
msgid ""
|
||||
"You have selected values of LH_BOOTLOADER and LH_BINARY_FILESYSTEM which are "
|
||||
"You have selected values of LB_BOOTLOADER and LB_BINARY_FILESYSTEM which are "
|
||||
"incompatible - syslinux only supports FAT filesystems."
|
||||
msgstr ""
|
||||
|
||||
|
|
|
@ -334,8 +334,8 @@ msgstr ""
|
|||
|
||||
#: ../helpers/lh_binary_debian-installer:467
|
||||
msgid ""
|
||||
"You selected values of LH_CACHE, LH_CACHE_PACKAGES, LH_CACHE_STAGES and "
|
||||
"LH_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being "
|
||||
"You selected values of LB_CACHE, LB_CACHE_PACKAGES, LB_CACHE_STAGES and "
|
||||
"LB_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being "
|
||||
"cached - these are required when integrating the Debian Installer."
|
||||
msgstr ""
|
||||
|
||||
|
@ -1034,13 +1034,13 @@ msgstr ""
|
|||
msgid ""
|
||||
"You have placed some preseeding files into config/binary_debian-installer "
|
||||
"but you didn't specify the default preseeding file through "
|
||||
"LH_DEBIAN_INSTALLER_PRESEEDFILE. This means that debian-installer will not "
|
||||
"LB_DEBIAN_INSTALLER_PRESEEDFILE. This means that debian-installer will not "
|
||||
"take up a preseeding file by default."
|
||||
msgstr ""
|
||||
|
||||
#: ../functions/defaults.sh:769
|
||||
msgid ""
|
||||
"You selected LH_DISTRIBUTION='etch' and LH_INITRAMFS='live-initramfs' This "
|
||||
"You selected LB_DISTRIBUTION='etch' and LB_INITRAMFS='live-initramfs' This "
|
||||
"is a possible unsafe configuration as live-initramfs is not part of the etch "
|
||||
"distribution. Either make sure that live-initramfs is installable (e.g. "
|
||||
"through setting up etch-backports repository as third-party source or "
|
||||
|
@ -1050,7 +1050,7 @@ msgstr ""
|
|||
|
||||
#: ../functions/defaults.sh:775
|
||||
msgid ""
|
||||
"You selected LH_DISTRIBUTION='etch' and LH_UNION_FILESYSTEM='aufs' This is a "
|
||||
"You selected LB_DISTRIBUTION='etch' and LB_UNION_FILESYSTEM='aufs' This is a "
|
||||
"possible unsafe configuration as aufs is not part of the etch distribution. "
|
||||
"Either make sure that aufs modules for your kernel are installable (e.g. "
|
||||
"through setting up etch-backports repository as third-party source or "
|
||||
|
@ -1059,20 +1059,20 @@ msgid ""
|
|||
msgstr ""
|
||||
|
||||
#: ../functions/defaults.sh:785
|
||||
msgid "You selected LH_PACKAGES_LISTS='%s' and LH_APT='aptitude'"
|
||||
msgid "You selected LB_PACKAGES_LISTS='%s' and LB_APT='aptitude'"
|
||||
msgstr ""
|
||||
|
||||
#: ../functions/defaults.sh:794
|
||||
msgid ""
|
||||
"You have selected values of LH_CACHE, LH_CACHE_PACKAGES, LH_CACHE_STAGES an "
|
||||
"dLH_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being "
|
||||
"You have selected values of LB_CACHE, LB_CACHE_PACKAGES, LB_CACHE_STAGES an "
|
||||
"dLB_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being "
|
||||
"cached. This is a possible unsafe configuration as the bootstrap packages "
|
||||
"are re-used when integrating the Debian Installer."
|
||||
msgstr ""
|
||||
|
||||
#: ../functions/defaults.sh:805
|
||||
msgid ""
|
||||
"You have selected values of LH_BOOTLOADER and LH_BINARY_FILESYSTEM which are "
|
||||
"You have selected values of LB_BOOTLOADER and LB_BINARY_FILESYSTEM which are "
|
||||
"incompatible - syslinux only supports FAT filesystems."
|
||||
msgstr ""
|
||||
|
||||
|
|
26
po/pt_BR.po
26
po/pt_BR.po
|
@ -69,12 +69,12 @@ msgstr "Não encontrei cache/packages_bootstrap."
|
|||
|
||||
#: ../helpers/lh_binary_debian-installer:467
|
||||
msgid ""
|
||||
"You selected values of LH_CACHE, LH_CACHE_PACKAGES, LH_CACHE_STAGES and "
|
||||
"LH_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being "
|
||||
"You selected values of LB_CACHE, LB_CACHE_PACKAGES, LB_CACHE_STAGES and "
|
||||
"LB_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being "
|
||||
"cached - these are required when integrating the Debian Installer."
|
||||
msgstr ""
|
||||
"Você selecionou valores para LH_CACHE, LH_CACHE_PACKAGES, LH_CACHE_STAGES e "
|
||||
"LH_DEBIAN_INSTALLER que resultará na não realização de cache dos pacotes de "
|
||||
"Você selecionou valores para LB_CACHE, LB_CACHE_PACKAGES, LB_CACHE_STAGES e "
|
||||
"LB_DEBIAN_INSTALLER que resultará na não realização de cache dos pacotes de "
|
||||
"'bootstrap' - note que estes são requeridos quando há integração com o "
|
||||
"Instalador do Debian."
|
||||
|
||||
|
@ -926,17 +926,17 @@ msgstr "Arquitetura ainda não suportada (FIXME)"
|
|||
msgid ""
|
||||
"You have placed some preseeding files into config/binary_debian-installer "
|
||||
"but you didn't specify the default preseeding file through "
|
||||
"LH_DEBIAN_INSTALLER_PRESEEDFILE. This means that debian-installer will not "
|
||||
"LB_DEBIAN_INSTALLER_PRESEEDFILE. This means that debian-installer will not "
|
||||
"take up a preseeding file by default."
|
||||
msgstr ""
|
||||
"Você colocou alguns arquivos de preseeding dentro de config/binary_debian-"
|
||||
"installer mas você não especificou o arquivo de preseeding padrão através de"
|
||||
"LH_DEBIAN_INSTALLER_PRESEEDFILE. Isso significa que o instalador do "
|
||||
"LB_DEBIAN_INSTALLER_PRESEEDFILE. Isso significa que o instalador do "
|
||||
"Debian não utilizará um arquivo de preseeding por padrão."
|
||||
|
||||
#: ../functions/defaults.sh:769
|
||||
msgid ""
|
||||
"You selected LH_DISTRIBUTION='etch' and LH_INITRAMFS='live-initramfs' This "
|
||||
"You selected LB_DISTRIBUTION='etch' and LB_INITRAMFS='live-initramfs' This "
|
||||
"is a possible unsafe configuration as live-initramfs is not part of the etch "
|
||||
"distribution. Either make sure that live-initramfs is installable (e.g. "
|
||||
"through setting up etch-backports repository as third-party source or "
|
||||
|
@ -946,7 +946,7 @@ msgstr ""
|
|||
|
||||
#: ../functions/defaults.sh:775
|
||||
msgid ""
|
||||
"You selected LH_DISTRIBUTION='etch' and LH_UNION_FILESYSTEM='aufs' This is a "
|
||||
"You selected LB_DISTRIBUTION='etch' and LB_UNION_FILESYSTEM='aufs' This is a "
|
||||
"possible unsafe configuration as aufs is not part of the etch distribution. "
|
||||
"Either make sure that aufs modules for your kernel are installable (e.g. "
|
||||
"through setting up etch-backports repository as third-party source or "
|
||||
|
@ -955,20 +955,20 @@ msgid ""
|
|||
msgstr ""
|
||||
|
||||
#: ../functions/defaults.sh:785
|
||||
msgid "You selected LH_PACKAGES_LISTS='%s' and LH_APT='aptitude'"
|
||||
msgstr "Você selecionou LH_PACKAGES_LISTS='%s' e LH_APT='aptitude'"
|
||||
msgid "You selected LB_PACKAGES_LISTS='%s' and LB_APT='aptitude'"
|
||||
msgstr "Você selecionou LB_PACKAGES_LISTS='%s' e LB_APT='aptitude'"
|
||||
|
||||
#: ../functions/defaults.sh:794
|
||||
msgid ""
|
||||
"You have selected values of LH_CACHE, LH_CACHE_PACKAGES, LH_CACHE_STAGES an "
|
||||
"dLH_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being "
|
||||
"You have selected values of LB_CACHE, LB_CACHE_PACKAGES, LB_CACHE_STAGES an "
|
||||
"dLB_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being "
|
||||
"cached. This is a possible unsafe configuration as the bootstrap packages "
|
||||
"are re-used when integrating the Debian Installer."
|
||||
msgstr ""
|
||||
|
||||
#: ../functions/defaults.sh:805
|
||||
msgid ""
|
||||
"You have selected values of LH_BOOTLOADER and LH_BINARY_FILESYSTEM which are "
|
||||
"You have selected values of LB_BOOTLOADER and LB_BINARY_FILESYSTEM which are "
|
||||
"incompatible - syslinux only supports FAT filesystems."
|
||||
msgstr ""
|
||||
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
#!/bin/sh
|
||||
|
||||
LH_BASE="${LH_BASE:-/usr/share/live/build}"
|
||||
LB_BASE="${LB_BASE:-/usr/share/live/build}"
|
||||
|
||||
# Source global functions
|
||||
for FUNCTION in "${LH_BASE}"/functions/*.sh
|
||||
for FUNCTION in "${LB_BASE}"/functions/*.sh
|
||||
do
|
||||
. "${FUNCTION}"
|
||||
done
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'build binary images')"
|
||||
|
@ -30,7 +30,7 @@ Setup_cleanup
|
|||
# Preparing root filesystem
|
||||
lb binary_chroot ${*}
|
||||
|
||||
if [ "${LH_BUILD_WITH_CHROOT}" = "true" ]
|
||||
if [ "${LB_BUILD_WITH_CHROOT}" = "true" ]
|
||||
then
|
||||
# Configuring chroot
|
||||
lb chroot_devpts install ${*}
|
||||
|
@ -68,7 +68,7 @@ lb binary_local-includes ${*}
|
|||
lb binary_local-hooks ${*}
|
||||
lb binary_checksums ${*}
|
||||
|
||||
if [ "${LH_BUILD_WITH_CHROOT}" != "true" ]
|
||||
if [ "${LB_BUILD_WITH_CHROOT}" != "true" ]
|
||||
then
|
||||
lb chroot_devpts install ${*}
|
||||
lb chroot_proc install ${*}
|
||||
|
@ -83,7 +83,7 @@ lb binary_tar ${*}
|
|||
lb binary_usb ${*}
|
||||
lb binary_virtual-hdd ${*}
|
||||
|
||||
if [ "${LH_BUILD_WITH_CHROOT}" = "true" ]
|
||||
if [ "${LB_BUILD_WITH_CHROOT}" = "true" ]
|
||||
then
|
||||
# Deconfiguring chroot
|
||||
rm -f .stage/chroot_sources
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'create binary checksums')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_CHECKSUMS}" = "none" ] || [ "${LH_BINARY_IMAGES}" = "virtual-hdd" ]
|
||||
if [ "${LB_CHECKSUMS}" = "none" ] || [ "${LB_BINARY_IMAGES}" = "virtual-hdd" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -41,7 +41,7 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
for CHECKSUM in ${LH_CHECKSUMS}
|
||||
for CHECKSUM in ${LB_CHECKSUMS}
|
||||
do
|
||||
Echo_message "Begin creating binary ${CHECKSUM}sum.txt..."
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'copy chroot into chroot')"
|
||||
|
@ -41,9 +41,9 @@ Create_lockfile .lock
|
|||
# Normally, virtual filesystems are not mounted here, but people tend to be lazy
|
||||
if [ -f chroot/proc/version ]
|
||||
then
|
||||
if [ "${LH_USE_FAKEROOT}" != "true" ]
|
||||
if [ "${LB_USE_FAKEROOT}" != "true" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} umount chroot/proc
|
||||
${LB_ROOT_COMMAND} umount chroot/proc
|
||||
else
|
||||
rm -rf chroot/proc
|
||||
mkdir -p chroot/proc
|
||||
|
@ -52,9 +52,9 @@ fi
|
|||
|
||||
if [ -d chroot/sys/kernel ]
|
||||
then
|
||||
if [ "${LH_USE_FAKEROOT}" != "true" ]
|
||||
if [ "${LB_USE_FAKEROOT}" != "true" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} umount chroot/sys
|
||||
${LB_ROOT_COMMAND} umount chroot/sys
|
||||
else
|
||||
rm -rf chroot/sys
|
||||
mkdir -p chroot/sys
|
||||
|
@ -62,18 +62,18 @@ then
|
|||
fi
|
||||
|
||||
# Copying /dev if using fakeroot
|
||||
if [ "${LH_USE_FAKEROOT}" = "true" ]
|
||||
if [ "${LB_USE_FAKEROOT}" = "true" ]
|
||||
then
|
||||
rm -rf chroot/dev
|
||||
find /dev | cpio -dmpu chroot
|
||||
fi
|
||||
|
||||
if [ "${LH_BUILD_WITH_CHROOT}" = "false" ]
|
||||
if [ "${LB_BUILD_WITH_CHROOT}" = "false" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [ "${LH_CACHE}" = "true" ] && Find_files cache/stages_rootfs/filesystem*
|
||||
if [ "${LB_CACHE}" = "true" ] && Find_files cache/stages_rootfs/filesystem*
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -81,25 +81,25 @@ fi
|
|||
Echo_message "This may take a while."
|
||||
|
||||
# Removing old chroot
|
||||
${LH_ROOT_COMMAND} rm -rf chroot/chroot
|
||||
${LH_ROOT_COMMAND} rm -rf chroot.tmp
|
||||
${LB_ROOT_COMMAND} rm -rf chroot/chroot
|
||||
${LB_ROOT_COMMAND} rm -rf chroot.tmp
|
||||
|
||||
# Copying new chroot
|
||||
if [ -d cache/stages_bootstrap ] && [ "${LH_CHROOT_FILESYSTEM}" != "plain" ]
|
||||
if [ -d cache/stages_bootstrap ] && [ "${LB_CHROOT_FILESYSTEM}" != "plain" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} mv chroot chroot.tmp
|
||||
${LH_ROOT_COMMAND} cp -a cache/stages_bootstrap chroot
|
||||
${LH_ROOT_COMMAND} touch chroot/chroot.cache
|
||||
${LB_ROOT_COMMAND} mv chroot chroot.tmp
|
||||
${LB_ROOT_COMMAND} cp -a cache/stages_bootstrap chroot
|
||||
${LB_ROOT_COMMAND} touch chroot/chroot.cache
|
||||
else
|
||||
${LH_ROOT_COMMAND} cp -a chroot chroot.tmp
|
||||
${LB_ROOT_COMMAND} cp -a chroot chroot.tmp
|
||||
fi
|
||||
|
||||
${LH_ROOT_COMMAND} mv chroot.tmp chroot/chroot
|
||||
${LB_ROOT_COMMAND} mv chroot.tmp chroot/chroot
|
||||
|
||||
# Handling chroot excludes
|
||||
if [ -f config/binary_rootfs/excludes ]
|
||||
then
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
cp config/binary_rootfs/excludes chroot/chroot/excludes
|
||||
chroot chroot/chroot /usr/bin/env -i xargs --arg-file=/excludes -I FILE bash -c 'rm -rf FILE'
|
||||
|
@ -114,9 +114,9 @@ then
|
|||
esac
|
||||
fi
|
||||
|
||||
if [ -n "${LH_ROOT_COMMAND}" ]
|
||||
if [ -n "${LB_ROOT_COMMAND}" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
${LB_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
fi
|
||||
|
||||
# Creating stage file
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'install debian-installer into binary')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_BINARY_IMAGES}" = "virtual-hdd" ]
|
||||
if [ "${LB_BINARY_IMAGES}" = "virtual-hdd" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -40,7 +40,7 @@ else
|
|||
fi
|
||||
|
||||
# Check d-i configuration
|
||||
case "${LH_DEBIAN_INSTALLER}" in
|
||||
case "${LB_DEBIAN_INSTALLER}" in
|
||||
true|cdrom|netinst|netboot|businesscard|live)
|
||||
;;
|
||||
|
||||
|
@ -49,7 +49,7 @@ case "${LH_DEBIAN_INSTALLER}" in
|
|||
;;
|
||||
|
||||
*)
|
||||
Echo_error "debian-installer flavour %s not supported." "${LH_DEBIAN_INSTALLER}"
|
||||
Echo_error "debian-installer flavour %s not supported." "${LB_DEBIAN_INSTALLER}"
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
@ -79,9 +79,9 @@ Restore_cache cache/packages_binary
|
|||
Install_package
|
||||
|
||||
# Setting destination directory
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
net)
|
||||
DESTDIR="tftpboot/debian-install/${LH_ARCHITECTURE}"
|
||||
DESTDIR="tftpboot/debian-install/${LB_ARCHITECTURE}"
|
||||
;;
|
||||
|
||||
usb*|tar)
|
||||
|
@ -94,12 +94,12 @@ case "${LH_BINARY_IMAGES}" in
|
|||
esac
|
||||
|
||||
# Set d-i image type
|
||||
case "${LH_DEBIAN_INSTALLER}" in
|
||||
case "${LB_DEBIAN_INSTALLER}" in
|
||||
businesscard|netboot|netinst)
|
||||
DI_IMAGE_TYPE="netboot"
|
||||
;;
|
||||
*)
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
net)
|
||||
DI_IMAGE_TYPE="netboot"
|
||||
;;
|
||||
|
@ -112,15 +112,15 @@ case "${LH_DEBIAN_INSTALLER}" in
|
|||
esac
|
||||
|
||||
# Set architecture-specific variables
|
||||
case "${LH_ARCHITECTURE}" in
|
||||
case "${LB_ARCHITECTURE}" in
|
||||
powerpc)
|
||||
case "${DI_IMAGE_TYPE}" in
|
||||
cdrom)
|
||||
DI_REMOTE_BASE="${LH_ARCHITECTURE}/cdrom"
|
||||
DI_REMOTE_BASE="${LB_ARCHITECTURE}/cdrom"
|
||||
;;
|
||||
|
||||
netboot)
|
||||
DI_REMOTE_BASE="${LH_ARCHITECTURE}/netboot"
|
||||
DI_REMOTE_BASE="${LB_ARCHITECTURE}/netboot"
|
||||
;;
|
||||
esac
|
||||
|
||||
|
@ -129,7 +129,7 @@ case "${LH_ARCHITECTURE}" in
|
|||
;;
|
||||
|
||||
sparc)
|
||||
DEFAULT_FLAVOUR="$(echo ${LH_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DEFAULT_FLAVOUR="$(echo ${LB_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DI_REMOTE_KERNEL="$(basename chroot/boot/vmlinuz-*${DEFAULT_FLAVOUR})"
|
||||
DI_REMOTE_BASE_GTK="none"
|
||||
|
||||
|
@ -138,8 +138,8 @@ case "${LH_ARCHITECTURE}" in
|
|||
*)
|
||||
case "${DI_IMAGE_TYPE}" in
|
||||
netboot)
|
||||
DI_REMOTE_BASE="netboot/debian-installer/${LH_ARCHITECTURE}"
|
||||
DI_REMOTE_BASE_GTK="netboot/gtk/debian-installer/${LH_ARCHITECTURE}"
|
||||
DI_REMOTE_BASE="netboot/debian-installer/${LB_ARCHITECTURE}"
|
||||
DI_REMOTE_BASE_GTK="netboot/gtk/debian-installer/${LB_ARCHITECTURE}"
|
||||
DI_REMOTE_KERNEL="linux"
|
||||
;;
|
||||
|
||||
|
@ -187,35 +187,35 @@ Install_file() {
|
|||
|
||||
# Set absolute directory for caching; we require it when we call Download_file
|
||||
# from a non-standard cwd.
|
||||
_LH_CACHE_DIR="$(pwd)/cache/binary_debian-installer"
|
||||
_LB_CACHE_DIR="$(pwd)/cache/binary_debian-installer"
|
||||
|
||||
Download_file () {
|
||||
local _LH_TARGET
|
||||
_LH_TARGET="${1}"
|
||||
local _LB_TARGET
|
||||
_LB_TARGET="${1}"
|
||||
|
||||
local _LH_URL
|
||||
_LH_URL="${2}"
|
||||
local _LB_URL
|
||||
_LB_URL="${2}"
|
||||
|
||||
_LH_CACHE_FILE="${_LH_CACHE_DIR}/$(echo "${_LH_URL}" | sed 's|/|_|g')"
|
||||
_LB_CACHE_FILE="${_LB_CACHE_DIR}/$(echo "${_LB_URL}" | sed 's|/|_|g')"
|
||||
|
||||
if [ ! -f "${_LH_CACHE_FILE}" ]
|
||||
if [ ! -f "${_LB_CACHE_FILE}" ]
|
||||
then
|
||||
mkdir -p ${_LH_CACHE_DIR}
|
||||
if ! wget ${WGET_OPTIONS} -O "${_LH_CACHE_FILE}" "${_LH_URL}"
|
||||
mkdir -p ${_LB_CACHE_DIR}
|
||||
if ! wget ${WGET_OPTIONS} -O "${_LB_CACHE_FILE}" "${_LB_URL}"
|
||||
then
|
||||
rm -f "${_LH_CACHE_FILE}"
|
||||
rm -f "${_LB_CACHE_FILE}"
|
||||
|
||||
Echo_error "Could not download file: %s" "${_LH_URL}"
|
||||
Echo_error "Could not download file: %s" "${_LB_URL}"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ "$(stat --printf %d "${_LH_CACHE_DIR}")" = "$(stat --printf %d ./)" ]
|
||||
if [ "$(stat --printf %d "${_LB_CACHE_DIR}")" = "$(stat --printf %d ./)" ]
|
||||
then
|
||||
CP_OPTIONS="-l"
|
||||
fi
|
||||
|
||||
cp -f ${CP_OPTIONS} -- "${_LH_CACHE_FILE}" "${_LH_TARGET}"
|
||||
cp -f ${CP_OPTIONS} -- "${_LB_CACHE_FILE}" "${_LB_TARGET}"
|
||||
}
|
||||
|
||||
VMLINUZ_DI="vmlinuz"
|
||||
|
@ -226,14 +226,14 @@ VMLINUZ_GI="gtk/vmlinuz"
|
|||
INITRD_GI="gtk/initrd.gz"
|
||||
DESTDIR_GI="${DESTDIR}/gtk"
|
||||
|
||||
if [ "${LH_DEBIAN_INSTALLER_DISTRIBUTION}" = "daily" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER_DISTRIBUTION}" = "daily" ]
|
||||
then
|
||||
LH_DEBIAN_INSTALLER_DISTRIBUTION="sid"
|
||||
LB_DEBIAN_INSTALLER_DISTRIBUTION="sid"
|
||||
|
||||
# Debian Installer daily builds
|
||||
case "${LH_ARCHITECTURE}" in
|
||||
case "${LB_ARCHITECTURE}" in
|
||||
alpha|amd64|hppa|ia64|mips|mipsel|powerpc)
|
||||
URL="http://d-i.debian.org/daily-images/${LH_ARCHITECTURE}/daily/"
|
||||
URL="http://d-i.debian.org/daily-images/${LB_ARCHITECTURE}/daily/"
|
||||
;;
|
||||
|
||||
arm|armel)
|
||||
|
@ -262,24 +262,24 @@ then
|
|||
;;
|
||||
esac
|
||||
else
|
||||
URL="${LH_MIRROR_DEBIAN_INSTALLER}/dists/${LH_DEBIAN_INSTALLER_DISTRIBUTION}/main/installer-${LH_ARCHITECTURE}/current/images/"
|
||||
URL="${LB_MIRROR_DEBIAN_INSTALLER}/dists/${LB_DEBIAN_INSTALLER_DISTRIBUTION}/main/installer-${LB_ARCHITECTURE}/current/images/"
|
||||
fi
|
||||
|
||||
mkdir -p "${DESTDIR_DI}"
|
||||
|
||||
if [ "${LH_ARCHITECTURE}" = "sparc" ] && [ "${DI_IMAGE_TYPE}" = "netboot" ]
|
||||
if [ "${LB_ARCHITECTURE}" = "sparc" ] && [ "${DI_IMAGE_TYPE}" = "netboot" ]
|
||||
then
|
||||
# There are no prepared kernel/initrd pairs for sparc netboot so we
|
||||
# must unpack them from a mini.iso
|
||||
Download_file mini.iso ${URL}/mini.iso
|
||||
|
||||
mkdir mini.tmp
|
||||
${LH_ROOT_COMMAND} mount -o loop -t iso9660 mini.iso mini.tmp
|
||||
${LB_ROOT_COMMAND} mount -o loop -t iso9660 mini.iso mini.tmp
|
||||
|
||||
cp mini.tmp/boot/vmlinuz-${DEFAULT_FLAVOUR} "${DESTDIR}"/"${VMLINUZ_DI}"
|
||||
cp mini.tmp/boot/initrd.gz "${DESTDIR}"/"${INITRD_DI}"
|
||||
|
||||
${LH_ROOT_COMMAND} umount mini.tmp
|
||||
${LB_ROOT_COMMAND} umount mini.tmp
|
||||
rm -rf mini.tmp mini.iso
|
||||
else
|
||||
# Downloading debian-installer
|
||||
|
@ -288,15 +288,15 @@ else
|
|||
|
||||
# Downloading graphical-installer
|
||||
DOWNLOAD_GTK_INSTALLER=0
|
||||
if [ "${LH_DEBIAN_INSTALLER_GUI}" = "true" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER_GUI}" = "true" ]
|
||||
then
|
||||
case "${LH_ARCHITECTURE}" in
|
||||
case "${LB_ARCHITECTURE}" in
|
||||
amd64|i386)
|
||||
DOWNLOAD_GTK_INSTALLER=1
|
||||
;;
|
||||
|
||||
powerpc)
|
||||
if [ "${LH_DEBIAN_INSTALLER}" = "netboot" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" = "netboot" ]
|
||||
then
|
||||
DOWNLOAD_GTK_INSTALLER=1
|
||||
fi
|
||||
|
@ -321,12 +321,12 @@ then
|
|||
mv chroot/var/lib/dpkg/status chroot/var/lib/dpkg/status.tmp
|
||||
touch chroot/var/lib/dpkg/status
|
||||
|
||||
case "${LH_ARCHITECTURE}" in
|
||||
case "${LB_ARCHITECTURE}" in
|
||||
amd64)
|
||||
#DI_REQ_PACKAGES="lilo grub grub2"
|
||||
DI_REQ_PACKAGES="lilo grub"
|
||||
|
||||
case "${LH_MODE}" in
|
||||
case "${LB_MODE}" in
|
||||
ubuntu)
|
||||
DI_PACKAGES="${DI_REQ_PACKAGES} linux-image-2.6-generic"
|
||||
;;
|
||||
|
@ -341,7 +341,7 @@ then
|
|||
#DI_REQ_PACKAGES="elilo lilo grub grub2"
|
||||
DI_REQ_PACKAGES="elilo lilo grub"
|
||||
|
||||
case "${LH_MODE}" in
|
||||
case "${LB_MODE}" in
|
||||
ubuntu)
|
||||
DI_PACKAGES="${DI_REQ_PACKAGES} linux-image-2.6-generic"
|
||||
;;
|
||||
|
@ -366,9 +366,9 @@ then
|
|||
DI_PACKAGES="${DI_PACKAGES} busybox cryptsetup lvm2"
|
||||
|
||||
# Set apt command prefix
|
||||
_LH_APT_COMMAND="apt-get ${APT_OPTIONS} -o Dir::Cache=/binary.deb -o APT::Install-Recommends=false --download-only"
|
||||
_LB_APT_COMMAND="apt-get ${APT_OPTIONS} -o Dir::Cache=/binary.deb -o APT::Install-Recommends=false --download-only"
|
||||
|
||||
if [ "${LH_DEBIAN_INSTALLER}" = "live" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" = "live" ]
|
||||
then
|
||||
# We don't want to duplicate .debs of packages in binary/pool that are already
|
||||
# installed to target/ via live-installer.
|
||||
|
@ -390,16 +390,16 @@ then
|
|||
done
|
||||
|
||||
# Download .deb's that we just marked as "purged" which caused broken dependencies
|
||||
Chroot chroot ${_LH_APT_COMMAND} -f dist-upgrade
|
||||
Chroot chroot ${_LB_APT_COMMAND} -f dist-upgrade
|
||||
|
||||
# Revert dpkg status file
|
||||
mv chroot/var/lib/dpkg/status.tmp chroot/var/lib/dpkg/status
|
||||
|
||||
# Download .debs of the required packages
|
||||
Chroot chroot ${_LH_APT_COMMAND} install ${DI_REQ_PACKAGES}
|
||||
Chroot chroot ${_LB_APT_COMMAND} install ${DI_REQ_PACKAGES}
|
||||
else
|
||||
# Download .debs of the required packages
|
||||
Chroot chroot ${_LH_APT_COMMAND} install ${DI_PACKAGES}
|
||||
Chroot chroot ${_LB_APT_COMMAND} install ${DI_PACKAGES}
|
||||
|
||||
# Revert dpkg status file
|
||||
mv chroot/var/lib/dpkg/status.tmp chroot/var/lib/dpkg/status
|
||||
|
@ -415,7 +415,7 @@ then
|
|||
done
|
||||
fi
|
||||
|
||||
if [ "${LH_DEBIAN_INSTALLER}" != "live" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" != "live" ]
|
||||
then
|
||||
# Including base debian packages
|
||||
if ls cache/packages_bootstrap/*.deb > /dev/null 2>&1
|
||||
|
@ -426,15 +426,15 @@ then
|
|||
done
|
||||
else
|
||||
Echo_error "Could not find packages in cache/packages_bootstrap."
|
||||
Echo_error "You selected values of LH_CACHE, LH_CACHE_PACKAGES, LH_CACHE_STAGES and LH_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being cached - these are required when integrating the Debian Installer."
|
||||
Echo_error "You selected values of LB_CACHE, LB_CACHE_PACKAGES, LB_CACHE_STAGES and LB_DEBIAN_INSTALLER which will result in 'bootstrap' packages not being cached - these are required when integrating the Debian Installer."
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
# Including local debs
|
||||
if Find_files config/binary_local-debs/*_"${LH_ARCHITECTURE}".deb
|
||||
if Find_files config/binary_local-debs/*_"${LB_ARCHITECTURE}".deb
|
||||
then
|
||||
for FILE in config/binary_local-debs/*_"${LH_ARCHITECTURE}".deb
|
||||
for FILE in config/binary_local-debs/*_"${LB_ARCHITECTURE}".deb
|
||||
do
|
||||
Install_file "${FILE}" "binary/pool/main"
|
||||
done
|
||||
|
@ -449,24 +449,24 @@ then
|
|||
fi
|
||||
|
||||
# Generating deb indices
|
||||
mkdir -p binary/dists/${LH_DEBIAN_INSTALLER_DISTRIBUTION}/main/binary-${LH_ARCHITECTURE}
|
||||
mkdir -p binary/dists/${LB_DEBIAN_INSTALLER_DISTRIBUTION}/main/binary-${LB_ARCHITECTURE}
|
||||
|
||||
mv binary chroot/root
|
||||
echo "cd /root/binary && apt-ftparchive packages pool/main > dists/${LH_DEBIAN_INSTALLER_DISTRIBUTION}/main/binary-${LH_ARCHITECTURE}/Packages" > chroot/binary.sh
|
||||
echo "cd /root/binary && apt-ftparchive packages pool/main > dists/${LB_DEBIAN_INSTALLER_DISTRIBUTION}/main/binary-${LB_ARCHITECTURE}/Packages" > chroot/binary.sh
|
||||
Chroot chroot "sh binary.sh"
|
||||
rm -f chroot/binary.sh
|
||||
mv chroot/root/binary ./
|
||||
|
||||
gzip -9 -c binary/dists/${LH_DEBIAN_INSTALLER_DISTRIBUTION}/main/binary-${LH_ARCHITECTURE}/Packages > binary/dists/${LH_DEBIAN_INSTALLER_DISTRIBUTION}/main/binary-${LH_ARCHITECTURE}/Packages.gz
|
||||
gzip -9 -c binary/dists/${LB_DEBIAN_INSTALLER_DISTRIBUTION}/main/binary-${LB_ARCHITECTURE}/Packages > binary/dists/${LB_DEBIAN_INSTALLER_DISTRIBUTION}/main/binary-${LB_ARCHITECTURE}/Packages.gz
|
||||
|
||||
# Fetching release
|
||||
Download_file binary/dists/${LH_DEBIAN_INSTALLER_DISTRIBUTION}/main/binary-${LH_ARCHITECTURE}/Release "${LH_MIRROR_CHROOT}"/dists/"${LH_DEBIAN_INSTALLER_DISTRIBUTION}"/main/binary-"${LH_ARCHITECTURE}"/Release
|
||||
Download_file binary/dists/${LB_DEBIAN_INSTALLER_DISTRIBUTION}/main/binary-${LB_ARCHITECTURE}/Release "${LB_MIRROR_CHROOT}"/dists/"${LB_DEBIAN_INSTALLER_DISTRIBUTION}"/main/binary-"${LB_ARCHITECTURE}"/Release
|
||||
|
||||
mkdir binary.udeb
|
||||
cd binary.udeb
|
||||
|
||||
# Downloading udeb indices
|
||||
Download_file Packages.gz "${LH_MIRROR_CHROOT}"/dists/"${LH_DEBIAN_INSTALLER_DISTRIBUTION}"/main/debian-installer/binary-"${LH_ARCHITECTURE}"/Packages.gz
|
||||
Download_file Packages.gz "${LB_MIRROR_CHROOT}"/dists/"${LB_DEBIAN_INSTALLER_DISTRIBUTION}"/main/debian-installer/binary-"${LB_ARCHITECTURE}"/Packages.gz
|
||||
gunzip -c Packages.gz > Packages
|
||||
|
||||
# Sorting udebs
|
||||
|
@ -481,7 +481,7 @@ then
|
|||
cp ../cache/packages_debian-installer.udeb/"$(basename ${UDEB})" ./
|
||||
else
|
||||
# Downloading udebs
|
||||
wget ${WGET_OPTIONS} "${LH_MIRROR_CHROOT}"/${UDEB}
|
||||
wget ${WGET_OPTIONS} "${LB_MIRROR_CHROOT}"/${UDEB}
|
||||
fi
|
||||
done
|
||||
|
||||
|
@ -491,9 +491,9 @@ then
|
|||
cp *.udeb ../cache/packages_debian-installer.udeb
|
||||
|
||||
# Including local udebs
|
||||
if Find_files ../config/binary_local-udebs/*_"${LH_ARCHITECTURE}".udeb
|
||||
if Find_files ../config/binary_local-udebs/*_"${LB_ARCHITECTURE}".udeb
|
||||
then
|
||||
for FILE in ../config/binary_local-udebs/*_"${LH_ARCHITECTURE}".udeb
|
||||
for FILE in ../config/binary_local-udebs/*_"${LB_ARCHITECTURE}".udeb
|
||||
do
|
||||
Install_file "${FILE}" "pool/main"
|
||||
|
||||
|
@ -514,9 +514,9 @@ then
|
|||
fi
|
||||
|
||||
# Excluding udebs
|
||||
grep -v "^#" "${LH_BASE}"/data/debian-cd/"${LH_DEBIAN_INSTALLER_DISTRIBUTION}"/udeb_exclude > exclude || true
|
||||
grep -v "^#" "${LH_BASE}"/data/debian-cd/"${LH_DEBIAN_INSTALLER_DISTRIBUTION}"/exclude-udebs >> exclude || true
|
||||
grep -v "^#" "${LH_BASE}"/data/debian-cd/"${LH_DEBIAN_INSTALLER_DISTRIBUTION}"/exclude-udebs-${LH_ARCHITECTURE} >> exclude || true
|
||||
grep -v "^#" "${LB_BASE}"/data/debian-cd/"${LB_DEBIAN_INSTALLER_DISTRIBUTION}"/udeb_exclude > exclude || true
|
||||
grep -v "^#" "${LB_BASE}"/data/debian-cd/"${LB_DEBIAN_INSTALLER_DISTRIBUTION}"/exclude-udebs >> exclude || true
|
||||
grep -v "^#" "${LB_BASE}"/data/debian-cd/"${LB_DEBIAN_INSTALLER_DISTRIBUTION}"/exclude-udebs-${LB_ARCHITECTURE} >> exclude || true
|
||||
|
||||
# Local exclude file
|
||||
if [ -e ../config/binary_debian-installer/udeb_exclude ]
|
||||
|
@ -529,7 +529,7 @@ then
|
|||
|
||||
while read EXCLUDE
|
||||
do
|
||||
if [ "${LH_DEBIAN_INSTALLER}" = "live" ] && [ "${EXCLUDE}" = "live-installer" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" = "live" ] && [ "${EXCLUDE}" = "live-installer" ]
|
||||
then
|
||||
continue
|
||||
fi
|
||||
|
@ -538,7 +538,7 @@ then
|
|||
done < exclude
|
||||
|
||||
# Enable live-installer
|
||||
if [ "${LH_DEBIAN_INSTALLER}" = "live" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" = "live" ]
|
||||
then
|
||||
# Remove local udebs
|
||||
rm -f pool/main/b/base-installer/bootstrap-base_*.udeb
|
||||
|
@ -558,17 +558,17 @@ then
|
|||
done
|
||||
|
||||
# Creating udeb indices
|
||||
mkdir -p dists/"${LH_DEBIAN_INSTALLER_DISTRIBUTION}"/main/debian-installer/binary-"${LH_ARCHITECTURE}"
|
||||
mkdir -p dists/"${LB_DEBIAN_INSTALLER_DISTRIBUTION}"/main/debian-installer/binary-"${LB_ARCHITECTURE}"
|
||||
cd "${OLDPWD}"
|
||||
|
||||
mv binary.udeb chroot/root
|
||||
echo "cd /root/binary.udeb && apt-ftparchive packages pool/main > dists/${LH_DEBIAN_INSTALLER_DISTRIBUTION}/main/debian-installer/binary-${LH_ARCHITECTURE}/Packages" > chroot/binary.sh
|
||||
echo "cd /root/binary.udeb && apt-ftparchive packages pool/main > dists/${LB_DEBIAN_INSTALLER_DISTRIBUTION}/main/debian-installer/binary-${LB_ARCHITECTURE}/Packages" > chroot/binary.sh
|
||||
Chroot chroot "sh binary.sh"
|
||||
rm -f chroot/binary.sh
|
||||
mv chroot/root/binary.udeb ./
|
||||
|
||||
cd binary.udeb
|
||||
gzip -9 -c dists/${LH_DEBIAN_INSTALLER_DISTRIBUTION}/main/debian-installer/binary-${LH_ARCHITECTURE}/Packages > dists/${LH_DEBIAN_INSTALLER_DISTRIBUTION}/main/debian-installer/binary-${LH_ARCHITECTURE}/Packages.gz
|
||||
gzip -9 -c dists/${LB_DEBIAN_INSTALLER_DISTRIBUTION}/main/debian-installer/binary-${LB_ARCHITECTURE}/Packages > dists/${LB_DEBIAN_INSTALLER_DISTRIBUTION}/main/debian-installer/binary-${LB_ARCHITECTURE}/Packages.gz
|
||||
|
||||
rm -f Packages* exclude
|
||||
find . | cpio -dmpu "${OLDPWD}"/binary
|
||||
|
@ -584,14 +584,14 @@ cat > chroot/binary.sh << EOF
|
|||
cd /root/binary && apt-ftparchive \
|
||||
-o APT::FTPArchive::Release::Origin="Debian" \
|
||||
-o APT::FTPArchive::Release::Label="Debian" \
|
||||
-o APT::FTPArchive::Release::Suite="${LH_DEBIAN_INSTALLER_DISTRIBUTION}" \
|
||||
-o APT::FTPArchive::Release::Suite="${LB_DEBIAN_INSTALLER_DISTRIBUTION}" \
|
||||
-o APT::FTPArchive::Release::Version="4.0" \
|
||||
-o APT::FTPArchive::Release::Codename="${LH_DEBIAN_INSTALLER_DISTRIBUTION}" \
|
||||
-o APT::FTPArchive::Release::Codename="${LB_DEBIAN_INSTALLER_DISTRIBUTION}" \
|
||||
-o APT::FTPArchive::Release::Date="$(date -R)" \
|
||||
-o APT::FTPArchive::Release::Architectures="${LH_ARCHITECTURE}" \
|
||||
-o APT::FTPArchive::Release::Architectures="${LB_ARCHITECTURE}" \
|
||||
-o APT::FTPArchive::Release::Components="main" \
|
||||
-o APT::FTPArchive::Release::Description="Last updated: $(date -R)" \
|
||||
release dists/${LH_DEBIAN_INSTALLER_DISTRIBUTION} > dists/${LH_DEBIAN_INSTALLER_DISTRIBUTION}/Release
|
||||
release dists/${LB_DEBIAN_INSTALLER_DISTRIBUTION} > dists/${LB_DEBIAN_INSTALLER_DISTRIBUTION}/Release
|
||||
EOF
|
||||
|
||||
Chroot chroot "sh binary.sh"
|
||||
|
@ -601,10 +601,10 @@ EOF
|
|||
# Creating dist symlinks
|
||||
for DISTRIBUTION in frozen stable testing unstable
|
||||
do
|
||||
ln -s ${LH_DEBIAN_INSTALLER_DISTRIBUTION} binary/dists/${DISTRIBUTION}
|
||||
ln -s ${LB_DEBIAN_INSTALLER_DISTRIBUTION} binary/dists/${DISTRIBUTION}
|
||||
done
|
||||
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
usb*)
|
||||
;;
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'install disk information into binary')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
iso*|usb*)
|
||||
;;
|
||||
*)
|
||||
|
@ -48,13 +48,13 @@ Create_lockfile .lock
|
|||
|
||||
mkdir -p binary/.disk
|
||||
|
||||
ARCHITECTURE="$(echo ${LH_ARCHITECTURE} | sed -e 's| |/|g')"
|
||||
DISTRIBUTION="$(echo ${LH_DISTRIBUTION} | cut -b 1 | tr '[a-z]' '[A-Z]')"
|
||||
DISTRIBUTION="${DISTRIBUTION}$(echo ${LH_DISTRIBUTION} | cut -b 2-)"
|
||||
eval VERSION="$`echo RELEASE_${LH_DISTRIBUTION}`"
|
||||
ARCHITECTURE="$(echo ${LB_ARCHITECTURE} | sed -e 's| |/|g')"
|
||||
DISTRIBUTION="$(echo ${LB_DISTRIBUTION} | cut -b 1 | tr '[a-z]' '[A-Z]')"
|
||||
DISTRIBUTION="${DISTRIBUTION}$(echo ${LB_DISTRIBUTION} | cut -b 2-)"
|
||||
eval VERSION="$`echo RELEASE_${LB_DISTRIBUTION}`"
|
||||
|
||||
TITLE="Debian GNU/Linux"
|
||||
case "${LH_MODE}" in
|
||||
case "${LB_MODE}" in
|
||||
debian)
|
||||
STRING="Official Snapshot ${ARCHITECTURE}"
|
||||
TRACE="project/trace/ftp-master.debian.org"
|
||||
|
@ -79,11 +79,11 @@ esac
|
|||
|
||||
if [ -n "${TRACE}" ]
|
||||
then
|
||||
echo "$(wget -q ${LH_MIRROR_BOOTSTRAP}/${TRACE} -O - | head -n 1)" \
|
||||
echo "$(wget -q ${LB_MIRROR_BOOTSTRAP}/${TRACE} -O - | head -n 1)" \
|
||||
> binary/.disk/archive_trace
|
||||
fi
|
||||
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
for INITRD in binary/casper/initrd.img*
|
||||
do
|
||||
|
@ -105,7 +105,7 @@ case "${LH_INITRAMFS}" in
|
|||
;;
|
||||
esac
|
||||
|
||||
case "${LH_DEBIAN_INSTALLER}" in
|
||||
case "${LB_DEBIAN_INSTALLER}" in
|
||||
cdrom)
|
||||
echo "main" > binary/.disk/base_components
|
||||
|
||||
|
@ -115,7 +115,7 @@ case "${LH_DEBIAN_INSTALLER}" in
|
|||
|
||||
echo "${TITLE} ${VERSION} \"${DISTRIBUTION}\" - ${STRING} LIVE/CD Binary $(date +%Y%m%d-%H:%M)" > binary/.disk/info
|
||||
|
||||
cp "${LH_BASE}"/data/debian-cd/${LH_DISTRIBUTION}/${LH_ARCHITECTURE}_udeb_include binary/.disk/udeb_include
|
||||
cp "${LB_BASE}"/data/debian-cd/${LB_DISTRIBUTION}/${LB_ARCHITECTURE}_udeb_include binary/.disk/udeb_include
|
||||
;;
|
||||
|
||||
true|netinst|live)
|
||||
|
@ -125,7 +125,7 @@ case "${LH_DEBIAN_INSTALLER}" in
|
|||
|
||||
echo "not_complete" > binary/.disk/cd_type
|
||||
|
||||
if [ "${LH_DEBIAN_INSTALLER}" = "live" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" = "live" ]
|
||||
then
|
||||
echo "${TITLE} ${VERSION} \"${DISTRIBUTION}\" - ${STRING} LIVE/INSTALL Binary $(date +%Y%m%d-%H:%M)" > binary/.disk/info
|
||||
else
|
||||
|
@ -133,9 +133,9 @@ case "${LH_DEBIAN_INSTALLER}" in
|
|||
|
||||
fi
|
||||
|
||||
cp "${LH_BASE}"/data/debian-cd/${LH_DISTRIBUTION}/${LH_ARCHITECTURE}_netinst_udeb_include binary/.disk/udeb_include
|
||||
cp "${LB_BASE}"/data/debian-cd/${LB_DISTRIBUTION}/${LB_ARCHITECTURE}_netinst_udeb_include binary/.disk/udeb_include
|
||||
|
||||
if [ "${LH_DEBIAN_INSTALLER}" = "live" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" = "live" ]
|
||||
then
|
||||
echo "live-installer" >> binary/.disk/udeb_include
|
||||
fi
|
||||
|
@ -148,7 +148,7 @@ case "${LH_DEBIAN_INSTALLER}" in
|
|||
|
||||
echo "${TITLE} ${VERSION} \"${DISTRIBUTION}\" - ${STRING} LIVE/BC Binary $(date +%Y%m%d-%H:%M)" > binary/.disk/info
|
||||
|
||||
cp "${LH_BASE}"/data/debian-cd/${LH_DISTRIBUTION}/${LH_ARCHITECTURE}_businesscard_udeb_include binary/.disk/udeb_include
|
||||
cp "${LB_BASE}"/data/debian-cd/${LB_DISTRIBUTION}/${LB_ARCHITECTURE}_businesscard_udeb_include binary/.disk/udeb_include
|
||||
;;
|
||||
|
||||
false)
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'encrypts rootfs')"
|
||||
|
@ -24,29 +24,29 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_BINARY_IMAGES}" = "virtual-hdd" ]
|
||||
if [ "${LB_BINARY_IMAGES}" = "virtual-hdd" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
case "${LH_ENCRYPTION}" in
|
||||
case "${LB_ENCRYPTION}" in
|
||||
aes128|aes192|aes256)
|
||||
;;
|
||||
""|false)
|
||||
exit 0
|
||||
;;
|
||||
*)
|
||||
Echo_error "Encryption type %s not supported." "${LH_ENCRYPTION}"
|
||||
Echo_error "Encryption type %s not supported." "${LB_ENCRYPTION}"
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
case "${LH_CHROOT_FILESYSTEM}" in
|
||||
case "${LB_CHROOT_FILESYSTEM}" in
|
||||
ext2|squashfs)
|
||||
;;
|
||||
|
||||
*)
|
||||
Echo_error "Encryption not yet supported on %s filesystems." "${LH_CHROOT_FILESYSTEM}"
|
||||
Echo_error "Encryption not yet supported on %s filesystems." "${LB_CHROOT_FILESYSTEM}"
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
@ -65,7 +65,7 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
INITFS="casper"
|
||||
;;
|
||||
|
@ -84,12 +84,12 @@ Restore_cache cache/packages_binary
|
|||
# Installing depends
|
||||
Install_package
|
||||
|
||||
Echo_message "Encrypting binary/%s/filesystem.%s with %s..." "${INITFS}" "${LH_CHROOT_FILESYSTEM}" "${LH_ENCRYPTION}"
|
||||
Echo_message "Encrypting binary/%s/filesystem.%s with %s..." "${INITFS}" "${LB_CHROOT_FILESYSTEM}" "${LB_ENCRYPTION}"
|
||||
|
||||
if [ "${LH_BUILD_WITH_CHROOT}" = "true" ]
|
||||
if [ "${LB_BUILD_WITH_CHROOT}" = "true" ]
|
||||
then
|
||||
# Moving image
|
||||
mv binary/${INITFS}/filesystem.${LH_CHROOT_FILESYSTEM} chroot
|
||||
mv binary/${INITFS}/filesystem.${LB_CHROOT_FILESYSTEM} chroot
|
||||
fi
|
||||
|
||||
while true
|
||||
|
@ -101,22 +101,22 @@ do
|
|||
Echo " (Passwords must be at least 20 characters long)"
|
||||
echo
|
||||
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
if Chroot chroot aespipe -e ${LH_ENCRYPTION} -T \
|
||||
< chroot/filesystem.${LH_CHROOT_FILESYSTEM} \
|
||||
> chroot/filesystem.${LH_CHROOT_FILESYSTEM}.tmp
|
||||
if Chroot chroot aespipe -e ${LB_ENCRYPTION} -T \
|
||||
< chroot/filesystem.${LB_CHROOT_FILESYSTEM} \
|
||||
> chroot/filesystem.${LB_CHROOT_FILESYSTEM}.tmp
|
||||
then
|
||||
mv chroot/filesystem.${LH_CHROOT_FILESYSTEM}.tmp binary/${INITFS}/filesystem.${LH_CHROOT_FILESYSTEM}
|
||||
mv chroot/filesystem.${LB_CHROOT_FILESYSTEM}.tmp binary/${INITFS}/filesystem.${LB_CHROOT_FILESYSTEM}
|
||||
break
|
||||
fi
|
||||
;;
|
||||
false)
|
||||
if aespipe -e ${LH_ENCRYPTION} -T \
|
||||
< binary/${INITFS}/filesystem.${LH_CHROOT_FILESYSTEM} \
|
||||
> binary/${INITFS}/filesystem.${LH_CHROOT_FILESYSTEM}.tmp
|
||||
if aespipe -e ${LB_ENCRYPTION} -T \
|
||||
< binary/${INITFS}/filesystem.${LB_CHROOT_FILESYSTEM} \
|
||||
> binary/${INITFS}/filesystem.${LB_CHROOT_FILESYSTEM}.tmp
|
||||
then
|
||||
mv binary/${INITFS}/filesystem.${LH_CHROOT_FILESYSTEM}.tmp binary/${INITFS}/filesystem.${LH_CHROOT_FILESYSTEM}
|
||||
mv binary/${INITFS}/filesystem.${LB_CHROOT_FILESYSTEM}.tmp binary/${INITFS}/filesystem.${LB_CHROOT_FILESYSTEM}
|
||||
break
|
||||
fi
|
||||
;;
|
||||
|
@ -133,9 +133,9 @@ do
|
|||
done
|
||||
|
||||
# Cleanup temporary filesystems
|
||||
rm -f chroot/filesystem.${LH_CHROOT_FILESYSTEM}
|
||||
rm -f chroot/filesystem.${LH_CHROOT_FILESYSTEM}.tmp
|
||||
rm -f binary/${INITFS}/filesystem.${LH_CHROOT_FILESYSTEM}.tmp
|
||||
rm -f chroot/filesystem.${LB_CHROOT_FILESYSTEM}
|
||||
rm -f chroot/filesystem.${LB_CHROOT_FILESYSTEM}.tmp
|
||||
rm -f binary/${INITFS}/filesystem.${LB_CHROOT_FILESYSTEM}.tmp
|
||||
|
||||
# Saving cache
|
||||
Save_cache cache/packages_binary
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'installs grub into binary')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_BOOTLOADER}" != "grub" ]
|
||||
if [ "${LB_BOOTLOADER}" != "grub" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -68,7 +68,7 @@ Grub_live_entry ()
|
|||
APPEND="${4}"
|
||||
|
||||
LINUX_LIVE="${LINUX_LIVE}\ntitle\t\tDebian GNU/Linux - ${LABEL}"
|
||||
LINUX_LIVE="${LINUX_LIVE}\nkernel\t\t/${KERNEL} boot=${INITFS} live-config LH_BOOTAPPEND_LIVE ${APPEND}"
|
||||
LINUX_LIVE="${LINUX_LIVE}\nkernel\t\t/${KERNEL} boot=${INITFS} live-config LB_BOOTAPPEND_LIVE ${APPEND}"
|
||||
LINUX_LIVE="${LINUX_LIVE}\ninitrd\t\t/${INITRD}"
|
||||
}
|
||||
|
||||
|
@ -112,12 +112,12 @@ Grub_install_entry ()
|
|||
|
||||
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\ntitle\t\t${LABEL} ${TYPE}"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\nkernel\t\t/${KERNEL} ${TAPPEND} ${LH_BOOTAPPEND_INSTALL}"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\nkernel\t\t/${KERNEL} ${TAPPEND} ${LB_BOOTAPPEND_INSTALL}"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\ninitrd\t\t/${INITRD}"
|
||||
done
|
||||
}
|
||||
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
INITFS="casper"
|
||||
;;
|
||||
|
@ -128,9 +128,9 @@ case "${LH_INITRAMFS}" in
|
|||
esac
|
||||
|
||||
# Setting destination directory
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
iso*|tar)
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
DESTDIR_LIVE="binary/casper"
|
||||
;;
|
||||
|
@ -157,62 +157,62 @@ mkdir -p "${DESTDIR_LIVE}"
|
|||
|
||||
# Setting boot parameters
|
||||
|
||||
case "${LH_ENCRYPTION}" in
|
||||
case "${LB_ENCRYPTION}" in
|
||||
""|false)
|
||||
;;
|
||||
*)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} encryption=${LH_ENCRYPTION}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} encryption=${LB_ENCRYPTION}"
|
||||
esac
|
||||
|
||||
if [ -n "${LH_USERNAME}" ]
|
||||
if [ -n "${LB_USERNAME}" ]
|
||||
then
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} username=${LH_USERNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} username=${LB_USERNAME}"
|
||||
;;
|
||||
|
||||
live-initramfs|live-boot)
|
||||
if [ "${LH_USERNAME}" != "user" ]
|
||||
if [ "${LB_USERNAME}" != "user" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} username=${LH_USERNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} username=${LB_USERNAME}"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
if [ -n "${LH_HOSTNAME}" ]
|
||||
if [ -n "${LB_HOSTNAME}" ]
|
||||
then
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} hostname=${LH_HOSTNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} hostname=${LB_HOSTNAME}"
|
||||
;;
|
||||
|
||||
live-initramfs|live-boot)
|
||||
if [ "${LH_HOSTNAME}" != "debian" ]
|
||||
if [ "${LB_HOSTNAME}" != "debian" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} hostname=${LH_HOSTNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} hostname=${LB_HOSTNAME}"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
if [ "${LH_UNION_FILESYSTEM}" != "aufs" ]
|
||||
if [ "${LB_UNION_FILESYSTEM}" != "aufs" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} union=${LH_UNION_FILESYSTEM}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} union=${LB_UNION_FILESYSTEM}"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_NET_COW_PATH}" ]
|
||||
if [ -n "${LB_NET_COW_PATH}" ]
|
||||
then
|
||||
Echo_error "Net cow not yet supported on grub"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ "${LH_EXPOSED_ROOT}" != "false" ]
|
||||
if [ "${LB_EXPOSED_ROOT}" != "false" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} exposedroot"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} exposedroot"
|
||||
fi
|
||||
|
||||
LH_BOOTAPPEND_LIVE="$(echo ${LH_BOOTAPPEND_LIVE} | sed -e 's| ||')"
|
||||
LB_BOOTAPPEND_LIVE="$(echo ${LB_BOOTAPPEND_LIVE} | sed -e 's| ||')"
|
||||
|
||||
# Parameters are listed at: linux/Documentation/kernel-parameters.txt
|
||||
FAILSAFE="noapic noapm nodma nomce nolapic nomodeset nosmp vga=normal"
|
||||
|
@ -220,7 +220,7 @@ FAILSAFE="noapic noapm nodma nomce nolapic nomodeset nosmp vga=normal"
|
|||
# Assembling kernel configuration
|
||||
|
||||
# Default entries
|
||||
DEFAULT_FLAVOUR="$(echo ${LH_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DEFAULT_FLAVOUR="$(echo ${LB_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DEFAULT_KERNEL="$(basename chroot/boot/vmlinuz-*${DEFAULT_FLAVOUR})"
|
||||
DEFAULT_INITRD="initrd.img-$(echo ${DEFAULT_KERNEL} | sed -e 's|vmlinuz-||')"
|
||||
|
||||
|
@ -238,7 +238,7 @@ done
|
|||
LINUX_LIVE="$(/bin/echo ${LINUX_LIVE} | sed -e 's|binary||g' -e 's|//|/|g')"
|
||||
|
||||
# Assembling debian-installer configuration
|
||||
if [ "${LH_DEBIAN_INSTALLER}" != "false" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" != "false" ]
|
||||
then
|
||||
LINUX_LIVE="title\t\tLive:\nroot\n\n${LINUX_LIVE}"
|
||||
LINUX_INSTALL="title\t\tInstaller:\nroot"
|
||||
|
@ -268,7 +268,7 @@ LINUX_INSTALL="$(/bin/echo ${LINUX_INSTALL} | sed -e 's|binary||g' -e 's|//|/|g'
|
|||
if [ -f "${DESTDIR_LIVE}"/memtest ]
|
||||
then
|
||||
MEMTEST="title\t\tOther:\nroot"
|
||||
MEMTEST="${MEMTEST}\n\ntitle\t\t${LH_MEMTEST}\nkernel\t\t/$(basename ${DESTDIR_LIVE})/memtest"
|
||||
MEMTEST="${MEMTEST}\n\ntitle\t\t${LB_MEMTEST}\nkernel\t\t/$(basename ${DESTDIR_LIVE})/memtest"
|
||||
MEMTEST="$(/bin/echo ${MEMTEST} | sed -e 's|//|/|g')"
|
||||
fi
|
||||
|
||||
|
@ -276,7 +276,7 @@ fi
|
|||
mkdir -p binary/boot/grub
|
||||
cp -r "${TEMPLATES}"/* binary/boot/grub
|
||||
|
||||
case ${LH_BINARY_IMAGES} in
|
||||
case ${LB_BINARY_IMAGES} in
|
||||
iso*)
|
||||
FILES="chroot/usr/lib/grub/*/stage2_eltorito"
|
||||
;;
|
||||
|
@ -286,7 +286,7 @@ case ${LH_BINARY_IMAGES} in
|
|||
;;
|
||||
esac
|
||||
|
||||
if [ "${LH_BUILD_WITH_CHROOT}" = "false" ]
|
||||
if [ "${LB_BUILD_WITH_CHROOT}" = "false" ]
|
||||
then
|
||||
FILES="$(echo ${FILES} | sed -e 's|chroot||g')"
|
||||
fi
|
||||
|
@ -303,15 +303,15 @@ fi
|
|||
# Copying splash screen
|
||||
if [ -f config/binary_grub/splash.xpm.gz ]
|
||||
then
|
||||
LH_GRUB_SPLASH="config/binary_grub/splash.xpm.gz"
|
||||
LB_GRUB_SPLASH="config/binary_grub/splash.xpm.gz"
|
||||
elif [ -f config/binary_grub/splash.xpm ]
|
||||
then
|
||||
LH_GRUB_SPLASH="config/binary_grub/splash.xpm"
|
||||
LB_GRUB_SPLASH="config/binary_grub/splash.xpm"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_GRUB_SPLASH}" ]
|
||||
if [ -n "${LB_GRUB_SPLASH}" ]
|
||||
then
|
||||
if [ "${LH_GRUB_SPLASH}" = "none" ]
|
||||
if [ "${LB_GRUB_SPLASH}" = "none" ]
|
||||
then
|
||||
# Removing splash file
|
||||
rm -f binary/boot/grub/splash.xpm.gz
|
||||
|
@ -320,13 +320,13 @@ then
|
|||
sed -i -e "s|splashimage.*||" binary/boot/grub/menu.lst
|
||||
else
|
||||
# Overwriting splash file
|
||||
cp -f "${LH_GRUB_SPLASH}" binary/boot/grub
|
||||
sed -i -e "s|splashimage.*|splashimage /boot/grub/$(basename ${LH_GRUB_SPLASH})|" binary/boot/grub/menu.lst
|
||||
cp -f "${LB_GRUB_SPLASH}" binary/boot/grub
|
||||
sed -i -e "s|splashimage.*|splashimage /boot/grub/$(basename ${LB_GRUB_SPLASH})|" binary/boot/grub/menu.lst
|
||||
fi
|
||||
fi
|
||||
|
||||
sed -i -e "s|LINUX_LIVE|${LINUX_LIVE}|" -e "s|LINUX_INSTALL|${LINUX_INSTALL}|" -e "s|MEMTEST|${MEMTEST}|" binary/boot/grub/menu.lst
|
||||
sed -i -e "s|LH_BOOTAPPEND_INSTALL|${LH_BOOTAPPEND_INSTALL}|" -e "s|LH_BOOTAPPEND_LIVE|${LH_BOOTAPPEND_LIVE}|" binary/boot/grub/menu.lst
|
||||
sed -i -e "s|LB_BOOTAPPEND_INSTALL|${LB_BOOTAPPEND_INSTALL}|" -e "s|LB_BOOTAPPEND_LIVE|${LB_BOOTAPPEND_LIVE}|" binary/boot/grub/menu.lst
|
||||
|
||||
sed -i -e 's|\ $||g' binary/boot/grub/menu.lst
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'installs grub2 into binary')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_BOOTLOADER}" != "grub2" ]
|
||||
if [ "${LB_BOOTLOADER}" != "grub2" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -68,7 +68,7 @@ Grub_live_entry ()
|
|||
APPEND="${4}"
|
||||
|
||||
LINUX_LIVE="${LINUX_LIVE}\nmenuentry \"Debian GNU/Linux - ${LABEL}\" {"
|
||||
LINUX_LIVE="${LINUX_LIVE}\nlinux\t\t/${KERNEL} boot=${INITFS} live-config LH_BOOTAPPEND_LIVE ${APPEND}"
|
||||
LINUX_LIVE="${LINUX_LIVE}\nlinux\t\t/${KERNEL} boot=${INITFS} live-config LB_BOOTAPPEND_LIVE ${APPEND}"
|
||||
LINUX_LIVE="${LINUX_LIVE}\ninitrd\t\t/${INITRD}"
|
||||
LINUX_LIVE="${LINUX_LIVE}\n}"
|
||||
}
|
||||
|
@ -86,12 +86,12 @@ Grub_install_entry ()
|
|||
fi
|
||||
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\nmenuentry \"Debian GNU/Linux - ${LABEL}\" {"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\nlinux\t\t/${KERNEL} ${APPEND} LH_BOOTAPPEND_INSTALL"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\nlinux\t\t/${KERNEL} ${APPEND} LB_BOOTAPPEND_INSTALL"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\ninitrd\t\t/${INITRD}"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\n}"
|
||||
}
|
||||
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
INITFS="casper"
|
||||
;;
|
||||
|
@ -102,9 +102,9 @@ case "${LH_INITRAMFS}" in
|
|||
esac
|
||||
|
||||
# Setting destination directory
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
iso*|tar)
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
DESTDIR_LIVE="binary/casper"
|
||||
;;
|
||||
|
@ -131,62 +131,62 @@ mkdir -p "${DESTDIR_LIVE}"
|
|||
|
||||
# Setting boot parameters
|
||||
|
||||
case "${LH_ENCRYPTION}" in
|
||||
case "${LB_ENCRYPTION}" in
|
||||
""|false)
|
||||
;;
|
||||
*)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} encryption=${LH_ENCRYPTION}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} encryption=${LB_ENCRYPTION}"
|
||||
esac
|
||||
|
||||
if [ -n "${LH_USERNAME}" ]
|
||||
if [ -n "${LB_USERNAME}" ]
|
||||
then
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} username=${LH_USERNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} username=${LB_USERNAME}"
|
||||
;;
|
||||
|
||||
live-initramfs|live-boot)
|
||||
if [ "${LH_USERNAME}" != "user" ]
|
||||
if [ "${LB_USERNAME}" != "user" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} username=${LH_USERNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} username=${LB_USERNAME}"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
if [ -n "${LH_HOSTNAME}" ]
|
||||
if [ -n "${LB_HOSTNAME}" ]
|
||||
then
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} hostname=${LH_HOSTNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} hostname=${LB_HOSTNAME}"
|
||||
;;
|
||||
|
||||
live-initramfs|live-boot)
|
||||
if [ "${LH_HOSTNAME}" != "debian" ]
|
||||
if [ "${LB_HOSTNAME}" != "debian" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} hostname=${LH_HOSTNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} hostname=${LB_HOSTNAME}"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
if [ "${LH_UNION_FILESYSTEM}" != "aufs" ]
|
||||
if [ "${LB_UNION_FILESYSTEM}" != "aufs" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} union=${LH_UNION_FILESYSTEM}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} union=${LB_UNION_FILESYSTEM}"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_NET_COW_PATH}" ]
|
||||
if [ -n "${LB_NET_COW_PATH}" ]
|
||||
then
|
||||
Echo_error "Net cow not yet supported on grub"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ "${LH_EXPOSED_ROOT}" != "false" ]
|
||||
if [ "${LB_EXPOSED_ROOT}" != "false" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} exposedroot"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} exposedroot"
|
||||
fi
|
||||
|
||||
LH_BOOTAPPEND_LIVE="$(echo ${LH_BOOTAPPEND_LIVE} | sed -e 's| ||')"
|
||||
LB_BOOTAPPEND_LIVE="$(echo ${LB_BOOTAPPEND_LIVE} | sed -e 's| ||')"
|
||||
|
||||
# Parameters are listed at: linux/Documentation/kernel-parameters.txt
|
||||
FAILSAFE="noapic noapm nodma nomce nolapic nomodeset nosmp vga=normal"
|
||||
|
@ -194,7 +194,7 @@ FAILSAFE="noapic noapm nodma nomce nolapic nomodeset nosmp vga=normal"
|
|||
# Assembling kernel configuration
|
||||
|
||||
# Default entries
|
||||
DEFAULT_FLAVOUR="$(echo ${LH_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DEFAULT_FLAVOUR="$(echo ${LB_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DEFAULT_KERNEL="$(basename chroot/boot/vmlinuz-*${DEFAULT_FLAVOUR})"
|
||||
DEFAULT_INITRD="initrd.img-$(echo ${DEFAULT_KERNEL} | sed -e 's|vmlinuz-||')"
|
||||
|
||||
|
@ -212,7 +212,7 @@ done
|
|||
LINUX_LIVE="$(/bin/echo ${LINUX_LIVE} | sed -e 's|binary||g' -e 's|//|/|g')"
|
||||
|
||||
# Assembling debian-installer configuration
|
||||
if [ "${LH_DEBIAN_INSTALLER}" != "false" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" != "false" ]
|
||||
then
|
||||
LINUX_LIVE="#\t \"Live\"\n${LINUX_LIVE}"
|
||||
LINUX_INSTALL="#\t \"Installer\"\n"
|
||||
|
@ -241,7 +241,7 @@ LINUX_INSTALL="$(/bin/echo ${LINUX_INSTALL} | sed -e 's|binary||g' -e 's|//|/|g'
|
|||
if [ -f "${DESTDIR_LIVE}"/memtest ]
|
||||
then
|
||||
MEMTEST="#\t \"Other\"\n"
|
||||
MEMTEST="${MEMTEST}\nmenuentry\t\"${LH_MEMTEST}\" {\nlinux16\t$(basename ${DESTDIR_LIVE})/memtest\n}"
|
||||
MEMTEST="${MEMTEST}\nmenuentry\t\"${LB_MEMTEST}\" {\nlinux16\t$(basename ${DESTDIR_LIVE})/memtest\n}"
|
||||
MEMTEST="$(/bin/echo ${MEMTEST} | sed -e 's|//|/|g')"
|
||||
fi
|
||||
|
||||
|
@ -249,7 +249,7 @@ fi
|
|||
mkdir -p binary/boot/grub
|
||||
cp -r "${TEMPLATES}"/* binary/boot/grub
|
||||
|
||||
case ${LH_BINARY_IMAGES} in
|
||||
case ${LB_BINARY_IMAGES} in
|
||||
iso*)
|
||||
FILES="chroot/usr/lib/grub/i386-pc/*.mod chroot/usr/lib/grub/i386-pc/*.lst chroot/usr/lib/grub/i386-pc/efiemu??.o chroot/usr/share/grub/*.pf2"
|
||||
;;
|
||||
|
@ -259,7 +259,7 @@ case ${LH_BINARY_IMAGES} in
|
|||
;;
|
||||
esac
|
||||
|
||||
if [ "${LH_BUILD_WITH_CHROOT}" = "false" ]
|
||||
if [ "${LB_BUILD_WITH_CHROOT}" = "false" ]
|
||||
then
|
||||
FILES="$(echo ${FILES} | sed -e 's|chroot||g')"
|
||||
fi
|
||||
|
@ -276,12 +276,12 @@ fi
|
|||
# Copying splash screen
|
||||
if [ -f config/binary_grub/splash.tga ]
|
||||
then
|
||||
LH_GRUB_SPLASH="config/binary_grub/splash.tga"
|
||||
LB_GRUB_SPLASH="config/binary_grub/splash.tga"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_GRUB_SPLASH}" ]
|
||||
if [ -n "${LB_GRUB_SPLASH}" ]
|
||||
then
|
||||
if [ "${LH_GRUB_SPLASH}" = "none" ]
|
||||
if [ "${LB_GRUB_SPLASH}" = "none" ]
|
||||
then
|
||||
# Removing splash file
|
||||
rm -f binary/boot/grub/splash.tga
|
||||
|
@ -290,13 +290,13 @@ then
|
|||
sed -i -e "s|background_image.*||" binary/boot/grub/grub.cfg
|
||||
else
|
||||
# Overwriting splash file
|
||||
cp -f "${LH_GRUB_SPLASH}" binary/boot/grub
|
||||
sed -i -e "s|background_image .*.tga|background_image \$\(root\)/boot/grub/$(basename ${LH_GRUB_SPLASH})|" binary/boot/grub/grub.cfg
|
||||
cp -f "${LB_GRUB_SPLASH}" binary/boot/grub
|
||||
sed -i -e "s|background_image .*.tga|background_image \$\(root\)/boot/grub/$(basename ${LB_GRUB_SPLASH})|" binary/boot/grub/grub.cfg
|
||||
fi
|
||||
fi
|
||||
|
||||
sed -i -e "s|LINUX_LIVE|${LINUX_LIVE}|" -e "s|LINUX_INSTALL|${LINUX_INSTALL}|" -e "s|MEMTEST|${MEMTEST}|" binary/boot/grub/grub.cfg
|
||||
sed -i -e "s|LH_BOOTAPPEND_INSTALL|${LH_BOOTAPPEND_INSTALL}|" -e "s|LH_BOOTAPPEND_LIVE|${LH_BOOTAPPEND_LIVE}|" binary/boot/grub/grub.cfg
|
||||
sed -i -e "s|LB_BOOTAPPEND_INSTALL|${LB_BOOTAPPEND_INSTALL}|" -e "s|LB_BOOTAPPEND_LIVE|${LB_BOOTAPPEND_LIVE}|" binary/boot/grub/grub.cfg
|
||||
|
||||
sed -i -e 's|\ $||g' binary/boot/grub/grub.cfg
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'copy files into binary')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_INCLUDES}" = "none" ]
|
||||
if [ "${LB_INCLUDES}" = "none" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -44,25 +44,25 @@ Check_lockfile .lock
|
|||
Create_lockfile .lock
|
||||
|
||||
# Check user includes
|
||||
if [ ! -d "${LH_INCLUDES}" ]
|
||||
if [ ! -d "${LB_INCLUDES}" ]
|
||||
then
|
||||
if [ -d ../"${LH_INCLUDES}" ]
|
||||
if [ -d ../"${LB_INCLUDES}" ]
|
||||
then
|
||||
LH_INCLUDES="../${LH_INCLUDES}"
|
||||
LB_INCLUDES="../${LB_INCLUDES}"
|
||||
else
|
||||
Echo_error "user specified includes not accessible in %s" "${LH_INCLUDES}"
|
||||
Echo_error "user specified includes not accessible in %s" "${LB_INCLUDES}"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
# Checking local includes
|
||||
if [ -d config/includes/"${LH_DISTRIBUTION}" ]
|
||||
if [ -d config/includes/"${LB_DISTRIBUTION}" ]
|
||||
then
|
||||
LH_INCLUDES="config/includes"
|
||||
LB_INCLUDES="config/includes"
|
||||
fi
|
||||
|
||||
# Assemble architecture
|
||||
case "${LH_ARCHITECTURE}" in
|
||||
case "${LB_ARCHITECTURE}" in
|
||||
amd64)
|
||||
ARCH="amd"
|
||||
;;
|
||||
|
@ -81,9 +81,9 @@ case "${LH_ARCHITECTURE}" in
|
|||
esac
|
||||
|
||||
# Working arround vfat limitations
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
usb*)
|
||||
case "${LH_BINARY_FILESYSTEM}" in
|
||||
case "${LB_BINARY_FILESYSTEM}" in
|
||||
fat*)
|
||||
CP_OPTIONS="-L"
|
||||
;;
|
||||
|
@ -92,51 +92,51 @@ case "${LH_BINARY_IMAGES}" in
|
|||
esac
|
||||
|
||||
# Copying common templates
|
||||
if [ -d "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/common ] && \
|
||||
Find_files "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/common/*
|
||||
if [ -d "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/common ] && \
|
||||
Find_files "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/common/*
|
||||
then
|
||||
cp -r ${CP_OPTIONS} "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/common/* binary
|
||||
cp -r ${CP_OPTIONS} "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/common/* binary
|
||||
fi
|
||||
|
||||
if [ -d "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/common."${ARCH}" ] && \
|
||||
Find_files "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/common."${ARCH}"/*
|
||||
if [ -d "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/common."${ARCH}" ] && \
|
||||
Find_files "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/common."${ARCH}"/*
|
||||
then
|
||||
cp -r ${CP_OPTIONS} "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/common."${ARCH}"/* binary
|
||||
cp -r ${CP_OPTIONS} "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/common."${ARCH}"/* binary
|
||||
fi
|
||||
|
||||
# Copying live templates
|
||||
if [ -d "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/live ] && \
|
||||
Find_files "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/live/*
|
||||
if [ -d "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/live ] && \
|
||||
Find_files "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/live/*
|
||||
then
|
||||
cp -r ${CP_OPTIONS} "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/live/* binary
|
||||
cp -r ${CP_OPTIONS} "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/live/* binary
|
||||
fi
|
||||
|
||||
if [ -d "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/live."${ARCH}" ] && \
|
||||
Find_files "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/live."${ARCH}"/*
|
||||
if [ -d "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/live."${ARCH}" ] && \
|
||||
Find_files "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/live."${ARCH}"/*
|
||||
then
|
||||
cp -r ${CP_OPTIONS} "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/live."${ARCH}"/* binary
|
||||
cp -r ${CP_OPTIONS} "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/live."${ARCH}"/* binary
|
||||
fi
|
||||
|
||||
if [ "${LH_DEBIAN_INSTALLER}" != "false" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" != "false" ]
|
||||
then
|
||||
# Copying install templates
|
||||
if [ -d "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/install ] && \
|
||||
Find_files "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/install/*
|
||||
if [ -d "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/install ] && \
|
||||
Find_files "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/install/*
|
||||
then
|
||||
cp -r ${CP_OPTIONS} "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/install/* binary
|
||||
cp -r ${CP_OPTIONS} "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/install/* binary
|
||||
fi
|
||||
|
||||
if [ -d "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/install."${ARCH}" ] && \
|
||||
Find_files "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/install."${ARCH}"/*
|
||||
if [ -d "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/install."${ARCH}" ] && \
|
||||
Find_files "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/install."${ARCH}"/*
|
||||
then
|
||||
cp -r ${CP_OPTIONS} "${LH_INCLUDES}"/"${LH_DISTRIBUTION}"/install."${ARCH}"/* binary
|
||||
cp -r ${CP_OPTIONS} "${LB_INCLUDES}"/"${LB_DISTRIBUTION}"/install."${ARCH}"/* binary
|
||||
fi
|
||||
|
||||
# Adjusting install templates
|
||||
ARCHITECTURE="$(echo ${LH_ARCHITECTURE} | sed -e 's| |/|g')"
|
||||
DISTRIBUTION="$(echo ${LH_DISTRIBUTION} | cut -b 1 | tr '[a-z]' '[A-Z]')"
|
||||
DISTRIBUTION="${DISTRIBUTION}$(echo ${LH_DISTRIBUTION} | cut -b 2-)"
|
||||
eval VERSION="$`echo RELEASE_${LH_DISTRIBUTION}`"
|
||||
ARCHITECTURE="$(echo ${LB_ARCHITECTURE} | sed -e 's| |/|g')"
|
||||
DISTRIBUTION="$(echo ${LB_DISTRIBUTION} | cut -b 1 | tr '[a-z]' '[A-Z]')"
|
||||
DISTRIBUTION="${DISTRIBUTION}$(echo ${LB_DISTRIBUTION} | cut -b 2-)"
|
||||
eval VERSION="$`echo RELEASE_${LB_DISTRIBUTION}`"
|
||||
|
||||
if [ -d binary/pool/main/l/live-installer ]
|
||||
then
|
||||
|
@ -148,7 +148,7 @@ then
|
|||
DEBIAN_NAME="Debian GNU/Linux ${VERSION} \"${DISTRIBUTION}\" - Official ${ARCHITECTURE} ${TYPE} Binary $(date +%Y%m%d-%H:%M)"
|
||||
DEBIAN_DATE="$(date +%Y%m%d-%H:%M)"
|
||||
|
||||
if [ "${LH_ARCHITECTURE}" = "i386" ]
|
||||
if [ "${LB_ARCHITECTURE}" = "i386" ]
|
||||
then
|
||||
DEBIAN_TOOLS_HTML=" <P>\n <tt> \n <A href="tools/">/tools/</a>\n </tt>\n\n and\n <tt> \n <A href="install/floppy/">/install/floppy/</a>\n </tt>"
|
||||
DEBIAN_TOOLS_TXT="/tools/ and /install/floppy/"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'build iso binary image')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
iso)
|
||||
IMAGE="binary.iso"
|
||||
;;
|
||||
|
@ -55,7 +55,7 @@ Create_lockfile .lock
|
|||
# Checking depends
|
||||
Check_package chroot/usr/bin/genisoimage genisoimage
|
||||
|
||||
if [ "${LH_BINARY_IMAGES}" = "iso-hybrid" ]
|
||||
if [ "${LB_BINARY_IMAGES}" = "iso-hybrid" ]
|
||||
then
|
||||
Check_package chroot/usr/bin/isohybrid syslinux
|
||||
fi
|
||||
|
@ -86,28 +86,28 @@ then
|
|||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -v"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_ISO_APPLICATION}" ] && [ "${LH_ISO_APPLICATION}" != "none" ]
|
||||
if [ -n "${LB_ISO_APPLICATION}" ] && [ "${LB_ISO_APPLICATION}" != "none" ]
|
||||
then
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -A \"${LH_ISO_APPLICATION}\""
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -A \"${LB_ISO_APPLICATION}\""
|
||||
fi
|
||||
|
||||
if [ -n "${LH_ISO_PREPARER}" ] && [ "${LH_ISO_PREPARER}" != "none" ]
|
||||
if [ -n "${LB_ISO_PREPARER}" ] && [ "${LB_ISO_PREPARER}" != "none" ]
|
||||
then
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -p \"${LH_ISO_PREPARER}\""
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -p \"${LB_ISO_PREPARER}\""
|
||||
fi
|
||||
|
||||
if [ -n "${LH_ISO_PUBLISHER}" ] && [ "${LH_ISO_PUBLISHER}" != "none" ]
|
||||
if [ -n "${LB_ISO_PUBLISHER}" ] && [ "${LB_ISO_PUBLISHER}" != "none" ]
|
||||
then
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -publisher \"${LH_ISO_PUBLISHER}\""
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -publisher \"${LB_ISO_PUBLISHER}\""
|
||||
fi
|
||||
|
||||
if [ -n "${LH_ISO_VOLUME}" ] && [ "${LH_ISO_VOLUME}" != "none" ]
|
||||
if [ -n "${LB_ISO_VOLUME}" ] && [ "${LB_ISO_VOLUME}" != "none" ]
|
||||
then
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -V \"${LH_ISO_VOLUME}\""
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -V \"${LB_ISO_VOLUME}\""
|
||||
fi
|
||||
|
||||
# Handle genisoimage architecture specific options
|
||||
case "${LH_BOOTLOADER}" in
|
||||
case "${LB_BOOTLOADER}" in
|
||||
grub)
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -no-emul-boot -boot-load-size 4 -boot-info-table"
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -r -b boot/grub/stage2_eltorito"
|
||||
|
@ -145,15 +145,15 @@ case "${LH_BOOTLOADER}" in
|
|||
;;
|
||||
esac
|
||||
|
||||
if In_list "stripped minimal" "${LH_PACKAGES_LISTS}"
|
||||
if In_list "stripped minimal" "${LB_PACKAGES_LISTS}"
|
||||
then
|
||||
if [ "${LH_DEBIAN_INSTALLER}" != "live" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" != "live" ]
|
||||
then
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -m ${GENISOIMAGE_EXCLUDE}"
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ "${LH_BOOTLOADER}" = "grub2" ]
|
||||
if [ "${LB_BOOTLOADER}" = "grub2" ]
|
||||
then
|
||||
|
||||
cat > binary.sh << EOF
|
||||
|
@ -190,7 +190,7 @@ cat >> binary.sh << EOF
|
|||
genisoimage ${GENISOIMAGE_OPTIONS} -o ${IMAGE} binary
|
||||
EOF
|
||||
|
||||
if [ "${LH_BINARY_IMAGES}" = "iso-hybrid" ]
|
||||
if [ "${LB_BINARY_IMAGES}" = "iso-hybrid" ]
|
||||
then
|
||||
|
||||
cat >> binary.sh << EOF
|
||||
|
@ -200,7 +200,7 @@ EOF
|
|||
|
||||
fi
|
||||
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
# Moving image
|
||||
mv binary.sh chroot
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'install linux-image into binary')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_BINARY_IMAGES}" = "virtual-hdd" ]
|
||||
if [ "${LB_BINARY_IMAGES}" = "virtual-hdd" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -43,7 +43,7 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
DESTDIR="binary/casper"
|
||||
;;
|
||||
|
@ -57,7 +57,7 @@ case "${LH_INITRAMFS}" in
|
|||
;;
|
||||
esac
|
||||
|
||||
case "${LH_ARCHITECTURE}" in
|
||||
case "${LB_ARCHITECTURE}" in
|
||||
powerpc)
|
||||
LINUX="vmlinux"
|
||||
;;
|
||||
|
@ -76,7 +76,7 @@ mkdir -p "${DESTDIR}"
|
|||
cp chroot/boot/"${LINUX}"-* "${DESTDIR}"
|
||||
cp chroot/boot/initrd.img-* "${DESTDIR}"
|
||||
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
live-initramfs|live-boot)
|
||||
if [ -e chroot/usr/share/doc/live-initramfs/parameters.txt ]
|
||||
then
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'execute local hooks in binary')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'copy files into binary')"
|
||||
|
@ -46,7 +46,7 @@ then
|
|||
cd "${OLDPWD}"
|
||||
|
||||
# Removing symlinks
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
usb*)
|
||||
find binary -type l | xargs rm -f
|
||||
;;
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'install local packages into binary')"
|
||||
|
@ -108,9 +108,9 @@ then
|
|||
do
|
||||
SECTION="$(basename ${SECTION})"
|
||||
|
||||
mkdir -p dists/${LH_DISTRIBUTION}/${SECTION}/binary-${LH_ARCHITECTURE}
|
||||
apt-ftparchive packages pool/${SECTION} > dists/${LH_DISTRIBUTION}/${SECTION}/binary-${LH_ARCHITECTURE}/Packages
|
||||
gzip -9 -c dists/${LH_DISTRIBUTION}/${SECTION}/binary-${LH_ARCHITECTURE}/Packages > dists/${LH_DISTRIBUTION}/${SECTION}/binary-${LH_ARCHITECTURE}/Packages.gz
|
||||
mkdir -p dists/${LB_DISTRIBUTION}/${SECTION}/binary-${LB_ARCHITECTURE}
|
||||
apt-ftparchive packages pool/${SECTION} > dists/${LB_DISTRIBUTION}/${SECTION}/binary-${LB_ARCHITECTURE}/Packages
|
||||
gzip -9 -c dists/${LB_DISTRIBUTION}/${SECTION}/binary-${LB_ARCHITECTURE}/Packages > dists/${LB_DISTRIBUTION}/${SECTION}/binary-${LB_ARCHITECTURE}/Packages.gz
|
||||
done
|
||||
|
||||
cd "${OLDPWD}"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'create manifest')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_BINARY_IMAGES}" = "virtual-hdd" ]
|
||||
if [ "${LB_BINARY_IMAGES}" = "virtual-hdd" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -43,7 +43,7 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
INITFS="casper"
|
||||
SUFFIX="manifest"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'installs a memtest into binary')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_BINARY_IMAGES}" = "virtual-hdd" ] || [ "${LH_MEMTEST}" = "false" ] || [ "${LH_MEMTEST}" = "none" ]
|
||||
if [ "${LB_BINARY_IMAGES}" = "virtual-hdd" ] || [ "${LB_MEMTEST}" = "false" ] || [ "${LB_MEMTEST}" = "none" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -43,13 +43,13 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ "${LH_ARCHITECTURE}" != "amd64" ] && [ "${LH_ARCHITECTURE}" != "i386" ]
|
||||
if [ "${LB_ARCHITECTURE}" != "amd64" ] && [ "${LB_ARCHITECTURE}" != "i386" ]
|
||||
then
|
||||
Echo_warning "skipping binary_memtest, foreign architecture."
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [ "${LH_BUILD_WITH_CHROOT}" = "true" ]
|
||||
if [ "${LB_BUILD_WITH_CHROOT}" = "true" ]
|
||||
then
|
||||
|
||||
if [ -f chroot/usr/sbin/grub ] && [ ! -f chroot/boot/grub/menu.lst ]
|
||||
|
@ -62,7 +62,7 @@ then
|
|||
fi
|
||||
|
||||
# Checking depends
|
||||
case "${LH_MEMTEST}" in
|
||||
case "${LB_MEMTEST}" in
|
||||
memtest86)
|
||||
Check_package chroot/boot/memtest86.bin memtest86
|
||||
;;
|
||||
|
@ -79,7 +79,7 @@ Restore_cache cache/packages_binary
|
|||
Install_package
|
||||
|
||||
# Setting destination directory
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
DESTDIR="binary/casper"
|
||||
;;
|
||||
|
@ -95,13 +95,13 @@ Check_multiarchitecture
|
|||
mkdir -p "${DESTDIR}"
|
||||
|
||||
# Installing memtest
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
cp chroot/boot/${LH_MEMTEST}.bin "${DESTDIR}"/memtest
|
||||
cp chroot/boot/${LB_MEMTEST}.bin "${DESTDIR}"/memtest
|
||||
;;
|
||||
|
||||
false)
|
||||
cp /boot/${LH_MEMTEST}.bin "${DESTDIR}"/memtest
|
||||
cp /boot/${LB_MEMTEST}.bin "${DESTDIR}"/memtest
|
||||
;;
|
||||
esac
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'build netboot binary image')"
|
||||
|
@ -24,12 +24,12 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if ! In_list net "${LH_BINARY_IMAGES}"
|
||||
if ! In_list net "${LB_BINARY_IMAGES}"
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [ "${LH_NET_TARBALL}" = "none" ]
|
||||
if [ "${LB_NET_TARBALL}" = "none" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -48,7 +48,7 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ "${LH_ARCHITECTURE}" = "sparc" ]
|
||||
if [ "${LB_ARCHITECTURE}" = "sparc" ]
|
||||
then
|
||||
# Checking depends
|
||||
Check_package chroot/usr/bin/elftoaout sparc-utils
|
||||
|
@ -61,7 +61,7 @@ then
|
|||
|
||||
# Set target and source directories
|
||||
DESTDIR="tftpboot"
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
ORIGDIR="binary/casper"
|
||||
;;
|
||||
|
@ -72,7 +72,7 @@ then
|
|||
esac
|
||||
|
||||
# Find defaults
|
||||
DEFAULT_FLAVOUR="$(echo ${LH_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DEFAULT_FLAVOUR="$(echo ${LB_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DEFAULT_KERNEL="$(basename chroot/boot/vmlinuz-*${DEFAULT_FLAVOUR})"
|
||||
DEFAULT_INITRD="initrd.img-$(echo ${DEFAULT_KERNEL} | sed -e 's|vmlinuz-||')"
|
||||
DEFAULT_MAP="$(echo chroot/boot/System.map-*${DEFAULT_FLAVOUR})"
|
||||
|
@ -120,7 +120,7 @@ rm -f binary-net.tar.gz
|
|||
rm -f binary-net.tar
|
||||
|
||||
# Creating image file
|
||||
ROOT_DIR=$(basename ${LH_NET_ROOT_PATH})
|
||||
ROOT_DIR=$(basename ${LB_NET_ROOT_PATH})
|
||||
if [ "${ROOT_DIR}" = "chroot" ]
|
||||
then
|
||||
mv chroot chroot.tmp
|
||||
|
@ -135,7 +135,7 @@ mkdir binary.tmp
|
|||
mv ${ROOT_DIR} tftpboot binary.tmp
|
||||
cd binary.tmp
|
||||
|
||||
case "${LH_NET_TARBALL}" in
|
||||
case "${LB_NET_TARBALL}" in
|
||||
bzip2)
|
||||
tar cfj ../binary-net-tar.bz2 *
|
||||
;;
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'build rootfs image')"
|
||||
|
@ -38,7 +38,7 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
case "${LH_ARCHITECTURE}" in
|
||||
case "${LB_ARCHITECTURE}" in
|
||||
amd64|i386)
|
||||
LINUX="vmlinuz"
|
||||
;;
|
||||
|
@ -48,7 +48,7 @@ case "${LH_ARCHITECTURE}" in
|
|||
;;
|
||||
esac
|
||||
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
INITFS="casper"
|
||||
;;
|
||||
|
@ -61,7 +61,7 @@ esac
|
|||
# Creating directory
|
||||
mkdir -p binary/${INITFS}
|
||||
|
||||
for STAGE in ${LH_CACHE_STAGES}
|
||||
for STAGE in ${LB_CACHE_STAGES}
|
||||
do
|
||||
if [ "${STAGE}" = "rootfs" ] && [ -d cache/stages_rootfs ]
|
||||
then
|
||||
|
@ -70,11 +70,11 @@ do
|
|||
|
||||
# Restoring old cache
|
||||
mkdir -p binary/"${INITFS}"
|
||||
${LH_ROOT_COMMAND} cp -a cache/stages_rootfs/filesystem.* binary/"${INITFS}"
|
||||
${LB_ROOT_COMMAND} cp -a cache/stages_rootfs/filesystem.* binary/"${INITFS}"
|
||||
|
||||
if [ -n "${LH_ROOT_COMMAND}" ]
|
||||
if [ -n "${LB_ROOT_COMMAND}" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} chown -R $(whoami):$(whoami) binary
|
||||
${LB_ROOT_COMMAND} chown -R $(whoami):$(whoami) binary
|
||||
fi
|
||||
|
||||
# Creating stage file
|
||||
|
@ -83,7 +83,7 @@ do
|
|||
fi
|
||||
done
|
||||
|
||||
case "${LH_CHROOT_FILESYSTEM}" in
|
||||
case "${LB_CHROOT_FILESYSTEM}" in
|
||||
ext2|ext3)
|
||||
# Checking depends
|
||||
Check_package chroot/usr/bin/genext2fs genext2fs
|
||||
|
@ -95,24 +95,24 @@ case "${LH_CHROOT_FILESYSTEM}" in
|
|||
Install_package
|
||||
|
||||
# Remove old image
|
||||
if [ -f binary/${INITFS}/filesystem.${LH_CHROOT_FILESYSTEM} ]
|
||||
if [ -f binary/${INITFS}/filesystem.${LB_CHROOT_FILESYSTEM} ]
|
||||
then
|
||||
rm -f binary/${INITFS}/filesystem.${LH_CHROOT_FILESYSTEM}
|
||||
rm -f binary/${INITFS}/filesystem.${LB_CHROOT_FILESYSTEM}
|
||||
fi
|
||||
|
||||
DU_DIM="$(du -ks chroot/chroot | cut -f1)"
|
||||
REAL_DIM="$(Calculate_partition_size ${DU_DIM} ${LH_CHROOT_FILESYSTEM})"
|
||||
REAL_DIM="$(Calculate_partition_size ${DU_DIM} ${LB_CHROOT_FILESYSTEM})"
|
||||
|
||||
RESERVED_PERCENTAGE="--reserved-percentage"
|
||||
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
Chroot chroot "genext2fs --size-in-blocks=${REAL_DIM} ${RESERVED_PERCENTAGE}=0 --root=chroot filesystem.${LH_CHROOT_FILESYSTEM}"
|
||||
Chroot chroot "genext2fs --size-in-blocks=${REAL_DIM} ${RESERVED_PERCENTAGE}=0 --root=chroot filesystem.${LB_CHROOT_FILESYSTEM}"
|
||||
|
||||
# Move image
|
||||
mv chroot/filesystem.${LH_CHROOT_FILESYSTEM} binary/${INITFS}
|
||||
mv chroot/filesystem.${LB_CHROOT_FILESYSTEM} binary/${INITFS}
|
||||
|
||||
case "${LH_MODE}" in
|
||||
case "${LB_MODE}" in
|
||||
ubuntu)
|
||||
du -B 1 -s chroot/chroot | cut -f1 > binary/${INITFS}/filesystem.size
|
||||
;;
|
||||
|
@ -166,7 +166,7 @@ case "${LH_CHROOT_FILESYSTEM}" in
|
|||
;;
|
||||
|
||||
false)
|
||||
genext2fs --size-in-blocks=${REAL_DIM} ${RESERVED_PERCENTAGE}=0 --root=chroot binary/${INITFS}/filesystem.${LH_CHROOT_FILESYSTEM}
|
||||
genext2fs --size-in-blocks=${REAL_DIM} ${RESERVED_PERCENTAGE}=0 --root=chroot binary/${INITFS}/filesystem.${LB_CHROOT_FILESYSTEM}
|
||||
;;
|
||||
esac
|
||||
|
||||
|
@ -190,12 +190,12 @@ case "${LH_CHROOT_FILESYSTEM}" in
|
|||
rm -f binary/${INITFS}/filesystem.jffs2
|
||||
fi
|
||||
|
||||
if [ -n "${LH_JFFS2_ERASEBLOCK}" ]
|
||||
if [ -n "${LB_JFFS2_ERASEBLOCK}" ]
|
||||
then
|
||||
JFFS2_OPTIONS="--eraseblock=${LH_JFFS2_ERASEBLOCK}"
|
||||
JFFS2_OPTIONS="--eraseblock=${LB_JFFS2_ERASEBLOCK}"
|
||||
fi
|
||||
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
Chroot chroot "mkfs.jffs2 ${JFFS2_OPTIONS} --root=chroot --output filesystem.jffs2"
|
||||
|
||||
|
@ -264,7 +264,7 @@ case "${LH_CHROOT_FILESYSTEM}" in
|
|||
rm -rf binary/${INITFS}/filesystem.dir
|
||||
fi
|
||||
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
mv chroot/chroot binary/${INITFS}/filesystem.dir
|
||||
;;
|
||||
|
@ -310,20 +310,20 @@ case "${LH_CHROOT_FILESYSTEM}" in
|
|||
cp config/binary_rootfs/squashfs.sort chroot #FIXME
|
||||
fi
|
||||
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
# Create image
|
||||
Chroot chroot "mksquashfs chroot filesystem.squashfs ${MKSQUASHFS_OPTIONS}"
|
||||
|
||||
case "${LH_MODE}" in
|
||||
case "${LB_MODE}" in
|
||||
ubuntu)
|
||||
du -B 1 -s chroot/chroot | cut -f1 > binary/${INITFS}/filesystem.size
|
||||
;;
|
||||
esac
|
||||
|
||||
# Move image
|
||||
${LH_ROOT_COMMAND} mv chroot/filesystem.squashfs binary/${INITFS}
|
||||
${LH_ROOT_COMMAND} rm -f chroot/squashfs.sort
|
||||
${LB_ROOT_COMMAND} mv chroot/filesystem.squashfs binary/${INITFS}
|
||||
${LB_ROOT_COMMAND} rm -f chroot/squashfs.sort
|
||||
|
||||
if [ -e chroot/chroot.cache ]
|
||||
then
|
||||
|
@ -371,13 +371,13 @@ case "${LH_CHROOT_FILESYSTEM}" in
|
|||
Remove_package
|
||||
fi
|
||||
|
||||
${LH_ROOT_COMMAND} chmod 0644 binary/${INITFS}/filesystem.squashfs
|
||||
${LB_ROOT_COMMAND} chmod 0644 binary/${INITFS}/filesystem.squashfs
|
||||
;;
|
||||
|
||||
false)
|
||||
mksquashfs chroot binary/${INITFS}/filesystem.squashfs ${MKSQUASHFS_OPTIONS}
|
||||
|
||||
case "${LH_MODE}" in
|
||||
case "${LB_MODE}" in
|
||||
ubuntu)
|
||||
du -B 1 -s chroot | cut -f1 > binary/${INITFS}/filesystem.size
|
||||
;;
|
||||
|
@ -385,9 +385,9 @@ case "${LH_CHROOT_FILESYSTEM}" in
|
|||
;;
|
||||
esac
|
||||
|
||||
if [ -n "${LH_ROOT_COMMAND}" ]
|
||||
if [ -n "${LB_ROOT_COMMAND}" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} chown -R $(whoami):$(whoami) binary/${INITFS}
|
||||
${LB_ROOT_COMMAND} chown -R $(whoami):$(whoami) binary/${INITFS}
|
||||
fi
|
||||
|
||||
# Saving cache
|
||||
|
@ -400,7 +400,7 @@ case "${LH_CHROOT_FILESYSTEM}" in
|
|||
rm -rf binary
|
||||
fi
|
||||
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
mv chroot/chroot binary
|
||||
;;
|
||||
|
@ -414,7 +414,7 @@ case "${LH_CHROOT_FILESYSTEM}" in
|
|||
|
||||
esac
|
||||
|
||||
for STAGE in ${LH_CACHE_STAGES}
|
||||
for STAGE in ${LB_CACHE_STAGES}
|
||||
do
|
||||
if [ "${STAGE}" = "rootfs" ]
|
||||
then
|
||||
|
@ -422,14 +422,14 @@ do
|
|||
|
||||
mkdir -p cache/stages_rootfs
|
||||
|
||||
if [ "${LH_CHROOT_FILESYSTEM}" != "none" ]
|
||||
if [ "${LB_CHROOT_FILESYSTEM}" != "none" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} cp -a binary/"${INITFS}"/filesystem.* cache/stages_rootfs
|
||||
${LB_ROOT_COMMAND} cp -a binary/"${INITFS}"/filesystem.* cache/stages_rootfs
|
||||
fi
|
||||
|
||||
if [ -n "${LH_ROOT_COMMAND}" ]
|
||||
if [ -n "${LB_ROOT_COMMAND}" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} chown -R $(whoami):$(whoami) cache/stages_rootfs
|
||||
${LB_ROOT_COMMAND} chown -R $(whoami):$(whoami) cache/stages_rootfs
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'installs silo into binary')"
|
||||
|
@ -24,13 +24,13 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_BOOTLOADER}" != "silo" ]
|
||||
if [ "${LB_BOOTLOADER}" != "silo" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Check image type
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
iso*|usb*|tar)
|
||||
;;
|
||||
|
||||
|
@ -82,7 +82,7 @@ Silo_live_entry ()
|
|||
LINUX_LIVE="${LINUX_LIVE}\nimage=${DIRECTORY}/${KERNEL}\n"
|
||||
LINUX_LIVE="${LINUX_LIVE}\t label=${LABEL}\n"
|
||||
LINUX_LIVE="${LINUX_LIVE}\t initrd=${DIRECTORY}/${INITRD}\n"
|
||||
LINUX_LIVE="${LINUX_LIVE}\t append=\"boot=${INITFS} live-config LH_BOOTAPPEND_LIVE ${APPEND}\"\n"
|
||||
LINUX_LIVE="${LINUX_LIVE}\t append=\"boot=${INITFS} live-config LB_BOOTAPPEND_LIVE ${APPEND}\"\n"
|
||||
}
|
||||
|
||||
Silo_install_entry ()
|
||||
|
@ -102,12 +102,12 @@ Silo_install_entry ()
|
|||
LINUX_INSTALL="${LINUX_INSTALL}\nimage=${DIRECTORY}/${KERNEL}\n"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\t label=${LABEL}\n"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\t initrd=${DIRECTORY}/${INITRD}\n"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\t append=\"LH_BOOTAPPEND_LIVE ${APPEND} LH_BOOTAPPEND_INSTALL\"\n"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\t append=\"LB_BOOTAPPEND_LIVE ${APPEND} LB_BOOTAPPEND_INSTALL\"\n"
|
||||
}
|
||||
|
||||
# Setting destination directories
|
||||
DESTDIR_INSTALL="binary/install"
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
INITFS="casper"
|
||||
DESTDIR_LIVE="binary/casper"
|
||||
|
@ -123,63 +123,63 @@ esac
|
|||
mkdir -p "${DESTDIR_LIVE}"
|
||||
|
||||
# Setting boot parameters
|
||||
case "${LH_ENCRYPTION}" in
|
||||
case "${LB_ENCRYPTION}" in
|
||||
""|false)
|
||||
;;
|
||||
*)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} encryption=${LH_ENCRYPTION}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} encryption=${LB_ENCRYPTION}"
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -n "${LH_USERNAME}" ]
|
||||
if [ -n "${LB_USERNAME}" ]
|
||||
then
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} username=${LH_USERNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} username=${LB_USERNAME}"
|
||||
;;
|
||||
|
||||
live-initramfs|live-boot)
|
||||
if [ "${LH_USERNAME}" != "user" ]
|
||||
if [ "${LB_USERNAME}" != "user" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} username=${LH_USERNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} username=${LB_USERNAME}"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
if [ -n "${LH_HOSTNAME}" ]
|
||||
if [ -n "${LB_HOSTNAME}" ]
|
||||
then
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} hostname=${LH_HOSTNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} hostname=${LB_HOSTNAME}"
|
||||
;;
|
||||
|
||||
live-initramfs|live-boot)
|
||||
if [ "${LH_HOSTNAME}" != "debian" ]
|
||||
if [ "${LB_HOSTNAME}" != "debian" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} hostname=${LH_HOSTNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} hostname=${LB_HOSTNAME}"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
if [ "${LH_UNION_FILESYSTEM}" != "aufs" ]
|
||||
if [ "${LB_UNION_FILESYSTEM}" != "aufs" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} union=${LH_UNION_FILESYSTEM}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} union=${LB_UNION_FILESYSTEM}"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_NET_COW_PATH}" ]
|
||||
if [ -n "${LB_NET_COW_PATH}" ]
|
||||
then
|
||||
Echo_error "Net cow not supported on silo"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ "${LH_EXPOSED_ROOT}" != "false" ]
|
||||
if [ "${LB_EXPOSED_ROOT}" != "false" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} exposedroot"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} exposedroot"
|
||||
fi
|
||||
|
||||
LH_BOOTAPPEND_LIVE="$(echo ${LH_BOOTAPPEND_LIVE} | sed -e 's| ||')"
|
||||
LB_BOOTAPPEND_LIVE="$(echo ${LB_BOOTAPPEND_LIVE} | sed -e 's| ||')"
|
||||
|
||||
# Parameters are listed at: linux/Documentation/kernel-parameters.txt
|
||||
FAILSAFE="noapic noapm nodma nomce nolapic nomodeset nosmp vga=ofonly"
|
||||
|
@ -187,14 +187,14 @@ FAILSAFE="noapic noapm nodma nomce nolapic nomodeset nosmp vga=ofonly"
|
|||
# Assembling kernel configuration
|
||||
|
||||
# Default entries
|
||||
DEFAULT_FLAVOUR="$(echo ${LH_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DEFAULT_FLAVOUR="$(echo ${LB_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DEFAULT_KERNEL="$(basename chroot/boot/vmlinuz-*${DEFAULT_FLAVOUR})"
|
||||
DEFAULT_INITRD="initrd.img-$(echo ${DEFAULT_KERNEL} | sed -e 's|vmlinuz-||')"
|
||||
|
||||
Silo_live_entry "live" "${DEFAULT_KERNEL}" "${DEFAULT_INITRD}"
|
||||
Silo_live_entry "live-failsafe" "${DEFAULT_KERNEL}" "${DEFAULT_INITRD}" "${FAILSAFE}"
|
||||
|
||||
if [ "$(echo ${LH_LINUX_FLAVOURS} | wc -w)" -gt "1" ]
|
||||
if [ "$(echo ${LB_LINUX_FLAVOURS} | wc -w)" -gt "1" ]
|
||||
then
|
||||
for KERNEL in chroot/boot/vmlinuz-*
|
||||
do
|
||||
|
@ -210,7 +210,7 @@ fi
|
|||
LINUX_LIVE="$(/bin/echo ${LINUX_LIVE} | sed -e 's|binary||g' -e 's|//|/|g')"
|
||||
|
||||
# Assembling debian-installer configuration
|
||||
if [ "${LH_DEBIAN_INSTALLER}" != "false" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" != "false" ]
|
||||
then
|
||||
VMLINUZ_DI="vmlinuz"
|
||||
INITRD_DI="initrd.gz"
|
||||
|
@ -225,12 +225,12 @@ fi
|
|||
|
||||
LINUX_INSTALL="$(/bin/echo ${LINUX_INSTALL} | sed -e 's|binary||g' -e 's|//|/|g')"
|
||||
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
iso*|usb*)
|
||||
# Copying silo
|
||||
mkdir -p binary/boot
|
||||
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
cp chroot/boot/second.b binary/boot
|
||||
;;
|
||||
|
@ -242,7 +242,7 @@ case "${LH_BINARY_IMAGES}" in
|
|||
|
||||
cp -r "${TEMPLATES}"/* binary/boot
|
||||
|
||||
if [ "${LH_DEBIAN_INSTALLER}" = "false" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" = "false" ]
|
||||
then
|
||||
rm -f binary/boot/debian.txt.install
|
||||
else
|
||||
|
@ -253,12 +253,12 @@ case "${LH_BINARY_IMAGES}" in
|
|||
sed -i -e "s|LINUX_LIVE|${LINUX_LIVE}|" \
|
||||
-e "s|LINUX_INSTALL|${LINUX_INSTALL}|" \
|
||||
binary/boot/silo.conf
|
||||
sed -i -e "s|LH_BOOTAPPEND_INSTALL|${LH_BOOTAPPEND_INSTALL}|" \
|
||||
-e "s|LH_BOOTAPPEND_LIVE|${LH_BOOTAPPEND_LIVE}|" \
|
||||
sed -i -e "s|LB_BOOTAPPEND_INSTALL|${LB_BOOTAPPEND_INSTALL}|" \
|
||||
-e "s|LB_BOOTAPPEND_LIVE|${LB_BOOTAPPEND_LIVE}|" \
|
||||
binary/boot/silo.conf
|
||||
sed -i -e "s|LH_DATE|$(date +%Y%m%d)|" \
|
||||
-e "s|LH_VERSION|${VERSION}|" \
|
||||
-e "s|LH_DISTRIBUTION|${LH_DISTRIBUTION}|" \
|
||||
sed -i -e "s|LB_DATE|$(date +%Y%m%d)|" \
|
||||
-e "s|LB_VERSION|${VERSION}|" \
|
||||
-e "s|LB_DISTRIBUTION|${LB_DISTRIBUTION}|" \
|
||||
binary/boot/debian.txt
|
||||
;;
|
||||
esac
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'installs syslinux into binary')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_BOOTLOADER}" != "syslinux" ]
|
||||
if [ "${LB_BOOTLOADER}" != "syslinux" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -90,7 +90,7 @@ Syslinux_live_entry ()
|
|||
INITRD="${4}"
|
||||
APPEND="${5}"
|
||||
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
iso*|usb*)
|
||||
NUMBER="$(ls -1 ${KERNEL_PATH} | grep 'vmlinuz[0-9]\+$' | wc -l)"
|
||||
NUMBER="$((${NUMBER} +1))"
|
||||
|
@ -127,7 +127,7 @@ Syslinux_live_entry ()
|
|||
fi
|
||||
|
||||
LINUX_LIVE="${LINUX_LIVE}\tkernel ${LIVE_KERNEL_PATH}/${KERNEL}\n"
|
||||
LINUX_LIVE="${LINUX_LIVE}\tappend initrd=${LIVE_KERNEL_PATH}/${INITRD} boot=${INITFS} live-config ${LH_BOOTAPPEND_LIVE} ${APPEND}\n"
|
||||
LINUX_LIVE="${LINUX_LIVE}\tappend initrd=${LIVE_KERNEL_PATH}/${INITRD} boot=${INITFS} live-config ${LB_BOOTAPPEND_LIVE} ${APPEND}\n"
|
||||
|
||||
# Failsafe kernel
|
||||
LINUX_LIVE="${LINUX_LIVE}\nlabel ${LABEL}failsafe\n"
|
||||
|
@ -139,7 +139,7 @@ Syslinux_live_entry ()
|
|||
fi
|
||||
|
||||
LINUX_LIVE="${LINUX_LIVE}\tkernel ${LIVE_KERNEL_PATH}/${KERNEL}\n"
|
||||
LINUX_LIVE="${LINUX_LIVE}\tappend initrd=${LIVE_KERNEL_PATH}/${INITRD} boot=${INITFS} live-config ${LH_BOOTAPPEND_LIVE} ${APPEND} ${FAILSAFE}\n"
|
||||
LINUX_LIVE="${LINUX_LIVE}\tappend initrd=${LIVE_KERNEL_PATH}/${INITRD} boot=${INITFS} live-config ${LB_BOOTAPPEND_LIVE} ${APPEND} ${FAILSAFE}\n"
|
||||
}
|
||||
|
||||
Syslinux_install_entry ()
|
||||
|
@ -184,7 +184,7 @@ Syslinux_install_entry ()
|
|||
LINUX_INSTALL="${LINUX_INSTALL}\nlabel $(echo "${TYPE}" | tr A-Z a-z)${TYPE_SUFFIX}\n"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\tmenu label ${LABEL} ${TYPE}\n"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\tkernel ${LIVE_INSTALL_KERNEL_PATH}/${KERNEL}\n"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\tappend initrd=${LIVE_INSTALL_KERNEL_PATH}/${INITRD} ${TAPPEND} ${LH_BOOTAPPEND_INSTALL}\n"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\tappend initrd=${LIVE_INSTALL_KERNEL_PATH}/${INITRD} ${TAPPEND} ${LB_BOOTAPPEND_INSTALL}\n"
|
||||
done
|
||||
}
|
||||
|
||||
|
@ -192,13 +192,13 @@ Copy_syslinux_templates ()
|
|||
{
|
||||
cp -r "${TEMPLATES}"/common/* ${SCREEN_PATH}
|
||||
|
||||
if [ "${LH_SYSLINUX_MENU}" = "false" ]
|
||||
if [ "${LB_SYSLINUX_MENU}" = "false" ]
|
||||
then
|
||||
cp -r "${TEMPLATES}"/normal/* ${SCREEN_PATH}
|
||||
else
|
||||
cp -r "${TEMPLATES}"/menu/* ${SCREEN_PATH}
|
||||
|
||||
case "${LH_SYSLINUX_MENU}" in
|
||||
case "${LB_SYSLINUX_MENU}" in
|
||||
gfxboot)
|
||||
MENUMODULE="gfxboot.c32"
|
||||
;;
|
||||
|
@ -212,16 +212,16 @@ Copy_syslinux_templates ()
|
|||
;;
|
||||
|
||||
*)
|
||||
if [ -z "${LH_SYSLINUX_CFG}" ]
|
||||
if [ -z "${LB_SYSLINUX_CFG}" ]
|
||||
then
|
||||
MENUMODULE=$(grep 'menu.c32' ${TEMPLATES}/menu/syslinux.cfg | sed 's|default\s*.*/\(.*menu.c32\)$|\1|g')
|
||||
else
|
||||
LH_SYSLINUX_CFG="${LH_SYSLINUX_CFG:-${TEMPLATES}/menu/syslinux.cfg}"
|
||||
LB_SYSLINUX_CFG="${LB_SYSLINUX_CFG:-${TEMPLATES}/menu/syslinux.cfg}"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
cp chroot/usr/lib/syslinux/"${MENUMODULE}" ${DATA_PATH}
|
||||
;;
|
||||
|
@ -231,9 +231,9 @@ Copy_syslinux_templates ()
|
|||
esac
|
||||
fi
|
||||
|
||||
if ls "${TEMPLATES}/${LH_LANGUAGE}"/* > /dev/null 2>&1
|
||||
if ls "${TEMPLATES}/${LB_LANGUAGE}"/* > /dev/null 2>&1
|
||||
then
|
||||
cp -r "${TEMPLATES}"/"${LH_LANGUAGE}"/* ${SCREEN_PATH}
|
||||
cp -r "${TEMPLATES}"/"${LB_LANGUAGE}"/* ${SCREEN_PATH}
|
||||
else
|
||||
if ls "${TEMPLATES}"/en/* > /dev/null 2>&1
|
||||
then
|
||||
|
@ -249,7 +249,7 @@ Copy_syslinux_templates ()
|
|||
done
|
||||
fi
|
||||
|
||||
if [ "${LH_DEBIAN_INSTALLER}" != "false" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" != "false" ]
|
||||
then
|
||||
if ls ${SCREEN_PATH}/*.install > /dev/null 2>&1
|
||||
then
|
||||
|
@ -259,7 +259,7 @@ Copy_syslinux_templates ()
|
|||
done
|
||||
fi
|
||||
|
||||
case "${LH_ARCHITECTURE}" in
|
||||
case "${LB_ARCHITECTURE}" in
|
||||
amd64|i386|powerpc)
|
||||
if ls ${SCREEN_PATH}/*.install.g-i > /dev/null 2>&1
|
||||
then
|
||||
|
@ -278,36 +278,36 @@ Copy_syslinux_templates ()
|
|||
rm -f ${SCREEN_PATH}/*.install*
|
||||
fi
|
||||
|
||||
if [ "${LH_SYSLINUX_MENU}" != "false" ]
|
||||
if [ "${LB_SYSLINUX_MENU}" != "false" ]
|
||||
then
|
||||
rm -f ${DATA_PATH}/boot.txt
|
||||
fi
|
||||
|
||||
# Copying custom splash screen
|
||||
if [ "${LH_SYSLINUX_SPLASH}" = "none" ]
|
||||
if [ "${LB_SYSLINUX_SPLASH}" = "none" ]
|
||||
then
|
||||
# no splash screen
|
||||
SPLASH=""
|
||||
rm -f ${SCREEN_PATH}/splash.rle
|
||||
rm -f ${DATA_PATH}/splash.png
|
||||
else
|
||||
if [ "${LH_SYSLINUX_MENU}" = "false" ]
|
||||
if [ "${LB_SYSLINUX_MENU}" = "false" ]
|
||||
then
|
||||
SPLASH="${LIVE_DATA_PATH}/splash.rle"
|
||||
else
|
||||
SPLASH="${LIVE_DATA_PATH}/splash.png"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_SYSLINUX_SPLASH}" ]
|
||||
if [ -n "${LB_SYSLINUX_SPLASH}" ]
|
||||
then
|
||||
if [ ! -e "${LH_SYSLINUX_SPLASH}" ]
|
||||
if [ ! -e "${LB_SYSLINUX_SPLASH}" ]
|
||||
then
|
||||
Echo_error "%s doen't exist" "${LH_SYSLINUX_SPLASH}"
|
||||
Echo_error "%s doen't exist" "${LB_SYSLINUX_SPLASH}"
|
||||
exit 1
|
||||
else
|
||||
rm -f ${SCREEN_PATH}/splash.rle
|
||||
rm -f ${DATA_PATH}/splash.png
|
||||
cp -f "${LH_SYSLINUX_SPLASH}" ${DATA_PATH}/$(basename ${SPLASH})
|
||||
cp -f "${LB_SYSLINUX_SPLASH}" ${DATA_PATH}/$(basename ${SPLASH})
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
@ -326,15 +326,15 @@ Configure_syslinux_templates ()
|
|||
-e "s|{\$LIVE_DATA_PATH}|${LIVE_DATA_PATH}|" \
|
||||
-e "s|{\$LIVE_KERNEL_PATH}|${LIVE_KERNEL_PATH}|" \
|
||||
-e "s|{\$SPLASH}|${SPLASH}|" \
|
||||
-e "s|{\$LH_DISTRIBUTION}|${LH_DISTRIBUTION}|" \
|
||||
-e "s|{\$LH_DATE}|$(date +%Y%m%d)|" \
|
||||
-e "s|{\$LH_MEDIA}|${MEDIA}|" \
|
||||
-e "s|{\$LH_VERSION}|${VERSION}|" \
|
||||
-e "s|{\$LH_SYSLINUX_TIMEOUT}|${LH_SYSLINUX_TIMEOUT}0|" \
|
||||
-e "s|{\$LB_DISTRIBUTION}|${LB_DISTRIBUTION}|" \
|
||||
-e "s|{\$LB_DATE}|$(date +%Y%m%d)|" \
|
||||
-e "s|{\$LB_MEDIA}|${MEDIA}|" \
|
||||
-e "s|{\$LB_VERSION}|${VERSION}|" \
|
||||
-e "s|{\$LB_SYSLINUX_TIMEOUT}|${LB_SYSLINUX_TIMEOUT}0|" \
|
||||
$template_file
|
||||
done
|
||||
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
usb*)
|
||||
if [ -f "${SYSLINUX_PATH}/exithelp.cfg" ]
|
||||
then
|
||||
|
@ -352,7 +352,7 @@ Configure_syslinux_templates ()
|
|||
}
|
||||
|
||||
# Setting up common variables
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
INITFS="casper"
|
||||
;;
|
||||
|
@ -363,7 +363,7 @@ case "${LH_INITRAMFS}" in
|
|||
esac
|
||||
|
||||
# Setting boot method specific variables
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
iso*)
|
||||
SYSLINUX_PATH="binary/isolinux"
|
||||
KERNEL_PATH="binary/${INITFS}"
|
||||
|
@ -378,12 +378,12 @@ case "${LH_BINARY_IMAGES}" in
|
|||
|
||||
net)
|
||||
SYSLINUX_PATH="tftpboot"
|
||||
KERNEL_PATH="${SYSLINUX_PATH}/debian-live/${LH_ARCHITECTURE}"
|
||||
SCREEN_PATH="${SYSLINUX_PATH}/debian-live/${LH_ARCHITECTURE}/boot-screens"
|
||||
KERNEL_PATH="${SYSLINUX_PATH}/debian-live/${LB_ARCHITECTURE}"
|
||||
SCREEN_PATH="${SYSLINUX_PATH}/debian-live/${LB_ARCHITECTURE}/boot-screens"
|
||||
DATA_PATH="${SCREEN_PATH}"
|
||||
LIVE_KERNEL_PATH="debian-live/${LH_ARCHITECTURE}"
|
||||
LIVE_INSTALL_KERNEL_PATH="debian-install/${LH_ARCHITECTURE}"
|
||||
LIVE_SCREEN_PATH="debian-live/${LH_ARCHITECTURE}/boot-screens"
|
||||
LIVE_KERNEL_PATH="debian-live/${LB_ARCHITECTURE}"
|
||||
LIVE_INSTALL_KERNEL_PATH="debian-install/${LB_ARCHITECTURE}"
|
||||
LIVE_SCREEN_PATH="debian-live/${LB_ARCHITECTURE}/boot-screens"
|
||||
LIVE_DATA_PATH="${LIVE_SCREEN_PATH}"
|
||||
MEDIA="netboot"
|
||||
;;
|
||||
|
@ -409,65 +409,65 @@ mkdir -p "${SCREEN_PATH}"
|
|||
mkdir -p "${DATA_PATH}"
|
||||
|
||||
# Setting boot parameters
|
||||
case "${LH_ENCRYPTION}" in
|
||||
case "${LB_ENCRYPTION}" in
|
||||
""|false)
|
||||
;;
|
||||
*)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} encryption=${LH_ENCRYPTION}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} encryption=${LB_ENCRYPTION}"
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -n "${LH_USERNAME}" ]
|
||||
if [ -n "${LB_USERNAME}" ]
|
||||
then
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} username=${LH_USERNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} username=${LB_USERNAME}"
|
||||
;;
|
||||
|
||||
live-initramfs|live-boot)
|
||||
if [ "${LH_USERNAME}" != "user" ]
|
||||
if [ "${LB_USERNAME}" != "user" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} username=${LH_USERNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} username=${LB_USERNAME}"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
if [ -n "${LH_HOSTNAME}" ]
|
||||
if [ -n "${LB_HOSTNAME}" ]
|
||||
then
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} hostname=${LH_HOSTNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} hostname=${LB_HOSTNAME}"
|
||||
;;
|
||||
|
||||
live-initramfs|live-boot)
|
||||
if [ "${LH_HOSTNAME}" != "debian" ]
|
||||
if [ "${LB_HOSTNAME}" != "debian" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} hostname=${LH_HOSTNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} hostname=${LB_HOSTNAME}"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
if [ "${LH_UNION_FILESYSTEM}" != "aufs" ]
|
||||
if [ "${LB_UNION_FILESYSTEM}" != "aufs" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} union=${LH_UNION_FILESYSTEM}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} union=${LB_UNION_FILESYSTEM}"
|
||||
fi
|
||||
|
||||
if [ "${LH_EXPOSED_ROOT}" != "false" ]
|
||||
if [ "${LB_EXPOSED_ROOT}" != "false" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} exposedroot"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} exposedroot"
|
||||
fi
|
||||
|
||||
if [ "${LH_BINARY_IMAGES}" = "net" ]
|
||||
if [ "${LB_BINARY_IMAGES}" = "net" ]
|
||||
then
|
||||
case "${LH_NET_ROOT_FILESYSTEM}" in
|
||||
case "${LB_NET_ROOT_FILESYSTEM}" in
|
||||
nfs)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} netboot=nfs nfsroot=${LH_NET_ROOT_SERVER}:${LH_NET_ROOT_PATH}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} netboot=nfs nfsroot=${LB_NET_ROOT_SERVER}:${LB_NET_ROOT_PATH}"
|
||||
;;
|
||||
|
||||
cifs)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} netboot=cifs nfsroot=//${LH_NET_ROOT_SERVER}${LH_NET_ROOT_PATH}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} netboot=cifs nfsroot=//${LB_NET_ROOT_SERVER}${LB_NET_ROOT_PATH}"
|
||||
;;
|
||||
|
||||
*)
|
||||
|
@ -476,22 +476,22 @@ then
|
|||
;;
|
||||
esac
|
||||
|
||||
if [ -n "${LH_NET_ROOT_MOUNTOPTIONS}" ]
|
||||
if [ -n "${LB_NET_ROOT_MOUNTOPTIONS}" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} nfsopts=${LH_NET_ROOT_MOUNTOPTIONS}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} nfsopts=${LB_NET_ROOT_MOUNTOPTIONS}"
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ -n "${LH_NET_COW_PATH}" ]
|
||||
if [ -n "${LB_NET_COW_PATH}" ]
|
||||
then
|
||||
case "${LH_NET_COW_FILESYSTEM}" in
|
||||
case "${LB_NET_COW_FILESYSTEM}" in
|
||||
nfs)
|
||||
if [ -n "${LH_NET_COW_MOUNTOPTIONS}" ]
|
||||
if [ -n "${LB_NET_COW_MOUNTOPTIONS}" ]
|
||||
then
|
||||
LH_NET_COW_MOUNTOPTIONS=",${LH_NET_COW_MOUNTOPTIONS}"
|
||||
LB_NET_COW_MOUNTOPTIONS=",${LB_NET_COW_MOUNTOPTIONS}"
|
||||
fi
|
||||
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} nfscow=${LH_NET_COW_SERVER}:${LH_NET_COW_PATH}${LH_NET_COW_MOUNTOPTIONS}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} nfscow=${LB_NET_COW_SERVER}:${LB_NET_COW_PATH}${LB_NET_COW_MOUNTOPTIONS}"
|
||||
;;
|
||||
|
||||
*)
|
||||
|
@ -501,7 +501,7 @@ then
|
|||
esac
|
||||
fi
|
||||
|
||||
LH_BOOTAPPEND_LIVE="$(echo ${LH_BOOTAPPEND_LIVE} | sed -e 's| ||')"
|
||||
LB_BOOTAPPEND_LIVE="$(echo ${LB_BOOTAPPEND_LIVE} | sed -e 's| ||')"
|
||||
|
||||
# Parameters are listed at: linux/Documentation/kernel-parameters.txt
|
||||
FAILSAFE="noapic noapm nodma nomce nolapic nomodeset nosmp vga=normal"
|
||||
|
@ -512,34 +512,34 @@ then
|
|||
mv binary/${INITFS}/vmlinuz* ${KERNEL_PATH}
|
||||
mv binary/${INITFS}/initrd* ${KERNEL_PATH}
|
||||
|
||||
if [ "${LH_MEMTEST}" != "false" ] && [ "${LH_MEMTEST}" != "none" ]
|
||||
if [ "${LB_MEMTEST}" != "false" ] && [ "${LB_MEMTEST}" != "none" ]
|
||||
then
|
||||
mv binary/${INITFS}/memtest ${KERNEL_PATH}
|
||||
fi
|
||||
fi
|
||||
|
||||
# Default entries
|
||||
DEFAULT_FLAVOUR="$(echo ${LH_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DEFAULT_FLAVOUR="$(echo ${LB_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DEFAULT_KERNEL="$(basename chroot/boot/vmlinuz-*${DEFAULT_FLAVOUR})"
|
||||
DEFAULT_INITRD="initrd.img-$(echo ${DEFAULT_KERNEL} | sed -e 's|vmlinuz-||')"
|
||||
|
||||
Syslinux_live_entry "live" "${LH_SYSLINUX_MENU_LIVE_ENTRY}" "${DEFAULT_KERNEL}" "${DEFAULT_INITRD}"
|
||||
Syslinux_live_entry "live" "${LB_SYSLINUX_MENU_LIVE_ENTRY}" "${DEFAULT_KERNEL}" "${DEFAULT_INITRD}"
|
||||
|
||||
if [ "$(echo ${LH_LINUX_FLAVOURS} | wc -w)" -gt "1" ]
|
||||
if [ "$(echo ${LB_LINUX_FLAVOURS} | wc -w)" -gt "1" ]
|
||||
then
|
||||
for FLAVOUR in ${LH_LINUX_FLAVOURS}
|
||||
for FLAVOUR in ${LB_LINUX_FLAVOURS}
|
||||
do
|
||||
if [ "${FLAVOUR}" != "${DEFAULT_FLAVOUR}" ]
|
||||
then
|
||||
FLAVOUR_KERNEL="$(basename chroot/boot/vmlinuz-*${FLAVOUR})"
|
||||
FLAVOUR_INITRD="initrd.img-$(echo ${FLAVOUR_KERNEL} | sed -e 's|vmlinuz-||')"
|
||||
Syslinux_live_entry "live-${FLAVOUR}" "${LH_SYSLINUX_MENU_LIVE_ENTRY} ${FLAVOUR}" "${FLAVOUR_KERNEL}" "${FLAVOUR_INITRD}"
|
||||
Syslinux_live_entry "live-${FLAVOUR}" "${LB_SYSLINUX_MENU_LIVE_ENTRY} ${FLAVOUR}" "${FLAVOUR_KERNEL}" "${FLAVOUR_INITRD}"
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
# Only needed for non-vesamenu, non-gfxboot syslinux
|
||||
case "${LH_SYSLINUX_MENU}" in
|
||||
case "${LB_SYSLINUX_MENU}" in
|
||||
false|menu)
|
||||
# Adding syslinux hardcoded default label entry
|
||||
Syslinux_live_entry "linux" "" "${DEFAULT_KERNEL}" "${DEFAULT_INITRD}"
|
||||
|
@ -547,7 +547,7 @@ case "${LH_SYSLINUX_MENU}" in
|
|||
esac
|
||||
|
||||
# Assembling debian-installer configuration
|
||||
if [ "${LH_DEBIAN_INSTALLER}" != "false" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" != "false" ]
|
||||
then
|
||||
VMLINUZ_DI="vmlinuz"
|
||||
INITRD_DI="initrd.gz"
|
||||
|
@ -571,7 +571,7 @@ fi
|
|||
# Assembling memtest configuration
|
||||
if [ -f "${KERNEL_PATH}"/memtest ]
|
||||
then
|
||||
Syslinux_memtest_entry "memtest" "${LH_SYSLINUX_MENU_MEMTEST_ENTRY}" "memtest"
|
||||
Syslinux_memtest_entry "memtest" "${LB_SYSLINUX_MENU_MEMTEST_ENTRY}" "memtest"
|
||||
fi
|
||||
|
||||
# Copy templates to base syslinux directory
|
||||
|
@ -581,9 +581,9 @@ Copy_syslinux_templates
|
|||
Configure_syslinux_templates
|
||||
|
||||
# Configure syslinux setup per boot method
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
iso*)
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
cp chroot/usr/lib/syslinux/isolinux.bin ${SCREEN_PATH}
|
||||
;;
|
||||
|
@ -595,14 +595,14 @@ case "${LH_BINARY_IMAGES}" in
|
|||
mv ${SCREEN_PATH}/syslinux.cfg ${SCREEN_PATH}/isolinux.cfg
|
||||
|
||||
# Copying configuration file
|
||||
if [ -n "${LH_SYSLINUX_CFG}" ]
|
||||
if [ -n "${LB_SYSLINUX_CFG}" ]
|
||||
then
|
||||
cp "${LH_SYSLINUX_CFG}" ${SCREEN_PATH}/isolinux.cfg
|
||||
cp "${LB_SYSLINUX_CFG}" ${SCREEN_PATH}/isolinux.cfg
|
||||
fi
|
||||
;;
|
||||
|
||||
net)
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
cp chroot/usr/lib/syslinux/pxelinux.0 ${KERNEL_PATH}
|
||||
;;
|
||||
|
@ -626,14 +626,14 @@ case "${LH_BINARY_IMAGES}" in
|
|||
mv ${SCREEN_PATH}/syslinux.cfg ${KERNEL_PATH}/pxelinux.cfg/default
|
||||
|
||||
# Copying configuration file
|
||||
if [ -n "${LH_SYSLINUX_CFG}" ]
|
||||
if [ -n "${LB_SYSLINUX_CFG}" ]
|
||||
then
|
||||
cp "${LH_SYSLINUX_CFG}" ${KERNEL_PATH}/pxelinux.cfg/default
|
||||
cp "${LB_SYSLINUX_CFG}" ${KERNEL_PATH}/pxelinux.cfg/default
|
||||
fi
|
||||
;;
|
||||
|
||||
usb*|tar)
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
cp chroot/usr/lib/syslinux/isolinux.bin ${SCREEN_PATH}/syslinux.bin
|
||||
;;
|
||||
|
@ -643,9 +643,9 @@ case "${LH_BINARY_IMAGES}" in
|
|||
esac
|
||||
|
||||
# Copying configuration file
|
||||
if [ -n "${LH_SYSLINUX_CFG}" ]
|
||||
if [ -n "${LB_SYSLINUX_CFG}" ]
|
||||
then
|
||||
cp "${LH_SYSLINUX_CFG}" ${SCREEN_PATH}/syslinux.cfg
|
||||
cp "${LB_SYSLINUX_CFG}" ${SCREEN_PATH}/syslinux.cfg
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'build harddisk binary image')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if ! In_list tar "${LH_BINARY_IMAGES}"
|
||||
if ! In_list tar "${LB_BINARY_IMAGES}"
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'build binary image')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if ! In_list usb-hdd "${LH_BINARY_IMAGES}"
|
||||
if ! In_list usb-hdd "${LB_BINARY_IMAGES}"
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -48,9 +48,9 @@ Check_package chroot/sbin/mkdosfs dosfstools
|
|||
Check_package chroot/usr/share/doc/mtools mtools
|
||||
Check_package chroot/sbin/parted parted
|
||||
|
||||
if [ "${LH_ARCHITECTURE}" = "sparc" ]
|
||||
if [ "${LB_ARCHITECTURE}" = "sparc" ]
|
||||
then
|
||||
case "${LH_BINARY_FILESYSTEM}" in
|
||||
case "${LB_BINARY_FILESYSTEM}" in
|
||||
ext2|ext3)
|
||||
Check_package chroot/sbin/mkfs.ext2 e2fsprogs
|
||||
;;
|
||||
|
@ -62,7 +62,7 @@ then
|
|||
esac
|
||||
fi
|
||||
|
||||
case "${LH_BOOTLOADER}" in
|
||||
case "${LB_BOOTLOADER}" in
|
||||
grub)
|
||||
Check_package chroot/usr/sbin/grub grub
|
||||
;;
|
||||
|
@ -85,28 +85,28 @@ then
|
|||
fi
|
||||
|
||||
# Enforce fat32 if we find individual files bigger than 2GB
|
||||
if [ "${LH_BINARY_FILESYSTEM}" = "fat16" ] && [ -n "$(find binary -size +1999M)" ]
|
||||
if [ "${LB_BINARY_FILESYSTEM}" = "fat16" ] && [ -n "$(find binary -size +1999M)" ]
|
||||
then
|
||||
Echo_warning "FAT16 doesn't support files larger than 2GB, automatically enforcing FAT32."
|
||||
|
||||
LH_BINARY_FILESYSTEM="fat32"
|
||||
export LH_BINARY_FILESYSTEM
|
||||
LB_BINARY_FILESYSTEM="fat32"
|
||||
export LB_BINARY_FILESYSTEM
|
||||
fi
|
||||
|
||||
# Enforce fat32 if we have images in total bigger than 2GB
|
||||
if [ "${LH_BINARY_FILESYSTEM}" = "fat16" ] && [ "$(du -s binary | awk '{ print $1 }')" -gt "1900000" ]
|
||||
if [ "${LB_BINARY_FILESYSTEM}" = "fat16" ] && [ "$(du -s binary | awk '{ print $1 }')" -gt "1900000" ]
|
||||
then
|
||||
Echo_warning "FAT16 doesn't support partitions larger than 2GB, automatically enforcing FAT32"
|
||||
|
||||
LH_BINARY_FILESYSTEM="fat32"
|
||||
export LH_BINARY_FILESYSTEM
|
||||
LB_BINARY_FILESYSTEM="fat32"
|
||||
export LB_BINARY_FILESYSTEM
|
||||
fi
|
||||
|
||||
# Everything which comes here needs to be cleaned up,
|
||||
DU_DIM="$(du -ms binary | cut -f1)"
|
||||
REAL_DIM="$(Calculate_partition_size ${DU_DIM} ${LH_BINARY_FILESYSTEM})"
|
||||
REAL_DIM="$(Calculate_partition_size ${DU_DIM} ${LB_BINARY_FILESYSTEM})"
|
||||
dd if=/dev/zero of=chroot/binary.img bs=1024k count=0 seek=${REAL_DIM}
|
||||
FREELO="$(${LH_LOSETUP} -f)"
|
||||
FREELO="$(${LB_LOSETUP} -f)"
|
||||
if [ ! -b chroot/${FREELO} ]
|
||||
then
|
||||
MAKEDEV="true"
|
||||
|
@ -118,7 +118,7 @@ fi
|
|||
echo "!!! The following error/warning messages can be ignored !!!"
|
||||
Losetup $FREELO chroot/binary.img 0
|
||||
|
||||
case "${LH_ARCHITECTURE}" in
|
||||
case "${LB_ARCHITECTURE}" in
|
||||
sparc)
|
||||
PARTITION_TABLE_TYPE="sun"
|
||||
;;
|
||||
|
@ -127,29 +127,29 @@ case "${LH_ARCHITECTURE}" in
|
|||
;;
|
||||
esac
|
||||
|
||||
case "${LH_BINARY_FILESYSTEM}" in
|
||||
case "${LB_BINARY_FILESYSTEM}" in
|
||||
ext2|ext3)
|
||||
PARTITION_TYPE="ext2"
|
||||
;;
|
||||
|
||||
fat16|fat32)
|
||||
PARTITION_TYPE="${LH_BINARY_FILESYSTEM}"
|
||||
PARTITION_TYPE="${LB_BINARY_FILESYSTEM}"
|
||||
;;
|
||||
|
||||
*)
|
||||
Echo_error "Unsupported binary filesystem %s" "${LH_BINARY_FILESYSTEM}"
|
||||
Echo_error "Unsupported binary filesystem %s" "${LB_BINARY_FILESYSTEM}"
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
Chroot chroot "parted -s ${FREELO} mklabel ${PARTITION_TABLE_TYPE}" || true
|
||||
Chroot chroot "parted -s ${FREELO} mkpart primary ${PARTITION_TYPE} 0.0 100%" || true
|
||||
Chroot chroot "parted -s ${FREELO} set 1 boot on" || true
|
||||
Chroot chroot "parted -s ${FREELO} set 1 lba off" || true
|
||||
|
||||
if [ "${LH_BOOTLOADER}" = "syslinux" ]
|
||||
if [ "${LB_BOOTLOADER}" = "syslinux" ]
|
||||
then
|
||||
dd if=chroot/usr/lib/syslinux/mbr.bin of=${FREELO} bs=440 count=1
|
||||
fi
|
||||
|
@ -161,7 +161,7 @@ case "${LH_BUILD_WITH_CHROOT}" in
|
|||
parted -s ${FREELO} set 1 boot on || true
|
||||
parted -s ${FREELO} set 1 lba off || true
|
||||
|
||||
if [ "${LH_BOOTLOADER}" = "syslinux" ]
|
||||
if [ "${LB_BOOTLOADER}" = "syslinux" ]
|
||||
then
|
||||
dd if=/usr/lib/syslinux/mbr.bin of=${FREELO} bs=440 count=1
|
||||
fi
|
||||
|
@ -169,14 +169,14 @@ case "${LH_BUILD_WITH_CHROOT}" in
|
|||
esac
|
||||
|
||||
sleep 1
|
||||
${LH_LOSETUP} -d ${FREELO}
|
||||
${LB_LOSETUP} -d ${FREELO}
|
||||
|
||||
FREELO="$(${LH_LOSETUP} -f)"
|
||||
FREELO="$(${LB_LOSETUP} -f)"
|
||||
Losetup $FREELO chroot/binary.img 1
|
||||
|
||||
case "${LH_BINARY_FILESYSTEM}" in
|
||||
case "${LB_BINARY_FILESYSTEM}" in
|
||||
ext2|ext3)
|
||||
MKFS="${LH_BINARY_FILESYSTEM}"
|
||||
MKFS="${LB_BINARY_FILESYSTEM}"
|
||||
MKFS_OPTIONS="-L DEBIAN_LIVE -m 0"
|
||||
;;
|
||||
|
||||
|
@ -191,7 +191,7 @@ case "${LH_BINARY_FILESYSTEM}" in
|
|||
;;
|
||||
esac
|
||||
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
Chroot chroot "mkfs.${MKFS} ${MKFS_OPTIONS} ${FREELO}"
|
||||
;;
|
||||
|
@ -201,19 +201,19 @@ case "${LH_BUILD_WITH_CHROOT}" in
|
|||
;;
|
||||
esac
|
||||
|
||||
case "${LH_BINARY_FILESYSTEM}" in
|
||||
case "${LB_BINARY_FILESYSTEM}" in
|
||||
fat*)
|
||||
CP_OPTIONS="-L"
|
||||
;;
|
||||
esac
|
||||
|
||||
mkdir -p chroot/binary.tmp
|
||||
${LH_ROOT_COMMAND} mount ${FREELO} chroot/binary.tmp
|
||||
${LB_ROOT_COMMAND} mount ${FREELO} chroot/binary.tmp
|
||||
cp -r -T ${CP_OPTIONS} binary/ chroot/binary.tmp
|
||||
|
||||
FIXME()
|
||||
{
|
||||
if [ "${LH_BOOTLOADER}" = "grub" ]
|
||||
if [ "${LB_BOOTLOADER}" = "grub" ]
|
||||
then
|
||||
|
||||
cat > chroot/grub.sh << EOF
|
||||
|
@ -242,12 +242,12 @@ EOF
|
|||
fi
|
||||
}
|
||||
|
||||
${LH_ROOT_COMMAND} umount chroot/binary.tmp
|
||||
${LB_ROOT_COMMAND} umount chroot/binary.tmp
|
||||
rmdir chroot/binary.tmp
|
||||
|
||||
if [ "${LH_BOOTLOADER}" = "syslinux" ]
|
||||
if [ "${LB_BOOTLOADER}" = "syslinux" ]
|
||||
then
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
Chroot chroot "syslinux ${FREELO}"
|
||||
;;
|
||||
|
@ -259,7 +259,7 @@ then
|
|||
fi
|
||||
|
||||
sleep 1
|
||||
${LH_LOSETUP} -d ${FREELO}
|
||||
${LB_LOSETUP} -d ${FREELO}
|
||||
|
||||
echo "!!! The above error/warning messages can be ignored !!!"
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'build binary image')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if ! In_list virtual-hdd "${LH_BINARY_IMAGES}"
|
||||
if ! In_list virtual-hdd "${LB_BINARY_IMAGES}"
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -43,9 +43,9 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ "${LH_BUILD_WITH_CHROOT}" = "true" ]
|
||||
if [ "${LB_BUILD_WITH_CHROOT}" = "true" ]
|
||||
then
|
||||
case "${LH_BINARY_FILESYSTEM}" in
|
||||
case "${LB_BINARY_FILESYSTEM}" in
|
||||
ext2|ext3)
|
||||
Check_package chroot/sbin/mkfs.ext2 e2fsprogs
|
||||
;;
|
||||
|
@ -65,9 +65,9 @@ then
|
|||
fi
|
||||
|
||||
Echo_message "Creating virtual disk image..."
|
||||
dd if=/dev/zero of=binary-virtual.img bs=1024k count=0 seek=${LH_VIRTUAL_ROOT_SIZE}
|
||||
dd if=/dev/zero of=binary-virtual.img bs=1024k count=0 seek=${LB_VIRTUAL_ROOT_SIZE}
|
||||
|
||||
if [ "${LH_BUILD_WITH_CHROOT}" = "true" ]
|
||||
if [ "${LB_BUILD_WITH_CHROOT}" = "true" ]
|
||||
then
|
||||
mv binary-virtual.img chroot
|
||||
|
||||
|
@ -78,7 +78,7 @@ then
|
|||
Chroot chroot "ln -s /proc/mounts /etc/mtab"
|
||||
fi
|
||||
|
||||
case "${LH_BINARY_FILESYSTEM}" in
|
||||
case "${LB_BINARY_FILESYSTEM}" in
|
||||
ext2)
|
||||
Chroot chroot "mkfs.ext2 -F binary-virtual.img"
|
||||
;;
|
||||
|
@ -90,7 +90,7 @@ then
|
|||
|
||||
mv chroot/binary-virtual.img ./
|
||||
else
|
||||
case "${LH_BINARY_FILESYSTEM}" in
|
||||
case "${LB_BINARY_FILESYSTEM}" in
|
||||
ext2)
|
||||
mkfs.ext2 -F binary-virtual.img
|
||||
;;
|
||||
|
@ -102,11 +102,11 @@ else
|
|||
fi
|
||||
|
||||
mkdir -p binary.tmp
|
||||
${LH_ROOT_COMMAND} mount -o loop binary-virtual.img binary.tmp
|
||||
${LB_ROOT_COMMAND} mount -o loop binary-virtual.img binary.tmp
|
||||
cp -a binary/* binary.tmp
|
||||
cp -af binary/.disk* binary.tmp
|
||||
|
||||
${LH_ROOT_COMMAND} umount binary.tmp
|
||||
${LB_ROOT_COMMAND} umount binary.tmp
|
||||
rmdir binary.tmp
|
||||
|
||||
# Saving cache
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'copy win32-loader into binary')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_WIN32_LOADER}" != "true" ] || [ "${LH_BINARY_IMAGES}" = "virtual-hdd" ]
|
||||
if [ "${LB_WIN32_LOADER}" != "true" ] || [ "${LB_BINARY_IMAGES}" = "virtual-hdd" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -43,9 +43,9 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
case "${LH_ARCHITECTURE}" in
|
||||
case "${LB_ARCHITECTURE}" in
|
||||
amd64|i386)
|
||||
case "${LH_DISTRIBUTION}" in
|
||||
case "${LB_DISTRIBUTION}" in
|
||||
lenny|squeeze)
|
||||
WIN32_LOADER="/usr/lib/win32-loader"
|
||||
;;
|
||||
|
@ -55,7 +55,7 @@ case "${LH_ARCHITECTURE}" in
|
|||
;;
|
||||
esac
|
||||
|
||||
if [ "${LH_BUILD_WITH_CHROOT}" = "true" ]
|
||||
if [ "${LB_BUILD_WITH_CHROOT}" = "true" ]
|
||||
then
|
||||
# Checking depends
|
||||
Check_package chroot/${WIN32_LOADER}/win32-loader.exe win32-loader
|
||||
|
@ -79,12 +79,12 @@ case "${LH_ARCHITECTURE}" in
|
|||
mv binary/win32-loader-standalone.exe binary/setup-standalone.exe
|
||||
fi
|
||||
|
||||
if [ "${LH_DEBIAN_INSTALLER}" != "false" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" != "false" ]
|
||||
then
|
||||
|
||||
cat > binary/win32-loader.ini << EOF
|
||||
[installer]
|
||||
arch=${LH_ARCHITECTURE}
|
||||
arch=${LB_ARCHITECTURE}
|
||||
i386/linux=install/vmlinuz
|
||||
i386/initrd=install/initrd.gz
|
||||
i386/gtk/linux=install/vmlinuz
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'installs yaboot into binary')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_BOOTLOADER}" != "yaboot" ]
|
||||
if [ "${LB_BOOTLOADER}" != "yaboot" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -72,7 +72,7 @@ Yaboot_live_entry ()
|
|||
LINUX_LIVE="${LINUX_LIVE}\nimage=${DIRECTORY}/${KERNEL}\n"
|
||||
LINUX_LIVE="${LINUX_LIVE}\tlabel=${LABEL}\n"
|
||||
LINUX_LIVE="${LINUX_LIVE}\tinitrd=${DIRECTORY}/${INITRD}\n"
|
||||
LINUX_LIVE="${LINUX_LIVE}\tappend=\"boot=${INITFS} live-config LH_BOOTAPPEND_LIVE ${APPEND}\"\n"
|
||||
LINUX_LIVE="${LINUX_LIVE}\tappend=\"boot=${INITFS} live-config LB_BOOTAPPEND_LIVE ${APPEND}\"\n"
|
||||
LINUX_LIVE="${LINUX_LIVE}\tinitrd-size=10240\n"
|
||||
}
|
||||
|
||||
|
@ -119,12 +119,12 @@ Yaboot_install_entry ()
|
|||
LINUX_INSTALL="${LINUX_INSTALL}\nimage=${DIRECTORY}/${KERNEL}\n"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\tlabel=${TYPE}${TYPE_SUFFIX}\n"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\tinitrd=${DIRECTORY}/${INITRD}\n"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\tappend=\"${TAPPEND} ${LH_BOOTAPPEND_INSTALL}\"\n"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\tappend=\"${TAPPEND} ${LB_BOOTAPPEND_INSTALL}\"\n"
|
||||
LINUX_INSTALL="${LINUX_INSTALL}\tinitrd-size=10240\n"
|
||||
done
|
||||
}
|
||||
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
INITFS="casper"
|
||||
;;
|
||||
|
@ -135,9 +135,9 @@ case "${LH_INITRAMFS}" in
|
|||
esac
|
||||
|
||||
# Setting destination directory
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
iso*)
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
DESTDIR_LIVE="binary/casper"
|
||||
;;
|
||||
|
@ -162,63 +162,63 @@ Check_multiarchitecture
|
|||
mkdir -p "${DESTDIR_LIVE}"
|
||||
|
||||
# Setting boot parameters
|
||||
case "${LH_ENCRYPTION}" in
|
||||
case "${LB_ENCRYPTION}" in
|
||||
""|false)
|
||||
;;
|
||||
*)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} encryption=${LH_ENCRYPTION}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} encryption=${LB_ENCRYPTION}"
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -n "${LH_USERNAME}" ]
|
||||
if [ -n "${LB_USERNAME}" ]
|
||||
then
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} username=${LH_USERNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} username=${LB_USERNAME}"
|
||||
;;
|
||||
|
||||
live-initramfs|live-boot)
|
||||
if [ "${LH_USERNAME}" != "user" ]
|
||||
if [ "${LB_USERNAME}" != "user" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} username=${LH_USERNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} username=${LB_USERNAME}"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
if [ -n "${LH_HOSTNAME}" ]
|
||||
if [ -n "${LB_HOSTNAME}" ]
|
||||
then
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} hostname=${LH_HOSTNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} hostname=${LB_HOSTNAME}"
|
||||
;;
|
||||
|
||||
live-initramfs|live-boot)
|
||||
if [ "${LH_HOSTNAME}" != "debian" ]
|
||||
if [ "${LB_HOSTNAME}" != "debian" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} hostname=${LH_HOSTNAME}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} hostname=${LB_HOSTNAME}"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
if [ "${LH_UNION_FILESYSTEM}" != "aufs" ]
|
||||
if [ "${LB_UNION_FILESYSTEM}" != "aufs" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} union=${LH_UNION_FILESYSTEM}"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} union=${LB_UNION_FILESYSTEM}"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_NET_COW_PATH}" ]
|
||||
if [ -n "${LB_NET_COW_PATH}" ]
|
||||
then
|
||||
Echo_error "Net cow not yet supported on yaboot"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ "${LH_EXPOSED_ROOT}" != "false" ]
|
||||
if [ "${LB_EXPOSED_ROOT}" != "false" ]
|
||||
then
|
||||
LH_BOOTAPPEND_LIVE="${LH_BOOTAPPEND_LIVE} exposedroot"
|
||||
LB_BOOTAPPEND_LIVE="${LB_BOOTAPPEND_LIVE} exposedroot"
|
||||
fi
|
||||
|
||||
LH_BOOTAPPEND_LIVE="$(echo ${LH_BOOTAPPEND_LIVE} | sed -e 's| ||')"
|
||||
LB_BOOTAPPEND_LIVE="$(echo ${LB_BOOTAPPEND_LIVE} | sed -e 's| ||')"
|
||||
|
||||
# Parameters are listed at: linux/Documentation/kernel-parameters.txt
|
||||
FAILSAFE="noapic noapm nodma nomce nolapic nomodeset nosmp vga=ofonly"
|
||||
|
@ -226,14 +226,14 @@ FAILSAFE="noapic noapm nodma nomce nolapic nomodeset nosmp vga=ofonly"
|
|||
# Assembling kernel configuration
|
||||
|
||||
# Default entries
|
||||
DEFAULT_FLAVOUR="$(echo ${LH_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DEFAULT_FLAVOUR="$(echo ${LB_LINUX_FLAVOURS} | awk '{ print $1 }')"
|
||||
DEFAULT_KERNEL="$(basename chroot/boot/vmlinux-*${DEFAULT_FLAVOUR})"
|
||||
DEFAULT_INITRD="initrd.img-$(echo ${DEFAULT_KERNEL} | sed -e 's|vmlinux-||')"
|
||||
|
||||
Yaboot_live_entry "live" "${DEFAULT_KERNEL}" "${DEFAULT_INITRD}"
|
||||
Yaboot_live_entry "live-failsafe" "${DEFAULT_KERNEL}" "${DEFAULT_INITRD}" "${FAILSAFE}"
|
||||
|
||||
if [ "$(echo ${LH_LINUX_FLAVOURS} | wc -w)" -gt "1" ]
|
||||
if [ "$(echo ${LB_LINUX_FLAVOURS} | wc -w)" -gt "1" ]
|
||||
then
|
||||
for KERNEL in chroot/boot/vmlinux-*
|
||||
do
|
||||
|
@ -249,7 +249,7 @@ fi
|
|||
LINUX_LIVE="$(/bin/echo ${LINUX_LIVE} | sed -e 's|binary||g' -e 's|//|/|g')"
|
||||
|
||||
# Assembling debian-installer configuration
|
||||
if [ "${LH_DEBIAN_INSTALLER}" != "false" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" != "false" ]
|
||||
then
|
||||
VMLINUZ_DI="vmlinuz"
|
||||
INITRD_DI="initrd.gz"
|
||||
|
@ -272,12 +272,12 @@ fi
|
|||
|
||||
LINUX_INSTALL="$(/bin/echo ${LINUX_INSTALL} | sed -e 's|binary||g' -e 's|//|/|g')"
|
||||
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
iso*|usb*)
|
||||
# Copying yaboot
|
||||
mkdir -p binary/yaboot
|
||||
|
||||
case "${LH_BUILD_WITH_CHROOT}" in
|
||||
case "${LB_BUILD_WITH_CHROOT}" in
|
||||
true)
|
||||
cp chroot/usr/lib/yaboot/yaboot binary/yaboot
|
||||
;;
|
||||
|
@ -289,7 +289,7 @@ case "${LH_BINARY_IMAGES}" in
|
|||
|
||||
cp -r "${TEMPLATES}"/* binary/yaboot
|
||||
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
usb*)
|
||||
mv binary/yaboot/yaboot.conf binary/yaboot/yaboot.conf.tmp
|
||||
echo "root=/dev/ram" > binary/yaboot/yaboot.conf
|
||||
|
@ -300,8 +300,8 @@ case "${LH_BINARY_IMAGES}" in
|
|||
|
||||
# Configure yaboot templates
|
||||
sed -i -e "s|LINUX_LIVE|${LINUX_LIVE}|" -e "s|LINUX_INSTALL|${LINUX_INSTALL}|" binary/yaboot/yaboot.conf
|
||||
sed -i -e "s|LH_BOOTAPPEND_INSTALL|${LH_BOOTAPPEND_INSTALL}|" -e "s|LH_BOOTAPPEND_LIVE|${LH_BOOTAPPEND_LIVE}|" binary/yaboot/yaboot.conf
|
||||
sed -i -e "s|LH_DATE|$(date +%Y%m%d)|" -e "s|LH_VERSION|${VERSION}|" binary/yaboot/boot.msg
|
||||
sed -i -e "s|LB_BOOTAPPEND_INSTALL|${LB_BOOTAPPEND_INSTALL}|" -e "s|LB_BOOTAPPEND_LIVE|${LB_BOOTAPPEND_LIVE}|" binary/yaboot/yaboot.conf
|
||||
sed -i -e "s|LB_DATE|$(date +%Y%m%d)|" -e "s|LB_VERSION|${VERSION}|" binary/yaboot/boot.msg
|
||||
;;
|
||||
esac
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'bootstrap a Debian system')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'cache bootstrap stage')"
|
||||
|
@ -29,7 +29,7 @@ Check_crossarchitecture
|
|||
|
||||
Echo_message "Begin caching bootstrap stage..."
|
||||
|
||||
for STAGE in ${LH_CACHE_STAGES}
|
||||
for STAGE in ${LB_CACHE_STAGES}
|
||||
do
|
||||
if [ "${STAGE}" = "bootstrap" ]
|
||||
then
|
||||
|
@ -50,11 +50,11 @@ do
|
|||
rm -rf chroot
|
||||
|
||||
# Restoring old cache
|
||||
${LH_ROOT_COMMAND} cp -a cache/stages_bootstrap chroot
|
||||
${LB_ROOT_COMMAND} cp -a cache/stages_bootstrap chroot
|
||||
|
||||
if [ -n "${LH_ROOT_COMMAND}" ]
|
||||
if [ -n "${LB_ROOT_COMMAND}" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
${LB_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
fi
|
||||
|
||||
# Creating stage file
|
||||
|
@ -79,11 +79,11 @@ do
|
|||
|
||||
mkdir -p cache
|
||||
|
||||
${LH_ROOT_COMMAND} cp -a chroot cache/stages_bootstrap
|
||||
${LB_ROOT_COMMAND} cp -a chroot cache/stages_bootstrap
|
||||
|
||||
if [ -n "${LH_ROOT_COMMAND}" ]
|
||||
if [ -n "${LB_ROOT_COMMAND}" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} chown -R $(whoami):$(whoami) cache/stages_bootstrap
|
||||
${LB_ROOT_COMMAND} chown -R $(whoami):$(whoami) cache/stages_bootstrap
|
||||
fi
|
||||
|
||||
# Creating stage file
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'bootstrap a Debian system with cdebootstrap(1)')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_BOOTSTRAP}" != "cdebootstrap" ] && [ "${LH_BOOTSTRAP}" != "cdebootstrap-static" ]
|
||||
if [ "${LB_BOOTSTRAP}" != "cdebootstrap" ] && [ "${LB_BOOTSTRAP}" != "cdebootstrap-static" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -34,7 +34,7 @@ Check_crossarchitecture
|
|||
|
||||
Echo_message "Begin bootstrapping system..."
|
||||
|
||||
Check_package /usr/bin/${LH_BOOTSTRAP} cdebootstrap
|
||||
Check_package /usr/bin/${LB_BOOTSTRAP} cdebootstrap
|
||||
|
||||
# Ensure that a system is built as root
|
||||
lb testroot
|
||||
|
@ -53,34 +53,34 @@ Create_lockfile .lock
|
|||
mkdir -p chroot
|
||||
|
||||
# Setting cdebootstrap options
|
||||
if [ -n "${LH_ARCHITECTURE}" ]
|
||||
if [ -n "${LB_ARCHITECTURE}" ]
|
||||
then
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --arch=${LH_ARCHITECTURE}"
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --arch=${LB_ARCHITECTURE}"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_BOOTSTRAP_CONFIG}" ]
|
||||
if [ -n "${LB_BOOTSTRAP_CONFIG}" ]
|
||||
then
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --suite-config=${LH_BOOTSTRAP_CONFIG}"
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --suite-config=${LB_BOOTSTRAP_CONFIG}"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_BOOTSTRAP_INCLUDE}" ]
|
||||
if [ -n "${LB_BOOTSTRAP_INCLUDE}" ]
|
||||
then
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --include=$(echo ${LH_BOOTSTRAP_INCLUDE} | sed 's| *|,|g')"
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --include=$(echo ${LB_BOOTSTRAP_INCLUDE} | sed 's| *|,|g')"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_BOOTSTRAP_EXCLUDE}" ]
|
||||
if [ -n "${LB_BOOTSTRAP_EXCLUDE}" ]
|
||||
then
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --exclude=$(echo ${LH_BOOTSTRAP_EXCLUDE} | sed 's| *|,|g')"
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --exclude=$(echo ${LB_BOOTSTRAP_EXCLUDE} | sed 's| *|,|g')"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_BOOTSTRAP_KEYRING}" ]
|
||||
if [ -n "${LB_BOOTSTRAP_KEYRING}" ]
|
||||
then
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --keyring=${LH_BOOTSTRAP_KEYRING}"
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --keyring=${LB_BOOTSTRAP_KEYRING}"
|
||||
fi
|
||||
|
||||
if [ -z "${LH_BOOTSTRAP_FLAVOUR}" ]
|
||||
if [ -z "${LB_BOOTSTRAP_FLAVOUR}" ]
|
||||
then
|
||||
case "${LH_PACKAGES_LISTS}" in
|
||||
case "${LB_PACKAGES_LISTS}" in
|
||||
stripped|minimal)
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --flavour=minimal"
|
||||
;;
|
||||
|
@ -89,13 +89,13 @@ then
|
|||
;;
|
||||
esac
|
||||
else
|
||||
case "${LH_BOOTSTRAP_FLAVOUR}" in
|
||||
case "${LB_BOOTSTRAP_FLAVOUR}" in
|
||||
stripped|minimal)
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --flavour=minimal"
|
||||
;;
|
||||
|
||||
*)
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --flavour=${LH_BOOTSTRAP_FLAVOUR}"
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --flavour=${LB_BOOTSTRAP_FLAVOUR}"
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
@ -115,14 +115,14 @@ then
|
|||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --verbose"
|
||||
fi
|
||||
|
||||
if [ "${LH_APT_SECURE}" = "false" ]
|
||||
if [ "${LB_APT_SECURE}" = "false" ]
|
||||
then
|
||||
CDEBOOTSTRAP_OPTIONS="${CDEBOOTSTRAP_OPTIONS} --allow-unauthenticated"
|
||||
fi
|
||||
|
||||
if [ -x "/usr/bin/cdebootstrap" ] || [ -x "/usr/bin/cdebootstrap-static" ]
|
||||
then
|
||||
if [ "${LH_CACHE_PACKAGES}" = "true" ]
|
||||
if [ "${LB_CACHE_PACKAGES}" = "true" ]
|
||||
then
|
||||
if ls cache/packages_bootstrap/*.deb > /dev/null 2>&1
|
||||
then
|
||||
|
@ -130,12 +130,12 @@ then
|
|||
cp cache/packages_bootstrap/*.deb chroot/var/cache/bootstrap
|
||||
fi
|
||||
|
||||
Echo_breakage "Running ${LH_BOOTSTRAP} (download-only)... "
|
||||
${LH_ROOT_COMMAND} ${LH_BOOTSTRAP} ${CDEBOOTSTRAP_OPTIONS} --download-only "${LH_DISTRIBUTION}" chroot "${LH_MIRROR_BOOTSTRAP}"
|
||||
Echo_breakage "Running ${LB_BOOTSTRAP} (download-only)... "
|
||||
${LB_ROOT_COMMAND} ${LB_BOOTSTRAP} ${CDEBOOTSTRAP_OPTIONS} --download-only "${LB_DISTRIBUTION}" chroot "${LB_MIRROR_BOOTSTRAP}"
|
||||
|
||||
if [ -n "${LH_ROOT_COMMAND}" ]
|
||||
if [ -n "${LB_ROOT_COMMAND}" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
${LB_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
fi
|
||||
|
||||
# Removing old cache
|
||||
|
@ -146,16 +146,16 @@ then
|
|||
cp chroot/var/cache/bootstrap/*.deb cache/packages_bootstrap
|
||||
fi
|
||||
|
||||
Echo_breakage "Running ${LH_BOOTSTRAP}... "
|
||||
${LH_ROOT_COMMAND} ${LH_BOOTSTRAP} ${CDEBOOTSTRAP_OPTIONS} "${LH_DISTRIBUTION}" chroot "${LH_MIRROR_BOOTSTRAP}"
|
||||
Echo_breakage "Running ${LB_BOOTSTRAP}... "
|
||||
${LB_ROOT_COMMAND} ${LB_BOOTSTRAP} ${CDEBOOTSTRAP_OPTIONS} "${LB_DISTRIBUTION}" chroot "${LB_MIRROR_BOOTSTRAP}"
|
||||
|
||||
if [ -n "${LH_ROOT_COMMAND}" ]
|
||||
if [ -n "${LB_ROOT_COMMAND}" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
${LB_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
fi
|
||||
|
||||
# Remove cdebootstrap-helper-diverts (needed at least for minimal flavours)
|
||||
case "${LH_PACKAGES_LISTS}" in
|
||||
case "${LB_PACKAGES_LISTS}" in
|
||||
stripped|minimal)
|
||||
Chroot chroot "dpkg -P cdebootstrap-helper-diverts"
|
||||
;;
|
||||
|
@ -172,6 +172,6 @@ then
|
|||
# Creating stage file
|
||||
Create_stagefile .stage/bootstrap
|
||||
else
|
||||
Echo_error "Can't process file /usr/bin/${LH_BOOTSTRAP} (FIXME)"
|
||||
Echo_error "Can't process file /usr/bin/${LB_BOOTSTRAP} (FIXME)"
|
||||
exit 1
|
||||
fi
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'bootstrap by copying the host system')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_BOOTSTRAP}" != "copy" ]
|
||||
if [ "${LB_BOOTSTRAP}" != "copy" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'bootstrap a Debian system with debootstrap(8)')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_BOOTSTRAP}" != "debootstrap" ]
|
||||
if [ "${LB_BOOTSTRAP}" != "debootstrap" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -53,47 +53,47 @@ Create_lockfile .lock
|
|||
mkdir -p chroot
|
||||
|
||||
# Setting debootstrap options
|
||||
if [ -n "${LH_ARCHITECTURE}" ]
|
||||
if [ -n "${LB_ARCHITECTURE}" ]
|
||||
then
|
||||
DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --arch ${LH_ARCHITECTURE}"
|
||||
DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --arch ${LB_ARCHITECTURE}"
|
||||
fi
|
||||
|
||||
if [ "${LH_ARCHIVE_AREAS}" != "main" ]
|
||||
if [ "${LB_ARCHIVE_AREAS}" != "main" ]
|
||||
then
|
||||
# Modify archive areas to remove leading/trailing whitespaces and replace other whitepspace with commas
|
||||
DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --components $(echo ${LH_ARCHIVE_AREAS} | sed -e 's| |,|g')"
|
||||
DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --components $(echo ${LB_ARCHIVE_AREAS} | sed -e 's| |,|g')"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_BOOTSTRAP_CONFIG}" ]
|
||||
if [ -n "${LB_BOOTSTRAP_CONFIG}" ]
|
||||
then
|
||||
if [ -d "/usr/share/debootstrap/scripts/" ]
|
||||
then
|
||||
LH_DEBOOTSTRAP_SCRIPT="/usr/share/debootstrap/scripts/${LH_BOOTSTRAP_CONFIG}"
|
||||
LB_DEBOOTSTRAP_SCRIPT="/usr/share/debootstrap/scripts/${LB_BOOTSTRAP_CONFIG}"
|
||||
else
|
||||
LH_DEBOOTSTRAP_SCRIPT="/usr/lib/debootstrap/scripts/${LH_BOOTSTRAP_CONFIG}"
|
||||
LB_DEBOOTSTRAP_SCRIPT="/usr/lib/debootstrap/scripts/${LB_BOOTSTRAP_CONFIG}"
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ -n "${LH_BOOTSTRAP_INCLUDE}" ]
|
||||
if [ -n "${LB_BOOTSTRAP_INCLUDE}" ]
|
||||
then
|
||||
DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --include=$(echo ${LH_BOOTSTRAP_INCLUDE} | sed 's| *|,|g')"
|
||||
DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --include=$(echo ${LB_BOOTSTRAP_INCLUDE} | sed 's| *|,|g')"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_BOOTSTRAP_EXCLUDE}" ]
|
||||
if [ -n "${LB_BOOTSTRAP_EXCLUDE}" ]
|
||||
then
|
||||
DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --exclude=$(echo ${LH_BOOTSTRAP_EXCLUDE} | sed 's| *|,|g')"
|
||||
DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --exclude=$(echo ${LB_BOOTSTRAP_EXCLUDE} | sed 's| *|,|g')"
|
||||
fi
|
||||
|
||||
if [ "${LH_USE_FAKEROOT}" != "true" ]
|
||||
if [ "${LB_USE_FAKEROOT}" != "true" ]
|
||||
then
|
||||
if [ -z "${LH_BOOTSTRAP_FLAVOUR}" ]
|
||||
if [ -z "${LB_BOOTSTRAP_FLAVOUR}" ]
|
||||
then
|
||||
if In_list "stripped minimal" "${LH_PACKAGES_LISTS}"
|
||||
if In_list "stripped minimal" "${LB_PACKAGES_LISTS}"
|
||||
then
|
||||
DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --variant=minbase"
|
||||
fi
|
||||
else
|
||||
case "${LH_BOOTSTRAP_FLAVOUR}" in
|
||||
case "${LB_BOOTSTRAP_FLAVOUR}" in
|
||||
stripped|minimal)
|
||||
DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --variant=minbase"
|
||||
;;
|
||||
|
@ -101,7 +101,7 @@ then
|
|||
;;
|
||||
|
||||
*)
|
||||
DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --variant=${LH_BOOTSTRAP_FLAVOUR}"
|
||||
DEBOOTSTRAP_OPTIONS="${DEBOOTSTRAP_OPTIONS} --variant=${LB_BOOTSTRAP_FLAVOUR}"
|
||||
esac
|
||||
fi
|
||||
else
|
||||
|
@ -115,7 +115,7 @@ fi
|
|||
|
||||
if [ -x "/usr/sbin/debootstrap" ]
|
||||
then
|
||||
if [ "${LH_CACHE_PACKAGES}" = "true" ]
|
||||
if [ "${LB_CACHE_PACKAGES}" = "true" ]
|
||||
then
|
||||
if ls cache/packages_bootstrap/*.deb > /dev/null 2>&1
|
||||
then
|
||||
|
@ -124,11 +124,11 @@ then
|
|||
fi
|
||||
|
||||
Echo_breakage "Running debootstrap (download-only)... "
|
||||
${LH_ROOT_COMMAND} debootstrap ${DEBOOTSTRAP_OPTIONS} --download-only "${LH_DISTRIBUTION}" chroot "${LH_MIRROR_BOOTSTRAP}" "${LH_DEBOOTSTRAP_SCRIPT}"
|
||||
${LB_ROOT_COMMAND} debootstrap ${DEBOOTSTRAP_OPTIONS} --download-only "${LB_DISTRIBUTION}" chroot "${LB_MIRROR_BOOTSTRAP}" "${LB_DEBOOTSTRAP_SCRIPT}"
|
||||
|
||||
if [ -n "${LH_ROOT_COMMAND}" ]
|
||||
if [ -n "${LB_ROOT_COMMAND}" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
${LB_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
fi
|
||||
|
||||
# Removing old cache
|
||||
|
@ -140,11 +140,11 @@ then
|
|||
fi
|
||||
|
||||
Echo_breakage "Running debootstrap... "
|
||||
${LH_ROOT_COMMAND} debootstrap ${DEBOOTSTRAP_OPTIONS} "${LH_DISTRIBUTION}" chroot "${LH_MIRROR_BOOTSTRAP}" "${LH_DEBOOTSTRAP_SCRIPT}"
|
||||
${LB_ROOT_COMMAND} debootstrap ${DEBOOTSTRAP_OPTIONS} "${LB_DISTRIBUTION}" chroot "${LB_MIRROR_BOOTSTRAP}" "${LB_DEBOOTSTRAP_SCRIPT}"
|
||||
|
||||
if [ -n "${LH_ROOT_COMMAND}" ]
|
||||
if [ -n "${LB_ROOT_COMMAND}" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
${LB_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
fi
|
||||
|
||||
# Deconfiguring debootstrap configurations
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Automatically populating config tree
|
||||
if [ -x auto/config ] && [ ! -e .stage/config ]
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'customize the Debian system')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'manage /etc/apt/apt.conf')"
|
||||
|
@ -43,19 +43,19 @@ case "${1}" in
|
|||
mkdir -p chroot/etc/apt/apt.conf.d
|
||||
|
||||
# Configuring apt ftp proxy
|
||||
if [ -n "${LH_APT_FTP_PROXY}" ]
|
||||
if [ -n "${LB_APT_FTP_PROXY}" ]
|
||||
then
|
||||
echo "Acquire::ftp::Proxy \"${LH_APT_FTP_PROXY}\";" > chroot/etc/apt/apt.conf.d/00ftp-proxy
|
||||
echo "Acquire::ftp::Proxy \"${LB_APT_FTP_PROXY}\";" > chroot/etc/apt/apt.conf.d/00ftp-proxy
|
||||
fi
|
||||
|
||||
# Configuring apt http proxy
|
||||
if [ -n "${LH_APT_HTTP_PROXY}" ]
|
||||
if [ -n "${LB_APT_HTTP_PROXY}" ]
|
||||
then
|
||||
echo "Acquire::http::Proxy \"${LH_APT_HTTP_PROXY}\";" > chroot/etc/apt/apt.conf.d/00http-proxy
|
||||
echo "Acquire::http::Proxy \"${LB_APT_HTTP_PROXY}\";" > chroot/etc/apt/apt.conf.d/00http-proxy
|
||||
fi
|
||||
|
||||
# Configuring apt pdiffs
|
||||
case "${LH_APT_PDIFFS}" in
|
||||
case "${LB_APT_PDIFFS}" in
|
||||
true)
|
||||
echo "Acquire::PDiffs \"true\";" > chroot/etc/apt/apt.conf.d/00pdiffs
|
||||
;;
|
||||
|
@ -66,13 +66,13 @@ case "${1}" in
|
|||
esac
|
||||
|
||||
# Configuring apt pipeline
|
||||
if [ -n "${LH_APT_PIPELINE}" ]
|
||||
if [ -n "${LB_APT_PIPELINE}" ]
|
||||
then
|
||||
echo "Acquire::http::Pipeline-Depth \"${LH_APT_PIPELINE}\";" > chroot/etc/apt/apt.conf.d/00pipeline
|
||||
echo "Acquire::http::Pipeline-Depth \"${LB_APT_PIPELINE}\";" > chroot/etc/apt/apt.conf.d/00pipeline
|
||||
fi
|
||||
|
||||
# Configuring apt recommends
|
||||
case "${LH_APT_RECOMMENDS}" in
|
||||
case "${LB_APT_RECOMMENDS}" in
|
||||
true)
|
||||
echo "APT::Install-Recommends \"true\";" > chroot/etc/apt/apt.conf.d/00recommends
|
||||
echo "Aptitude::Recommends-Important \"true\";" >> chroot/etc/apt/apt.conf.d/00recommends
|
||||
|
@ -85,7 +85,7 @@ case "${1}" in
|
|||
esac
|
||||
|
||||
# Configuring apt secure
|
||||
case "${LH_APT_SECURE}" in
|
||||
case "${LB_APT_SECURE}" in
|
||||
true)
|
||||
echo "APT::Get::AllowUnauthenticated \"false\";" > chroot/etc/apt/apt.conf.d/00secure
|
||||
echo "Aptitude::CmdLine::Ignore-Trust-Violations \"false\";" >> chroot/etc/apt/apt.conf.d/00secure
|
||||
|
@ -164,7 +164,7 @@ case "${1}" in
|
|||
rm -f chroot/etc/apt/apt.conf.d/00http-proxy
|
||||
|
||||
# Deconfiguring aptitude pdiffs
|
||||
if [ "${LH_APT_PDIFFS}" = "true" ]
|
||||
if [ "${LB_APT_PDIFFS}" = "true" ]
|
||||
then
|
||||
rm -f chroot/etc/apt/apt.conf.d/00pdiffs
|
||||
fi
|
||||
|
@ -173,13 +173,13 @@ case "${1}" in
|
|||
rm -f chroot/etc/apt/apt.conf.d/00pipeline
|
||||
|
||||
# Deconfiguring aptitude recommends
|
||||
if [ "${LH_APT_RECOMMENDS}" = "true" ]
|
||||
if [ "${LB_APT_RECOMMENDS}" = "true" ]
|
||||
then
|
||||
rm -f chroot/etc/apt/apt.conf.d/00recommends
|
||||
fi
|
||||
|
||||
# Deconfiguring aptitude secure
|
||||
if [ "${LH_APT_SECURE}" = "true" ]
|
||||
if [ "${LB_APT_SECURE}" = "true" ]
|
||||
then
|
||||
rm -f chroot/etc/apt/apt.conf.d/00secure
|
||||
fi
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'cache chroot stage')"
|
||||
|
@ -26,7 +26,7 @@ Set_defaults
|
|||
|
||||
Echo_message "Begin caching chroot stage..."
|
||||
|
||||
for STAGE in ${LH_CACHE_STAGES}
|
||||
for STAGE in ${LB_CACHE_STAGES}
|
||||
do
|
||||
if [ "${STAGE}" = "chroot" ]
|
||||
then
|
||||
|
@ -47,11 +47,11 @@ do
|
|||
rm -rf chroot
|
||||
|
||||
# Restoring old cache
|
||||
${LH_ROOT_COMMAND} cp -a cache/stages_chroot chroot
|
||||
${LB_ROOT_COMMAND} cp -a cache/stages_chroot chroot
|
||||
|
||||
if [ -n "${LH_ROOT_COMMAND}" ]
|
||||
if [ -n "${LB_ROOT_COMMAND}" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
${LB_ROOT_COMMAND} chown -R $(whoami):$(whoami) chroot
|
||||
fi
|
||||
|
||||
# Creating stage file
|
||||
|
@ -75,11 +75,11 @@ do
|
|||
|
||||
mkdir -p cache
|
||||
|
||||
${LH_ROOT_COMMAND} cp -a chroot cache/stages_chroot
|
||||
${LB_ROOT_COMMAND} cp -a chroot cache/stages_chroot
|
||||
|
||||
if [ -n "${LH_ROOT_COMMAND}" ]
|
||||
if [ -n "${LB_ROOT_COMMAND}" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} chown -R $(whoami):$(whoami) cache/stages_chroot
|
||||
${LB_ROOT_COMMAND} chown -R $(whoami):$(whoami) cache/stages_chroot
|
||||
fi
|
||||
|
||||
# Creating stage file
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'manage /etc/debian_chroot')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'mount /dev/pts')"
|
||||
|
@ -43,13 +43,13 @@ case "${1}" in
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ "${LH_USE_FAKEROOT}" != "true" ]
|
||||
if [ "${LB_USE_FAKEROOT}" != "true" ]
|
||||
then
|
||||
# Creating mountpoint
|
||||
mkdir -p chroot/dev/pts
|
||||
|
||||
# Mounting /dev/pts
|
||||
${LH_ROOT_COMMAND} mount devpts-live -t devpts chroot/dev/pts || true
|
||||
${LB_ROOT_COMMAND} mount devpts-live -t devpts chroot/dev/pts || true
|
||||
fi
|
||||
|
||||
# Creating stage file
|
||||
|
@ -66,13 +66,13 @@ case "${1}" in
|
|||
Create_lockfile .lock
|
||||
|
||||
# Unmounting /dev/pts
|
||||
if [ "${LH_USE_FAKEROOT}" != "true" ]
|
||||
if [ "${LB_USE_FAKEROOT}" != "true" ]
|
||||
then
|
||||
if grep -qs "$(pwd)/chroot/dev/pts" /proc/mounts || Find_files chroot/dev/pts/*
|
||||
then
|
||||
${LH_ROOT_COMMAND} umount chroot/dev/pts
|
||||
${LB_ROOT_COMMAND} umount chroot/dev/pts
|
||||
else
|
||||
${LH_ROOT_COMMAND} umount -f chroot/dev/pts > /dev/null 2>&1 || true
|
||||
${LB_ROOT_COMMAND} umount -f chroot/dev/pts > /dev/null 2>&1 || true
|
||||
fi
|
||||
fi
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'manage /sbin/dpkg')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'manage /var/lib/dpkg')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'execute hacks in chroot')"
|
||||
|
@ -38,9 +38,9 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
case "${LH_DISTRIBUTION}" in
|
||||
case "${LB_DISTRIBUTION}" in
|
||||
squeeze|sid)
|
||||
if echo "${LH_TASKS}" | grep -qs lxde
|
||||
if echo "${LB_TASKS}" | grep -qs lxde
|
||||
then
|
||||
GDM="gdm"
|
||||
else
|
||||
|
@ -54,12 +54,12 @@ case "${LH_DISTRIBUTION}" in
|
|||
esac
|
||||
|
||||
# Handling default desktop configuration
|
||||
for TASK in ${LH_TASKS}
|
||||
for TASK in ${LB_TASKS}
|
||||
do
|
||||
case "${TASK}" in
|
||||
gnome-desktop)
|
||||
# gnome is the only desktop environment in this image
|
||||
if [ -z "$(echo ${LH_TASKS} | sed -e 's|gnome-desktop||' -e 's| desktop ||' | grep desktop)" ]
|
||||
if [ -z "$(echo ${LB_TASKS} | sed -e 's|gnome-desktop||' -e 's| desktop ||' | grep desktop)" ]
|
||||
then
|
||||
# set display manager
|
||||
echo "${GDM} shared/default-x-display-manager select ${GDM}" > chroot/root/preseed
|
||||
|
@ -75,7 +75,7 @@ do
|
|||
|
||||
kde-desktop)
|
||||
# kde is the only desktop-environment in this image
|
||||
if [ -z "$(echo ${LH_TASKS} | sed -e 's|kde-desktop||' -e 's| desktop ||' | grep desktop)" ]
|
||||
if [ -z "$(echo ${LB_TASKS} | sed -e 's|kde-desktop||' -e 's| desktop ||' | grep desktop)" ]
|
||||
then
|
||||
# set display manager
|
||||
echo "kdm shared/default-x-display-manager select kdm" > chroot/root/preseed
|
||||
|
@ -94,7 +94,7 @@ do
|
|||
|
||||
lxde-desktop)
|
||||
# lxde is the only desktop environment in this image
|
||||
if [ -z "$(echo ${LH_TASKS} | sed -e 's|lxde-desktop||' -e 's| desktop ||' | grep desktop)" ]
|
||||
if [ -z "$(echo ${LB_TASKS} | sed -e 's|lxde-desktop||' -e 's| desktop ||' | grep desktop)" ]
|
||||
then
|
||||
# set display manager
|
||||
echo "${GDM} shared/default-x-display-manager select ${GDM}" > chroot/root/preseed
|
||||
|
@ -110,7 +110,7 @@ do
|
|||
|
||||
xfce-desktop)
|
||||
# xfce is the only desktop environment in this image
|
||||
if [ -z "$(echo ${LH_TASKS} | sed -e 's|xfce-desktop||' -e 's| desktop ||' | grep desktop)" ]
|
||||
if [ -z "$(echo ${LB_TASKS} | sed -e 's|xfce-desktop||' -e 's| desktop ||' | grep desktop)" ]
|
||||
then
|
||||
# set display manager
|
||||
echo "${GDM} shared/default-x-display-manager select ${GDM}" > chroot/root/preseed
|
||||
|
@ -134,7 +134,7 @@ done
|
|||
# Removing udev mac caching rule
|
||||
rm -f chroot/etc/udev/rules.d/*persistent-net.rules
|
||||
|
||||
case "${LH_BINARY_IMAGES}" in
|
||||
case "${LB_BINARY_IMAGES}" in
|
||||
net)
|
||||
if [ ! -f chroot/usr/bin/smbmount ]
|
||||
then
|
||||
|
@ -158,7 +158,7 @@ EOF
|
|||
esac
|
||||
|
||||
# Update initramfs (always, because of udev rules in initrd)
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
UPDATE_INITRAMFS_OPTIONS="CASPER_GENERATE_UUID=1"
|
||||
;;
|
||||
|
@ -188,12 +188,12 @@ rm -f chroot/var/cache/debconf/*-old
|
|||
rm -f chroot/var/lib/dpkg/*-old
|
||||
rm -f chroot/var/log/apt/term.log
|
||||
|
||||
if [ -n "${LH_ROOT_COMMAND}" ]
|
||||
if [ -n "${LB_ROOT_COMMAND}" ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} chown -R --quiet $(whoami):$(whoami) chroot
|
||||
${LB_ROOT_COMMAND} chown -R --quiet $(whoami):$(whoami) chroot
|
||||
fi
|
||||
|
||||
case "${LH_INITRAMFS}" in
|
||||
case "${LB_INITRAMFS}" in
|
||||
casper)
|
||||
ID="999"
|
||||
;;
|
||||
|
@ -203,12 +203,12 @@ case "${LH_INITRAMFS}" in
|
|||
;;
|
||||
esac
|
||||
|
||||
if [ -d chroot/home/${LH_USERNAME} ]
|
||||
if [ -d chroot/home/${LB_USERNAME} ]
|
||||
then
|
||||
chown -R --quiet ${ID}:${ID} chroot/home/${LH_USERNAME}
|
||||
chown -R --quiet ${ID}:${ID} chroot/home/${LB_USERNAME}
|
||||
fi
|
||||
|
||||
if [ "${LH_DEBIAN_INSTALLER}" = "live" ]
|
||||
if [ "${LB_DEBIAN_INSTALLER}" = "live" ]
|
||||
then
|
||||
# This is a temporary hack to get rid of fstab;
|
||||
# needs cleanup in live-initramfs first to proper fix.
|
||||
|
@ -221,9 +221,9 @@ then
|
|||
# packages lists. As a very cheap workaround, we ensure that the
|
||||
# bootloader is already installed in the image. Very ugly, but it's to
|
||||
# late to fix it in d-i because lenny rc2 has been already released.
|
||||
case "${LH_ARCHITECTURE}" in
|
||||
case "${LB_ARCHITECTURE}" in
|
||||
amd64|i386)
|
||||
case "${LH_BOOTLOADER}" in
|
||||
case "${LB_BOOTLOADER}" in
|
||||
grub)
|
||||
Apt install grub
|
||||
;;
|
||||
|
@ -240,7 +240,7 @@ then
|
|||
esac
|
||||
fi
|
||||
|
||||
if [ "${LH_EXPOSED_ROOT}" = "true" ]
|
||||
if [ "${LB_EXPOSED_ROOT}" = "true" ]
|
||||
then
|
||||
# Make sure RW dirs exist so that the initramfs script has
|
||||
# a directory in which to bind the tmpfs filesystems
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'execute hooks in chroot')"
|
||||
|
@ -39,14 +39,14 @@ Check_lockfile .lock
|
|||
Create_lockfile .lock
|
||||
|
||||
# Processing hooks
|
||||
HOOKS="$(echo ${LH_HOOKS} ${LH_PACKAGES_LISTS} ${LH_TASKS} | sed -e 's| |\n|g' | sort -u)"
|
||||
HOOKS="$(echo ${LB_HOOKS} ${LB_PACKAGES_LISTS} ${LB_TASKS} | sed -e 's| |\n|g' | sort -u)"
|
||||
|
||||
for HOOK in ${HOOKS}
|
||||
do
|
||||
if [ -f ${LH_BASE:-/usr/share/live/build}/hooks/"${HOOK}" ]
|
||||
if [ -f ${LB_BASE:-/usr/share/live/build}/hooks/"${HOOK}" ]
|
||||
then
|
||||
# Copying hook
|
||||
cp ${LH_BASE:-/usr/share/live/build}/hooks/"${HOOK}" chroot/root
|
||||
cp ${LB_BASE:-/usr/share/live/build}/hooks/"${HOOK}" chroot/root
|
||||
|
||||
# Making hook executable
|
||||
if [ ! -x chroot/root/"${HOOK}" ]
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'manage /bin/hostname')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'manage /etc/hosts')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'install queued packages into chroot')"
|
||||
|
@ -44,7 +44,7 @@ then
|
|||
Restore_cache cache/packages_chroot
|
||||
|
||||
# Installing packages
|
||||
case "${LH_APT}" in
|
||||
case "${LB_APT}" in
|
||||
apt|apt-get)
|
||||
Chroot chroot "xargs --arg-file=/root/chroot_packages apt-get ${APT_OPTIONS} install"
|
||||
;;
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'make build interactive')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_INTERACTIVE}" = "false" ]
|
||||
if [ "${LB_INTERACTIVE}" = "false" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -43,7 +43,7 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
case "${LH_INTERACTIVE}" in
|
||||
case "${LB_INTERACTIVE}" in
|
||||
true|shell)
|
||||
Echo_message "Pausing build: starting interactive shell..."
|
||||
Chroot chroot "/bin/bash --login"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'manage /etc/kernel-img.conf')"
|
||||
|
@ -54,27 +54,27 @@ warn_initrd = No
|
|||
EOF
|
||||
|
||||
# Diverting update-initramfs
|
||||
#case "${LH_INITRAMFS}" in
|
||||
#case "${LB_INITRAMFS}" in
|
||||
# live-initramfs|live-boot)
|
||||
# mv chroot/usr/sbin/update-initramfs chroot/usr/sbin/update-initramfs.live-build
|
||||
# ;;
|
||||
#esac
|
||||
|
||||
if [ "${LH_LINUX_PACKAGES}" != "none" ]
|
||||
if [ "${LB_LINUX_PACKAGES}" != "none" ]
|
||||
then
|
||||
for FLAVOUR in ${LH_LINUX_FLAVOURS}
|
||||
for FLAVOUR in ${LB_LINUX_FLAVOURS}
|
||||
do
|
||||
for PACKAGE in ${LH_LINUX_PACKAGES}
|
||||
for PACKAGE in ${LB_LINUX_PACKAGES}
|
||||
do
|
||||
echo ${PACKAGE}-${FLAVOUR} >> chroot/root/chroot_packages
|
||||
done
|
||||
done
|
||||
fi
|
||||
|
||||
# Queue installation of linux-image and ${LH_INITRAMFS}
|
||||
if [ "${LH_INITRAMFS}" != "none" ]
|
||||
# Queue installation of linux-image and ${LB_INITRAMFS}
|
||||
if [ "${LB_INITRAMFS}" != "none" ]
|
||||
then
|
||||
echo ${LH_INITRAMFS} >> chroot/root/chroot_packages
|
||||
echo ${LB_INITRAMFS} >> chroot/root/chroot_packages
|
||||
fi
|
||||
|
||||
# Creating stage file
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'execute local hooks in chroot')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'copy local files into chroot')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'queue install of local packages into chroot')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'queue install of local packages lists into chroot')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'apply local patches against chroot')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'execute local preseed in chroot')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'install localization packages into chroot')"
|
||||
|
@ -39,9 +39,9 @@ Check_lockfile .lock
|
|||
Create_lockfile .lock
|
||||
|
||||
# Setting localizations
|
||||
if [ -n "${LH_LANGUAGE}" ]
|
||||
if [ -n "${LB_LANGUAGE}" ]
|
||||
then
|
||||
case "${LH_LANGUAGE}" in
|
||||
case "${LB_LANGUAGE}" in
|
||||
af)
|
||||
# Afrikaans
|
||||
LOCALIZATIONS="iceweasel kde openoffice"
|
||||
|
@ -593,12 +593,12 @@ then
|
|||
esac
|
||||
|
||||
# Setting languages
|
||||
ICEAPE="${ICEAPE:-$LH_LANGUAGE}"
|
||||
ICEDOVE="${ICEDOVE:-$LH_LANGUAGE}"
|
||||
ICEWEASEL="${ICEWEASEL:-$LH_LANGUAGE}"
|
||||
KDE="${KDE:-$LH_LANGUAGE}"
|
||||
KOFFICE="${KOFFICE:-$LH_LANGUAGE}"
|
||||
OPENOFFICE="${OPENOFFICE:-$LH_LANGUAGE}"
|
||||
ICEAPE="${ICEAPE:-$LB_LANGUAGE}"
|
||||
ICEDOVE="${ICEDOVE:-$LB_LANGUAGE}"
|
||||
ICEWEASEL="${ICEWEASEL:-$LB_LANGUAGE}"
|
||||
KDE="${KDE:-$LB_LANGUAGE}"
|
||||
KOFFICE="${KOFFICE:-$LB_LANGUAGE}"
|
||||
OPENOFFICE="${OPENOFFICE:-$LB_LANGUAGE}"
|
||||
|
||||
# Setting packages
|
||||
for LOCALIZATION in ${LOCALIZATIONS}
|
||||
|
@ -612,7 +612,7 @@ then
|
|||
Check_installed chroot/usr/bin/icedove icedove
|
||||
if [ $INSTALL_STATUS -eq 0 ]
|
||||
then
|
||||
if [ "${LH_DISTRIBUTION}" = lenny ]
|
||||
if [ "${LB_DISTRIBUTION}" = lenny ]
|
||||
then
|
||||
Check_package "" icedove-locale-"${ICEDOVE}"
|
||||
else
|
||||
|
@ -639,7 +639,7 @@ then
|
|||
esac
|
||||
done
|
||||
|
||||
if [ "${LH_DISTRIBUTION}" = "lenny" ]
|
||||
if [ "${LB_DISTRIBUTION}" = "lenny" ]
|
||||
then
|
||||
Check_installed chroot/usr/bin/gwenview gwenview; [ $INSTALL_STATUS -eq 0 ] && Check_package "" gwenview-i18n
|
||||
fi
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'queue install of packages into chroot')"
|
||||
|
@ -38,9 +38,9 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ -n "${LH_PACKAGES}" ] && [ "${LH_PACKAGES}" != "none" ]
|
||||
if [ -n "${LB_PACKAGES}" ] && [ "${LB_PACKAGES}" != "none" ]
|
||||
then
|
||||
echo ${LH_PACKAGES} >> chroot/root/chroot_packages
|
||||
echo ${LB_PACKAGES} >> chroot/root/chroot_packages
|
||||
|
||||
# Creating stage file
|
||||
Create_stagefile .stage/chroot_packages
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'queue install of packages lists into chroot')"
|
||||
|
@ -38,10 +38,10 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ -n "${LH_PACKAGES_LISTS}" ] && [ "${LH_PACKAGES_LISTS}" != "none" ]
|
||||
if [ -n "${LB_PACKAGES_LISTS}" ] && [ "${LB_PACKAGES_LISTS}" != "none" ]
|
||||
then
|
||||
|
||||
for LIST in ${LH_PACKAGES_LISTS}
|
||||
for LIST in ${LB_PACKAGES_LISTS}
|
||||
do
|
||||
# Generating package list
|
||||
Expand_packagelist "${LIST}" >> chroot/root/chroot_packages
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'execute preseed in chroot')"
|
||||
|
@ -39,9 +39,9 @@ Check_lockfile .lock
|
|||
Create_lockfile .lock
|
||||
|
||||
# Processing preseeds
|
||||
for PRESEED in ${LH_PACKAGES_LISTS} ${LH_TASKS}
|
||||
for PRESEED in ${LB_PACKAGES_LISTS} ${LB_TASKS}
|
||||
do
|
||||
if [ -f ${LH_BASE:-/usr/share/live/build}/preseed/"${PRESEED}" ]
|
||||
if [ -f ${LB_BASE:-/usr/share/live/build}/preseed/"${PRESEED}" ]
|
||||
then
|
||||
# Check dependency
|
||||
Check_package chroot/usr/bin/debconf-set-selections debconf
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'mount /proc')"
|
||||
|
@ -43,13 +43,13 @@ case "${1}" in
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ "${LH_USE_FAKEROOT}" != "true" ]
|
||||
if [ "${LB_USE_FAKEROOT}" != "true" ]
|
||||
then
|
||||
# Creating mountpoint
|
||||
mkdir -p chroot/proc
|
||||
|
||||
# Mounting /proc
|
||||
${LH_ROOT_COMMAND} mount proc-live -t proc chroot/proc
|
||||
${LB_ROOT_COMMAND} mount proc-live -t proc chroot/proc
|
||||
else
|
||||
rm -rf chroot/proc
|
||||
ln -s /proc chroot/
|
||||
|
@ -68,19 +68,19 @@ case "${1}" in
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ "${LH_USE_FAKEROOT}" != "true" ]
|
||||
if [ "${LB_USE_FAKEROOT}" != "true" ]
|
||||
then
|
||||
# Workaround binfmt-support /proc locking
|
||||
if [ -e chroot/proc/sys/fs/binfmt_misc/status ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} umount chroot/proc/sys/fs/binfmt_misc
|
||||
${LB_ROOT_COMMAND} umount chroot/proc/sys/fs/binfmt_misc
|
||||
fi
|
||||
|
||||
# Unmounting /proc
|
||||
#fuser -km chroot/proc
|
||||
if [ -e chroot/proc/version ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} umount chroot/proc
|
||||
${LB_ROOT_COMMAND} umount chroot/proc
|
||||
fi
|
||||
else
|
||||
rm -rf chroot/proc
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'manage /etc/resolv.conf')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'mount /selinux')"
|
||||
|
@ -45,13 +45,13 @@ case "${1}" in
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ "${LH_USE_FAKEROOT}" != "true" ]
|
||||
if [ "${LB_USE_FAKEROOT}" != "true" ]
|
||||
then
|
||||
# Create mountpoint
|
||||
mkdir -p chroot/selinux
|
||||
|
||||
# Mounting /selinux
|
||||
${LH_ROOT_COMMAND} mount selinuxfs-live -t selinuxfs chroot/selinux
|
||||
${LB_ROOT_COMMAND} mount selinuxfs-live -t selinuxfs chroot/selinux
|
||||
else
|
||||
rm -rf chroot/selinux
|
||||
ln -s /selinux chroot/
|
||||
|
@ -71,13 +71,13 @@ case "${1}" in
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ "${LH_USE_FAKEROOT}" != "true" ]
|
||||
if [ "${LB_USE_FAKEROOT}" != "true" ]
|
||||
then
|
||||
# Unmounting /selinux
|
||||
#fuser -km chroot/selinux
|
||||
if [ -e chroot/selinux/enforce ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} umount chroot/selinux
|
||||
${LB_ROOT_COMMAND} umount chroot/selinux
|
||||
fi
|
||||
else
|
||||
if [ -e chroot/selinux ]
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'manage /etc/apt/sources.list')"
|
||||
|
@ -27,7 +27,7 @@ Set_defaults
|
|||
# Requiring stage file
|
||||
Require_stagefile .stage/config .stage/bootstrap
|
||||
|
||||
_LH_LOCAL_KEY_EMAIL="live-build-local-key@invalid"
|
||||
_LB_LOCAL_KEY_EMAIL="live-build-local-key@invalid"
|
||||
|
||||
case "${1}" in
|
||||
install)
|
||||
|
@ -46,60 +46,60 @@ case "${1}" in
|
|||
Restore_cache cache/packages_chroot
|
||||
|
||||
# Configure custom sources.list
|
||||
echo "deb ${LH_MIRROR_CHROOT} ${LH_DISTRIBUTION} ${LH_ARCHIVE_AREAS}" > chroot/etc/apt/sources.list
|
||||
echo "deb ${LB_MIRROR_CHROOT} ${LB_DISTRIBUTION} ${LB_ARCHIVE_AREAS}" > chroot/etc/apt/sources.list
|
||||
|
||||
if [ "${LH_SOURCE}" = "true" ]
|
||||
if [ "${LB_SOURCE}" = "true" ]
|
||||
then
|
||||
echo "deb-src ${LH_MIRROR_CHROOT} ${LH_DISTRIBUTION} ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb-src ${LB_MIRROR_CHROOT} ${LB_DISTRIBUTION} ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
fi
|
||||
|
||||
if [ "${LH_SECURITY}" = "true" ]
|
||||
if [ "${LB_SECURITY}" = "true" ]
|
||||
then
|
||||
case "${LH_MODE}" in
|
||||
case "${LB_MODE}" in
|
||||
ubuntu)
|
||||
echo "deb ${LH_MIRROR_CHROOT_SECURITY} ${LH_DISTRIBUTION}-security ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb ${LB_MIRROR_CHROOT_SECURITY} ${LB_DISTRIBUTION}-security ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
|
||||
if [ "${LH_SOURCE}" = "true" ]
|
||||
if [ "${LB_SOURCE}" = "true" ]
|
||||
then
|
||||
echo "deb-src ${LH_MIRROR_CHROOT_SECURITY} ${LH_DISTRIBUTION}-security ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb-src ${LB_MIRROR_CHROOT_SECURITY} ${LB_DISTRIBUTION}-security ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
fi
|
||||
;;
|
||||
|
||||
*)
|
||||
if [ "${LH_DISTRIBUTION}" != "sid" ] && [ "${LH_DISTRIBUTION}" != "unstable" ]
|
||||
if [ "${LB_DISTRIBUTION}" != "sid" ] && [ "${LB_DISTRIBUTION}" != "unstable" ]
|
||||
then
|
||||
echo "deb ${LH_MIRROR_CHROOT_SECURITY} ${LH_DISTRIBUTION}/updates ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb ${LB_MIRROR_CHROOT_SECURITY} ${LB_DISTRIBUTION}/updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
|
||||
if [ "${LH_SOURCE}" = "true" ]
|
||||
if [ "${LB_SOURCE}" = "true" ]
|
||||
then
|
||||
echo "deb-src ${LH_MIRROR_CHROOT_SECURITY} ${LH_DISTRIBUTION}/updates ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb-src ${LB_MIRROR_CHROOT_SECURITY} ${LB_DISTRIBUTION}/updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
if [ "${LH_VOLATILE}" = "true" ]
|
||||
if [ "${LB_VOLATILE}" = "true" ]
|
||||
then
|
||||
case "${LH_MODE}" in
|
||||
case "${LB_MODE}" in
|
||||
debian|debian-release)
|
||||
if [ "${LH_DISTRIBUTION}" != "sid" ] && [ "${LH_DISTRIBUTION}" != "unstable" ]
|
||||
if [ "${LB_DISTRIBUTION}" != "sid" ] && [ "${LB_DISTRIBUTION}" != "unstable" ]
|
||||
then
|
||||
echo "deb ${LH_MIRROR_CHROOT_VOLATILE} ${LH_DISTRIBUTION}/volatile ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb ${LB_MIRROR_CHROOT_VOLATILE} ${LB_DISTRIBUTION}/volatile ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
|
||||
if [ "${LH_SOURCE}" = "true" ]
|
||||
if [ "${LB_SOURCE}" = "true" ]
|
||||
then
|
||||
echo "deb-src ${LH_MIRROR_CHROOT_VOLATILE} ${LH_DISTRIBUTION}/volatile ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb-src ${LB_MIRROR_CHROOT_VOLATILE} ${LB_DISTRIBUTION}/volatile ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
|
||||
ubuntu)
|
||||
echo "deb ${LH_MIRROR_CHROOT_VOLATILE} ${LH_DISTRIBUTION}-updates ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb ${LB_MIRROR_CHROOT_VOLATILE} ${LB_DISTRIBUTION}-updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
|
||||
if [ "${LH_SOURCE}" = "true" ]
|
||||
if [ "${LB_SOURCE}" = "true" ]
|
||||
then
|
||||
echo "deb-src ${LH_MIRROR_CHROOT_VOLATILE} ${LH_DISTRIBUTION}-updates ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb-src ${LB_MIRROR_CHROOT_VOLATILE} ${LB_DISTRIBUTION}-updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
@ -125,11 +125,11 @@ case "${1}" in
|
|||
fi
|
||||
|
||||
# Configure third-party repositories
|
||||
if [ -n "${LH_REPOSITORIES}" ]
|
||||
if [ -n "${LB_REPOSITORIES}" ]
|
||||
then
|
||||
for REPOSITORY in ${LH_REPOSITORIES}
|
||||
for REPOSITORY in ${LB_REPOSITORIES}
|
||||
do
|
||||
for PLACE in config/repositories "${LH_BASE}/repositories"
|
||||
for PLACE in config/repositories "${LB_BASE}/repositories"
|
||||
do
|
||||
# Prefer repositories from the config tree
|
||||
# over the global ones.
|
||||
|
@ -141,19 +141,19 @@ case "${1}" in
|
|||
# Adding sources.list entries (chroot)
|
||||
if [ -e "${PLACE}/${REPOSITORY}.chroot" ]
|
||||
then
|
||||
sed -e "s|@DISTRIBUTION@|${LH_DISTRIBUTION}|g" \
|
||||
-e "s|@ARCHIVE_AREAS@|${LH_ARCHIVE_AREAS}|g" \
|
||||
sed -e "s|@DISTRIBUTION@|${LB_DISTRIBUTION}|g" \
|
||||
-e "s|@ARCHIVE_AREAS@|${LB_ARCHIVE_AREAS}|g" \
|
||||
"${PLACE}/${REPOSITORY}.chroot" > \
|
||||
"chroot/etc/apt/sources.list.d/${REPOSITORY}.list"
|
||||
elif [ -e "${PLACE}/${REPOSITORY}" ]
|
||||
then
|
||||
sed -e "s|@DISTRIBUTION@|${LH_DISTRIBUTION}|g" \
|
||||
-e "s|@ARCHIVE_AREAS@|${LH_ARCHIVE_AREAS}|g" \
|
||||
sed -e "s|@DISTRIBUTION@|${LB_DISTRIBUTION}|g" \
|
||||
-e "s|@ARCHIVE_AREAS@|${LB_ARCHIVE_AREAS}|g" \
|
||||
"${PLACE}/${REPOSITORY}" > \
|
||||
"chroot/etc/apt/sources.list.d/${REPOSITORY}.list"
|
||||
fi
|
||||
|
||||
if [ "${LH_APT_SECURE}" != false ]
|
||||
if [ "${LB_APT_SECURE}" != false ]
|
||||
then
|
||||
# Adding archive signing keys (chroot)
|
||||
if [ -e "${PLACE}/${REPOSITORY}.chroot.gpg" ]
|
||||
|
@ -180,9 +180,9 @@ case "${1}" in
|
|||
fi
|
||||
|
||||
# Copy packages
|
||||
if Find_files config/chroot_local-packages/*_"${LH_ARCHITECTURE}".deb
|
||||
if Find_files config/chroot_local-packages/*_"${LB_ARCHITECTURE}".deb
|
||||
then
|
||||
cp ${CP_OPTIONS} config/chroot_local-packages/*_"${LH_ARCHITECTURE}".deb chroot/root/local-packages
|
||||
cp ${CP_OPTIONS} config/chroot_local-packages/*_"${LB_ARCHITECTURE}".deb chroot/root/local-packages
|
||||
fi
|
||||
|
||||
if Find_files config/chroot_local-packages/*_all.deb
|
||||
|
@ -195,7 +195,7 @@ case "${1}" in
|
|||
# If we bootstrapped a minimal chroot, we need
|
||||
# to install apt-utils before we have have
|
||||
# completed all the indices.
|
||||
case "${LH_PACKAGES_LISTS}" in
|
||||
case "${LB_PACKAGES_LISTS}" in
|
||||
stripped|minimal)
|
||||
Chroot chroot "apt-get update"
|
||||
;;
|
||||
|
@ -216,12 +216,12 @@ case "${1}" in
|
|||
-o APT::FTPArchive::Release::Origin=chroot_local-packages \
|
||||
release . > Release" | Chroot chroot sh
|
||||
|
||||
if [ "${LH_APT_SECURE}" = "true" ]
|
||||
if [ "${LB_APT_SECURE}" = "true" ]
|
||||
then
|
||||
_LH_DOTGNUPG_EXISTED=0
|
||||
_LB_DOTGNUPG_EXISTED=0
|
||||
if [ -d chroot/root/.gnupg ]
|
||||
then
|
||||
_LH_DOTGNUPG_EXISTED=1
|
||||
_LB_DOTGNUPG_EXISTED=1
|
||||
fi
|
||||
|
||||
# Ensure ~/.gnupg exists (required for gnupg >= ~1.4.9)
|
||||
|
@ -243,21 +243,21 @@ case "${1}" in
|
|||
Subkey-Type: ELG-E
|
||||
Subkey-Length: 1024
|
||||
Name-Real: live-build local packages key
|
||||
Name-Email: ${_LH_LOCAL_KEY_EMAIL}
|
||||
Name-Email: ${_LB_LOCAL_KEY_EMAIL}
|
||||
Expire-Date: 0
|
||||
%secring /root/local-package-keyring.sec
|
||||
%pubring /root/local-package-keyring.pub
|
||||
%commit" | Chroot chroot "gpg --batch --gen-key" || _LH_RET=${?}
|
||||
%commit" | Chroot chroot "gpg --batch --gen-key" || _LB_RET=${?}
|
||||
|
||||
case "${_LH_RET}" in
|
||||
case "${_LB_RET}" in
|
||||
""|2)
|
||||
# Gnupg sometimes seems to return with a status of 2 when there was not
|
||||
# enough entropy (and key creation blocks temporarily) even if the
|
||||
# operation was ultimately successful.
|
||||
;;
|
||||
*)
|
||||
Echo_error "GPG exited with error status %s" "${_LH_RET}"
|
||||
exit ${_LH_RET}
|
||||
Echo_error "GPG exited with error status %s" "${_LB_RET}"
|
||||
exit ${_LB_RET}
|
||||
;;
|
||||
esac
|
||||
|
||||
|
@ -273,7 +273,7 @@ case "${1}" in
|
|||
# Import key
|
||||
Chroot chroot "gpg --no-default-keyring --secret-keyring /root/local-package-keyring.sec \
|
||||
--keyring /root/local-package-keyring.pub --armor \
|
||||
--export ${_LH_LOCAL_KEY_EMAIL}" | Chroot chroot "apt-key add -"
|
||||
--export ${_LB_LOCAL_KEY_EMAIL}" | Chroot chroot "apt-key add -"
|
||||
|
||||
# Remove temporary keyrings
|
||||
rm chroot/root/local-package-keyring.pub
|
||||
|
@ -283,7 +283,7 @@ case "${1}" in
|
|||
mv chroot/dev/random.orig chroot/dev/random
|
||||
|
||||
# Remove /root/.gnupg if we created it during the signing process
|
||||
if [ "${_LH_DOTGNUPG_EXISTED}" -eq 0 ]
|
||||
if [ "${_LB_DOTGNUPG_EXISTED}" -eq 0 ]
|
||||
then
|
||||
rm -rf chroot/root/.gnupg
|
||||
fi
|
||||
|
@ -300,7 +300,7 @@ case "${1}" in
|
|||
fi
|
||||
|
||||
# Update indices from cache
|
||||
if [ "${LH_CACHE_INDICES}" = "true" ] && [ -d cache/indices_bootstrap ]
|
||||
if [ "${LB_CACHE_INDICES}" = "true" ] && [ -d cache/indices_bootstrap ]
|
||||
then
|
||||
if Find_files cache/indices_bootstrap/secring.gpg*
|
||||
then
|
||||
|
@ -337,7 +337,7 @@ case "${1}" in
|
|||
cp -f cache/indices_bootstrap/*_Release* chroot/var/lib/apt/lists
|
||||
fi
|
||||
|
||||
if [ "${LH_APT}" = "aptitude" ] && [ ! -x /usr/bin/aptitude ]
|
||||
if [ "${LB_APT}" = "aptitude" ] && [ ! -x /usr/bin/aptitude ]
|
||||
then
|
||||
Chroot chroot "apt-get ${APT_OPTIONS} install aptitude"
|
||||
fi
|
||||
|
@ -365,7 +365,7 @@ case "${1}" in
|
|||
fi
|
||||
|
||||
# Installing aptitude
|
||||
if [ "${LH_APT}" = "aptitude" ] && [ ! -x /usr/bin/aptitude ]
|
||||
if [ "${LB_APT}" = "aptitude" ] && [ ! -x /usr/bin/aptitude ]
|
||||
then
|
||||
Chroot chroot "apt-get ${APT_OPTIONS} update"
|
||||
Chroot chroot "apt-get ${APT_OPTIONS} install aptitude"
|
||||
|
@ -376,13 +376,13 @@ case "${1}" in
|
|||
Apt dist-upgrade
|
||||
|
||||
# Installing keyring packages
|
||||
if [ -n "${LH_KEYRING_PACKAGES}" ]
|
||||
if [ -n "${LB_KEYRING_PACKAGES}" ]
|
||||
then
|
||||
Chroot chroot "apt-get --yes --force-yes install ${LH_KEYRING_PACKAGES}"
|
||||
Chroot chroot "apt-get --yes --force-yes install ${LB_KEYRING_PACKAGES}"
|
||||
Apt update
|
||||
fi
|
||||
|
||||
if [ "${LH_CACHE_INDICES}" = "true" ]
|
||||
if [ "${LB_CACHE_INDICES}" = "true" ]
|
||||
then
|
||||
mkdir -p cache/indices_bootstrap
|
||||
|
||||
|
@ -425,8 +425,8 @@ case "${1}" in
|
|||
|
||||
# Configure generic indices
|
||||
# Don't do anything if it's not required
|
||||
if [ "${LH_MIRROR_CHROOT}" = "${LH_MIRROR_BINARY}" ] && \
|
||||
[ "${LH_MIRROR_CHROOT_SECURITY}" = "${LH_MIRROR_BINARY_SECURITY}" ] && \
|
||||
if [ "${LB_MIRROR_CHROOT}" = "${LB_MIRROR_BINARY}" ] && \
|
||||
[ "${LB_MIRROR_CHROOT_SECURITY}" = "${LB_MIRROR_BINARY_SECURITY}" ] && \
|
||||
[ ! -d chroot/root/local-packages ]
|
||||
then
|
||||
# Removing stage file
|
||||
|
@ -439,74 +439,74 @@ case "${1}" in
|
|||
rm -rf chroot/var/lib/apt/lists
|
||||
mkdir -p chroot/var/lib/apt/lists/partial
|
||||
|
||||
echo "deb ${LH_MIRROR_BINARY} ${LH_DISTRIBUTION} ${LH_ARCHIVE_AREAS}" > chroot/etc/apt/sources.list
|
||||
echo "deb ${LB_MIRROR_BINARY} ${LB_DISTRIBUTION} ${LB_ARCHIVE_AREAS}" > chroot/etc/apt/sources.list
|
||||
|
||||
if [ "${LH_SOURCE}" = "true" ]
|
||||
if [ "${LB_SOURCE}" = "true" ]
|
||||
then
|
||||
echo "deb-src ${LH_MIRROR_BINARY} ${LH_DISTRIBUTION} ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb-src ${LB_MIRROR_BINARY} ${LB_DISTRIBUTION} ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
fi
|
||||
|
||||
if [ "${LH_SECURITY}" = "true" ]
|
||||
if [ "${LB_SECURITY}" = "true" ]
|
||||
then
|
||||
case "${LH_MODE}" in
|
||||
case "${LB_MODE}" in
|
||||
ubuntu)
|
||||
echo "deb ${LH_MIRROR_BINARY_SECURITY} ${LH_DISTRIBUTION}-security ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb ${LB_MIRROR_BINARY_SECURITY} ${LB_DISTRIBUTION}-security ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
|
||||
if [ "${LH_SOURCE}" = "true" ]
|
||||
if [ "${LB_SOURCE}" = "true" ]
|
||||
then
|
||||
echo "deb-src ${LH_MIRROR_BINARY_SECURITY} ${LH_DISTRIBUTION}-security ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb-src ${LB_MIRROR_BINARY_SECURITY} ${LB_DISTRIBUTION}-security ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
fi
|
||||
;;
|
||||
|
||||
*)
|
||||
if [ "${LH_DISTRIBUTION}" != "sid" ] && [ "${LH_DISTRIBUTION}" != "unstable" ]
|
||||
if [ "${LB_DISTRIBUTION}" != "sid" ] && [ "${LB_DISTRIBUTION}" != "unstable" ]
|
||||
then
|
||||
echo "deb ${LH_MIRROR_BINARY_SECURITY} ${LH_DISTRIBUTION}/updates ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb ${LB_MIRROR_BINARY_SECURITY} ${LB_DISTRIBUTION}/updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
|
||||
if [ "${LH_SOURCE}" = "true" ]
|
||||
if [ "${LB_SOURCE}" = "true" ]
|
||||
then
|
||||
echo "deb-src ${LH_MIRROR_BINARY_SECURITY} ${LH_DISTRIBUTION}/updates ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb-src ${LB_MIRROR_BINARY_SECURITY} ${LB_DISTRIBUTION}/updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
if [ "${LH_VOLATILE}" = "true" ]
|
||||
if [ "${LB_VOLATILE}" = "true" ]
|
||||
then
|
||||
case "${LH_MODE}" in
|
||||
case "${LB_MODE}" in
|
||||
debian|debian-release)
|
||||
if [ "${LH_DISTRIBUTION}" != "sid" ] && [ "${LH_DISTRIBUTION}" != "unstable" ]
|
||||
if [ "${LB_DISTRIBUTION}" != "sid" ] && [ "${LB_DISTRIBUTION}" != "unstable" ]
|
||||
then
|
||||
echo "deb ${LH_MIRROR_BINARY_VOLATILE} ${LH_DISTRIBUTION}/volatile ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb ${LB_MIRROR_BINARY_VOLATILE} ${LB_DISTRIBUTION}/volatile ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
|
||||
if [ "${LH_SOURCE}" = "true" ]
|
||||
if [ "${LB_SOURCE}" = "true" ]
|
||||
then
|
||||
echo "deb-src ${LH_MIRROR_BINARY_VOLATILE} ${LH_DISTRIBUTION}/volatile ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb-src ${LB_MIRROR_BINARY_VOLATILE} ${LB_DISTRIBUTION}/volatile ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
|
||||
ubuntu)
|
||||
echo "deb ${LH_MIRROR_BINARY_VOLATILE} ${LH_DISTRIBUTION}-updates ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb ${LB_MIRROR_BINARY_VOLATILE} ${LB_DISTRIBUTION}-updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
|
||||
if [ "${LH_SOURCE}" = "true" ]
|
||||
if [ "${LB_SOURCE}" = "true" ]
|
||||
then
|
||||
echo "deb-src ${LH_MIRROR_BINARY_VOLATILE} ${LH_DISTRIBUTION}-updates ${LH_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
echo "deb-src ${LB_MIRROR_BINARY_VOLATILE} ${LB_DISTRIBUTION}-updates ${LB_ARCHIVE_AREAS}" >> chroot/etc/apt/sources.list
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
# Configure third-party repositories
|
||||
if [ -n "${LH_REPOSITORIES}" ]
|
||||
if [ -n "${LB_REPOSITORIES}" ]
|
||||
then
|
||||
for REPOSITORY in ${LH_REPOSITORIES}
|
||||
for REPOSITORY in ${LB_REPOSITORIES}
|
||||
do
|
||||
# Removing sources.list entries (chroot)
|
||||
rm -f "chroot/etc/apt/sources.list.d/${REPOSITORY}.list"
|
||||
|
||||
for PLACE in config/repositories "${LH_BASE}/repositories"
|
||||
for PLACE in config/repositories "${LB_BASE}/repositories"
|
||||
do
|
||||
# Prefer repositories from the config tree
|
||||
# over the global ones.
|
||||
|
@ -518,19 +518,19 @@ case "${1}" in
|
|||
# Adding sources.list entries (binary)
|
||||
if [ -e "${PLACE}/${REPOSITORY}.binary" ]
|
||||
then
|
||||
sed -e "s|@DISTRIBUTION@|${LH_DISTRIBUTION}|g" \
|
||||
-e "s|@ARCHIVE_AREAS@|${LH_ARCHIVE_AREAS}|g" \
|
||||
sed -e "s|@DISTRIBUTION@|${LB_DISTRIBUTION}|g" \
|
||||
-e "s|@ARCHIVE_AREAS@|${LB_ARCHIVE_AREAS}|g" \
|
||||
"${PLACE}/${REPOSITORY}.binary" > \
|
||||
"chroot/etc/apt/sources.list.d/${REPOSITORY}.list"
|
||||
elif [ -e "${PLACE}/${REPOSITORY}" ]
|
||||
then
|
||||
sed -e "s|@DISTRIBUTION@|${LH_DISTRIBUTION}|g" \
|
||||
-e "s|@ARCHIVE_AREAS@|${LH_ARCHIVE_AREAS}|g" \
|
||||
sed -e "s|@DISTRIBUTION@|${LB_DISTRIBUTION}|g" \
|
||||
-e "s|@ARCHIVE_AREAS@|${LB_ARCHIVE_AREAS}|g" \
|
||||
"${PLACE}/${REPOSITORY}" > \
|
||||
"chroot/etc/apt/sources.list.d/${REPOSITORY}.list"
|
||||
fi
|
||||
|
||||
if [ "${LH_APT_SECURE}" != false ]
|
||||
if [ "${LB_APT_SECURE}" != false ]
|
||||
then
|
||||
# Adding archive signing keys (binary)
|
||||
if [ -e "${PLACE}/${REPOSITORY}.binary.gpg" ]
|
||||
|
@ -583,7 +583,7 @@ case "${1}" in
|
|||
mkdir -p chroot/var/cache/apt/archives/partial
|
||||
|
||||
# Cleaning apt package lists
|
||||
if [ "${LH_BINARY_INDICES}" = "false" ]
|
||||
if [ "${LB_BINARY_INDICES}" = "false" ]
|
||||
then
|
||||
rm -rf chroot/var/lib/apt/lists
|
||||
mkdir -p chroot/var/lib/apt/lists/partial
|
||||
|
@ -594,9 +594,9 @@ case "${1}" in
|
|||
rm -rf chroot/root/local-packages
|
||||
|
||||
# Remove local packages key if it exists
|
||||
if apt-key list | grep -q ${_LH_LOCAL_KEY_EMAIL}
|
||||
if apt-key list | grep -q ${_LB_LOCAL_KEY_EMAIL}
|
||||
then
|
||||
apt-key del ${_LH_LOCAL_KEY_EMAIL}
|
||||
apt-key del ${_LB_LOCAL_KEY_EMAIL}
|
||||
fi
|
||||
|
||||
# Removing stage file
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'convert symlinks')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_SYMLINKS}" != "true" ]
|
||||
if [ "${LB_SYMLINKS}" != "true" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'mount /sys')"
|
||||
|
@ -43,13 +43,13 @@ case "${1}" in
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ "${LH_USE_FAKEROOT}" != "true" ]
|
||||
if [ "${LB_USE_FAKEROOT}" != "true" ]
|
||||
then
|
||||
# Create mountpoint
|
||||
mkdir -p chroot/sys
|
||||
|
||||
# Mounting /sys
|
||||
${LH_ROOT_COMMAND} mount sysfs-live -t sysfs chroot/sys
|
||||
${LB_ROOT_COMMAND} mount sysfs-live -t sysfs chroot/sys
|
||||
else
|
||||
rm -rf chroot/sys
|
||||
ln -s /sys chroot/
|
||||
|
@ -68,13 +68,13 @@ case "${1}" in
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ "${LH_USE_FAKEROOT}" != "true" ]
|
||||
if [ "${LB_USE_FAKEROOT}" != "true" ]
|
||||
then
|
||||
# Unmounting /sys
|
||||
#fuser -km chroot/sys
|
||||
if [ -e chroot/sys/class ]
|
||||
then
|
||||
${LH_ROOT_COMMAND} umount chroot/sys
|
||||
${LB_ROOT_COMMAND} umount chroot/sys
|
||||
fi
|
||||
else
|
||||
rm -rf chroot/sys
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'manage /usr/sbin/policy-rc.d')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'configure sysvinit')"
|
||||
|
@ -38,7 +38,7 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ "${LH_SYSVINIT}" = "true" ]
|
||||
if [ "${LB_SYSVINIT}" = "true" ]
|
||||
then
|
||||
# Disable all
|
||||
for FILE in chroot/etc/init.d/*
|
||||
|
@ -47,7 +47,7 @@ then
|
|||
done
|
||||
|
||||
# Re-enable all required (taken from -f standard chroot)
|
||||
for PACKAGE in ${LH_INITRAMFS} console-common cron dpkg ifupdown initscripts kbd klogd libc6 libdevmapper1.02 libselinux1 libsepol1 login makedev module-init-tools netbase openbsd-inetd procps sudo sysklogd udev util-linux
|
||||
for PACKAGE in ${LB_INITRAMFS} console-common cron dpkg ifupdown initscripts kbd klogd libc6 libdevmapper1.02 libselinux1 libsepol1 login makedev module-init-tools netbase openbsd-inetd procps sudo sysklogd udev util-linux
|
||||
do
|
||||
if [ -f chroot/var/lib/dpkg/info/${PACKAGE}.postinst ]
|
||||
then
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'install tasks into chroot')"
|
||||
|
@ -38,13 +38,13 @@ Check_lockfile .lock
|
|||
# Creating lock file
|
||||
Create_lockfile .lock
|
||||
|
||||
if [ -n "${LH_TASKS}" ] && [ "${LH_TASKS}" != "none" ]
|
||||
if [ -n "${LB_TASKS}" ] && [ "${LB_TASKS}" != "none" ]
|
||||
then
|
||||
# Restoring cache
|
||||
Restore_cache cache/packages_chroot
|
||||
|
||||
# Checking depends
|
||||
case "${LH_TASKSEL}" in
|
||||
case "${LB_TASKSEL}" in
|
||||
aptitude)
|
||||
Check_package chroot/usr/bin/aptitude aptitude
|
||||
;;
|
||||
|
@ -58,13 +58,13 @@ then
|
|||
Install_package
|
||||
|
||||
# Installing tasks
|
||||
case "${LH_TASKSEL}" in
|
||||
case "${LB_TASKSEL}" in
|
||||
aptitude)
|
||||
Chroot chroot "aptitude ${APTITUDE_OPTIONS} install ${LH_TASKS}"
|
||||
Chroot chroot "aptitude ${APTITUDE_OPTIONS} install ${LB_TASKS}"
|
||||
;;
|
||||
|
||||
tasksel)
|
||||
for TASK in ${LH_TASKS}
|
||||
for TASK in ${LB_TASKS}
|
||||
do
|
||||
case "${TASK}" in
|
||||
gnome*)
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'manage /usr/sbin/initctl')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Read meta config
|
||||
if [ "${1}" != "noauto" ] && [ -x auto/clean ]
|
||||
|
@ -68,30 +68,30 @@ do
|
|||
;;
|
||||
|
||||
--cache)
|
||||
${LH_ROOT_COMMAND} rm -rf cache
|
||||
${LB_ROOT_COMMAND} rm -rf cache
|
||||
;;
|
||||
|
||||
--chroot)
|
||||
Echo_message "Cleaning chroot"
|
||||
${LH_ROOT_COMMAND} umount -f chroot/sys > /dev/null 2>&1 || true
|
||||
${LH_ROOT_COMMAND} umount -f chroot/proc/sys/fs/binfmt_misc > /dev/null 2>&1 || true
|
||||
${LH_ROOT_COMMAND} umount -f chroot/proc > /dev/null 2>&1 || true
|
||||
${LH_ROOT_COMMAND} umount -f chroot/lib/init/rw > /dev/null 2>&1 || true
|
||||
${LH_ROOT_COMMAND} umount -f chroot/dev/shm > /dev/null 2>&1 || true
|
||||
${LH_ROOT_COMMAND} umount -f chroot/dev/pts > /dev/null 2>&1 || true
|
||||
${LH_ROOT_COMMAND} umount -f chroot/dev > /dev/null 2>&1 || true
|
||||
${LH_ROOT_COMMAND} umount -f chroot/var/lib/dpkg > /dev/null 2>&1 || true
|
||||
${LB_ROOT_COMMAND} umount -f chroot/sys > /dev/null 2>&1 || true
|
||||
${LB_ROOT_COMMAND} umount -f chroot/proc/sys/fs/binfmt_misc > /dev/null 2>&1 || true
|
||||
${LB_ROOT_COMMAND} umount -f chroot/proc > /dev/null 2>&1 || true
|
||||
${LB_ROOT_COMMAND} umount -f chroot/lib/init/rw > /dev/null 2>&1 || true
|
||||
${LB_ROOT_COMMAND} umount -f chroot/dev/shm > /dev/null 2>&1 || true
|
||||
${LB_ROOT_COMMAND} umount -f chroot/dev/pts > /dev/null 2>&1 || true
|
||||
${LB_ROOT_COMMAND} umount -f chroot/dev > /dev/null 2>&1 || true
|
||||
${LB_ROOT_COMMAND} umount -f chroot/var/lib/dpkg > /dev/null 2>&1 || true
|
||||
|
||||
${LH_ROOT_COMMAND} umount -f chroot/binary.tmp > /dev/null 2>&1 || true
|
||||
${LH_ROOT_COMMAND} umount -f chroot/dev.tmp/pts > /dev/null 2>&1 || true
|
||||
${LB_ROOT_COMMAND} umount -f chroot/binary.tmp > /dev/null 2>&1 || true
|
||||
${LB_ROOT_COMMAND} umount -f chroot/dev.tmp/pts > /dev/null 2>&1 || true
|
||||
|
||||
${LH_ROOT_COMMAND} rm -rf chroot chroot.tmp
|
||||
${LB_ROOT_COMMAND} rm -rf chroot chroot.tmp
|
||||
|
||||
rm -f .stage/chroot*
|
||||
;;
|
||||
|
||||
--binary)
|
||||
${LH_ROOT_COMMAND} umount -f binary.tmp > /dev/null 2>&1 || true
|
||||
${LB_ROOT_COMMAND} umount -f binary.tmp > /dev/null 2>&1 || true
|
||||
rm -rf binary.tmp binary.deb binary.udeb
|
||||
rm -f binary*.iso
|
||||
rm -f binary*.img
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'utility to build Debian Live systems')"
|
||||
|
@ -42,9 +42,9 @@ case "${1}" in
|
|||
COMMAND="${1}"
|
||||
shift
|
||||
|
||||
if [ -x "${LH_BASE}/scripts/build/${COMMAND}" ]
|
||||
if [ -x "${LB_BASE}/scripts/build/${COMMAND}" ]
|
||||
then
|
||||
LH=1 exec "${LH_BASE}/scripts/build/${COMMAND}" "${@}"
|
||||
LH=1 exec "${LB_BASE}/scripts/build/${COMMAND}" "${@}"
|
||||
elif [ -x /usr/share/live/build/scripts/build/${COMMAND} ]
|
||||
then
|
||||
LH=1 exec /usr/share/live/build/scripts/build/"${COMMAND}" "${@}"
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
if [ -x "$(which man 2>/dev/null)" ]
|
||||
then
|
||||
|
|
|
@ -8,10 +8,10 @@
|
|||
## under certain conditions; see COPYING for details.
|
||||
|
||||
|
||||
LH_BASE="${PWD}/live-build"
|
||||
PATH="${LH_BASE}/helpers:${PATH}"
|
||||
LB_BASE="${PWD}/live-build"
|
||||
PATH="${LB_BASE}/helpers:${PATH}"
|
||||
|
||||
export LH_BASE PATH
|
||||
export LB_BASE PATH
|
||||
|
||||
if [ ! -z "${1}" ]
|
||||
then
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'build source images')"
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'create source checksums')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_CHECKSUMS}" = "none" ] || [ "${LH_SOURCE}" != "true" ]
|
||||
if [ "${LB_CHECKSUMS}" = "none" ] || [ "${LB_SOURCE}" != "true" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -48,7 +48,7 @@ do
|
|||
continue
|
||||
fi
|
||||
|
||||
for CHECKSUM in ${LH_CHECKSUMS}
|
||||
for CHECKSUM in ${LB_CHECKSUMS}
|
||||
do
|
||||
Echo_message "Begin creating source ${CHECKSUM}sum.txt..."
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'debian sources')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_SOURCE}" != "true" ]
|
||||
if [ "${LB_SOURCE}" != "true" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
@ -53,9 +53,9 @@ fi
|
|||
Chroot chroot "dpkg --get-selections" | awk '{ print $1 }' > source-selection.txt
|
||||
|
||||
cat >> source-selection.txt << EOF
|
||||
${LH_BOOTLOADER}
|
||||
${LB_BOOTLOADER}
|
||||
live-helper
|
||||
${LH_INITRAMFS}
|
||||
${LB_INITRAMFS}
|
||||
dosfstools
|
||||
genisoimage
|
||||
parted
|
||||
|
@ -64,7 +64,7 @@ genext2fs
|
|||
mtd-tools
|
||||
EOF
|
||||
|
||||
case "${LH_ARCHITECTURE}" in
|
||||
case "${LB_ARCHITECTURE}" in
|
||||
amd64|i386)
|
||||
|
||||
cat >> source-selection.txt << EOF
|
||||
|
@ -73,9 +73,9 @@ syslinux
|
|||
grub
|
||||
EOF
|
||||
|
||||
if [ "${LH_MEMTEST}" != "false" ] && [ "${LH_MEMTEST}" != "none" ]
|
||||
if [ "${LB_MEMTEST}" != "false" ] && [ "${LB_MEMTEST}" != "none" ]
|
||||
then
|
||||
echo "${LH_MEMTEST}" >> source-selection.txt
|
||||
echo "${LB_MEMTEST}" >> source-selection.txt
|
||||
fi
|
||||
;;
|
||||
|
||||
|
@ -93,9 +93,9 @@ EOF
|
|||
;;
|
||||
esac
|
||||
|
||||
if [ -n "${LH_TASKS}" ]
|
||||
if [ -n "${LB_TASKS}" ]
|
||||
then
|
||||
echo "${LH_TASKSEL}" >> source-selection.txt
|
||||
echo "${LB_TASKSEL}" >> source-selection.txt
|
||||
fi
|
||||
|
||||
MISSING=""
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'copy debian-live config into source')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_SOURCE}" != "true" ]
|
||||
if [ "${LB_SOURCE}" != "true" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'install disk information into source')"
|
||||
|
@ -24,7 +24,7 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
case "${LH_SOURCE_IMAGES}" in
|
||||
case "${LB_SOURCE_IMAGES}" in
|
||||
iso*|usb*)
|
||||
;;
|
||||
|
||||
|
@ -50,11 +50,11 @@ Create_lockfile .lock
|
|||
mkdir -p source/.disk
|
||||
|
||||
TITLE="Debian GNU/Linux"
|
||||
DISTRIBUTION="$(echo ${LH_DISTRIBUTION} | cut -b 1 | tr '[a-z]' '[A-Z]')"
|
||||
DISTRIBUTION="${DISTRIBUTION}$(echo ${LH_DISTRIBUTION} | cut -b 2-)"
|
||||
eval VERSION="$`echo RELEASE_${LH_DISTRIBUTION}`"
|
||||
DISTRIBUTION="$(echo ${LB_DISTRIBUTION} | cut -b 1 | tr '[a-z]' '[A-Z]')"
|
||||
DISTRIBUTION="${DISTRIBUTION}$(echo ${LB_DISTRIBUTION} | cut -b 2-)"
|
||||
eval VERSION="$`echo RELEASE_${LB_DISTRIBUTION}`"
|
||||
|
||||
case "${LH_MODE}" in
|
||||
case "${LB_MODE}" in
|
||||
debian)
|
||||
STRING="Official Snapshot ${ARCHITECTURE}"
|
||||
TRACE="project/trace/ftp-master.debian.org"
|
||||
|
@ -79,11 +79,11 @@ esac
|
|||
|
||||
if [ -n "${TRACE}" ]
|
||||
then
|
||||
echo "$(wget -q ${LH_MIRROR_BOOTSTRAP}/${TRACE} -O - | head -n 1)" \
|
||||
echo "$(wget -q ${LB_MIRROR_BOOTSTRAP}/${TRACE} -O - | head -n 1)" \
|
||||
> source/.disk/archive_trace
|
||||
fi
|
||||
|
||||
case "${LH_DEBIAN_INSTALLER}" in
|
||||
case "${LB_DEBIAN_INSTALLER}" in
|
||||
cdrom)
|
||||
echo "${TITLE} ${VERSION} \"${DISTRIBUTION}\" - ${STRING} LIVE/CD Source $(date +%Y%m%d-%H:%M)" > source/.disk/info
|
||||
;;
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'build iso source image')"
|
||||
|
@ -24,12 +24,12 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_SOURCE}" != "true" ]
|
||||
if [ "${LB_SOURCE}" != "true" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
case "${LH_SOURCE_IMAGES}" in
|
||||
case "${LB_SOURCE_IMAGES}" in
|
||||
iso*)
|
||||
;;
|
||||
|
||||
|
@ -74,24 +74,24 @@ then
|
|||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -v"
|
||||
fi
|
||||
|
||||
if [ -n "${LH_ISO_APPLICATION}" ] && [ "${LH_ISO_APPLICATION}" != "none" ]
|
||||
if [ -n "${LB_ISO_APPLICATION}" ] && [ "${LB_ISO_APPLICATION}" != "none" ]
|
||||
then
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -A \"${LH_ISO_APPLICATION}\""
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -A \"${LB_ISO_APPLICATION}\""
|
||||
fi
|
||||
|
||||
if [ -n "${LH_ISO_PREPARER}" ] && [ "${LH_ISO_PREPARER}" != "none" ]
|
||||
if [ -n "${LB_ISO_PREPARER}" ] && [ "${LB_ISO_PREPARER}" != "none" ]
|
||||
then
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -p \"${LH_ISO_PREPARER}\""
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -p \"${LB_ISO_PREPARER}\""
|
||||
fi
|
||||
|
||||
if [ -n "${LH_ISO_PUBLISHER}" ] && [ "${LH_ISO_PUBLISHER}" != "none" ]
|
||||
if [ -n "${LB_ISO_PUBLISHER}" ] && [ "${LB_ISO_PUBLISHER}" != "none" ]
|
||||
then
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -publisher \"${LH_ISO_PUBLISHER}\""
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -publisher \"${LB_ISO_PUBLISHER}\""
|
||||
fi
|
||||
|
||||
if [ -n "${LH_ISO_VOLUME}" ] && [ "${LH_ISO_VOLUME}" != "none" ]
|
||||
if [ -n "${LB_ISO_VOLUME}" ] && [ "${LB_ISO_VOLUME}" != "none" ]
|
||||
then
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -V \"${LH_ISO_VOLUME}\""
|
||||
GENISOIMAGE_OPTIONS="${GENISOIMAGE_OPTIONS} -V \"${LB_ISO_VOLUME}\""
|
||||
fi
|
||||
|
||||
# Moving image
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'build source net image')"
|
||||
|
@ -24,12 +24,12 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_SOURCE}" != "true" ]
|
||||
if [ "${LB_SOURCE}" != "true" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if ! In_list net "${LH_SOURCE_IMAGES}"
|
||||
if ! In_list net "${LB_SOURCE_IMAGES}"
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
set -e
|
||||
|
||||
# Including common functions
|
||||
. "${LH_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
. "${LB_BASE:-/usr/share/live/build}"/scripts/build.sh
|
||||
|
||||
# Setting static variables
|
||||
DESCRIPTION="$(Echo 'build source tarball')"
|
||||
|
@ -24,12 +24,12 @@ Arguments "${@}"
|
|||
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
|
||||
Set_defaults
|
||||
|
||||
if [ "${LH_SOURCE}" != "true" ]
|
||||
if [ "${LB_SOURCE}" != "true" ]
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if ! In_list tar "${LH_SOURCE_IMAGES}"
|
||||
if ! In_list tar "${LB_SOURCE_IMAGES}"
|
||||
then
|
||||
exit 0
|
||||
fi
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue