2020-04-24 23:36:52 +00:00
|
|
|
{ stdenv }:
|
|
|
|
|
|
|
|
stdenv.mkDerivation {
|
|
|
|
name = "expand-response-params";
|
|
|
|
src = ./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
|
|
|
|
src=$PWD
|
|
|
|
'';
|
|
|
|
buildPhase = ''
|
2021-03-19 17:17:44 +00:00
|
|
|
NIX_CC_USE_RESPONSE_FILE=0 "$CC" -std=c99 -O3 -o "expand-response-params" expand-response-params.c
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $prefix/bin
|
|
|
|
mv expand-response-params $prefix/bin/
|
|
|
|
'';
|
|
|
|
}
|