Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions easybuild/framework/easyblock.py
Original file line number Diff line number Diff line change
Expand Up @@ -1895,7 +1895,7 @@ def package_step(self):

pkgtype = build_option('package_type')
pkgdir_dest = os.path.abspath(package_path())
opt_force = build_option('force')
opt_force = build_option('force') or build_option('rebuild')

self.log.info("Generating %s package in %s", pkgtype, pkgdir_dest)
pkgdir_src = package(self)
Expand Down Expand Up @@ -2383,7 +2383,7 @@ def update_config_template_run_step(self):
def _skip_step(self, step, skippable):
"""Dedice whether or not to skip the specified step."""
module_only = build_option('module_only')
force = build_option('force')
force = build_option('force') or build_option('rebuild')
skip = False

# skip step if specified as individual (skippable) step
Expand Down
11 changes: 11 additions & 0 deletions test/framework/toy_build.py
Original file line number Diff line number Diff line change
Expand Up @@ -1235,6 +1235,17 @@ def test_module_only(self):

os.remove(toy_mod)

# --module-only --rebuild should be equivalent with --module-only --force
self.eb_main(args + ['--rebuild'], do_build=True, raise_error=True)
self.assertTrue(os.path.exists(toy_mod))

# make sure load statements for dependencies are included in additional module file generated with --module-only
modtxt = read_file(toy_mod)
self.assertTrue(re.search('load.*ictce/4.1.13', modtxt), "load statement for ictce/4.1.13 found in module")
self.assertTrue(re.search('load.*GCC/4.7.2', modtxt), "load statement for GCC/4.7.2 found in module")

os.remove(toy_mod)

# installing another module under a different naming scheme and using Lua module syntax works fine

# first actually build and install toy software + module
Expand Down