fix: add k8s and hpc modules to main repo

This commit is contained in:
Jonas Juselius
2025-06-30 12:21:05 +02:00
parent 4aa9fa677a
commit bc3a034654
46 changed files with 4393 additions and 0 deletions

38
modules/hpc/xpmem.nix Normal file
View 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
'';
}