In python 3, itertools is a builtin module, so whether or not the
python you link against is a shared or a static one, importing it
works.
Change the import test to use ctypes which is a dynamic module in both
python 2 and 3.
gdb/ChangeLog:
PR python/26832
* configure: Regenerate.
* configure.ac: Check for python modules ctypes instead of
itertools.
+2020-11-06 Romain Geissler <romain.geissler@amadeus.com>
+
+ PR python/26832
+ * configure: Regenerate.
+ * configure.ac: Check for python modules ctypes instead of
+ itertools.
+
2020-11-06 Pedro Alves <pedro@palves.net>
* macroexp.c (struct macro_buffer): Split in two classes. Add
{
int err;
Py_Initialize ();
- err = PyRun_SimpleString ("import itertools\n");
+ err = PyRun_SimpleString ("import ctypes\n");
Py_Finalize ();
return err == 0 ? 0 : 1;
;
[#include "Python.h"],
[int err;
Py_Initialize ();
- err = PyRun_SimpleString ("import itertools\n");
+ err = PyRun_SimpleString ("import ctypes\n");
Py_Finalize ();
return err == 0 ? 0 : 1;])],
[dynamic_list=true], [], [true])