py-xmlsec uses pkg-config to retrieve the CFLAGS required for compiling against libxmlsec1. It then marshalls them into an array for distutils.core.Extension to build and install the python module. However, it has a bug where by py-xmlsec's setup.py reads in a CFLAG define present on 64bit configurations of xmlsec1, which is only specified as "-DXMLSEC_NO_SIZE_T" by xmlsec1's pkg-config. It passes this to distutils as the tuple '(XMLSEC_NO_SIZE_T)', which is interpreted by distutils as being a CFLAG undefine, and is passed into the build phase as "-UXMLSEC_NO_SIZE_T". This causes missized structures to be passed between the two, leading very quickly to a seg fault. Fix: Replace security/py-xmlsec/files/patch-setup.py with attached patch (I hate patches of patches!) Patch attached with submission follows: How-To-Repeat: (on amd64) cd /usr/ports/security/py-xmlsec make clean all install echo -e "import xmlsec\nprint xmlsec.keyDataRsaId().getName()" | python - Segmentation fault: 11 (core dumped)
Responsible Changed From-To: freebsd-ports-bugs->freebsd-python freebsd-python@ wants this port PRs (via the GNATS Auto Assign Tool)
State Changed From-To: open->closed Committed, thanks!
pav 2009-01-11 15:03:34 UTC FreeBSD ports repository Modified files: security/py-xmlsec Makefile security/py-xmlsec/files patch-setup.py Log: - Fix runtime crash on 64 bit platforms PR: ports/127616 Submitted by: Tom Evans <tevans.uk@googlemail.com> Revision Changes Path 1.8 +1 -0 ports/security/py-xmlsec/Makefile 1.2 +12 -0 ports/security/py-xmlsec/files/patch-setup.py _______________________________________________ cvs-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/cvs-all To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"