From: Thierry Parmentelat Date: Thu, 4 Mar 2010 14:46:46 +0000 (+0000) Subject: this change should let the build select the kernel config to use X-Git-Tag: linux-2.6-27-7~4 X-Git-Url: http://git.onelab.eu/?p=linux-2.6.git;a=commitdiff_plain;h=7ba769295c8f4ebf53233081c7e3154f7acf3917 this change should let the build select the kernel config to use default is to search config after pldistro like we did before but can be overridden in the mk file with e.g. kernel-SPECVARS := kernelconfig=planetlab --- diff --git a/kernel-2.6.spec b/kernel-2.6.spec index 4cf01ebf0..6d91e4604 100644 --- a/kernel-2.6.spec +++ b/kernel-2.6.spec @@ -14,7 +14,14 @@ Summary: The Linux kernel (the core of the Linux operating system) %define builddoc 0 %define headers 1 -# from 2.6.27 iwlwifi in builtin +%{!?pldistro:%global pldistro planetlab} + +# default is to search the config file after pldistro +# e.g. set +# kernel-SPECVARS := kernelconfig=planetlab +# to use the planetlab config from another pldistro +# without having to manage symlinks +%{!?kernelconfig:%global kernelconfig %{pldistro}} # Versions of various parts @@ -42,8 +49,6 @@ Summary: The Linux kernel (the core of the Linux operating system) %define release vs%{vsversion}.%{taglevel}%{?pldistro:.%{pldistro}}%{?date:.%{date}} -%{!?pldistro:%global pldistro planetlab} - %define signmodules 0 %define make_target bzImage %define KVERREL %{PACKAGE_VERSION}-%{PACKAGE_RELEASE} @@ -126,13 +131,13 @@ BuildConflicts: rhbuildsys(DiskFree) < 500Mb Source0: ftp://ftp.kernel.org/pub/linux/kernel/v2.6/linux-%{kversion}.tar.bz2 -Source11: %{pldistro}-%{kversion}-i686.config -Source12: %{pldistro}-%{kversion}-x86_64.config +Source11: %{kernelconfig}-%{kversion}-i686.config +Source12: %{kernelconfig}-%{kversion}-x86_64.config %if %{builduml} -Source20: %{pldistro}-%{kversion}-i686-uml.config +Source20: %{kernelconfig}-%{kversion}-i686-uml.config %endif %if %{buildxen} -Source30: %{pldistro}-%{kversion}-i686-xenU.config +Source30: %{kernelconfig}-%{kversion}-i686-xenU.config %endif # Mainline patches @@ -186,6 +191,7 @@ The kernel package contains the Linux kernel (vmlinuz), the core of any Linux operating system. The kernel handles the basic functions of the operating system: memory allocation, process allocation, device input and output, etc. +Configured with kernelconfig=%{kernelconfig} %package devel Summary: Development package for building kernel modules to match the kernel. @@ -415,11 +421,11 @@ BuildKernel() { # Pick the right config file for the kernel we're building if [ -n "$Flavour" ] ; then - Config=%{pldistro}-%{kversion}-%{_target_cpu}-$Flavour.config + Config=%{kernelconfig}-%{kversion}-%{_target_cpu}-$Flavour.config DevelDir=/usr/src/kernels/%{KVERREL}-$Flavour-%{_target_cpu} DevelLink=/usr/src/kernels/%{KVERREL}$Flavour-%{_target_cpu} else - Config=%{pldistro}-%{kversion}-%{_target_cpu}.config + Config=%{kernelconfig}-%{kversion}-%{_target_cpu}.config DevelDir=/usr/src/kernels/%{KVERREL}-%{_target_cpu} DevelLink= fi diff --git a/onelab-2.6.27-i686.config b/onelab-2.6.27-i686.config deleted file mode 120000 index 83d91e791..000000000 --- a/onelab-2.6.27-i686.config +++ /dev/null @@ -1 +0,0 @@ -planetlab-2.6.27-i686.config \ No newline at end of file diff --git a/onelab-2.6.27-x86_64.config b/onelab-2.6.27-x86_64.config deleted file mode 120000 index 40b44f14e..000000000 --- a/onelab-2.6.27-x86_64.config +++ /dev/null @@ -1 +0,0 @@ -planetlab-2.6.27-x86_64.config \ No newline at end of file