Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1addGuileLibPath () {
2 if test -d "$1/share/guile/site/2.0"; then
3 export GUILE_LOAD_PATH="${GUILE_LOAD_PATH-}${GUILE_LOAD_PATH:+:}$1/share/guile/site/2.0"
4 export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/share/guile/site/2.0"
5 elif test -d "$1/share/guile/site"; then
6 export GUILE_LOAD_PATH="${GUILE_LOAD_PATH-}${GUILE_LOAD_PATH:+:}$1/share/guile/site"
7 export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/share/guile/site"
8 fi
9
10 if test -d "$1/lib/guile/2.0/ccache"; then
11 export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/lib/guile/2.0/ccache"
12 fi
13
14 if test -d "$1/lib/guile/2.0/site-ccache"; then
15 export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/lib/guile/2.0/site-ccache"
16 fi
17}
18
19addEnvHooks "$hostOffset" addGuileLibPath