Skip to content

Commit

Permalink
buildPython*: make name-relaed attributes overridable via overrideAttrs
Browse files Browse the repository at this point in the history
Make name, pname and version overridable via overrideAttrs
for Python packgaes constructed with buildPython*.
  • Loading branch information
ShamrockLee committed Feb 3, 2025
1 parent c721a7f commit b3b430d
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions pkgs/development/interpreters/python/mk-python-derivation.nix
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,6 @@ let
in

{
name ? "${attrs.pname}-${attrs.version}",

# Build-time dependencies for the package
nativeBuildInputs ? [ ],

Expand Down Expand Up @@ -228,7 +226,7 @@ let
throwMismatch =
attrName: drv:
let
myName = "'${namePrefix}${name}'";
myName = "'${finalAttrs.name}'";
theirName = "'${drv.name}'";
optionalLocation =
let
Expand Down Expand Up @@ -280,7 +278,7 @@ let
(cleanAttrs attrs)
// {

name = namePrefix + name;
name = namePrefix + attrs.name or "${finalAttrs.pname}-${finalAttrs.version}";

nativeBuildInputs =
[
Expand Down

0 comments on commit b3b430d

Please sign in to comment.