Skip to content

Commit

Permalink
enhance sanity check
Browse files Browse the repository at this point in the history
  • Loading branch information
branfosj committed Jul 31, 2024
1 parent 40a9c2f commit bc7fa88
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion easybuild/easyblocks/o/ocaml.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,12 +146,21 @@ def sanity_check_step(self):
binaries.append('bin/opam')
dirs.append(OPAM_SUBDIR)

extension_names = [ext_name for ext_name, _ in self.cfg['exts_list']]

custom_commands = ["ocaml --help"]
if 'ocamlfind' in extension_names:
custom_commands.append("ocamlfind list")

if 'dune' in extension_names:
custom_commands.append("dune --version")

custom_paths = {
'files': binaries,
'dirs': dirs,
}

super(EB_OCaml, self).sanity_check_step(custom_paths=custom_paths)
super(EB_OCaml, self).sanity_check_step(custom_paths=custom_paths, custom_commands=custom_commands)

def make_module_req_guess(self):
"""Custom extra paths/variables to define in generated module for OCaml."""
Expand Down

0 comments on commit bc7fa88

Please sign in to comment.