> On 10 Oct 2018, at 10:38, Kenneth Hoste <[email protected]> wrote:
> 
> Dear Jakob,
> 
> 
> Resolving the value of an environment variable to define another environment 
> variable via modextravars currently isn't possible.
> 
> We have a mechanism to specify that an environment variable should be 
> resolved at "module load" time, but it currently only works in a very 
> specific situation (for $HOME in --subdir-user-modules).
> 
> But you can work around this, with either modtclfooter or modluafooter, 
> depending on which syntax your module files are being generated in.
> 
> Something like this should work (totally untested, I'll leave that up to you):
> 
> modtclfooter = "setenv GPAW_FFTWSO $::env(EBROOTFFTW)/lib"
> 
> or
> 
> modluafooter = 'setenv("GPAW_FFTWSO", pathJoin(os.getenv("EBROOTFFTW"), 
> "lib”)'

Dear Kenneth, 

Thanks for your reply.  I am not sure this is portable, since the EB file 
should work regardless of whether the site using it uses one or the other 
module syntax.

I think that before trying this I may try to patch the GPAW python code to do 
the right thing instead.

Best regards

Jakob

> 
> 
> regards,
> 
> Kenneth
> 
> 
>> Best regards
>> Jakob
>> --
>> Jakob Schiøtz, professor, Ph.D.
>> Department of Physics
>> Technical University of Denmark
>> DK-2800 Kongens Lyngby, Denmark
>> http://www.fysik.dtu.dk/~schiotz/

--
Jakob Schiøtz, professor, Ph.D.
Department of Physics
Technical University of Denmark
DK-2800 Kongens Lyngby, Denmark
http://www.fysik.dtu.dk/~schiotz/



Reply via email to