expand-response-params: Build more normally
This commit is contained in:
committed by
John Ericson
parent
287fce6402
commit
a470be5a16
@@ -3,11 +3,17 @@
|
||||
stdenv.mkDerivation {
|
||||
name = "expand-response-params";
|
||||
src = ./expand-response-params.c;
|
||||
buildCommand = ''
|
||||
# Work around "stdenv-darwin-boot-2 is not allowed to refer to path /nix/store/...-expand-response-params.c"
|
||||
# Work around "stdenv-darwin-boot-2 is not allowed to refer to path
|
||||
# /nix/store/...-expand-response-params.c"
|
||||
unpackPhase = ''
|
||||
cp "$src" expand-response-params.c
|
||||
"$CC" -std=c99 -O3 -o "$out" expand-response-params.c
|
||||
strip -S $out
|
||||
${stdenv.lib.optionalString stdenv.hostPlatform.isLinux "patchelf --shrink-rpath $out"}
|
||||
src=$PWD
|
||||
'';
|
||||
buildPhase = ''
|
||||
"$CC" -std=c99 -O3 -o "expand-response-params" expand-response-params.c
|
||||
'';
|
||||
installPhase = ''
|
||||
mkdir -p $prefix/bin
|
||||
mv expand-response-params $prefix/bin/
|
||||
'';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user