tidy script init (1/4) - arg and config processing

Partial fix for #952919

Gbp-Dch: Short
This commit is contained in:
jnqnfe 2015-02-05 03:30:47 +00:00 committed by Luca Boccassi
parent ed2d70bde1
commit b49abcc1a8
68 changed files with 155 additions and 329 deletions

22
functions/init.sh Executable file
View File

@ -0,0 +1,22 @@
#!/bin/sh
## live-build(7) - System Build Scripts
## Copyright (C) 2006-2014 Daniel Baumann <mail@daniel-baumann.ch>
##
## This program comes with ABSOLUTELY NO WARRANTY; for details see COPYING.
## This is free software, and you are welcome to redistribute it
## under certain conditions; see COPYING for details.
Common_config_files ()
{
echo "config/all config/common config/bootstrap config/chroot config/binary config/source"
}
Init_config_data ()
{
Arguments "${@}"
Read_conffiles $(Common_config_files)
Set_defaults
}

View File

@ -25,11 +25,8 @@ DESCRIPTION="Build binary images"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Setup cleanup function
Setup_cleanup

View File

@ -18,11 +18,8 @@ DESCRIPTION="Create binary checksums"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_CHECKSUMS}" = "none" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Copy chroot into chroot"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Echo_message "Begin copying chroot..."

View File

@ -18,11 +18,8 @@ DESCRIPTION="Install disk information into binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
case "${LIVE_IMAGE_TYPE}" in
iso*|hdd*)

View File

@ -18,11 +18,8 @@ DESCRIPTION="Prepares and installs Grub based EFI support into binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Check_Any_Bootloader_Role "grub-efi"

View File

@ -18,11 +18,8 @@ DESCRIPTION="Installs grub-legacy into binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Check_First_Bootloader_Role "grub-legacy"

View File

@ -18,11 +18,8 @@ DESCRIPTION="Installs grub-pc into binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Check_Any_Bootloader_Role "grub-pc"

View File

@ -18,11 +18,8 @@ DESCRIPTION="Build binary image"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if ! In_list hdd "${LIVE_IMAGE_TYPE}"
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Execute hooks in binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Echo_message "Begin executing hooks..."

View File

@ -18,11 +18,8 @@ DESCRIPTION="Copy files into binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Echo_message "Begin copying binary includes..."

View File

@ -18,11 +18,8 @@ DESCRIPTION="Build iso binary image"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
case "${LIVE_IMAGE_TYPE}" in
iso)

View File

@ -18,11 +18,8 @@ DESCRIPTION="Install linux-image into binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_LINUX_PACKAGES}" = "none" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Copy loadlin into binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_LOADLIN}" != "true" ] || [ "${LB_BINARY_IMAGES}" = "netboot" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Installs loopback.cfg into binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# We avoid checking if we need to be running this bootloader
# on purpose. The reason: You will always want to have

View File

@ -18,11 +18,8 @@ DESCRIPTION="Create manifest"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_CHROOT_FILESYSTEM}" = "none" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Installs a memtest into binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_MEMTEST}" = "none" ] || [ "${LB_CHROOT_FILESYSTEM}" = "none" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Build netboot binary image"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if ! In_list netboot "${LIVE_IMAGE_TYPE}"
then

View File

@ -19,11 +19,8 @@ DESCRIPTION="Build ONIE binary image"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_ONIE}" != "true" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Install local packages into binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Echo_message "Begin installing local package lists..."

View File

@ -18,11 +18,8 @@ DESCRIPTION="Build rootfs image"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Echo_message "Begin building root filesystem image..."

View File

@ -18,11 +18,8 @@ DESCRIPTION="Installs syslinux into binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Check_Any_Bootloader_Role "syslinux"

View File

@ -18,11 +18,8 @@ DESCRIPTION="Build binary tarball"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if ! In_list tar "${LIVE_IMAGE_TYPE}"
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Copy win32-loader into binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_WIN32_LOADER}" != "true" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Build zsync control files"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LIVE_IMAGE_TYPE}" != "iso" ] && [ "${LIVE_IMAGE_TYPE}" != "iso-hybrid" ]
then

