easybuild-framework icon indicating copy to clipboard operation
easybuild-framework copied to clipboard

allow extensions to add text to the module file

Open Flamefire opened this issue 1 year ago • 2 comments

Introduce make_extension_module_extra which gets called during module file creation for every extension similar to make_module_extra. This ensures it will also be called for parallel extension or --module-only builds.

Fixes https://github.com/easybuilders/easybuild-framework/issues/4647

I'm open for a better name but make_module_extra_extensions already exists so make_module_extra_extension might be confusing.

Currently the (now deprecated) feature is only used by the numpy easyblock to add the numpy includes to $CPATH. So that easyblock needs to be updated. I'd argue that we shouldn't add the numpy includes as a regular pip install numpy doesn't do that either. So if a user updates the numpy in a virtualenv using our current approach might end up using headers from one numpy and libs/python files from another.

However I'm not sure if (and why) other software we have already relies on that. One which did will be fixed by https://github.com/easybuilders/easybuild-easyconfigs/pull/21467

Flamefire avatar Sep 23 '24 09:09 Flamefire