fix various build failures
Some checks failed
Hydra bcachefs-tools Hydra build #54620 of nix-packages:x86_64-linux-master-pr276:bcachefs-tools
Hydra woodpecker-frontend Hydra build #54607 of nix-packages:x86_64-linux-master-pr276:woodpecker-frontend
Hydra woodpecker-server Hydra build #54608 of nix-packages:x86_64-linux-master-pr276:woodpecker-server
Hydra linux-bcachefs Hydra build #54610 of nix-packages:x86_64-linux-master-pr276:linux-bcachefs
Some checks failed
Hydra bcachefs-tools Hydra build #54620 of nix-packages:x86_64-linux-master-pr276:bcachefs-tools
Hydra woodpecker-frontend Hydra build #54607 of nix-packages:x86_64-linux-master-pr276:woodpecker-frontend
Hydra woodpecker-server Hydra build #54608 of nix-packages:x86_64-linux-master-pr276:woodpecker-server
Hydra linux-bcachefs Hydra build #54610 of nix-packages:x86_64-linux-master-pr276:linux-bcachefs
This commit is contained in:
parent
ddac8229cd
commit
7fd282c4dc
5 changed files with 108 additions and 8 deletions
|
@ -77,7 +77,7 @@ in
|
||||||
// (
|
// (
|
||||||
if pkgs.system == "riscv64-linux"
|
if pkgs.system == "riscv64-linux"
|
||||||
then {
|
then {
|
||||||
inherit (pkgsWithOverlay) vf2Kernel;
|
inherit (pkgsWithOverlay) vf2Kernel valgrind;
|
||||||
}
|
}
|
||||||
else {}
|
else {}
|
||||||
)
|
)
|
||||||
|
|
|
@ -121,7 +121,7 @@
|
||||||
// (
|
// (
|
||||||
if system == "riscv64-linux"
|
if system == "riscv64-linux"
|
||||||
then {
|
then {
|
||||||
inherit (pkgs) vf2Kernel;
|
inherit (pkgs) vf2Kernel valgrind;
|
||||||
}
|
}
|
||||||
else {}
|
else {}
|
||||||
)
|
)
|
||||||
|
|
19
overlay.nix
19
overlay.nix
|
@ -32,16 +32,23 @@ system: self: super: let
|
||||||
});
|
});
|
||||||
libopus = super.libopus.overrideAttrs (_: {
|
libopus = super.libopus.overrideAttrs (_: {
|
||||||
mesonFlags = [
|
mesonFlags = [
|
||||||
(lib.mesonBool "fixed-point" false)
|
"-Dfixed-point=false"
|
||||||
(lib.mesonBool "custom-modes" true)
|
"-Dcustom-modes=true"
|
||||||
(lib.mesonEnable "intrinsics" false)
|
"-Dintrinsics=disabled"
|
||||||
(lib.mesonEnable "rtcd" false)
|
"-Drtcd=disabled"
|
||||||
(lib.mesonEnable "asm" false)
|
"-Dasm=disabled"
|
||||||
(lib.mesonEnable "docs" false)
|
"-Dasm=disabled"
|
||||||
|
"-Ddocs=disabled"
|
||||||
];
|
];
|
||||||
doCheck = false;
|
doCheck = false;
|
||||||
doInstallCheck = false;
|
doInstallCheck = false;
|
||||||
});
|
});
|
||||||
|
valgrind = self.callPackage ./riscv/valgrind {};
|
||||||
|
valgrind-light = self.valgrind;
|
||||||
|
openldap = super.openldap.overrideAttrs (_: {
|
||||||
|
doCheck = false;
|
||||||
|
doInstallCheck = false;
|
||||||
|
});
|
||||||
})
|
})
|
||||||
else (_: _: {});
|
else (_: _: {});
|
||||||
|
|
||||||
|
|
82
riscv/valgrind/default.nix
Normal file
82
riscv/valgrind/default.nix
Normal file
|
@ -0,0 +1,82 @@
|
||||||
|
{
|
||||||
|
lib,
|
||||||
|
stdenv,
|
||||||
|
fetchFromGitHub,
|
||||||
|
perl,
|
||||||
|
gdb,
|
||||||
|
autoreconfHook,
|
||||||
|
}: let
|
||||||
|
source = builtins.fromJSON (builtins.readFile ./source.json);
|
||||||
|
in
|
||||||
|
stdenv.mkDerivation rec {
|
||||||
|
pname = "valgrind-riscv64";
|
||||||
|
version = source.date;
|
||||||
|
|
||||||
|
src = fetchFromGitHub {
|
||||||
|
owner = "petrpavlu";
|
||||||
|
repo = "valgrind-riscv64";
|
||||||
|
inherit (source) rev sha256;
|
||||||
|
};
|
||||||
|
|
||||||
|
outputs = ["out" "dev"];
|
||||||
|
|
||||||
|
hardeningDisable = ["stackprotector"];
|
||||||
|
|
||||||
|
# GDB is needed to provide a sane default for `--db-command'.
|
||||||
|
# Perl is needed for `callgrind_{annotate,control}'.
|
||||||
|
buildInputs = [gdb perl];
|
||||||
|
|
||||||
|
# Perl is also a native build input.
|
||||||
|
nativeBuildInputs = [autoreconfHook perl];
|
||||||
|
|
||||||
|
enableParallelBuilding = true;
|
||||||
|
separateDebugInfo = stdenv.isLinux;
|
||||||
|
|
||||||
|
# To prevent rebuild on linux when moving darwin's postPatch fixes to preConfigure
|
||||||
|
postPatch = "";
|
||||||
|
|
||||||
|
doCheck = true;
|
||||||
|
|
||||||
|
postInstall = ''
|
||||||
|
for i in $out/libexec/valgrind/*.supp; do
|
||||||
|
substituteInPlace $i \
|
||||||
|
--replace 'obj:/lib' 'obj:*/lib' \
|
||||||
|
--replace 'obj:/usr/X11R6/lib' 'obj:*/lib' \
|
||||||
|
--replace 'obj:/usr/lib' 'obj:*/lib'
|
||||||
|
done
|
||||||
|
'';
|
||||||
|
|
||||||
|
passthru.updateScript = [
|
||||||
|
../../scripts/update-git.sh
|
||||||
|
"https://github.com/petrpavlu/valgrind-riscv64"
|
||||||
|
"riscv/valgrind/source.json"
|
||||||
|
];
|
||||||
|
|
||||||
|
meta = {
|
||||||
|
homepage = "http://www.valgrind.org/";
|
||||||
|
description = "Debugging and profiling tool suite";
|
||||||
|
|
||||||
|
longDescription = ''
|
||||||
|
Valgrind is an award-winning instrumentation framework for
|
||||||
|
building dynamic analysis tools. There are Valgrind tools that
|
||||||
|
can automatically detect many memory management and threading
|
||||||
|
bugs, and profile your programs in detail. You can also use
|
||||||
|
Valgrind to build new tools.
|
||||||
|
'';
|
||||||
|
|
||||||
|
license = lib.licenses.gpl2Plus;
|
||||||
|
|
||||||
|
maintainers = [lib.maintainers.nickcao];
|
||||||
|
platforms = lib.platforms.unix;
|
||||||
|
badPlatforms = [
|
||||||
|
"armv5tel-linux"
|
||||||
|
"armv6l-linux"
|
||||||
|
"armv6m-linux"
|
||||||
|
"sparc-linux"
|
||||||
|
"sparc64-linux"
|
||||||
|
"riscv32-linux"
|
||||||
|
"alpha-linux"
|
||||||
|
];
|
||||||
|
broken = stdenv.isDarwin || stdenv.hostPlatform.isStatic; # https://hydra.nixos.org/build/128521440/nixlog/2
|
||||||
|
};
|
||||||
|
}
|
11
riscv/valgrind/source.json
Normal file
11
riscv/valgrind/source.json
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
{
|
||||||
|
"url": "https://github.com/petrpavlu/valgrind-riscv64",
|
||||||
|
"rev": "71272b252977fe52f03ea4fa8306b457b098cca5",
|
||||||
|
"date": "2023-04-10T20:43:50+02:00",
|
||||||
|
"path": "/nix/store/g00qg2qhm10c0a6v5v7al89pc57b4bjy-valgrind-riscv64",
|
||||||
|
"sha256": "0znk98hypdh7j84h237131aqsczz91mrwpwkvy1xgaxkhiskhgy4",
|
||||||
|
"fetchLFS": false,
|
||||||
|
"fetchSubmodules": false,
|
||||||
|
"deepClone": false,
|
||||||
|
"leaveDotGit": false
|
||||||
|
}
|
Reference in a new issue