hpcugent/Lmod-UGent

provide `environment(modules)`

Closed this issue · 7 comments

# dnf install python3-sphinx
Last metadata expiration check: 0:07:19 ago on Sat 29 Aug 2020 10:36:32 PM CEST.
Error: 
 Problem: package python3-sphinx-1:1.7.6-1.el8.noarch requires environment(modules), but none of the providers can be installed
  - package Lmod-8.2.5-2.ug.el8.x86_64 conflicts with environment-modules provided by environment-modules-4.1.4-4.el8.x86_64
  - package Lmod-8.2.5-2.ug.el8.x86_64 conflicts with environment-modules provided by environment-modules-4.1.4-1.el8.x86_64
  - problem with installed package Lmod-8.2.5-2.ug.el8.x86_64
  - conflicting requests
  - package Lmod-8.2.7-1.el8.x86_64 is filtered out by exclude filtering

the Lmod rpm/spec should mention a 'Provides: environment(modules)' if it does provide environment-modules compatibilty

It's a bit strange that python3-sphinx requires an environment modules tool, but I found the reason why in https://src.fedoraproject.org/rpms/python-sphinx/c/fa7e4f510bfb46af9fd23ff2c063b75ab6e9fe5f?branch=master (because it ships a module file).

They're also switching there from Lmod to environment(modules), so it makes sense to add Provides: environment(modules) to the Lmod spec, like they do in Fedora: https://src.fedoraproject.org/rpms/Lmod/blob/master/f/Lmod.spec#_38

@boegel i like the fedora spec. is there any reason we can't use the lmod fedora build, and add our customisations to that in and actual Lmod-UGent rpm that has it as a dependency?

@boegel ah i see. the configure options are (very) different

@stdweird fixed in #42

The reason the epel/fedora rpm is not used directly is that Lmod doesn't have a config file. You can set the options either in the configure script (which hardcodes it in the lua source) or through environment variables. As the latter is error prone, we used the former.

The proper thing would be to have a config file for Lmod and just ship the SitePackage in a separate RPM.