1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2025-01-22 14:45:27 +00:00

In Emacs site-start.el check that NIX_PROFILES is set.

In the stdenv this is not set, which causes an elisp error
which in turn makes builds depending on Emacs (eg gnuplot) fail.

svn path=/nixpkgs/trunk/; revision=31261
This commit is contained in:
Karn Kallio 2012-01-04 05:48:38 +00:00
parent 0e1ea067ab
commit ec8e23cc97
3 changed files with 12 additions and 12 deletions
pkgs/applications/editors
emacs-22
emacs-23
emacs-snapshot

View file

@ -33,10 +33,10 @@ stdenv.mkDerivation rec {
postInstall = ''
cat >$out/share/emacs/site-lisp/site-start.el <<EOF
;; nixos specific load-path
(setq load-path
(append (reverse (mapcar (lambda (x) (concat x "/share/emacs/site-lisp/"))
(split-string (getenv "NIX_PROFILES"))))
load-path))
(when (getenv "NIX_PROFILES") (setq load-path
(append (reverse (mapcar (lambda (x) (concat x "/share/emacs/site-lisp/"))
(split-string (getenv "NIX_PROFILES"))))
load-path)))
EOF
'';

View file

@ -34,10 +34,10 @@ stdenv.mkDerivation rec {
postInstall = ''
cat >$out/share/emacs/site-lisp/site-start.el <<EOF
;; nixos specific load-path
(setq load-path
(append (reverse (mapcar (lambda (x) (concat x "/share/emacs/site-lisp/"))
(split-string (getenv "NIX_PROFILES"))))
load-path))
(when (getenv "NIX_PROFILES") (setq load-path
(append (reverse (mapcar (lambda (x) (concat x "/share/emacs/site-lisp/"))
(split-string (getenv "NIX_PROFILES"))))
load-path)))
EOF
'';

View file

@ -51,10 +51,10 @@ stdenv.mkDerivation {
postInstall = ''
cat >$out/share/emacs/site-lisp/site-start.el <<EOF
;; nixos specific load-path
(setq load-path
(append (reverse (mapcar (lambda (x) (concat x "/share/emacs/site-lisp/"))
(split-string (getenv "NIX_PROFILES"))))
load-path))
(when (getenv "NIX_PROFILES") (setq load-path
(append (reverse (mapcar (lambda (x) (concat x "/share/emacs/site-lisp/"))
(split-string (getenv "NIX_PROFILES"))))
load-path)))
EOF
'';