mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-21 20:34:06 +00:00
Merge pull request #228352 from kira-bruneau/rr
rr: encode gdb dep with wrapProgram instead of propagatedBuildInputs
This commit is contained in:
commit
6f3b947593
@ -1,5 +1,6 @@
|
|||||||
{ lib, stdenv, fetchFromGitHub, fetchpatch
|
{ lib, stdenv, fetchFromGitHub, fetchpatch
|
||||||
, cmake, libpfm, zlib, pkg-config, python3Packages, which, procps, gdb, capnproto
|
, cmake, pkg-config, which, makeWrapper
|
||||||
|
, libpfm, zlib, python3Packages, procps, gdb, capnproto
|
||||||
}:
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
@ -38,11 +39,11 @@ stdenv.mkDerivation rec {
|
|||||||
# See also https://github.com/NixOS/nixpkgs/pull/110846
|
# See also https://github.com/NixOS/nixpkgs/pull/110846
|
||||||
preConfigure = ''substituteInPlace CMakeLists.txt --replace "-flto" ""'';
|
preConfigure = ''substituteInPlace CMakeLists.txt --replace "-flto" ""'';
|
||||||
|
|
||||||
nativeBuildInputs = [ cmake pkg-config which ];
|
nativeBuildInputs = [ cmake pkg-config which makeWrapper ];
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
libpfm zlib python3Packages.python python3Packages.pexpect procps gdb capnproto
|
libpfm zlib python3Packages.python python3Packages.pexpect procps gdb capnproto
|
||||||
|
libpfm zlib python3Packages.python python3Packages.pexpect procps capnproto
|
||||||
];
|
];
|
||||||
propagatedBuildInputs = [ gdb ]; # needs GDB to replay programs at runtime
|
|
||||||
cmakeFlags = [
|
cmakeFlags = [
|
||||||
"-Ddisable32bit=ON"
|
"-Ddisable32bit=ON"
|
||||||
];
|
];
|
||||||
@ -57,6 +58,14 @@ stdenv.mkDerivation rec {
|
|||||||
|
|
||||||
preCheck = "export HOME=$TMPDIR";
|
preCheck = "export HOME=$TMPDIR";
|
||||||
|
|
||||||
|
# needs GDB to replay programs at runtime
|
||||||
|
preFixup = ''
|
||||||
|
wrapProgram "$out/bin/rr" \
|
||||||
|
--prefix PATH ":" "${lib.makeBinPath [
|
||||||
|
gdb
|
||||||
|
]}";
|
||||||
|
'';
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
homepage = "https://rr-project.org/";
|
homepage = "https://rr-project.org/";
|
||||||
description = "Records nondeterministic executions and debugs them deterministically";
|
description = "Records nondeterministic executions and debugs them deterministically";
|
||||||
|
Loading…
Reference in New Issue
Block a user