Skip to content

Commit e7a9bdf

Browse files
committed
Fix #629
The LD_LIB_P_VAR *should* be *once* de-referenced in the echo statements within `prerequisits/install-functions/report_results.sh` so that it takes the value of `LD_LIBRARY_PATH` or `DYLD_LIBRARY_PATH` in the setup script, which then checks if the user has anything set here and decides whether to add additional search paths (if they have it set) or set it directly if it is empty.
1 parent 1f0770b commit e7a9bdf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

prerequisites/install-functions/report_results.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,10 +69,10 @@ report_results()
6969
if [[ -d "${compiler_install_root%/}/lib" || -d "${compiler_install_root%/}/lib64" ]]; then
7070
echo "# Prepend the compiler library paths to the ${LD_LIB_P_VAR} environment variable:" | tee -a setup.sh setup.csh
7171
compiler_lib_paths="${compiler_install_root%/}/lib64/:${compiler_install_root%/}/lib"
72-
echo "if [[ -z \"\${!LD_LIB_P_VAR}\" ]]; then " >> setup.sh
72+
echo "if [[ -z \"\${!${LD_LIB_P_VAR}}\" ]]; then " >> setup.sh
7373
echo " export ${LD_LIB_P_VAR}=\"${compiler_lib_paths%/}\" " >> setup.sh
7474
echo "else " >> setup.sh
75-
echo " export ${LD_LIB_P_VAR}=\"${compiler_lib_paths%/}:\${!LD_LIB_P_VAR}\" " >> setup.sh
75+
echo " export ${LD_LIB_P_VAR}=\"${compiler_lib_paths%/}:\${!${LD_LIB_P_VAR}}\" " >> setup.sh
7676
echo "fi " >> setup.sh
7777
echo "setenv LD_LIBRARY_PATH \"${compiler_lib_paths%/}:\${LD_LIBRARY_PATH}\" " >> setup.csh
7878
fi

0 commit comments

Comments
 (0)