Skip to content

Commit

Permalink
Merge pull request #20293 from charris/backport-20270
Browse files Browse the repository at this point in the history
BUG: Fix headers for universal2 builds
  • Loading branch information
charris committed Nov 4, 2021
2 parents acbbf1a + 3a7424d commit b134e90
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions numpy/core/include/numpy/numpyconfig.h
Expand Up @@ -19,6 +19,19 @@
#define NPY_SIZEOF_LONG 4
#define NPY_SIZEOF_PY_INTPTR_T 4
#endif

#undef NPY_SIZEOF_LONGDOUBLE
#undef NPY_SIZEOF_COMPLEX_LONGDOUBLE

#ifdef __x86_64
#define NPY_SIZEOF_LONGDOUBLE 16
#define NPY_SIZEOF_COMPLEX_LONGDOUBLE 32
#elif defined(__arm64__)
#define NPY_SIZEOF_LONGDOUBLE 8
#define NPY_SIZEOF_COMPLEX_LONGDOUBLE 16
#else
#error "unknown architecture"
#endif
#endif

/**
Expand Down

0 comments on commit b134e90

Please sign in to comment.