summaryrefslogtreecommitdiff
path: root/dbus_glib_bindings
diff options
context:
space:
mode:
authorSimon McVittie <smcv@collabora.com>2021-09-14 16:48:18 +0100
committerSimon McVittie <smcv@collabora.com>2021-09-15 18:49:14 +0100
commit98cbe2b3ace53ef70738345548402cb4e74a4db7 (patch)
tree8214142a629fc4d45b0fc647860b7ae4bd6b9776 /dbus_glib_bindings
parentabd5b946bb2ca9b6c4d2f5e455aaaae5f38946c6 (diff)
Remove support for Python 2
Python 2 reached EOL on 2020-01-01, and the latest version of AX_PYTHON_DEVEL breaks the build with Python 2. This seems as good a time as any to drop compatibility. Signed-off-by: Simon McVittie <smcv@collabora.com>
Diffstat (limited to 'dbus_glib_bindings')
-rw-r--r--dbus_glib_bindings/module.c17
1 files changed, 0 insertions, 17 deletions
diff --git a/dbus_glib_bindings/module.c b/dbus_glib_bindings/module.c
index 6614394..8b04eef 100644
--- a/dbus_glib_bindings/module.c
+++ b/dbus_glib_bindings/module.c
@@ -29,11 +29,7 @@
#include <dbus/dbus-python.h>
#include <dbus-gmain/dbus-gmain.h>
-#ifdef PY3
PyMODINIT_FUNC PyInit__dbus_glib_bindings(void);
-#else
-PyMODINIT_FUNC init_dbus_glib_bindings(void);
-#endif
#if defined(__GNUC__)
# if __GNUC__ >= 3
@@ -175,7 +171,6 @@ static PyMethodDef module_functions[] = {
{NULL, NULL, 0, NULL}
};
-#ifdef PY3
PyMODINIT_FUNC
PyInit__dbus_glib_bindings(void)
{
@@ -201,17 +196,5 @@ PyInit__dbus_glib_bindings(void)
}
return this_module;
}
-#else
-PyMODINIT_FUNC
-init_dbus_glib_bindings(void)
-{
- PyObject *this_module;
-
- if (import_dbus_bindings("_dbus_glib_bindings") < 0) return;
- this_module = Py_InitModule3 ("_dbus_glib_bindings", module_functions,
- module_doc);
- if (!this_module) return;
-}
-#endif
/* vim:set ft=c cino< sw=4 sts=4 et: */