buildGoPackage: warn if buildFlagsArray is used

This commit is contained in:
zowoq 2021-08-23 14:55:51 +10:00
parent e6494966dd
commit 3c2d7dbfdf

View file

@ -43,8 +43,9 @@
, CGO_ENABLED ? go.CGO_ENABLED
# needed for buildFlags warning
# needed for buildFlags{,Array} warning
, buildFlags ? ""
, buildFlagsArray ? ""
, meta ? {}, ... } @ args:
@ -260,6 +261,6 @@ let
} // meta;
});
in
lib.warnIf (buildFlags != "")
"Use the `ldflags` and/or `tags` attributes instead of `buildFlags`"
lib.warnIf (buildFlags != "" || buildFlagsArray != "")
"Use the `ldflags` and/or `tags` attributes instead of `buildFlags`/`buildFlagsArray`"
package