3
# lh_binary_win32-loader(1) - copy win32-loader into binary
4
# Copyright (C) 2006-2010 Daniel Baumann <daniel@debian.org>
6
# live-helper comes with ABSOLUTELY NO WARRANTY; for details see COPYING.
7
# This is free software, and you are welcome to redistribute it
8
# under certain conditions; see COPYING for details.
12
# Including common functions
13
. "${LH_BASE:-/usr/share/live-helper}"/scripts/build.sh
15
# Setting static variables
16
DESCRIPTION="$(Echo 'copy win32-loader into binary')"
18
USAGE="${PROGRAM} [--force]"
22
# Reading configuration files
23
Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
26
if [ "${LH_WIN32_LOADER}" != "true" ] || [ "${LH_BINARY_IMAGES}" = "virtual-hdd" ]
31
Echo_message "Begin copying win32-loader..."
33
# Requiring stage file
34
Require_stagefile .stage/config .stage/bootstrap
37
Check_stagefile .stage/binary_win32-loader
45
case "${LH_ARCHITECTURE}" in
47
case "${LH_DISTRIBUTION}" in
49
WIN32_LOADER="/usr/lib/win32-loader"
53
WIN32_LOADER="/usr/share/win32"
57
if [ "${LH_BUILD_WITH_CHROOT}" = "true" ]
60
Check_package chroot/${WIN32_LOADER}/win32-loader.exe win32-loader
63
Restore_cache cache/packages_binary
68
# Copying win32-loader
69
cp -r chroot/${WIN32_LOADER}/* binary
71
cp -r ${WIN32_LOADER}/* binary
74
mv binary/win32-loader.exe binary/setup.exe
76
if [ -e binary/win32-loader-standalone.exe ]
78
mv binary/win32-loader-standalone.exe binary/setup-standalone.exe
81
if [ "${LH_DEBIAN_INSTALLER}" != "false" ]
84
cat > binary/win32-loader.ini << EOF
86
arch=${LH_ARCHITECTURE}
87
i386/linux=install/vmlinuz
88
i386/initrd=install/initrd.gz
89
i386/gtk/linux=install/vmlinuz
90
i386/gtk/initrd=install/gtk/initrd.gz
100
Save_cache cache/packages_binary
107
Echo_warning "win32-loader inclusion is set to true but not compatible with your architecture, ignoring."
111
# Creating stage file
112
Create_stagefile .stage/binary_win32-loader