History log of /sssd-io/src/util/sss_python.c
Revision Date Author Comments Expand
810935f67a25f130b37f72948cc9a8b37529afc1 18-Apr-2018 Lukas Slebodnik <lslebodn@redhat.com>

UTIL: Use alternative way for detecting PyErr_NewExceptionWithDoc Function PyErr_NewExceptionWithDoc was added in python 2.7.0 and we use fallback implementation for older versions of python. Previously, we used detection of PyErr_NewExceptionWithDoc at configure time; but it does not work well in case of python2.6 and python3.x Resolves: https://pagure.io/SSSD/sssd/issue/3656 Reviewed-by: Sumit Bose <sbose@redhat.com>

69fb159e1464ef91376f56e65afa9704d5bafad8 02-Jan-2017 Lukas Slebodnik <lslebodn@redhat.com>

Fix compilation with python3.6 Autotools does not generate defines in conditional way (ifndef .. define) and therefore it might happen that "defines" in config.h migt redefine some macros in different way and generate a warning. e.g. In file included from /home/build/sssd/src/util/util.h:24:0, from /home/build/sssd/src/python/pyhbac.c:24: ./config.h:322:0: error: "HAVE_LONG_LONG" redefined [-Werror] #define HAVE_LONG_LONG 1 In file included from /usr/include/python3.6m/Python.h:50:0, from /home/build/sssd/src/python/pyhbac.c:21: /usr/include/python3.6m/pyport.h:42:0: note: this is the location of the previous definition #define HAVE_LONG_LONG We need to include config.h before Python.h to avoid redefinition of HAVE_LONG_LONG which is definded conditionally in Python.h Reviewed-by: Jakub Hrozek <jhrozek@redhat.com>

e4796d5ed8e08be7f3767e12753389b18a2ce9f0 25-Feb-2015 Lukas Slebodnik <lslebodn@redhat.com>

UTIL: Remove python wrapper sss_python_unicode_from_string The function PyUnicode_FromString is available in python >= 2.6 Reviewed-by: Stephen Gallagher <sgallagh@redhat.com>

a63b368a025a61edf41a3d5ce34f325b03295cf6 25-Feb-2015 Lukas Slebodnik <lslebodn@redhat.com>

UTIL: Remove python wrapper sss_python_set_check The macro PySet_Check is defined in python >= 2.6 Reviewed-by: Stephen Gallagher <sgallagh@redhat.com>

887edd6b7c53fde44eb9f9060e09db5cd981ba37 25-Feb-2015 Lukas Slebodnik <lslebodn@redhat.com>

UTIL: Remove python wrapper sss_python_set_add The function PySet_Add is available in python >= 2.6 Reviewed-by: Stephen Gallagher <sgallagh@redhat.com>

9eabaad5e0f3f20a6bcec0629342584c244a79bc 25-Feb-2015 Lukas Slebodnik <lslebodn@redhat.com>

UTIL: Remove python wrapper sss_python_set_new The function PySet_New is available in python >= 2.6 Reviewed-by: Stephen Gallagher <sgallagh@redhat.com>

72e60fd4eabcfbcdbfe01e8c38b94052bc6c2067 13-Jul-2011 Jakub Hrozek <jhrozek@redhat.com>

Fix python HBAC bindings for python <= 2.4 Several parts of the HBAC python bindings did not work with old Python versions, such as the one shipped in RHEL5. The changes include: * a compatibility wrapper around python set object * PyModule_AddIntMacro compat macro * Py_ssize_t compat definition * Do not use PyUnicode_FromFormat * several function prototypes and structures used to have "char arguments where they have "const char *" in recent versions. This caused compilation warnings this patch mitigates by using the discard_const hack on python 2.4