kernel/linux: reorder upstream/custom-tree handling
author"Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Tue Jun 15 20:04:01 2010 +0200 (2010-06-15)
changeset 1989f357bc3abfa6
parent 1988 200b3e97b0b1
child 1990 c12158f27395
kernel/linux: reorder upstream/custom-tree handling
config/kernel/linux.in
scripts/build/kernel/linux.sh
     1.1 --- a/config/kernel/linux.in	Sat May 22 14:11:27 2010 +0200
     1.2 +++ b/config/kernel/linux.in	Tue Jun 15 20:04:01 2010 +0200
     1.3 @@ -20,14 +20,6 @@
     1.4  
     1.5  if KERNEL_LINUX_INSTALL
     1.6  
     1.7 -config KERNEL_LINUX_INSTALL_CHECK
     1.8 -    bool
     1.9 -    prompt "Check installed headers"
    1.10 -    default y
    1.11 -    help
    1.12 -      If you are in doubt that installed headers are buggy, say 'Y'
    1.13 -      here to have an extra check passed onto the headers.
    1.14 -
    1.15  choice
    1.16      bool
    1.17      prompt "Linux kernel version"
    1.18 @@ -140,11 +132,19 @@
    1.19      default 1 if KERNEL_LINUX_VERBOSITY_1
    1.20      default 2 if KERNEL_LINUX_VERBOSITY_2
    1.21  
    1.22 -endif
    1.23 +config KERNEL_LINUX_INSTALL_CHECK
    1.24 +    bool
    1.25 +    prompt "Check installed headers"
    1.26 +    default y
    1.27 +    help
    1.28 +      If you are in doubt that installed headers are buggy, say 'Y'
    1.29 +      here to have an extra check passed onto the headers.
    1.30 +
    1.31 +endif # KERNEL_LINUX_INSTALL
    1.32  
    1.33  config KERNEL_LINUX_USE_CUSTOM_HEADERS
    1.34      bool
    1.35 -    prompt "Use custom headers"
    1.36 +    prompt "custom, and/or pre-installed, headers tree"
    1.37      help
    1.38        If you have some kernel headers lying around, you can enter the path
    1.39        below.
    1.40 @@ -175,6 +175,6 @@
    1.41      help
    1.42        See KERNEL_LINUX_CUSTOM_IS_TARBALL, above.
    1.43  
    1.44 -endif # KERNEL_LINUX_USE_CUSTOM_DIR
    1.45 +endif # KERNEL_LINUX_USE_CUSTOM_HEADERS
    1.46  
    1.47  endchoice
     2.1 --- a/scripts/build/kernel/linux.sh	Sat May 22 14:11:27 2010 +0200
     2.2 +++ b/scripts/build/kernel/linux.sh	Tue Jun 15 20:04:01 2010 +0200
     2.3 @@ -17,30 +17,28 @@
     2.4  
     2.5  # Download the kernel
     2.6  do_kernel_get() {
     2.7 -    if [ "${CT_KERNEL_LINUX_USE_CUSTOM_HEADERS}" != "y" ]; then
     2.8 +    if [ "${CT_KERNEL_LINUX_INSTALL}" = "y" ]; then
     2.9          CT_GetFile "linux-${CT_KERNEL_VERSION}" \
    2.10                     {ftp,http}://ftp.{de.,eu.,}kernel.org/pub/linux/kernel/v2.{6{,/testing},4,2}
    2.11      fi
    2.12 -    return 0
    2.13  }
    2.14  
    2.15  # Extract kernel
    2.16  do_kernel_extract() {
    2.17 -    if [ "${CT_KERNEL_LINUX_USE_CUSTOM_HEADERS}" != "y" ]; then
    2.18 +    if [ "${CT_KERNEL_LINUX_INSTALL}" = "y" ]; then
    2.19          CT_Extract "linux-${CT_KERNEL_VERSION}"
    2.20          CT_Patch "linux" "${CT_KERNEL_VERSION}"
    2.21      fi
    2.22 -    return 0
    2.23  }
    2.24  
    2.25  # Wrapper to the actual headers install method
    2.26  do_kernel_headers() {
    2.27      CT_DoStep INFO "Installing kernel headers"
    2.28  
    2.29 -    if [ "${CT_KERNEL_LINUX_USE_CUSTOM_HEADERS}" = "y" ]; then
    2.30 +    if [ "${CT_KERNEL_LINUX_INSTALL}" = "y" ]; then
    2.31 +        do_kernel_install
    2.32 +    else
    2.33          do_kernel_custom
    2.34 -    else
    2.35 -        do_kernel_install
    2.36      fi
    2.37  
    2.38      CT_EndStep