about summary refs log tree commit diff
path: root/pkgs/development/lisp-modules
diff options
context:
space:
mode:
authorIlan Joselevich <personal@ilanjoselevich.com>2023-05-29 11:38:00 +0300
committerGitHub <noreply@github.com>2023-05-29 11:38:00 +0300
commita4a8624d74c99b44c19427cf4fdfd6e5b319efd8 (patch)
tree36a5e877edbbf9cb00247b2bc5401eca488622e8 /pkgs/development/lisp-modules
parent6e9531b9131da0c6542119f8d700e76d9c2eb1f4 (diff)
parenteb1c777cef1c21767aa27ae69d09733f785a6f7a (diff)
downloadnixlib-a4a8624d74c99b44c19427cf4fdfd6e5b319efd8.tar
nixlib-a4a8624d74c99b44c19427cf4fdfd6e5b319efd8.tar.gz
nixlib-a4a8624d74c99b44c19427cf4fdfd6e5b319efd8.tar.bz2
nixlib-a4a8624d74c99b44c19427cf4fdfd6e5b319efd8.tar.lz
nixlib-a4a8624d74c99b44c19427cf4fdfd6e5b319efd8.tar.xz
nixlib-a4a8624d74c99b44c19427cf4fdfd6e5b319efd8.tar.zst
nixlib-a4a8624d74c99b44c19427cf4fdfd6e5b319efd8.zip
Merge pull request #232913 from Uthar/stumpwm-fixes2
stumpwm: fix package conflict and HOME errors when loading modules
Diffstat (limited to 'pkgs/development/lisp-modules')
-rw-r--r--pkgs/development/lisp-modules/packages.nix20
1 files changed, 18 insertions, 2 deletions
diff --git a/pkgs/development/lisp-modules/packages.nix b/pkgs/development/lisp-modules/packages.nix
index d7c801b716c2..3bc7e276122d 100644
--- a/pkgs/development/lisp-modules/packages.nix
+++ b/pkgs/development/lisp-modules/packages.nix
@@ -322,13 +322,27 @@ let
     };
     buildScript = pkgs.writeText "build-stumpwm.lisp" ''
       (load "${super.stumpwm.asdfFasl}/asdf.${super.stumpwm.faslExt}")
-      (asdf:load-system 'stumpwm/build)
+
+      (asdf:load-system 'stumpwm)
+
+      ;; Prevents package conflict error
+      (when (uiop:version<= "3.1.5" (asdf:asdf-version))
+        (uiop:symbol-call '#:asdf '#:register-immutable-system :stumpwm)
+        (dolist (system-name (uiop:symbol-call '#:asdf
+                                               '#:system-depends-on
+                                               (asdf:find-system :stumpwm)))
+          (uiop:symbol-call '#:asdf '#:register-immutable-system system-name)))
+
+      ;; Prevents "cannot create /homeless-shelter" error
+      (asdf:disable-output-translations)
+
       (sb-ext:save-lisp-and-die
         "stumpwm"
         :executable t
+        :purify t
         #+sb-core-compression :compression
         #+sb-core-compression t
-        :toplevel #'stumpwm:main)
+        :toplevel #'stumpwm:stumpwm)
     '';
     installPhase = ''
       mkdir -p $out/bin
@@ -336,6 +350,8 @@ let
     '';
   });
 
+  stumpwm-unwrapped = super.stumpwm;
+
   ltk = super.ltk.overrideLispAttrs (o: {
     src = pkgs.fetchzip {
       url = "https://github.com/uthar/ltk/archive/f19162e76d6c7c2f51bd289b811d9ba20dd6555e.tar.gz";