Skip to content

Commit

Permalink
Merge pull request #442 from boegel/2023.06-software.eessi.io_2023b
Browse files Browse the repository at this point in the history
  • Loading branch information
bedroge authored Jan 4, 2024
2 parents 9b6c1ed + 5c00615 commit 4805315
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
easyconfigs:
- GCC-13.2.0.eb
- foss-2023b.eb
8 changes: 8 additions & 0 deletions eb_hooks.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import os
import re

import easybuild.tools.environment as env
from easybuild.easyblocks.generic.configuremake import obtain_config_guess
from easybuild.framework.easyconfig.constants import EASYCONFIG_CONSTANTS
from easybuild.tools.build_log import EasyBuildError, print_msg
Expand Down Expand Up @@ -258,6 +259,13 @@ def pre_configure_hook_openblas_optarch_generic(self, *args, **kwargs):
if build_option('optarch') == OPTARCH_GENERIC:
for step in ('build', 'test', 'install'):
self.cfg.update(f'{step}opts', "DYNAMIC_ARCH=1")

# use -mtune=generic rather than -mcpu=generic in $CFLAGS on aarch64,
# because -mcpu=generic implies a particular -march=armv* which clashes with those used by OpenBLAS
# when building with DYNAMIC_ARCH=1
if get_cpu_architecture() == AARCH64:
cflags = os.getenv('CFLAGS').replace('-mcpu=generic', '-mtune=generic')
env.setvar('CFLAGS', cflags)
else:
raise EasyBuildError("OpenBLAS-specific hook triggered for non-OpenBLAS easyconfig?!")

Expand Down

0 comments on commit 4805315

Please sign in to comment.