Fix for bug #54455; moved the code to create a backup .config upwards since
authorTim Yamin <plasmaroo@gentoo.org>
Sat, 19 Jun 2004 22:38:08 +0000 (22:38 +0000)
committerTim Yamin <plasmaroo@gentoo.org>
Sat, 19 Jun 2004 22:38:08 +0000 (22:38 +0000)
before the "make mrproper" just wiped it out.

git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/genkernel/trunk@108 67a159dc-881f-0410-a524-ba9dfbe2cb84

gen_configkernel.sh

index 8c9bba33941fa17d7d6e10ee512b3a02273593d0..927cba2c2ecb0c88da2ac17ed6f0429e3f84c2aa 100644 (file)
@@ -28,6 +28,7 @@ config_kernel() {
        determine_config_file
        cd "${KERNEL_DIR}" || gen_die 'Could not switch to the kernel directory!'
 
+       isTrue "${CLEAN}" && cp "${KERNEL_DIR}/.config" "${KERNEL_DIR}/.config.bak" > /dev/null 2>&1
        if isTrue ${MRPROPER}
        then
                print_info 1 'kernel: >> Running mrproper...'
@@ -41,7 +42,6 @@ config_kernel() {
        then
                print_info 1 "config: Using config from ${KERNEL_CONFIG}"
                print_info 1 '        Previous config backed up to .config.bak'
-               cp "${KERNEL_DIR}/.config" "${KERNEL_DIR}/.config.bak" > /dev/null 2>&1
                cp "${KERNEL_CONFIG}" "${KERNEL_DIR}/.config" || gen_die 'Could not copy configuration file!'
        fi
        if isTrue "${CLEAN}" || isTrue "${OLDCONFIG}"