From c0ce72bfc2422b33b6d0582bb3af9dabc8ac0f00 Mon Sep 17 00:00:00 2001 From: Michael Raskin <7c6f434c@mail.ru> Date: Tue, 8 Jan 2008 00:18:20 +0000 Subject: [PATCH] Added dmidecode and kqemu svn path=/nixpkgs/trunk/; revision=10098 --- pkgs/os-specific/linux/dmidecode/2.9.nix | 22 ++++++++++++++ pkgs/os-specific/linux/kqemu/1.3.0pre11.nix | 30 +++++++++++++++++++ .../linux/module-init-tools/aggregator.nix | 1 + pkgs/top-level/all-packages.nix | 18 +++++++++++ 4 files changed, 71 insertions(+) create mode 100644 pkgs/os-specific/linux/dmidecode/2.9.nix create mode 100644 pkgs/os-specific/linux/kqemu/1.3.0pre11.nix diff --git a/pkgs/os-specific/linux/dmidecode/2.9.nix b/pkgs/os-specific/linux/dmidecode/2.9.nix new file mode 100644 index 000000000000..787846465d84 --- /dev/null +++ b/pkgs/os-specific/linux/dmidecode/2.9.nix @@ -0,0 +1,22 @@ +args : with args; + with builderDefs { + src = /* put a fetchurl here */ + fetchurl { + url = http://download.savannah.gnu.org/releases/dmidecode/dmidecode-2.9.tar.bz2; + sha256 = "05g0ln400fhqjspg9h4x0a1dvmwiyjq5rk9q9kimxvywbg1b53l8"; + }; + + buildInputs = []; + configureFlags = []; + makeFlags = "prefix=\$out"; + } null; /* null is a terminator for sumArgs */ +stdenv.mkDerivation rec { + name = "dmidecode-"+version; + builder = writeScript (name + "-builder") + (textClosure [ doMakeInstall doForceShare doPropagate]); + meta = { + description = " + Tool to decode Desktop Management Interface and SBIOS data. +"; + }; +} diff --git a/pkgs/os-specific/linux/kqemu/1.3.0pre11.nix b/pkgs/os-specific/linux/kqemu/1.3.0pre11.nix new file mode 100644 index 000000000000..3aa2731ac3fb --- /dev/null +++ b/pkgs/os-specific/linux/kqemu/1.3.0pre11.nix @@ -0,0 +1,30 @@ +args : with args; + with builderDefs { + src = /* put a fetchurl here */ + fetchurl { + url = http://fabrice.bellard.free.fr/qemu/kqemu-1.3.0pre11.tar.gz; + sha256 = "03svg2x52ziglf9r9irf6ziiz8iwa731fk1mdskwdip5jxbyy6jl"; + }; + buildInputs = []; + configureFlags = [''--prefix=$out'' ''--kernel-path=$(ls -d ${kernel}/lib/modules/*/build)'']; + } null; /* null is a terminator for sumArgs */ +let + debugStep = FullDepEntry ('' + cat config-host.mak + '') [minInit]; + preConfigure = FullDepEntry ('' + sed -e '/kernel_path=/akernel_path=$out$kernel_path' -i install.sh + sed -e '/depmod/d' -i install.sh + cat install.sh + '') [minInit doUnpack]; +in +stdenv.mkDerivation rec { + name = "kqemu-"+version; + builder = writeScript (name + "-builder") + (textClosure [preConfigure doConfigure debugStep doMakeInstall doForceShare doPropagate]); + meta = { + description = " + Kernel module for Qemu acceleration +"; + }; +} diff --git a/pkgs/os-specific/linux/module-init-tools/aggregator.nix b/pkgs/os-specific/linux/module-init-tools/aggregator.nix index b0a518cd2160..09866f414e5d 100644 --- a/pkgs/os-specific/linux/module-init-tools/aggregator.nix +++ b/pkgs/os-specific/linux/module-init-tools/aggregator.nix @@ -13,6 +13,7 @@ cd $out/ for i in $moduleSources; do lndir $i/ done +rm -rf nix-support cd lib/modules/ rm */modules.* MODULE_DIR=$PWD/ depmod -a diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index b9a9c25a2496..830a8b78507c 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -3013,6 +3013,14 @@ rec { static = true; })); + dmidecodeFun = lib.sumArgs (selectVersion ../os-specific/linux/dmidecode) { + inherit fetchurl stdenv builderDefs; + }; + + dmidecode = dmidecodeFun { + version = "2.9"; + } null; + dietlibc = import ../os-specific/linux/dietlibc { inherit fetchurl glibc; # Dietlibc 0.30 doesn't compile on PPC with GCC 4.1, bus GCC 3.4 works. @@ -3309,6 +3317,16 @@ rec { [(getConfig ["kernel" "addConfig"] "")]; }; + kqemuFun = lib.sumArgs (selectVersion ../os-specific/linux/kqemu) { + inherit fetchurl stdenv builderDefs; + }; + + # No finished expression is provided - pick your own kernel + kqemuFunCurrent = theKernel: (kqemuFun { + version = "1.3.0pre11"; + kernel = theKernel; + } null); + libselinux = import ../os-specific/linux/libselinux { inherit fetchurl stdenv libsepol; };