@@ -34,7 +34,7 @@ report_results()
34
34
# Prepend the OpenCoarrays license to the setup.sh script:
35
35
while IFS=' ' read -r line || [[ -n " ${line} " ]]; do
36
36
echo " # ${line} " >> setup.sh
37
- done < " ${opencoarrays_src_dir } /LICENSE"
37
+ done < " ${OpenCoarrays_src_dir } /LICENSE"
38
38
while IFS=' ' read -r line || [[ -n " ${line} " ]]; do
39
39
echo " # ${line} " >> setup.csh
40
40
done < " ${opencoarrays_src_dir} /LICENSE"
@@ -49,18 +49,18 @@ report_results()
49
49
echo " else " >> setup.sh
50
50
echo " if ! [[ \"\$ {PATH}\" =~ \" ${cmake_install_path} \" ]] ; then " >> setup.sh
51
51
echo " export PATH=\" ${cmake_install_path%/ } \" :\$ {PATH} " >> setup.sh
52
- echo " fi " >> setup.sh
52
+ echo " fi " >> setup.sh
53
53
echo " fi " >> setup.sh
54
- echo " set path = (\" ${cmake_install_path%/ } \" \"\ $ path\" ) " >> setup.csh
54
+ echo " set path = (\" ${cmake_install_path%/ } \" \$ path) " >> setup.csh
55
55
fi
56
56
if [[ -x " ${fully_qualified_FC} " ]]; then
57
57
echo " # Prepend the compiler path to the PATH environment variable:" | tee -a setup.sh setup.csh
58
- echo " if [[ -z \"\$ {PATH}\" ]]; then " >> setup.sh
58
+ echo " if [[ -z \"\$ {PATH}\" ]]; then " >> setup.sh
59
59
echo " export PATH=\" ${compiler_install_root%/ } /bin\" " >> setup.sh
60
60
echo " else " >> setup.sh
61
- echo " export PATH=\" ${compiler_install_root%/ } /bin:\$ {PATH}\" " >> setup.sh
61
+ echo " export PATH=\" ${compiler_install_root%/ } /bin:\$ {PATH}\" " >> setup.sh
62
62
echo " fi " >> setup.sh
63
- echo " set path = (\" ${compiler_install_root%/ } \" /bin \"\ $ path\" ) " >> setup.csh
63
+ echo " set path (\" ${compiler_install_root%/ } \" /bin \$ path) " >> setup.csh
64
64
fi
65
65
LD_LIB_P_VAR=LD_LIBRARY_PATH
66
66
if [[ " ${OSTYPE:- } " =~ [Dd]arwin ]]; then
@@ -74,23 +74,23 @@ report_results()
74
74
echo " else " >> setup.sh
75
75
echo " export ${LD_LIB_P_VAR} =\" ${compiler_lib_paths%/ } :\$ {!LD_LIB_P_VAR}\" " >> setup.sh
76
76
echo " fi " >> setup.sh
77
- echo " set LD_LIBRARY_PATH = ( \" ${compiler_lib_paths%/ } \" \"\ $ {LD_LIBRARY_PATH}\" ) " >> setup.csh
77
+ echo " setenv LD_LIBRARY_PATH \" ${compiler_lib_paths%/ } : \ $ {LD_LIBRARY_PATH}\" " >> setup.csh
78
78
fi
79
- echo " " >> setup.sh
79
+ echo " " >> setup.sh
80
80
if [[ -x " ${mpi_install_root} /bin/mpifort" ]]; then
81
81
echo " # Prepend the MPI path to the PATH environment variable:" | tee -a setup.sh setup.csh
82
- echo " if [[ -z \"\$ {PATH}\" ]]; then " >> setup.sh
83
- echo " export PATH=\" ${mpi_install_root%/ } /bin\" " >> setup.sh
82
+ echo " if [[ -z \"\$ {PATH}\" ]]; then " >> setup.sh
83
+ echo " export PATH=\" ${mpi_install_root%/ } /bin\" " >> setup.sh
84
84
echo " else " >> setup.sh
85
85
echo " export PATH=\" ${mpi_install_root%/ } /bin\" :\$ {PATH} " >> setup.sh
86
86
echo " fi " >> setup.sh
87
- echo " set path = (\" ${mpi_install_root%/ } \" /bin \" \$ path\" ) " >> setup.csh
87
+ echo " set path = (\" ${mpi_install_root%/ } /bin\" \$ path) " >> setup.csh
88
88
fi
89
89
# In all likelihood, the following paths are only needed if OpenCoarrays built them,
90
90
# In by far the most common such use case, they would have been built in a recursive
91
91
# build of all the OpenCoarrays dependency tree (rather than built indvidually via
92
92
# ./install --package) so we only need check the default location in which OpenCoarrays
93
- # would install them. If they are not there, then it is very likely the case that the
93
+ # would install them. If they are not there, then it is very likely the case that the
94
94
# the system versions of these packages are present and in the user's path or that the
95
95
# user doesn't need them at all (e.g. there was no need to build gfortran from source).
96
96
flex_install_path=$( " ${build_script} " -P flex)
@@ -100,7 +100,7 @@ report_results()
100
100
echo " export PATH=\" ${flex_install_path} /bin\" " >> setup.sh
101
101
echo " else " >> setup.sh
102
102
echo " export PATH=\" ${flex_install_path} /bin\" :\$ {PATH} " >> setup.sh
103
- echo " set path = (\" $flex_install_path \" /bin \"\ $ path\" ) " >> setup.csh
103
+ echo " set path = (\" $flex_install_path \" /bin \$ path) " >> setup.csh
104
104
echo " fi " >> setup.sh
105
105
fi
106
106
bison_install_path=$( " ${build_script} " -P bison)
@@ -111,7 +111,7 @@ report_results()
111
111
echo " else " >> setup.sh
112
112
echo " export PATH=\" ${bison_install_path} /bin\" :\$ {PATH} " >> setup.sh
113
113
echo " fi " >> setup.sh
114
- echo " set path = (\" $bison_install_path \" /bin \"\ $ path\" ) " >> setup.csh
114
+ echo " set path = (\" $bison_install_path \" /bin \$ path) " >> setup.csh
115
115
fi
116
116
m4_install_path=$( " ${build_script} " -P m4)
117
117
if [[ -x " ${m4_install_path} /bin/m4" ]]; then
@@ -121,7 +121,7 @@ report_results()
121
121
echo " else " >> setup.sh
122
122
echo " export PATH=\" ${m4_install_path} /bin\" :\$ {PATH} " >> setup.sh
123
123
echo " fi " >> setup.sh
124
- echo " set path = (\" $m4_install_path \" /bin \"\ $ path\" ) " >> setup.csh
124
+ echo " set path = (\" $m4_install_path \" /bin \$ path) " >> setup.csh
125
125
fi
126
126
opencoarrays_install_path=" ${install_path} "
127
127
if [[ -x " ${opencoarrays_install_path} /bin/caf" ]]; then
@@ -131,7 +131,7 @@ report_results()
131
131
echo " else " >> setup.sh
132
132
echo " export PATH=\" ${opencoarrays_install_path%/ } /bin\" :\$ {PATH} " >> setup.sh
133
133
echo " fi " >> setup.sh
134
- echo " set path = (\" ${opencoarrays_install_path%/ } \" /bin \"\ $ path\" ) " >> setup.csh
134
+ echo " set path = (\" ${opencoarrays_install_path%/ } \" /bin \$ path) " >> setup.csh
135
135
fi
136
136
if ${SUDO:- } mv setup.sh " ${opencoarrays_install_path} " ; then
137
137
setup_sh_location=${opencoarrays_install_path}
0 commit comments