10000 BUG: Fixes for building on Cygwin. by DWesl · Pull Request #16246 · numpy/numpy · GitHub
[go: up one dir, main page]

Skip to content

BUG: Fixes for building on Cygwin. #16246

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 32 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
46409ed
BLD: Move the configuration defines in Python.h earlier.
DWesl May 14, 2020
058cfa1
DEV: Try to rebase f2py-created modules for fewer fork() failures in …
DWesl May 14, 2020
5c9f8a0
TST: Mark the tests that seem to fail due to different floating-point…
DWesl May 14, 2020
973b14b
TST: Try to mark the tests still suseptible to fork() failures on cyg…
DWesl May 14, 2020
acea157
DEV: Revert executable renames for F77/G77 compiler.
DWesl May 18, 2020
34184fd
BLD: Add functions that fail tests on Cygwin to npy_config.h.
DWesl May 18, 2020
9c07574
TST: Describe what I know about the FPE test failure.
DWesl May 18, 2020
df5b0c6
STY: A few largely cosmetic changes.
DWesl May 18, 2020
8b11932
DEV: Stop trying to rebase f2py modules.
DWesl May 18, 2020
fc56c79
Remove xfails from tests that now pass.
DWesl May 19, 2020
8000
10dae6e
Use parametrize for the dtypes in the abs tests.
DWesl May 19, 2020
debf846
Remove xfail mark from an assert function.
DWesl May 20, 2020
b530f99
Remove references to np.complex256
DWesl May 25, 2020
c11ee6f
Remove reference to np.complex256 in the other test
DWesl May 25, 2020
1a2292f
Don't add `gfortran` to the list of GNU77 compilers
DWesl May 29, 2020
20df822
Include only 'gfortran' in gnu fcompiler, not absolute version
DWesl Jun 6, 2020
52b9ed5
Merge branch 'master' into cygwin-fixes
DWesl Jul 9, 2020
6a16452
TST: Use usual names for the dtypes in xfail mark
DWesl Jul 9, 2020
92eaff3
BLD: Remind GCC that .seh_savexmm fails for xmm16-31.
DWesl Jun 17, 2020
d9c21bb
BLD: Fix code checking for old GCC on cygwin.
DWesl Jun 19, 2020
eca1e27
TST: Only mark fork()-using tests xfail on 32-bit cygwin.
DWesl Jun 19, 2020
6ffbcb2
BLD: Fix flags added to compiler line for old GCC on MS.
DWesl Jun 19, 2020
5adbca1
TST: parametrize test_npymath_complex.
DWesl Jul 9, 2020
51fbbb8
TST: Clarify the xfail messages for branch cuts.
DWesl Aug 29, 2020
f47f315
BLD: Remove probably-unnecessary include.
DWesl Aug 29, 2020
5cb8a0f
TST: Try to keep testing code from changing tempfile name.
DWesl Aug 23, 2020
ced41b5
BLD: Mark modfl as problematic on cygwin.
DWesl Aug 29, 2020
d706499
Undef HAVE_MODFL only on 64-bit cygwin
DWesl Sep 1, 2020
160fd73
Revert "BLD: Fix flags added to compiler line for old GCC on MS."
DWesl Oct 27, 2020
cc9e8df
Revert "BLD: Fix code checking for old GCC on cygwin."
DWesl Oct 27, 2020
e18c4b6
Revert "BLD: Remind GCC that .seh_savexmm fails for xmm16-31."
DWesl Oct 27, 2020
4abffbd
Merge branch 'master' into cygwin-fixes
charris Dec 31, 2020
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
Prev Previous commit
Next Next commit
TST: Only mark fork()-using tests xfail on 32-bit cygwin.
The problem seems to have gone away on 64-bit.
  • Loading branch information
DWesl committed Jul 9, 2020
commit eca1e273d4501ecbdb3749c718dcd61ed36c25cb
7 changes: 4 additions & 3 deletions numpy/f2py/tests/test_compile_function.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import numpy.f2py

from numpy.testing import assert_equal
from numpy.testing._private.utils import IS_32BIT_CYGWIN
from . import util


