@@ -4244,6 +4244,12 @@ AS_CASE([$MACHDEP],
4244
4244
[ SELECTMODULE_LIBS=""]
4245
4245
)
4246
4246
4247
+ dnl On MINGW, you need to link againt ole32, oleaut32 and uuid for ctypes
4248
+ AS_CASE ( [ $MACHDEP] ,
4249
+ [ win32] , [ CTYPES_LIBS="-lole32 -loleaut32 -luuid"] ,
4250
+ [ CTYPES_LIBS=""]
4251
+ )
4252
+
4247
4253
dnl detect sqlite3 from Emscripten emport
4248
4254
PY_CHECK_EMSCRIPTEN_PORT([ LIBSQLITE3] , [ -sUSE_SQLITE3] )
4249
4255
@@ -7927,7 +7933,7 @@ PY_STDLIB_MOD([_crypt],
7927
7933
[ $LIBCRYPT_CFLAGS] , [ $LIBCRYPT_LIBS] )
7928
7934
PY_STDLIB_MOD([ _ctypes] ,
7929
7935
[ ] , [ test "$have_libffi" = yes] ,
7930
- [ $NO_STRICT_OVERFLOW_CFLAGS $LIBFFI_CFLAGS] , [ $LIBFFI_LIBS] )
7936
+ [ $NO_STRICT_OVERFLOW_CFLAGS $LIBFFI_CFLAGS] , [ $LIBFFI_LIBS $CTYPES_LIBS ] )
7931
7937
PY_STDLIB_MOD([ _curses] ,
7932
7938
[ ] , [ test "$have_curses" != "no"] ,
7933
7939
[ $CURSES_CFLAGS] , [ $CURSES_LIBS]
@@ -7997,7 +8003,7 @@ PY_STDLIB_MOD([xxsubtype], [test "$TEST_MODULES" = yes])
7997
8003
PY_STDLIB_MOD([ _xxtestfuzz] , [ test "$TEST_MODULES" = yes] )
7998
8004
PY_STDLIB_MOD([ _ctypes_test] ,
7999
8005
[ test "$TEST_MODULES" = yes] , [ test "$have_libffi" = yes -a "$have_dynamic_loading" = yes] ,
8000
- [ ] , [ $LIBM] )
8006
+ [ ] , [ $LIBM $CTYPES_LIBS ] )
8001
8007
8002
8008
dnl Limited API template modules.
8003
8009
dnl The limited C API is not compatible with the Py_TRACE_REFS macro.
0 commit comments