about summary refs log tree commit diff
path: root/pkgs/development/lisp-modules
diff options
context:
space:
mode:
authorMichael Raskin <7c6f434c@mail.ru>2024-01-12 00:41:25 +0100
committerMichael Raskin <7c6f434c@mail.ru>2024-01-12 01:21:26 +0100
commit6815a0077d291a35a2f7c3eb715ece3da7035419 (patch)
tree13f2bbaaef6780a74518eea1cab04e8e15eb61de /pkgs/development/lisp-modules
parent55bfd59d5f4556005f50a1802d1bd498cafc260a (diff)
nix-cl: provide the original pname as an attribute
Overrides often inherit pname from the overriden package, and if they
get the already-prefixed version, defaulting the systems list to [pname]
produces wrong (and unintuitive) results. So we keep the prefix in the
store paths for clarity, and nix-env sees disambiguated names with -i/-u
(which should not be used anyway); but overrides won't be broken.
Diffstat (limited to 'pkgs/development/lisp-modules')
-rw-r--r--pkgs/development/lisp-modules/nix-cl.nix11
1 files changed, 9 insertions, 2 deletions
diff --git a/pkgs/development/lisp-modules/nix-cl.nix b/pkgs/development/lisp-modules/nix-cl.nix
index 327f4aa65aff5..6c52e9254f37a 100644
--- a/pkgs/development/lisp-modules/nix-cl.nix
+++ b/pkgs/development/lisp-modules/nix-cl.nix
@@ -145,7 +145,7 @@ let
       ...
     } @ args:
 
-    stdenv.mkDerivation (rec {
+    (stdenv.mkDerivation (rec {
       inherit
         version nativeLibs javaLibs lispLibs systems asds
         pkg program flags faslExt
@@ -226,7 +226,14 @@ let
       meta = (args.meta or {}) // {
         maintainers = args.meta.maintainers or lib.teams.lisp.members;
       };
-    })));
+    })) // {
+      # Useful for overriding
+      # Overriding code would prefer to use pname from the attribute set
+      # However, pname is extended with the implementation name
+      # Moreover, it is used in the default list of systems to load
+      # So we pass the original pname
+      pname = args.pname;
+    }));
 
   # Build the set of lisp packages using `lisp`
   # These packages are defined manually for one reason or another: