Public bug reported: gcc and g++ interprets pyport.h in different way.
``` (system) inada-n@oldbench:~$ cat longbits.c #include <Python.h> #include <longintrepr.h> int main() { printf("digit bits = %d\n", PYLONG_BITS_IN_DIGIT); printf("sizeof(digit) = %lu\n", sizeof(digit)); } (system) inada-n@oldbench:~$ gcc longbits.c -I /usr/include/python2.7/ (system) inada-n@oldbench:~$ ./a.out digit bits = 30 sizeof(digit) = 4 (system) inada-n@oldbench:~$ g++ longbits.c -I /usr/include/python2.7/ (system) inada-n@oldbench:~$ ./a.out digit bits = 15 sizeof(digit) = 2 ``` This breaks some extension modules. For example, see https://github.com/msgpack/msgpack-python/issues/169 Please backport this bugfix. https://github.com/python/cpython/commit/050ba5ec1e941e05607ef29049bde08798387bcc ** Affects: python2.7 (Ubuntu) Importance: Undecided Status: New -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to python2.7 in Ubuntu. https://bugs.launchpad.net/bugs/1545899 Title: PYLONG_BITS_IN_DIGIT is misconfigured on g++ Status in python2.7 package in Ubuntu: New Bug description: gcc and g++ interprets pyport.h in different way. ``` (system) inada-n@oldbench:~$ cat longbits.c #include <Python.h> #include <longintrepr.h> int main() { printf("digit bits = %d\n", PYLONG_BITS_IN_DIGIT); printf("sizeof(digit) = %lu\n", sizeof(digit)); } (system) inada-n@oldbench:~$ gcc longbits.c -I /usr/include/python2.7/ (system) inada-n@oldbench:~$ ./a.out digit bits = 30 sizeof(digit) = 4 (system) inada-n@oldbench:~$ g++ longbits.c -I /usr/include/python2.7/ (system) inada-n@oldbench:~$ ./a.out digit bits = 15 sizeof(digit) = 2 ``` This breaks some extension modules. For example, see https://github.com/msgpack/msgpack-python/issues/169 Please backport this bugfix. https://github.com/python/cpython/commit/050ba5ec1e941e05607ef29049bde08798387bcc To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/python2.7/+bug/1545899/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp