nixos-riscv/overlay.nix

77 lines
1.7 KiB
Nix
Raw Normal View History

2024-01-17 18:22:30 +01:00
final: prev:
# Changes to packages from nixpkgs
{
2024-05-28 18:12:14 +02:00
blis = ((prev.blis.override {
blas64 = true;
withArchitecture = "generic";
}).overrideAttrs (old: {
nativeBuildInputs = (old.nativeBuildInputs or []) ++ [
prev.buildPackages.gfortran
];
})).overrideDerivation (old : {
configureFlags = [
"--enable-cblas"
"--blas-int-size=64"
"--enable-threading=openmp"
#"--build=x86_64-unknown-linux-gnu"
#"--host=riscv64-unknown-linux-gnu"
"generic"
];
});
2024-01-18 15:59:51 +01:00
2024-05-28 18:12:14 +02:00
unalignedCheck = prev.stdenv.mkDerivation {
name = "unaligned-check";
src = ./unalign.c;
unpackPhase = ''
cp ${./unalign.c} unalign.c
'';
dontConfigure = true;
buildPhase = ''
$CC unalign.c -o unalign_check
'';
installPhase = ''
mkdir -p $out/bin
cp unalign_check $out/bin/
'';
};
2024-07-08 13:32:29 +02:00
csrtool = prev.pkgsStatic.stdenv.mkDerivation {
name = "csrtool";
src = ./csrtool.c;
unpackPhase = ''
cp ${./csrtool.c} csrtool.c
'';
dontConfigure = true;
buildPhase = ''
$CC -static csrtool.c -o csrtool
'';
installPhase = ''
mkdir -p $out/bin
cp csrtool $out/bin/
'';
};
2024-07-09 15:15:35 +02:00
memtool = prev.pkgsStatic.stdenv.mkDerivation {
name = "memtool";
src = ./memtool.c;
unpackPhase = ''
cp ${./memtool.c} memtool.c
'';
dontConfigure = true;
buildPhase = ''
$CC -static memtool.c -o memtool
'';
installPhase = ''
mkdir -p $out/bin
cp memtool $out/bin/
'';
};
2024-07-08 13:32:29 +02:00
bitstreams = builtins.fetchGit {
url = "git@bscpm03.bsc.es:rarias/bitstreams.git";
2024-07-08 17:37:46 +02:00
rev = "ad901b0c21ffbdb310ff1dfb269f169f6ac6bde6";
2024-07-08 13:32:29 +02:00
};
2024-01-17 18:22:30 +01:00
}