View File

@ -25,11 +25,8 @@ DESCRIPTION="Bootstrap a Debian system"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Setup cleanup function
Setup_cleanup

View File

@ -25,11 +25,8 @@ if [ "${_PASS}" != "binary" ] && [ "${_PASS}" != "source" ]; then
Usage
fi
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Requiring stage file
Require_stagefile .build/config .build/bootstrap

View File

@ -18,11 +18,8 @@ DESCRIPTION="Cache bootstrap stage"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Check architecture
Check_crossarchitectures

View File

@ -18,11 +18,8 @@ DESCRIPTION="Bootstrap a Debian system with debootstrap(8)"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ ! $(which debootstrap) ]
then

View File

@ -38,8 +38,6 @@ DESCRIPTION="Build a Debian Live system"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
if [ ! -d config ]
then
Echo_warning "No config/ directory; using defaults for all options"
@ -58,9 +56,8 @@ then
exit 1
fi
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Checking defaults
Check_defaults

View File

@ -25,11 +25,8 @@ DESCRIPTION="Customize the Debian system"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Setup cleanup function
Setup_cleanup

View File

@ -18,11 +18,8 @@ DESCRIPTION="Manage /etc/apt/apt.conf"
HELP=""
USAGE="${PROGRAM} {install|install-binary|remove} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Requiring stage file
Require_stagefile .build/config .build/bootstrap

View File

@ -26,11 +26,8 @@ then
Usage
fi
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Requiring stage file
Require_stagefile .build/config .build/bootstrap

View File

@ -18,11 +18,8 @@ DESCRIPTION="Cache chroot stage"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if ! In_list "chroot" ${LB_CACHE_STAGES}
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Manage /etc/debian_chroot"
HELP=""
USAGE="${PROGRAM} {install|remove} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Requiring stage file
Require_stagefile .build/config .build/bootstrap

View File

@ -18,11 +18,8 @@ DESCRIPTION="Mount /dev/pts"
HELP=""
USAGE="${PROGRAM} {install|remove} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Requiring stage file
Require_stagefile .build/config .build/bootstrap

View File

@ -18,11 +18,8 @@ DESCRIPTION="Manage /sbin/dpkg"
HELP=""
USAGE="${PROGRAM} {install|remove} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Requiring stage file
Require_stagefile .build/config .build/bootstrap

View File

@ -18,11 +18,8 @@ DESCRIPTION="Schedule kernel packages for installation"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_FIRMWARE_CHROOT}" != "true" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Execute hacks in chroot"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Echo_message "Begin executing hacks..."

View File

@ -18,11 +18,8 @@ DESCRIPTION="Execute hooks in chroot"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Echo_message "Begin executing hooks..."

View File

@ -18,11 +18,8 @@ DESCRIPTION="Manage /bin/hostname"
HELP=""
USAGE="${PROGRAM} {install|remove} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Requiring stage file
Require_stagefile .build/config .build/bootstrap

View File

@ -18,11 +18,8 @@ DESCRIPTION="Manage /etc/hosts"
HELP=""
USAGE="${PROGRAM} {install|remove} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Requiring stage file
Require_stagefile .build/config .build/bootstrap

View File

@ -18,11 +18,8 @@ DESCRIPTION="Copy files into chroot"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Echo_message "Begin copying chroot includes..."

View File

@ -21,11 +21,8 @@ USAGE="${PROGRAM} {install|live} [--force]"
_PASS="${1}"
shift
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Echo_message "Begin installing packages (${_PASS} pass)..."

View File

@ -18,11 +18,8 @@ DESCRIPTION="Make build interactive"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_INTERACTIVE}" = "false" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Schedule kernel packages for installation"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_LINUX_PACKAGES}" = "none" ]
then

View File

@ -21,11 +21,8 @@ USAGE="${PROGRAM} {install|live} [--force]"
_PASS="${1}"
shift
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Echo_message "Begin queueing installation of package lists (${_PASS} pass)..."

