On 18/11/15 12:49, Fokko Masselink wrote:
Hi EasyBuilders,

when trying to install for example Intel software (Intel C compiler, VTune,
etc...) it requires a license.
Currently you can set that in the .eb file via license_file or via the
environment variable INTEL_LICENSE_FILE.
We build the software, though it gets distributed around the world internally.
Each location has it's own license server (otherwise latencies are being too
much of a hurdle).
So the value of either of the two options may differ per location.

So I've been thinking about how to cope with that.
I came up with all licenses being available as modules. In this case hidden
modules, so they don't clutter the already long list of built software.

Since EB 2.4.0 hidden modules function well as dependencies :-)
My license modules detect the user location an set the corresponding value for
INTEL_LICENSE_FILE.
I can also make changes for specific users.

Though with the current IntelBase.py script it will always include
INTEL_LICENSE_FILE in the modulefile, so it gets "hardcoded".
Can you think of a way to avoid that and solely rely on the license module at
both build and runtime?
In IntelBase.py self.cfg['license_file'] gets re-set, so no way to later check
for it if it was left empty.

==============================================
VTune.eb
dependencies = [
    ('licenses', '.vtune'),
]
license_file = ''
==============================================

For now I've added an extra variable to extra_vars in intelbase.py:
set_license_file_via_module
And added that to Vtune.eb file.

Though that makes me deviate from the EasyBuild standard delivered and
evergreened codeblocks.

Right now, including the definition of $INTEL_LICENSE_FILE is indeed hardcoded in the IntelBase.py generic easyblock.

I'm glad you find a proper workaround yourself, and it think it makes sense to make that optional.

Send us a pull request for your change to IntelBase, and we'll look into merging it in the 'official' EasyBuild codebase.

Documentation on contributing back is available at https://github.com/hpcugent/easybuild/wiki/Contributing-back (of course, you need to replace 'easyconfigs' with 'easyblocks' in this case).


regards,

Kenneth

Reply via email to