@@ -17,37 +17,6 @@ display_help() {
1717 echo " --skip-cuda-install - disable installing a full CUDA SDK in the host_injections prefix (e.g. in CI)"
1818}
1919
20- function copy_build_log() {
21- # copy specified build log to specified directory, with some context added
22- build_log=${1}
23- build_logs_dir=${2}
24-
25- # also copy to build logs directory, if specified
26- if [ ! -z " ${build_logs_dir} " ]; then
27- log_filename=" $( basename ${build_log} ) "
28- if [ ! -z " ${SLURM_JOB_ID} " ]; then
29- # use subdirectory for build log in context of a Slurm job
30- build_log_path=" ${build_logs_dir} /jobs/${SLURM_JOB_ID} /${log_filename} "
31- else
32- build_log_path=" ${build_logs_dir} /non-jobs/${log_filename} "
33- fi
34- mkdir -p $( dirname ${build_log_path} )
35- cp -a ${build_log} ${build_log_path}
36- chmod 0644 ${build_log_path}
37-
38- # add context to end of copied log file
39- echo >> ${build_log_path}
40- echo " Context from which build log was copied:" >> ${build_log_path}
41- echo " - original path of build log: ${build_log} " >> ${build_log_path}
42- echo " - working directory: ${PWD} " >> ${build_log_path}
43- echo " - Slurm job ID: ${SLURM_OUT} " >> ${build_log_path}
44- echo " - EasyBuild version: ${eb_version} " >> ${build_log_path}
45- echo " - easystack file: ${easystack_file} " >> ${build_log_path}
46-
47- echo " EasyBuild log file ${build_log} copied to ${build_log_path} (with context appended)"
48- fi
49- }
50-
5120function safe_module_use {
5221 # add a given non-empty directory to $MODULEPATH if and only if it is not yet in
5322 directory=${1}
0 commit comments