fix: add k8s and hpc modules to main repo
This commit is contained in:
38
modules/hpc/xpmem.nix
Normal file
38
modules/hpc/xpmem.nix
Normal file
@@ -0,0 +1,38 @@
|
||||
{ pkgs, kernel ? pkgs.linux, ... } :
|
||||
with pkgs;
|
||||
let
|
||||
version = "master";
|
||||
kdir="${kernel.dev}/lib/modules/${kernel.modDirVersion}";
|
||||
in stdenv.mkDerivation {
|
||||
inherit version;
|
||||
name = "xpmem-${version}-${kernel.version}";
|
||||
|
||||
src = fetchgit {
|
||||
name = "xpmem-${version}";
|
||||
url = "https://github.com/hpc/xpmem.git";
|
||||
sha256 = "sha256-lB4adWBLhaj32Ll11jWPuCJSuKF8EVBG9L1Pk8HIbzY=";
|
||||
};
|
||||
|
||||
hardeningDisable = [ "fortify" "pic" "stackprotector" ];
|
||||
|
||||
nativeBuildInputs = [ which kmod ];
|
||||
|
||||
buildInputs = kernel.moduleBuildDependencies ++ [
|
||||
libtool autoconf pkgconf automake hwloc
|
||||
] ;
|
||||
|
||||
preConfigurePhases = "preConfigure";
|
||||
preConfigure = ''
|
||||
autoupdate
|
||||
./autogen.sh
|
||||
'';
|
||||
|
||||
configureFlags = [
|
||||
"--with-kerneldir=${kdir}/source"
|
||||
];
|
||||
|
||||
installPhase = ''
|
||||
make install
|
||||
rm -rf $out/etc $out/sbin
|
||||
'';
|
||||
}
|
||||
Reference in New Issue
Block a user