View File

@ -18,11 +18,8 @@ DESCRIPTION="Execute local preseed in chroot"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Echo_message "Begin executing local preseeds..."

View File

@ -18,11 +18,8 @@ DESCRIPTION="Mount /proc"
HELP=""
USAGE="${PROGRAM} {install|remove} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Requiring stage file
Require_stagefile .build/config .build/bootstrap

View File

@ -18,11 +18,8 @@ DESCRIPTION="Manage /etc/resolv.conf"
HELP=""
USAGE="${PROGRAM} {install|remove} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Requiring stage file
Require_stagefile .build/config .build/bootstrap

View File

@ -18,11 +18,8 @@ DESCRIPTION="Mount /sys/fs/selinux"
HELP=""
USAGE="${PROGRAM} {install|remove} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Requiring stage file
Require_stagefile .build/config .build/bootstrap

View File

@ -18,11 +18,8 @@ DESCRIPTION="Mount /sys"
HELP=""
USAGE="${PROGRAM} {install|remove} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Requiring stage file
Require_stagefile .build/config .build/bootstrap

View File

@ -18,11 +18,8 @@ DESCRIPTION="Manage /usr/sbin/policy-rc.d"
HELP=""
USAGE="${PROGRAM} {install|remove} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Requiring stage file
Require_stagefile .build/config .build/bootstrap

View File

@ -18,11 +18,8 @@ DESCRIPTION="Use tmpfs to speedup the build"
HELP=""
USAGE="${PROGRAM} {install|remove} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_BUILD_WITH_TMPFS}" != "true" ]
then

View File

@ -34,7 +34,7 @@ USAGE="${PROGRAM} [--all] [--cache] [--chroot] [--binary] [--purge] [--remove] [
#Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Read_conffiles $(Common_config_files)
Set_defaults
# Avoid cases were users accidentally nuke their config/binary

View File

@ -186,7 +186,7 @@ Local_arguments ()
Echo "%s: This is live-build version %s" "${0}" "${VERSION_DPKG:-${VERSION}}"
# Dump conffile contents
Print_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Print_conffiles $(Common_config_files)
# Dump contents of directories that contain text files
for DIRECTORY in config/package-lists config/apt config/preseed config/rootfs
@ -909,7 +909,7 @@ then
fi
# Reading existing configuration
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Read_conffiles $(Common_config_files)
Local_arguments "${@}"

View File

@ -25,11 +25,8 @@ DESCRIPTION="Preparing installer images"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Setup cleanup function
Setup_cleanup

View File

@ -18,11 +18,8 @@ DESCRIPTION="Install debian-installer into binary"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${_DEBUG}" = "true" ]
then

View File

@ -18,12 +18,8 @@ DESCRIPTION="Include local preseed in installer"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
# Check d-i configuration
case "${LB_DEBIAN_INSTALLER}" in

View File

@ -25,11 +25,8 @@ DESCRIPTION="Build source images"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_SOURCE}" != "true" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Create source checksums"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_CHECKSUMS}" = "none" ] || [ "${LB_SOURCE}" != "true" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Debian sources"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_SOURCE}" != "true" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Install disk information into source"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
case "${LB_SOURCE_IMAGES}" in
iso*|hdd*)

View File

@ -18,11 +18,8 @@ DESCRIPTION="Build source image"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_SOURCE}" != "true" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Execute hooks in source"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/source config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
Echo_message "Begin executing hooks..."

View File

@ -18,11 +18,8 @@ DESCRIPTION="Build iso source image"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_SOURCE}" != "true" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Copy live config into source"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_SOURCE}" != "true" ]
then

View File

@ -18,11 +18,8 @@ DESCRIPTION="Build source tarball"
HELP=""
USAGE="${PROGRAM} [--force]"
Arguments "${@}"
# Reading configuration files
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
Set_defaults
# Processing arguments and configuration files
Init_config_data "${@}"
if [ "${LB_SOURCE}" != "true" ]
then