nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix

Merge #56143: luajit, lmdb, knot-resolver: cross-fixes

Master commit: e52396ce2c0. It's bugfixes, basically.

+21 -13
+11 -12
pkgs/development/interpreters/luajit/default.nix
··· 1 - { stdenv, lib, fetchurl 1 + { stdenv, lib, fetchurl, buildPackages 2 2 , name ? "luajit-${version}" 3 3 , isStable 4 4 , sha256 ··· 20 20 21 21 luaversion = "5.1"; 22 22 23 - patchPhase = '' 24 - substituteInPlace Makefile \ 25 - --replace /usr/local "$out" 26 - 27 - substituteInPlace src/Makefile --replace gcc cc 28 - '' + stdenv.lib.optionalString (stdenv.cc.libc != null) 29 - '' 30 - substituteInPlace Makefile \ 31 - --replace ldconfig ${stdenv.cc.libc.bin or stdenv.cc.libc}/bin/ldconfig 23 + postPatch = '' 24 + substituteInPlace Makefile --replace ldconfig : 32 25 ''; 33 26 34 27 configurePhase = false; 35 28 29 + makeFlags = [ 30 + "PREFIX=$(out)" 31 + "DEFAULT_CC=cc" 32 + "CROSS=${stdenv.cc.targetPrefix}" 33 + # TODO: when pointer size differs, we would need e.g. -m32 34 + "HOST_CC=${buildPackages.stdenv.cc}/bin/cc" 35 + ]; 36 36 buildFlags = [ "amalg" ]; # Build highly optimized version 37 37 enableParallelBuilding = true; 38 38 39 - installPhase = '' 40 - make install PREFIX="$out" 39 + postInstall = '' 41 40 ( cd "$out/include"; ln -s luajit-*/* . ) 42 41 ln -s "$out"/bin/luajit-* "$out"/bin/lua 43 42 ''
+5 -1
pkgs/development/libraries/lmdb/default.nix
··· 18 18 19 19 outputs = [ "bin" "out" "dev" ]; 20 20 21 - makeFlags = [ "prefix=$(out)" "CC=cc" ] 21 + makeFlags = [ 22 + "prefix=$(out)" 23 + "CC=${stdenv.cc.targetPrefix}cc" 24 + "AR=${stdenv.cc.targetPrefix}ar" 25 + ] 22 26 ++ stdenv.lib.optional stdenv.isDarwin "LDFLAGS=-Wl,-install_name,$(out)/lib/liblmdb.so"; 23 27 24 28 doCheck = true;
+5
pkgs/servers/dns/knot-resolver/default.nix
··· 19 19 sha256 = "d1396888ec3a63f19dccdf2b7dbcb0d16a5d8642766824b47f4c21be90ce362b"; 20 20 }; 21 21 22 + # Short-lived cross fix, as upstream is migrating to meson anyway. 23 + postPatch = '' 24 + substituteInPlace platform.mk --replace "objdump" "$OBJDUMP" 25 + ''; 26 + 22 27 outputs = [ "out" "dev" ]; 23 28 24 29 configurePhase = "patchShebangs scripts/";