mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-09 13:20:08 +02:00
36 lines
1.3 KiB
Plaintext
36 lines
1.3 KiB
Plaintext
From 1dd2496df06097bb05246b9d13595265854e6e85 Mon Sep 17 00:00:00 2001
|
|
From: begasus <begasus@gmail.com>
|
|
Date: Sat, 17 Sep 2022 15:03:47 +0200
|
|
Subject: numpy, fix build for scipy
|
|
|
|
|
|
diff --git a/numpy/core/include/numpy/npy_os.h b/numpy/core/include/numpy/npy_os.h
|
|
index 6d335f7..57740d3 100644
|
|
--- a/numpy/core/include/numpy/npy_os.h
|
|
+++ b/numpy/core/include/numpy/npy_os.h
|
|
@@ -27,6 +27,8 @@
|
|
#define NPY_OS_MINGW
|
|
#elif defined(__APPLE__)
|
|
#define NPY_OS_DARWIN
|
|
+#elif defined(__HAIKU__)
|
|
+ #define NPY_OS_HAIKU
|
|
#else
|
|
#define NPY_OS_UNKNOWN
|
|
#endif
|
|
diff --git a/numpy/f2py/cfuncs.py b/numpy/f2py/cfuncs.py
|
|
index 408587d..4a8aa0e 100644
|
|
--- a/numpy/f2py/cfuncs.py
|
|
+++ b/numpy/f2py/cfuncs.py
|
|
@@ -578,7 +578,7 @@ cppmacros["F2PY_THREAD_LOCAL_DECL"] = """\
|
|
&& (__STDC_VERSION__ >= 201112L) \\
|
|
&& !defined(__STDC_NO_THREADS__) \\
|
|
&& (!defined(__GLIBC__) || __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 12)) \\
|
|
- && !defined(NPY_OS_OPENBSD)
|
|
+ && !defined(NPY_OS_OPENBSD) && !defined(NPY_OS_HAIKU)
|
|
/* __STDC_NO_THREADS__ was first defined in a maintenance release of glibc 2.12,
|
|
see https://lists.gnu.org/archive/html/commit-hurd/2012-07/msg00180.html,
|
|
so `!defined(__STDC_NO_THREADS__)` may give false positive for the existence
|
|
--
|
|
2.36.1
|
|
|