Skip to content

Commit 26a31fd

Browse files
hpwxfRUrlus
authored andcommitted
Prevent useless link with pythonXX_d.lib in Debug mode
1 parent d68389a commit 26a31fd

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

include/carma_bits/cnalloc.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
#ifndef INCLUDE_CARMA_BITS_CNALLOC_H_
22
#define INCLUDE_CARMA_BITS_CNALLOC_H_
33

4+
// pybind11 include required even if not explicitly used
5+
// to prevent link with pythonXX_d.lib on Win32
6+
// (cf Py_DEBUG defined in numpy headers and https://github.com/pybind/pybind11/issues/1295)
7+
#include <pybind11/pybind11.h>
48
#define NPY_NO_DEPRECATED_API NPY_1_14_API_VERSION
59
#include <numpy/arrayobject.h>
610
#include <numpy/ndarraytypes.h>

0 commit comments

Comments
 (0)