Skip to content

Commit

Permalink
BLD: Add clang -ffp-exception-behavior=strict also for _so
Browse files Browse the repository at this point in the history
Apparently, there is a second `compiler_so` that is actually the
main compiler being used, and modifying only the first one is just
futile.
  • Loading branch information
seberg committed Jul 14, 2021
1 parent f353371 commit 7eae81e
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions numpy/distutils/ccompiler.py
Expand Up @@ -389,6 +389,7 @@ def CCompiler_customize_cmd(self, cmd, ignore=()):
# clang defaults to a non-strict floating error point model.
# Since NumPy and most Python libs give warnings for these, override:
self.compiler.append('-ffp-exception-behavior=strict')
self.compiler_so.append('-ffp-exception-behavior=strict')

def allow(attr):
return getattr(cmd, attr, None) is not None and attr not in ignore
Expand Down

0 comments on commit 7eae81e

Please sign in to comment.