Files
Tom Hunze 2f2b2bf499 buildPerlPackage: remove explicit src argument
This goal of this change is to make nix-update-script work out of the
box with packages built using `buildPerlPackage`.

Explicitly setting `src` in the `stdenv.mkDerivation` call currently
causes `builtins.unsafeGetAttrPos "src" <package>` to point to
`pkgs/development/perl-modules/generic/default.nix` for packages built
using `buildPerlPackage`. If the result of this expression is not
`null`, nix-update will try to update `src` of `<package>` in this
file [1], which will fail for obvious reasons.

A good example of this happening is with the pgformatter package.
Removing the explicit `inherit src` allows
`builtins.unsafeGetAttrPos "src" <package>` to point to the file where
`<package>.src` is actually defined, fixing nix-update runs for
affected packages.

Git history doesn't provide any indication as to why this argument was
introduced in the first place, so I hope it's fine to remove it. The
only difference in evaluation will be for calls to `buildPerlPackage`
without `src`: In these cases, `src` will be unset instead of `null`.

[1] 8227513ecf/nix_update/eval.nix (L99)
2026-01-19 00:20:48 +01:00
..