5
if [ "$ARCH" = "alpha" ] || [ "$ARCH" = "ia64" ]; then
11
required="base-files base-passwd bash bsdutils debconf debianutils diff dpkg e2fsprogs fileutils findutils grep gzip hostname libcap1 libc6 libdb2 libdb3 libncurses5 libnewt0 libpam-modules libpam-runtime libpam0g libperl5.6 libpopt0 libreadline4 libstdc++2.10-glibc2.2 login makedev mawk modutils mount ncurses-base ncurses-bin passwd perl-base procps sed shellutils slang1 sysvinit tar textutils util-linux whiptail"
13
base="adduser apt apt-utils at base-config bsdmainutils console-common console-tools console-tools-libs console-data cpio cron dhcp-client ed exim fdutils gettext-base groff-base ifupdown info klogd libident libldap2 liblockfile1 libpcre3 libsasl7 libwrap0 logrotate mailx man-db manpages modconf nano net-tools netbase netkit-inetd netkit-ping nvi ppp pppconfig pppoe pppoeconf libpcap0 sysklogd tasksel tcpd telnet"
16
echo "$2" | tr ' ' '\n' | grep -v "^$1$" | tr '\n' ' '
23
required="$(without_package "libc6" "$required") libc6.1"
24
base="$base setserial aboot pciutils"
28
base="$base setserial libgpmg1"
29
IPFWTOOL="ipchains iptables"
32
required="$(without_package "libperl5.6" "$required") mbr"
33
base="$base lilo pciutils setserial syslinux psmisc pcmcia-cs"
34
IPFWTOOL="ipchains iptables"
37
required="$(without_package "libc6" "$required") libc6.1 gcc-2.96-base"
38
base="$base elilo efibootmgr dosfstools libparted1.4 parted"
41
base="$base atari-bootstrap atari-fdisk amiga-fdisk eject mac-fdisk pmac-fdisk-cross setserial vmelilo"
45
base="$base quik mac-fdisk amiga-fdisk psmisc powerpc-utils setserial pciutils hfsutils yaboot pcmcia-cs"
46
IPFWTOOL="ipchains iptables"
49
base="$base silo eject pciutils sparc-utils"
50
IPFWTOOL="ipchains iptables"
53
base="$base dvhtool pciutils setserial" # pcmcia-cs
56
base="$base delo pciutils setserial" # pcmcia-cs
59
base="$base palo libstdc++3 gcc-3.0-base"
60
required="$(without_package "libstdc++2.10-glibc2.2" "$required")"
63
# base-config depends on console-data and console-common
64
# so we can't exclude them although they are useless on s390
65
base="$base s390-tools telnetd devfsd"
66
base="$(without_package "console-tools" "$base")"
67
base="$(without_package "console-tools-libs" "$base")"
68
base="$(without_package "fdutils" "$base")"
69
base="$(without_package "ppp" "$base")"
70
base="$(without_package "pppconfig" "$base")"
71
base="$(without_package "pppoe" "$base")"
72
base="$(without_package "pppoeconf" "$base")"
79
base="$base $IPFWTOOL"
82
first_stage_install () {
85
mkdir -p "$TARGET/var/lib/dpkg"
86
: >"$TARGET/var/lib/dpkg/status"
87
echo >"$TARGET/var/lib/dpkg/available"
90
if [ ! -e "$TARGET/etc/fstab" ]; then
91
echo '# UNCONFIGURED FSTAB FOR BASE SYSTEM' > "$TARGET/etc/fstab"
92
chown 0:0 "$TARGET/etc/fstab"; chmod 644 "$TARGET/etc/fstab"
99
local deb="$(debfor $pkg)"
100
local ver="$(extract_deb_field "$TARGET/$deb" Version)"
102
mkdir -p "$TARGET/var/lib/dpkg/info"
107
Status: install ok installed" >> "$TARGET/var/lib/dpkg/status"
109
touch "$TARGET/var/lib/dpkg/info/${pkg}.list"
115
second_stage_install () {
117
smallyes '' | in_target dpkg --force-depends --install $(debfor "$@")
121
baseprog="$(($baseprog + ${1:-1}))"
125
in_target /sbin/ldconfig
127
DEBIAN_FRONTEND=Noninteractive
128
export DEBIAN_FRONTEND
133
p; progress $baseprog $bases INSTBASE "Installing base system" #1
134
info INSTCORE "Installing core packages..."
136
p; progress $baseprog $bases INSTBASE "Installing base system" #2
137
ln -sf mawk "$TARGET/usr/bin/awk"
138
x_core_install base-files base-passwd
139
p; progress $baseprog $bases INSTBASE "Installing base system" #3
142
if [ ! -e "$TARGET/etc/localtime" ]; then
143
ln -sf /usr/share/zoneinfo/UTC "$TARGET/etc/localtime"
146
p; progress $baseprog $bases INSTBASE "Installing base system" #4
149
p; progress $baseprog $bases INSTBASE "Installing base system" #5
150
x_core_install perl-base
151
p; progress $baseprog $bases INSTBASE "Installing base system" #6
152
rm "$TARGET/usr/bin/awk"
154
p; progress $baseprog $bases INSTBASE "Installing base system" #7
155
x_core_install debconf
157
info UNPACKREQ "Unpacking required packages..."
159
p; progress $baseprog $bases INSTBASE "Installing base system" #8
160
smallyes '' | repeatn 5 in_target_failmsg UNPACK_REQ_FAIL_FIVE "Failure while unpacking required packages. This will be attempted up to five times." "" dpkg --force-depends --unpack $(debfor $required)
161
p 10; progress $baseprog $bases INSTBASE "Installing base system" #18
163
info CONFREQ "Configuring required packages..."
165
mv "$TARGET/sbin/start-stop-daemon" "$TARGET/sbin/start-stop-daemon.REAL"
169
echo \"Warning: Fake start-stop-daemon called, doing nothing\"" > "$TARGET/sbin/start-stop-daemon"
170
chmod 755 "$TARGET/sbin/start-stop-daemon"
172
setup_dselect_method apt
174
p; progress $baseprog $bases INSTBASE "Installing base system" #19
175
smallyes '' | in_target_failmsg CONF_REQ_FAIL "Failure while configuring required packages." "" dpkg --configure --pending --force-configure-any --force-depends
176
p 10; progress $baseprog $bases INSTBASE "Installing base system" #29
178
if [ ! -e "$TARGET/etc/exim/exim.conf" ]; then
179
mkdir -p "$TARGET/etc/exim"
180
touch "$TARGET/etc/exim/exim.conf"
183
info INSTBASE "Installing base packages..."
185
p; progress $baseprog $bases INSTBASE "Installing base system" #30
186
smallyes '' | repeatn 5 in_target_failmsg INST_BASE_FAIL_FIVE "Failure while installing base packages. This will be re-attempted up to five times." "" dpkg --force-auto-select --force-overwrite --force-confold --skip-same-version --unpack $(debfor $base)
188
rm -f "$TARGET/usr/sbin/sendmail"
189
ln -sf /bin/true "$TARGET/usr/sbin/sendmail"
191
smallyes '' | repeatn 5 in_target_failmsg CONF_BASE_FAIL_FIVE "Failure while configuring base packages. This will be attempted 5 times." "" dpkg --force-confold --skip-same-version --configure -a
193
rm -f "$TARGET/usr/sbin/sendmail"
194
ln -sf exim "$TARGET/usr/sbin/sendmail"
196
p 9; progress $baseprog $bases INSTBASE "Installing base system" #39
198
mv "$TARGET/sbin/start-stop-daemon.REAL" "$TARGET/sbin/start-stop-daemon"
200
progress $bases $bases INSTBASE "Installing base system" #40
201
info BASESUCCESS "Base system installed successfully."