Folks,
I have the following setup:
/net/software/{x86_64,aarch64,armv7l,riscv} contains all software on
shared storage. /net/software/modules/modulefiles contains the
corresponding module files for these software packages, e.g.,
clang/13.0.0, gcc/9.2.0, etc. The module files use the $ARCH
environment variable to setup the environment for the software.
Since I do not have all software packages compiled for all systems, I
was wondering what would be the best way to avoid loading (or even
better hide) modules that do not have the software package for a
particular architecture?
I have come up with either checking in the module file, if the software
exists and if not throw some sort of error. I could also have
$ARCH-specific module locations and use "module use" on these locations,
depending on the machine I'm on. But is there a better way to automate
all this w/o too much duplication of module files or code in the module
files?
I'm using Modules Release 4.4.1 (2020-01-03), all systems are Ubuntu
systems.
Kind regards,
-michael
|