diff --git a/easybuild/easyblocks/generic/configuremake.py b/easybuild/easyblocks/generic/configuremake.py index 7cfafd9601f..2f262c6430a 100644 --- a/easybuild/easyblocks/generic/configuremake.py +++ b/easybuild/easyblocks/generic/configuremake.py @@ -70,7 +70,7 @@ def check_config_guess(config_guess, log=None): """Check timestamp & SHA256 checksum of config.guess script. - :param configu_gess: Path to config.guess script to check + :param config_guess: Path to config.guess script to check :param log: Instance of a logger to use or None to run in quiet mode :return: Whether the script is valid (matches the version and checksum) """ @@ -100,12 +100,13 @@ def check_config_guess(config_guess, log=None): result = False tup = (config_guess, config_guess_version, CONFIG_GUESS_VERSION) if log: - log.warning("config.guess version at %s does not match expected version: %s vs %s" % tup) + print_warning("config.guess version at %s does not match expected version: %s vs %s" % tup, log=log) if config_guess_checksum != CONFIG_GUESS_SHA256: result = False tup = (config_guess, config_guess_checksum, CONFIG_GUESS_SHA256) if log: - log.warning("SHA256 checksum of config.guess at %s does not match expected checksum: %s vs %s" % tup) + print_warning("SHA256 checksum of config.guess at %s does not match expected checksum: %s vs %s" % tup, + log=log) return result diff --git a/easybuild/easyblocks/generic/rpackage.py b/easybuild/easyblocks/generic/rpackage.py index d0ab8b2d74a..4cf66c92bf0 100644 --- a/easybuild/easyblocks/generic/rpackage.py +++ b/easybuild/easyblocks/generic/rpackage.py @@ -33,7 +33,6 @@ @author: Balazs Hajgato (Vrije Universiteit Brussel) """ import os -import shutil from easybuild.easyblocks.r import EXTS_FILTER_R_PACKAGES, EB_R from easybuild.easyblocks.generic.configuremake import check_config_guess, obtain_config_guess @@ -175,13 +174,14 @@ def install_R_package(self, cmd, inp=None): else: self.log.debug("R package %s installed succesfully" % self.name) - def update_config_guess(self, src_dir): - """Update any config.guess found in src_dir""" - for config_guess_dir in (root for root, _, files in os.walk(src_dir) if 'config.guess' in files): + def update_config_guess(self, path): + """Update any config.guess found in specified directory""" + for config_guess_dir in (root for root, _, files in os.walk(path) if 'config.guess' in files): config_guess = os.path.join(config_guess_dir, 'config.guess') if not check_config_guess(config_guess): updated_config_guess = obtain_config_guess(log=self.log) copy_file(updated_config_guess, config_guess) + self.log.debug("Replacing outdated %s with more recent copy at %s", config_guess, updated_config_guess) def install_step(self): """Install procedure for R packages."""