diff options
author | Dieter Plaetinck <dieter@plaetinck.be> | 2009-03-29 18:16:42 +0200 |
---|---|---|
committer | Dieter Plaetinck <dieter@plaetinck.be> | 2009-03-29 18:16:42 +0200 |
commit | ef2290b0e31c285267bba9dde3634b628df0ebf0 (patch) | |
tree | de627bb47c87f535ad7eea5d7b3da9bc2cbef3c7 /src/core/libs/lib-software.sh | |
parent | 71f5510aaaa20ae5ae9c773dca12028bd96aafdf (diff) | |
parent | ff1bc0cd6060d0a23911f1ef25633f706a9af619 (diff) |
Merge branch 'experimental'2009.03.29
Diffstat (limited to 'src/core/libs/lib-software.sh')
-rw-r--r-- | src/core/libs/lib-software.sh | 29 |
1 files changed, 15 insertions, 14 deletions
diff --git a/src/core/libs/lib-software.sh b/src/core/libs/lib-software.sh index 726d20f..384cab4 100644 --- a/src/core/libs/lib-software.sh +++ b/src/core/libs/lib-software.sh @@ -1,7 +1,7 @@ #!/bin/bash -TMP_MKINITCPIO_LOG=$RUNTIME_DIR/mkinitcpio.log -TMP_PACMAN_LOG=$RUNTIME_DIR/pacman.log +TMP_MKINITCPIO_LOG=$LOG_DIR/mkinitcpio.log +TMP_PACMAN_LOG=$LOG_DIR/pacman.log # run_mkinitcpio() taken from setup. adapted a lot # runs mkinitcpio on the target system, displays output @@ -9,9 +9,7 @@ run_mkinitcpio() { target_special_fs on - run_background mkinitcpio "chroot $var_TARGET_DIR /sbin/mkinitcpio -p kernel26" $TMP_MKINITCPIO_LOG - follow_progress "Rebuilding initcpio images ..." $TMP_MKINITCPIO_LOG - wait_for mkinitcpio + run_controlled mkinitcpio "chroot $var_TARGET_DIR /sbin/mkinitcpio -p kernel26" $TMP_MKINITCPIO_LOG "Rebuilding initcpio images ..." target_special_fs off @@ -24,16 +22,20 @@ run_mkinitcpio() # installpkg(). taken from setup. modified bigtime # performs package installation to the target system installpkg() { - notify "Package installation will begin now. You can watch the output in the progress window. Please be patient." + ALL_PACKAGES=$var_TARGET_PACKAGES + [ -n "$TARGET_GROUPS" ] && ALL_PACKAGES="$ALL_PACKAGES "`list_packages group "$TARGET_GROUPS" | awk '{print $2}'` + ALL_PACKAGES=`echo $ALL_PACKAGES` + [ -z "$ALL_PACKAGES" ] && die_error "No packages/groups specified to install" + target_special_fs on - run_background pacman-installpkg "$PACMAN_TARGET --noconfirm -S $TARGET_PACKAGES" $TMP_PACMAN_LOG #TODO: There may be something wrong here. See http://projects.archlinux.org/?p=installer.git;a=commitdiff;h=f504e9ecfb9ecf1952bd8dcce7efe941e74db946 ASKDEV (Simo) - follow_progress " Installing... Please Wait " $TMP_PACMAN_LOG - wait_for pacman-installpkg - + notify "Package installation will begin now. You can watch the output in the progress window. Please be patient." + + #TODO: There may be something wrong here. See http://projects.archlinux.org/?p=installer.git;a=commitdiff;h=f504e9ecfb9ecf1952bd8dcce7efe941e74db946 ASKDEV (Simo) + run_controlled pacman_installpkg "$PACMAN_TARGET --noconfirm -S $ALL_PACKAGES" $TMP_PACMAN_LOG "Installing... Please Wait" local _result='' - if [ ${pacman-installpkg_exitcode} -ne 0 ]; then + if [ ${pacman_installpkg_exitcode} -ne 0 ]; then _result="Installation Failed (see errors below)" echo -e "\nPackage Installation FAILED." >>$TMP_PACMAN_LOG else @@ -46,14 +48,13 @@ installpkg() { target_special_fs off sync - #return ${pacman-installpkg_exitcode} TODO: fix this. there is something wrong here - return 0 + return ${pacman_installpkg_exitcode} } # auto_locale(). taken from setup # enable glibc locales from rc.conf and build initial locale DB -target_configure_inital_locale() +target_configure_initial_locale() { for i in $(grep "^LOCALE" ${var_TARGET_DIR}/etc/rc.conf | sed -e 's/.*="//g' -e's/\..*//g'); do sed -i -e "s/^#$i/$i/g" ${var_TARGET_DIR}/etc/locale.gen |