Hi,
Ward Poelmans <[email protected]> writes:
> Hi Loris,
>
> On 27/03/19 13:35, Loris Bennett wrote:
>
>>
>> However, the binaries are not directly under 'bin', but in the
>> subdirectories shown below:
>>
>> [build@admin bin]$ tree -L 1
>> .
>> ├── em64t-unknown-linux-gnu
>> ├── em64t-unknown-linux-gnu_mpi
>> ├── em64t-unknown-linux-gnu_smp
>> ├── x86_64-unknown-linux-gnu
>> ├── x86_64-unknown-linux-gnu_mpi
>> └── x86_64-unknown-linux-gnu_smp
>>
>> What is the standard way of tweaking the PATH variable in such a case?
>
> modextrapaths = {'PATH': ['bin/x86_64-unknown-linux-gnu']}
>
> would work. But it it's a lot of path, maybe a easyblock is nicer.
In the end I just added
modluafooter = 'setenv("TURBOMOLE_SYSNAME",
subprocess(pathJoin("%(installdir)s", "scripts/sysname")));
prepend_path("PATH",pathJoin("%(installdir)s","bin",subprocess(pathJoin("%(installdir)s",
"scripts/sysname"))))'
This way the path will be set correctly based on the value of PARA_ARCH,
which can be unset, 'SMP' or 'MPI'.
For reasons unknown to me, I wasn't able to just use
os.getenv("TURBOMOLE_SYSNAME")
in the prepend_path, as the variable was apparently unset, so I just
used the klugde of calling the same subprocess again.
Cheers,
Loris
--
Dr. Loris Bennett (Mr.)
ZEDAT, Freie Universität Berlin Email [email protected]