Commit e1f9aa4e authored by Peter Eisentraut's avatar Peter Eisentraut

Change PyInit_plpy to external linkage

Module initialization functions in Python 3 must have external
linkage, because PyMODINIT_FUNC does dllexport on Windows-like
platforms.  Without this change, the build with Python 3 fails on
Windows.
parent f684bcb5
......@@ -4066,7 +4066,13 @@ PLy_add_exceptions(PyObject *plpy)
}
#if PY_MAJOR_VERSION >= 3
static PyMODINIT_FUNC
/*
* Must have external linkage, because PyMODINIT_FUNC does dllexport on
* Windows-like platforms.
*/
PyMODINIT_FUNC PyInit_plpy(void);
PyMODINIT_FUNC
PyInit_plpy(void)
{
PyObject *m;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment