ruby: disable yjit on cross
Fix `nix build .#pkgsCross.aarch64-multiplatform.ruby` failing with: ``` partial linking yjit/target/release/libyjit.a into yjit/target/release/libyjit.o /nix/store/…/bin/aarch64-unknown-linux-gnu-ld: yjit/target/release/libyjit.a(yjit.1fllkjkj80qowi7xzzkaw1xy8.rcgu.o): Relocations in generic ELF (EM: 62) /nix/store/…/bin/aarch64-unknown-linux-gnu-ld: yjit/target/release/libyjit.a(yjit.1fllkjkj80qowi7xzzkaw1xy8.rcgu.o): Relocations in generic ELF (EM: 62) /nix/store/…/bin/aarch64-unknown-linux-gnu-ld: yjit/target/release/libyjit.a(yjit.1fllkjkj80qowi7xzzkaw1xy8.rcgu.o): error adding symbols: file in wrong format ``` Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
This commit is contained in:
@@ -57,9 +57,13 @@ let
|
||||
}:
|
||||
let
|
||||
ver = version;
|
||||
isCross = stdenv.buildPlatform != stdenv.hostPlatform;
|
||||
# https://github.com/ruby/ruby/blob/v3_2_2/yjit.h#L21
|
||||
yjitSupported =
|
||||
stdenv.hostPlatform.isx86_64 || (!stdenv.hostPlatform.isWindows && stdenv.hostPlatform.isAarch64);
|
||||
!isCross
|
||||
&& (
|
||||
stdenv.hostPlatform.isx86_64 || (!stdenv.hostPlatform.isWindows && stdenv.hostPlatform.isAarch64)
|
||||
);
|
||||
rubyDrv = lib.makeOverridable (
|
||||
{
|
||||
stdenv,
|
||||
|
||||
Reference in New Issue
Block a user