3 software_and_version=$1
6 # get the absolute path of the directory containing this script
7 execPath=$(readlink -f $(dirname $0))
9 archive=${execPath}/../archives/${archive_file}
10 src_dir=${execPath}/../src/${software_and_version}
11 build_dir=${execPath}/../build/${software_and_version}
12 install_dir=${execPath}/../install/${software_and_version}
15 mkdir -p ${install_dir}
19 if [ ! -d "${src_dir}" ]
21 ${execPath}/extract.sh ${archive} ${src_dir}
24 status=$?; if [ ${status} -ne 0 ]; then exit ${status}; fi
29 . ${execPath}/environment.sh
30 cmake -DCMAKE_INSTALL_PREFIX=${install_dir} -DMEDFILE_ROOT_DIR=${MED3HOME} -DSALOME_MED_STANDALONE=ON -DSALOME_MED_ENABLE_PYTHON=ON -DSALOME_MED_ENABLE_PARTITIONER=OFF -DSALOME_MED_ENABLE_RENUMBER=OFF -DSALOME_MED_WITH_FILE_EXAMPLES=OFF -DSALOME_BUILD_TESTS=OFF -DSALOME_BUILD_DOC=OFF -DSALOME_MED_MEDLOADER_USE_XDR=OFF ${src_dir}
31 ) | tee ${build_dir}/configure.log 2>&1
32 status=$?; if [ ${status} -ne 0 ]; then exit ${status}; fi
37 . ${execPath}/environment.sh
39 ) | tee ${build_dir}/build.log 2>&1
40 status=$?; if [ ${status} -ne 0 ]; then exit ${status}; fi
41 status=$?; if [ ${status} -ne 0 ]; then exit ${status}; fi
46 . ${execPath}/environment.sh
48 ) | tee ${build_dir}/install.log 2>&1
49 status=$?; if [ ${status} -ne 0 ]; then exit ${status}; fi
52 echo "" >> ${execPath}/environment.sh
53 echo "#------- MEDCoupling ------" >> ${execPath}/environment.sh
54 echo "export MED_ROOT_DIR=${install_dir}" >> ${execPath}/environment.sh
55 echo "export LD_LIBRARY_PATH=\${MED_ROOT_DIR}/lib/salome:\${LD_LIBRARY_PATH}" >> ${execPath}/environment.sh
56 echo "export PYTHONPATH=\${MED_ROOT_DIR}/lib/python\${PYTHON_VERSION}/site-packages/salome:\${PYTHONPATH}"