cleaning up mish-mash of S= and things. and also making sure that if we dont recalc...
authorJohn Mylchreest <johnm@gentoo.org>
Fri, 26 Nov 2004 02:08:27 +0000 (02:08 +0000)
committerJohn Mylchreest <johnm@gentoo.org>
Fri, 26 Nov 2004 02:08:27 +0000 (02:08 +0000)
eclass/kernel-2.eclass

index bc98604f701ae82fa2a4e46b8e64ad109ca188f2..a9dec4029792529c63c8b2ed09cb6fcbb925a0ae 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2004 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/kernel-2.eclass,v 1.52 2004/11/26 01:49:05 johnm Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/kernel-2.eclass,v 1.53 2004/11/26 02:08:27 johnm Exp $
 
 # kernel.eclass rewrite for a clean base regarding the 2.6 series of kernel
 # with back-compatibility for 2.4
@@ -152,10 +152,6 @@ universal_unpack() {
                die "Unable to move source tree to ${KV}."
        fi
 
-       # since pkg_setup sets S, and then portage resets S we
-       # need to re-set S= or it wont be correct.
-       S="${WORKDIR}/linux-${KV}"
-
        cd ${S}
        # change incorrect install path
        [ -z "${K_NOFIXINSTALL_PATH}" ] && \
@@ -575,7 +571,14 @@ detect_version() {
        # KV: Kernel Version (2.6.0-gentoo/2.6.0-test11-gentoo-r1)
        # EXTRAVERSION: The additional version appended to OKV (-gentoo/-gentoo-r1)
        
-       [ -n "${DETECTED}" ] && return
+       # if ${DETECTED} is still set then we must know about all this other stuff
+       # too, so lets just reset S and be done with it
+       if [ -n "${DETECTED}" ];
+       then
+               # set S properly again shall we?
+               S=${WORKDIR}/linux-${KV}
+               return
+       fi
        
        if [ -z "${OKV}" ];
        then