Skip to content

Commit d1695f1

Browse files
committed
Use msvc major version
1 parent 71b0e9e commit d1695f1

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

include/pybind11/detail/internals.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -316,7 +316,11 @@ struct type_info {
316316
# if defined(__GXX_ABI_VERSION)
317317
# define PYBIND11_BUILD_ABI "_cxxabi" PYBIND11_TOSTRING(__GXX_ABI_VERSION)
318318
# elif defined(_MSC_VER) && defined(_MT)
319-
# define PYBIND11_BUILD_ABI "_mscver" PYBIND11_TOSTRING(_MSC_VER)
319+
# define PYBIND11_BUILD_ABI "_mt_mscver" PYBIND11_TOSTRING(_MSC_VER)
320+
# elif defined(_MSC_VER) && defined(_MD) && (_MSC_VER >= 1900) && (_MSC_VER < 2000)
321+
# define PYBIND11_BUILD_ABI "_md_mscver14"
322+
# elif defined(_MSC_VER) && defined(_MD)
323+
# define PYBIND11_BUILD_ABI "_md_mscver" PYBIND11_TOSTRING(_MSC_VER)
320324
# else
321325
# define PYBIND11_BUILD_ABI ""
322326
# endif

0 commit comments

Comments
 (0)