Unverified Commit ad1cab49 authored by Philip Taron's avatar Philip Taron Committed by GitHub
Browse files

buildGoModule: warn for passthru.overrideModAttrs lost after overriding (#434546)

parents 68a18fd3 8c54246b
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -25,7 +25,11 @@
- GCC 9, 10, 11, and 12 have been removed, as they have reached end‐of‐life upstream and are no longer supported.

- `base16-builder` node package has been removed due to lack of upstream maintenance.

- `buildGoModule` now warns if `<pkg>.passthru.overrideModAttrs` is lost during the overriding of its result packages.

- `gentium` package now provides `Gentium-*.ttf` files, and not `GentiumPlus-*.ttf` files like before. The font identifiers `Gentium Plus*` are available in the `gentium-plus` package, and if you want to use the more recently updated package `gentium` [by sil](https://software.sil.org/gentium/), you should update your configuration files to use the `Gentium` font identifier.

- `space-orbit` package has been removed due to lack of upstream maintenance. Debian upstream stopped tracking it in 2011.

- Derivations setting both `separateDebugInfo` and one of `allowedReferences`, `allowedRequisites`, `disallowedReferences` or `disallowedRequisites` must now set `__structuredAttrs` to `true`. The effect of reference whitelisting or blacklisting will be disabled on the `debug` output created by `separateDebugInfo`.
+9 −1
Original line number Diff line number Diff line
@@ -202,7 +202,15 @@ lib.extendMkDerivation {
            outputHashAlgo = if finalAttrs.vendorHash == "" then "sha256" else null;
            # in case an overlay clears passthru by accident, don't fail evaluation
          }).overrideAttrs
            (finalAttrs.passthru.overrideModAttrs or overrideModAttrs);
            (
              let
                pos = builtins.unsafeGetAttrPos "passthru" finalAttrs;
                posString =
                  if pos == null then "unknown" else "${pos.file}:${toString pos.line}:${toString pos.column}";
              in
              finalAttrs.passthru.overrideModAttrs
                or (lib.warn "buildGoModule: ${finalAttrs.name or finalAttrs.pname}: passthru.overrideModAttrs missing after overrideAttrs. Last overridden at ${posString}." overrideModAttrs)
            );

      nativeBuildInputs = [ go ] ++ nativeBuildInputs;