root/current/host/trunk/emdebian-tools/trunk/pbuilder/emdebian.crossd

Revision 4931, 2.6 kB (checked in by codehelp, 4 months ago)

* embootstrap fails if /bin/sh is not symlinked to /bin/bash (Closes:

#498495)

* pbuilder/emdebian.coreutils pbuilder/emdebian.crossd

pbuilder/emdebian.gpe pbuilder/emdebian.gtk pbuilder/empbuilderlib
pbuilder/emrootfslib: migrate POSIX functions out of empbuilderlib
and into a new shell library, emrootfslib, that is checked for
bashisms each build. Migrate deboostrap suite scripts into
/usr/share. Add experimental pbuilder/emdebian.coreutils.

Line 
1#  emdebian secondstage support (Default busybox, dpkg and apt version)
2#
3#  Copyright (C) 2007-2008  Neil Williams <codehelp@debian.org>
4#
5#  This package is free software; you can redistribute it and/or modify
6#  it under the terms of the GNU General Public License as published by
7#  the Free Software Foundation; either version 3 of the License, or
8#  (at your option) any later version.
9#
10#  This program is distributed in the hope that it will be useful,
11#  but WITHOUT ANY WARRANTY; without even the implied warranty of
12#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13#  GNU General Public License for more details.
14#
15#  You should have received a copy of the GNU General Public License
16#  along with this program.  If not, see <http://www.gnu.org/licenses/>.
17#
18
19mirror_style release
20download_style apt
21
22work_out_debs () {
23        required="busybox dpkg libstdc++6 libgcc1 libc6 cdebconf
24        debconf-shell libdebian-installer4 zlib1g libnewt0.52
25        libslang2 base-passwd"
26
27        base="apt gpgv libncurses5 libreadline5 readline-common
28        debianutils makedev whiptail gnupg udev base-files
29        debian-archive-keyring dhcp3-client
30        util-linux module-init-tools initscripts"
31}
32
33first_stage_install () {
34        PRESERVE_BUILDPLACE="yes"
35        . /usr/share/emdebian-tools/emrootfslib
36        extract $required
37        make_dpkg_dirs
38        prepare_proc
39        prepare_var
40        info INSTCORE " -> Preparing basic defaults for $BUILDPLACE/etc"
41        basic_etc_fstab
42        basic_group_setup
43        basic_passwd_setup
44        basic_shadow_setup
45        basic_etc_profile
46        shell_update_rcd
47        set_approx_time
48        set_cdebconf_default
49        provide_empty_install_info
50        provide_var_lib_x11
51        info INSTCORE " -> Setting up dpkg in $BUILDPLACE"
52        x_feign_install dpkg
53        info INSTCORE " -> Unpacking packages in $BUILDPLACE"
54        unpack_debootstrap
55        info INSTCORE " -> Adapting configuration for Emdebian"
56        disable_apt_recommends
57        busybox_inittab
58        busybox_rcS
59        setup_devices
60        info INSTCORE " -> First stage install complete in $BUILDPLACE"
61}
62
63second_stage_install () {
64        if [ -f /datestring ]; then
65                TIME=`cat /datestring`
66                echo "Setting approximate time of $TIME"
67                date -s $TIME
68        fi
69        info INSTCORE "Running ldconfig..."
70        in_target /sbin/ldconfig
71        in_target depmod
72        info INSTCORE "Setting cdebconf environment"
73        export DEBCONF_USE_CDEBCONF=true
74        DEBIAN_FRONTEND=noninteractive
75        DEBCONF_NONINTERACTIVE_SEEN=true
76        export DEBIAN_FRONTEND DEBCONF_NONINTERACTIVE_SEEN
77        # bug: See #451130
78        in_target /usr/lib/cdebconf/debconf-loadtemplate /usr/share/debconf/demo /usr/share/debconf/demo.templates
79        info INSTCORE "Configuring in $BUILDPLACE"
80        in_target dpkg --configure -a
81        info BASESUCCESS "Emdebian base system installed successfully."
82}
Note: See TracBrowser for help on using the browser.