2009-09-11 15:16:18 +02:00
|
|
|
a :
|
|
|
|
let
|
|
|
|
s = import ./src-for-2.6.31-zen0.nix;
|
|
|
|
in
|
|
|
|
(import ../kernel/generic.nix) (rec {
|
|
|
|
inherit (a) stdenv fetchurl perl mktemp module_init_tools;
|
|
|
|
|
|
|
|
src = a.builderDefs.fetchGitFromSrcInfo s;
|
|
|
|
version = "2.6.31-zen0";
|
|
|
|
config = "./kernel-config";
|
|
|
|
features = {
|
|
|
|
iwlwifi = true;
|
|
|
|
zen = true;
|
|
|
|
};
|
|
|
|
|
|
|
|
extraMeta = {
|
|
|
|
maintainers = [
|
|
|
|
a.lib.maintainers.raskin
|
|
|
|
];
|
|
|
|
platforms = with a.lib.platforms;
|
|
|
|
linux;
|
|
|
|
};
|
|
|
|
|
|
|
|
preConfigure = ''
|
2009-09-11 15:50:40 +02:00
|
|
|
killOption () {
|
2009-09-12 08:59:44 +02:00
|
|
|
sed -re 's/^('"$1"')=[ym]/# \1 is not set/' -i .config
|
2009-09-11 15:50:40 +02:00
|
|
|
}
|
|
|
|
setOptionMod () {
|
2009-09-12 08:59:44 +02:00
|
|
|
sed -re 's/^# ('"$1"') is not set/\1=m/' -i .config
|
|
|
|
sed -re "1i$1=m" -i .config
|
2009-09-11 15:50:40 +02:00
|
|
|
}
|
|
|
|
setOptionYes () {
|
2009-09-12 09:33:55 +02:00
|
|
|
sed -re 's/^# ('"$1"') is not set/\1=y/' -i .config
|
2009-09-12 08:59:44 +02:00
|
|
|
sed -re "1i$1=y" -i .config
|
2009-09-11 15:50:40 +02:00
|
|
|
}
|
|
|
|
|
2009-09-11 15:16:18 +02:00
|
|
|
make allmodconfig
|
|
|
|
|
2009-09-13 18:37:17 +02:00
|
|
|
killOption CONFIG_CMDLINE_OVERRIDE
|
|
|
|
|
2009-09-11 15:50:40 +02:00
|
|
|
killOption CONFIG_IMA
|
2009-09-12 08:59:44 +02:00
|
|
|
killOption 'CONFIG_.*_DEBUG.*'
|
2009-09-13 22:10:19 +02:00
|
|
|
killOption 'CONFIG_DEBUG.*'
|
2009-09-12 08:59:44 +02:00
|
|
|
killOption CONFIG_AUDIT_ARCH
|
|
|
|
|
|
|
|
killOption CONFIG_KERNEL_BZIP2
|
|
|
|
killOption CONFIG_KERNEL_LZMA
|
|
|
|
setOptionYes CONFIG_KERNEL_GZIP
|
|
|
|
|
|
|
|
killOption CONFIG_TASKSTATS
|
|
|
|
killOption CONFIG_PREEMPT_NONE
|
|
|
|
setOptionYes CONFIG_PREEMPT_VOLUNTARY
|
2009-09-11 15:50:40 +02:00
|
|
|
|
2009-09-13 18:37:17 +02:00
|
|
|
killOption CONFIG_SLQB
|
|
|
|
killOption CONFIG_SLQB_ALLOCATOR
|
|
|
|
setOptionYes CONFIG_SLUB_ALLOCATOR
|
|
|
|
setOptionYes CONFIG_SLUB
|
|
|
|
killOption CONFIG_ACPI_CUSTOM_DSDT_INITRD
|
|
|
|
killOption CONFIG_DEVTMPFS
|
|
|
|
killOption CONFIG_DEVTMPFS_MOUNT
|
|
|
|
|
2009-09-11 15:16:18 +02:00
|
|
|
cp .config ${config}
|
|
|
|
'';
|
|
|
|
})
|