mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-21 22:43:01 +00:00
memstream: cross-compilation fixes
- Use `$(CC)` to pick up the prefixed compiler automatically; and - Only run check phase when the builder can execute host binaries.
This commit is contained in:
parent
7306ea41bd
commit
5709115ac9
@ -9,13 +9,18 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "0kvdb897g7nyviaz72arbqijk2g2wa61cmi3l5yh48rzr49r3a3a";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace Makefile \
|
||||
--replace-fail 'cc' '$(CC)'
|
||||
'';
|
||||
|
||||
dontConfigure = true;
|
||||
|
||||
postBuild = ''
|
||||
$AR rcs libmemstream.a memstream.o
|
||||
'';
|
||||
|
||||
doCheck = true;
|
||||
doCheck = stdenv.buildPlatform.canExecute stdenv.hostPlatform;
|
||||
checkPhase = ''
|
||||
runHook preCheck
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user