Expand All @@ -26,7 +27,7 @@ def setup_module():
"extra_args", [['--noopt', '--debug'], '--noopt --debug', '']
)
@pytest.mark.leaks_references(reason="Imported module seems never deleted.")
@pytest.mark.xfail(sys.platform == 'cygwin', reason="Random fork failures",
@pytest.mark.xfail(IS_32BIT_CYGWIN, reason="Random fork failures",
raises=BlockingIOError)
def test_f2py_init_compile(extra_args):
# flush through the f2py __init__ compile() function code path as a
Expand Down Expand Up @@ -85,7 +86,7 @@ def test_f2py_init_compile(extra_args):
del sys.modules[modname]


@pytest.mark.xfail(sys.platform == 'cygwin', reason="Random fork failures",
@pytest.mark.xfail(IS_32BIT_CYGWIN, reason="Random fork failures",
raises=BlockingIOError)
def test_f2py_init_compile_failure():
# verify an appropriate integer status value returned by
Expand Down Expand Up @@ -115,7 +116,7 @@ def test_f2py_init_compile_bad_cmd():
@pytest.mark.parametrize('fsource',
['program test_f2py\nend program test_f2py',
b'program test_f2py\nend program test_f2py',])
@pytest.mark.xfail(sys.platform == 'cygwin', reason="Random fork failures",
@pytest.mark.xfail(IS_32BIT_CYGWIN, reason="Random fork failures",
raises=BlockingIOError)
def test_compile_from_strings(tmpdir, fsource):
# Make sure we can compile str and bytes gh-12796
Expand Down
3 changes: 2 additions & 1 deletion numpy/f2py/tests/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@

from numpy.compat import asbytes, asstr
from numpy.testing import temppath
from numpy.testing._private.utils import IS_32BIT_CYGWIN
from importlib import import_module

from hashlib import md5
Expand Down Expand Up @@ -322,7 +323,7 @@ class F2PyTest:
# Pytest seems to ignore this, but I'm not sure where else to put
# it, besides trying to make a metaclass that decorates every
# method of a subclass of F2PyTest
@pytest.mark.xfail(sys.platform == 'cygwin',
@pytest.mark.xfail(IS_32BIT_CYGWIN,
reason='Fork() randomly fails on cygwin',
raises=BlockingIOError)
def setup(self):
Expand Down
3 changes: 2 additions & 1 deletion numpy/random/tests/test_extending.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import sys
import warnings
import numpy as np
from numpy.testing._private.utils import IS_32BIT_CYGWIN

try:
import cffi
Expand Down Expand Up @@ -42,7 +43,7 @@

@pytest.mark.skipif(cython is None, reason="requires cython")
@pytest.mark.slow
@pytest.mark.xfail(sys.platform == "cygwin",
@pytest.mark.xfail(IS_32BIT_CYGWIN,
reason="Random fork() failures",
raises=BlockingIOError)
def test_cython(tmp_path):
Expand Down
3 changes: 2 additions & 1 deletion numpy/testing/_private/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
'SkipTest', 'KnownFailureException', 'temppath', 'tempdir', 'IS_PYPY',
'HAS_REFCOUNT', 'suppress_warnings', 'assert_array_compare',
'_assert_valid_refcount', '_gen_alignment_data', 'assert_no_gc_cycles',
'break_cycles', 'HAS_LAPACK64'
'break_cycles', 'HAS_LAPACK64', 'IS_32BIT_CYGWIN'
]


Expand All @@ -48,6 +48,7 @@ class KnownFailureException(Exception):
verbose = 0

IS_PYPY = platform.python_implementation() == 'PyPy'
IS_32BIT_CYGWIN = (sys.platform == 'cygwin' and (sys.maxsize >> 30) == 1)
HAS_REFCOUNT = getattr(sys, 'getrefcount', None) is not None
HAS_LAPACK64 = numpy.linalg.lapack_lite._ilp64

Expand Down
3 changes: 2 additions & 1 deletion numpy/tests/test_public_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

import numpy as np
import numpy
from numpy.testing._private.utils import IS_32BIT_CYGWIN
import pytest

try:
Expand Down Expand Up @@ -77,7 +78,7 @@ def test_numpy_namespace():


@pytest.mark.parametrize('name', ['testing', 'Tester'])
@pytest.mark.xfail(sys.platform == 'cygwin', reason="Random fork failures",
@pytest.mark.xfail(IS_32BIT_CYGWIN, reason="Random fork failures",
raises=BlockingIOError)
def test_import_lazy_import(name):
"""Make sure we can actually use the modules we lazy load.
Expand Down
3 changes: 2 additions & 1 deletion numpy/tests/test_scripts.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@

import numpy as np
from numpy.testing import assert_equal
from numpy.testing._private.utils import IS_32BIT_CYGWIN

is_inplace = isfile(pathjoin(dirname(np.__file__), '..', 'setup.py'))

Expand Down Expand Up @@ -41,7 +42,7 @@ def test_f2py(f2py_cmd):
assert_equal(stdout.strip(), b'2')


@pytest.mark.xfail(sys.platform == 'cygwin', reason="Random fork failures",
@pytest.mark.xfail(IS_32BIT_CYGWIN, reason="Random fork failures",
raises=BlockingIOError)
def test_pep338():
stdout = subprocess.check_output([sys.executable, '-mnumpy.f2py', '-v'])
Expand Down
0