lispPackages.clwrapper: build helper; saving dynamic library search path from NIX_LISP_

This commit is contained in:
Michael Raskin
2018-01-29 15:15:51 +01:00
parent 57ecb3a8f0
commit 0a70f37275
2 changed files with 33 additions and 9 deletions
@@ -15,9 +15,8 @@ in
export configureFlags="$configureFlags --with-$NIX_LISP=common-lisp.sh";
'';
postInstall = ''
"$out/bin/stumpwm-lisp-launcher.sh" --eval '(asdf:make :stumpwm)' \
--eval '(setf (asdf/system:component-entry-point (asdf:find-system :stumpwm)) (function stumpwm:stumpwm))' \
--eval '(asdf:perform (quote asdf:program-op) :stumpwm)'
export NIX_LISP_PRELAUNCH_HOOK="nix_lisp_build_system stumpwm '(function stumpwm:stumpwm)'"
"$out/bin/stumpwm-lisp-launcher.sh"
cp "$out/lib/common-lisp/stumpwm/stumpwm" "$out/bin"
'';
@@ -69,12 +68,10 @@ in
export NIX_LISP_ASDF_PATHS="$NIX_LISP_ASDF_PATHS
$out/lib/common-lisp/query-fs"
export HOME=$PWD
"$out/bin/query-fs-lisp-launcher.sh" --eval '(asdf:make :query-fs)' \
--eval "(progn $(for i in $linkedSystems; do echo "(asdf:make :$i)"; done) )" \
--eval '(setf (asdf/system:component-entry-point (asdf:find-system :query-fs))
(function query-fs:run-fs-with-cmdline-args))' \
--eval '(asdf:perform (quote asdf:program-op) :query-fs)'
cp "$out/lib/common-lisp/query-fs/query-fs" "$out/bin/"
export NIX_LISP_PRELAUNCH_HOOK="nix_lisp_build_system query-fs \
'(function query-fs:run-fs-with-cmdline-args)' '$linkedSystems'"
"$out/bin/query-fs-lisp-launcher.sh"
cp "$out/lib/common-lisp/query-fs/query-fs" "$out/bin/"
'';
};
};