summaryrefslogtreecommitdiff
path: root/numpy/distutils/command/config.py
diff options
context:
space:
mode:
Diffstat (limited to 'numpy/distutils/command/config.py')
-rw-r--r--numpy/distutils/command/config.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/numpy/distutils/command/config.py b/numpy/distutils/command/config.py
index bfc3a20e9..b88741e88 100644
--- a/numpy/distutils/command/config.py
+++ b/numpy/distutils/command/config.py
@@ -126,6 +126,13 @@ int main()
body = []
if decl:
body.append("int %s ();" % func)
+ # Handle MSVC intrisincs: force MS compiler to make a function call.
+ # Useful to test for some functions when built with optimization on, to
+ # avoid build error because the intrisinc and our 'fake' test
+ # declaration do not match.
+ body.append("#ifdef _MSC_VER")
+ body.append("#define function(%s)" % func)
+ body.append("#endif")
body.append("int main (void) {")
if call:
if call_args is None: