mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-10 11:45:45 +03:00
libtommath: fix cross build (#370328)
This commit is contained in:
commit
7e96237672
1 changed files with 6 additions and 4 deletions
|
@ -14,15 +14,17 @@ stdenv.mkDerivation rec {
|
||||||
sha256 = "sha256-KWJy2TQ1mRMI63NgdgDANLVYgHoH6CnnURQuZcz6nQg=";
|
sha256 = "sha256-KWJy2TQ1mRMI63NgdgDANLVYgHoH6CnnURQuZcz6nQg=";
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = [ libtool ];
|
|
||||||
|
|
||||||
postPatch = ''
|
postPatch = ''
|
||||||
substituteInPlace makefile.shared --replace glibtool libtool
|
substituteInPlace makefile.shared \
|
||||||
substituteInPlace makefile_include.mk --replace "shell arch" "shell uname -m"
|
--replace-fail glibtool libtool \
|
||||||
|
--replace-fail libtool "${lib.getExe (libtool.override { stdenv = stdenv; })}"
|
||||||
|
substituteInPlace makefile_include.mk \
|
||||||
|
--replace-fail "gcc" "${stdenv.cc.targetPrefix}cc"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
preBuild = ''
|
preBuild = ''
|
||||||
makeFlagsArray=(PREFIX=$out \
|
makeFlagsArray=(PREFIX=$out \
|
||||||
|
CC=${stdenv.cc.targetPrefix}cc \
|
||||||
INSTALL_GROUP=$(id -g) \
|
INSTALL_GROUP=$(id -g) \
|
||||||
INSTALL_USER=$(id -u))
|
INSTALL_USER=$(id -u))
|
||||||
'';
|
'';
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue