Skip to content

Commit

Permalink
replace run_cmd with run_shell_cmd in atlas.py
Browse files Browse the repository at this point in the history
  • Loading branch information
branfosj committed Jan 28, 2024
1 parent f1221e2 commit 62adda7
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions easybuild/easyblocks/a/atlas.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
from easybuild.framework.easyconfig import CUSTOM
from easybuild.tools.build_log import EasyBuildError
from easybuild.tools.modules import get_software_root
from easybuild.tools.run import run_cmd
from easybuild.tools.run import run_shell_cmd
from easybuild.tools.systemtools import AMD, INTEL, get_cpu_speed, get_cpu_vendor, get_shared_lib_ext


Expand Down Expand Up @@ -142,9 +142,10 @@ def configure_step(self):
# call configure in parent dir
cmd = "%s %s/configure --prefix=%s %s" % (self.cfg['preconfigopts'], self.cfg['start_dir'],
self.installdir, self.cfg['configopts'])
(out, exitcode) = run_cmd(cmd, log_all=False, log_ok=False, simple=False)
res = run_shell_cmd(cmd, fail_on_error=False)

if exitcode != 0:
if res.code != 0:
out = res.output
throttling_regexp = re.compile("cpu throttling [a-zA-Z]* enabled", re.IGNORECASE)
if throttling_regexp.search(out):
errormsg = (
Expand Down Expand Up @@ -175,7 +176,7 @@ def build_step(self, verbose=False):

self.log.debug("Building shared libraries")
cmd = "make shared cshared ptshared cptshared"
run_cmd(cmd, log_all=True, simple=True)
run_shell_cmd(cmd)

try:
os.chdir('..')
Expand Down

0 comments on commit 62adda7

Please sign in to comment.