diff --git a/EM/IMOD/README.md b/EM/IMOD/README.md index 034c88d..452197b 100644 --- a/EM/IMOD/README.md +++ b/EM/IMOD/README.md @@ -12,3 +12,7 @@ The installation includes environment scripts which install into `$IMOD_DIR/profile.d`. These are sourced in the modulefile. This means that the module cannot be unloaded cleanly (eg IMOD remains in the PATH after unloading). + +TODO solution: re-write the .sh script that is sourced in the modulefile into the +modulefile directly. Variables and Path extensions will then automatically be +"unset" when unloding. diff --git a/EM/IMOD/build b/EM/IMOD/build index f4fdc4d..2a4b937 100755 --- a/EM/IMOD/build +++ b/EM/IMOD/build @@ -1,18 +1,16 @@ #!/usr/bin/env modbuild -set -e -pbuild::add_to_group 'EM' pbuild::prep() { : ${CUDA_VERSION:?No CUDA_VERSION set} + #local cuda="${CUDA_VERSION%.*}" IF the cua version matches the cuda version in the filename local cuda="${CUDA_VERSION%.*}" - local filename="imod_${V_PKG}_RHEL7-64_CUDA${cuda}.sh" - if [[ $V_RELEASE == *beta* ]]; then - local url="https://bio3d.colorado.edu/ftp/latestIMOD/RHEL7-64_CUDA${cuda}/$filename" - else - local url="https://bio3d.colorado.edu/imod/AMD64-RHEL5/$filename" - fi + #otherwise: + local cuda="12.0" + local filename="imod_${V_PKG}_RHEL8-64_CUDA${cuda}.sh" + # beta release link for Merlin7 ( RH8 for Opensuse) + local url="https://bio3d.colorado.edu/ftp/latestIMOD/RHEL8-64_CUDA${cuda}/$filename" local dst="$PMODULES_DISTFILESDIR/${filename}" if [ -f "$dst" ]; then echo "Found cached $dst" >&2 @@ -35,8 +33,11 @@ pbuild::compile() { pbuild::install() { : ${CUDA_VERSION:?No CUDA_VERSION set} - local cuda="${CUDA_VERSION%.*}" - local filename="imod_${V_PKG}_RHEL7-64_CUDA${cuda}.sh" + #local cuda="${CUDA_VERSION%.*}" + #(if cuda version matches the file name) if not: + local cuda="12.0" + + local filename="imod_${V_PKG}_RHEL8-64_CUDA${cuda}.sh" local dst="$PMODULES_DISTFILESDIR/${filename}" mkdir -p "$PREFIX/profile.d" diff --git a/EM/IMOD/files/config.yaml b/EM/IMOD/files/config.yaml new file mode 100644 index 0000000..c62c171 --- /dev/null +++ b/EM/IMOD/files/config.yaml @@ -0,0 +1,15 @@ +--- +format: 1 +IMOD: + defaults: + group: EM + overlay: base + relstage: unstable + versions: + 5.0.0: + variants: + - overlay: Alps + systems: [.*.merlin7.psi.ch] + relstage: unstable + runtime_deps: + - cuda/12.2.0 diff --git a/EM/IMOD/files/variants b/EM/IMOD/files/variants deleted file mode 100644 index 2c4368a..0000000 --- a/EM/IMOD/files/variants +++ /dev/null @@ -1,4 +0,0 @@ -IMOD/4.9.5 stable -IMOD/4.11.20 stable cuda/10.1.105 -IMOD/4.11.24 unstable cuda/10.1.105 -IMOD/4.12.50-beta unstable cuda/10.1.105 diff --git a/EM/IMOD/modulefile b/EM/IMOD/modulefile index d19b9e2..e3f1302 100644 --- a/EM/IMOD/modulefile +++ b/EM/IMOD/modulefile @@ -3,7 +3,7 @@ module-whatis "IMOD is a set of image processing, modeling and display programs used for tomographic reconstruction and for 3D reconstruction of EM serial sections and optical sections." module-url "http://bio3d.colorado.edu/imod/" module-license "mostly GPLv2.0, with the exceptions, see http://bio3d.colorado.edu/imod/COPYRIGHT.txt" -module-maintainer "Spencer Bliven / Dmitry Ozerov " +module-maintainer "Greta Assmann - greta.assmann@psi.ch" module-help " IMOD is a set of image processing, modeling and display programs used for tomographic @@ -34,6 +34,11 @@ For tomographic reconstruction, see also: > tomographic reconstruction in IMOD. J. Struct. Biol. 197:102-113. " +# TO DO : rewrite IMOD-linx.sh script directly into the following section instead of sourcing the script + +#this is needed to NOT set the default IMOD_DIR by pmodules, as this is set later in the IMOD-linux.sh +set dont-setenv { IMOD_DIR } + switch [module-info mode] { "load" { puts stdout "source $PREFIX/profile.d/IMOD-linux.sh"