root: fix build on aarch64-linux (#203267)

This commit is contained in:
Weijia Wang 2022-11-29 07:41:49 +01:00 committed by GitHub
parent d91da6d1fb
commit 280b4b8279
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -207,6 +207,8 @@ stdenv.mkDerivation rec {
"-Druntime_cxxmodules=OFF"
];
NIX_LDFLAGS = lib.optionalString (stdenv.isLinux && stdenv.isAarch64 && stdenv.cc.isGNU) "-lgcc";
postInstall = ''
for prog in rootbrowse rootcp rooteventselector rootls rootmkdir rootmv rootprint rootrm rootslimtree; do
wrapProgram "$out/bin/$prog" \
@ -262,9 +264,5 @@ stdenv.mkDerivation rec {
platforms = platforms.unix;
maintainers = [ maintainers.veprbl ];
license = licenses.lgpl21;
# See https://github.com/NixOS/nixpkgs/pull/192581#issuecomment-1256860426
# for some context on issues on aarch64.
broken = stdenv.isAarch64 && stdenv.isLinux;
};
}

View File

@ -36288,6 +36288,8 @@ with pkgs;
root = callPackage ../applications/science/misc/root {
python = python3;
inherit (darwin.apple_sdk.frameworks) Cocoa CoreSymbolication OpenGL;
# https://github.com/NixOS/nixpkgs/issues/201254
stdenv = if stdenv.isLinux && stdenv.isAarch64 && stdenv.cc.isGNU then gcc11Stdenv else stdenv;
};
root5 = lowPrio (callPackage ../applications/science/misc/root/5.nix {