Author: ludo
Date: Tue May 22 21:18:20 2012
New Revision: 34215
URL: https://nixos.org/websvn/nix/?rev=34215&sc=1

Log:
GNU Guile 2.0: Provide a 2.0ish setup hook.

Added:
   nixpkgs/trunk/pkgs/development/interpreters/guile/setup-hook-2.0.sh
Modified:
   nixpkgs/trunk/pkgs/development/interpreters/guile/default.nix

Modified: nixpkgs/trunk/pkgs/development/interpreters/guile/default.nix
==============================================================================
--- nixpkgs/trunk/pkgs/development/interpreters/guile/default.nix       Tue May 
22 21:00:16 2012        (r34214)
+++ nixpkgs/trunk/pkgs/development/interpreters/guile/default.nix       Tue May 
22 21:18:20 2012        (r34215)
@@ -46,7 +46,7 @@
 
   doCheck = true;
 
-  setupHook = ./setup-hook.sh;
+  setupHook = ./setup-hook-2.0.sh;
 
   crossAttrs.preConfigure =
     stdenv.lib.optionalString (stdenv.cross.config == "i586-pc-gnu")

Added: nixpkgs/trunk/pkgs/development/interpreters/guile/setup-hook-2.0.sh
==============================================================================
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ nixpkgs/trunk/pkgs/development/interpreters/guile/setup-hook-2.0.sh Tue May 
22 21:18:20 2012        (r34215)
@@ -0,0 +1,13 @@
+addGuileLibPath () {
+    if test -d "$1/share/guile/site/2.0"
+    then
+        export 
GUILE_LOAD_PATH="${GUILE_LOAD_PATH}${GUILE_LOAD_PATH:+:}$1/share/guile/site/2.0"
+        export 
GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH}${GUILE_LOAD_COMPILED_PATH:+:}$1/share/guile/site/2.0"
+    elif test -d "$1/share/guile/site"
+    then
+        export 
GUILE_LOAD_PATH="${GUILE_LOAD_PATH}${GUILE_LOAD_PATH:+:}$1/share/guile/site"
+        export 
GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH}${GUILE_LOAD_COMPILED_PATH:+:}$1/share/guile/site"
+    fi
+}
+
+envHooks=(${envHooks[@]} addGuileLibPath)
_______________________________________________
nix-commits mailing list
[email protected]
http://lists.science.uu.nl/mailman/listinfo/nix-commits

Reply via email to