buildGoModule: passing CGO_ENABLED explicitly

This commit is contained in:
Nick Cao 2022-06-14 11:04:55 +08:00 committed by zowoq
parent db487935dd
commit e4515da3c2

View file

@ -39,6 +39,8 @@
# IE: programs coupled with the compiler
, allowGoReference ? false
, CGO_ENABLED ? go.CGO_ENABLED
, meta ? {}
# Not needed with buildGoModule
@ -141,6 +143,7 @@ let
GO111MODULE = "on";
GOFLAGS = lib.optionals (!proxyVendor) [ "-mod=vendor" ] ++ lib.optionals (!allowGoReference) [ "-trimpath" ];
inherit CGO_ENABLED;
configurePhase = args.configurePhase or ''
runHook preConfigure