Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 148277 - dev-python/sip doesn't compile against Python 2.5
Summary: dev-python/sip doesn't compile against Python 2.5
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Python Gentoo Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: python-2.5 148396 148397
  Show dependency tree
 
Reported: 2006-09-19 20:32 UTC by Chris Connett
Modified: 2006-12-26 14:04 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
sip-4.3.2-python2.5.patch (sip-4.3.2-python2.5.patch,6.26 KB, text/plain)
2006-09-20 04:34 UTC, Krzysztof Pawlik (RETIRED)
Details
sip-4.3.2-python2.5.patch (sip-4.3.2-python2.5.patch,6.79 KB, text/plain)
2006-09-20 05:34 UTC, Krzysztof Pawlik (RETIRED)
Details
sip-4.2.1-python2.5.patch (sip-4.2.1-python2.5.patch,6.53 KB, patch)
2006-10-10 03:57 UTC, Peter Alexander
Details | Diff
sip 4.4.3 patch for python 2.5 (sip-4.4.3-python-2.5-compat.diff,5.90 KB, patch)
2006-11-01 13:16 UTC, Jimmy.Jazz
Details | Diff
sip-4.4.3.ebuild for python 2.5 (sip-4.4.3.ebuild,1.48 KB, text/plain)
2006-11-01 13:19 UTC, Jimmy.Jazz
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Connett 2006-09-19 20:32:50 UTC
dev-python/sip doesn't compile against Python 2.5.  Python 2.5 is installed via the ~amd64 keyword.

x86_64-pc-linux-gnu-gcc -c -pipe -O2 -march=k8 -pipe -fPIC -O2 -march=k8 -pipe -fno-strict-aliasing -w -D_REENTRANT -DSIP_QT_SUPPORT -DQT_NO_DEBUG -DQT_THREAD_SUPPORT -I. -I/usr/include/python2.5 -I/usr/qt/3/include -I/usr/X11R6/include -o siplib.o siplib.c
siplib.c: In function `initsip':
siplib.c:323: error: structure has no member named `type'
siplib.c: In function `sip_api_export_module':
siplib.c:728: error: structure has no member named `type'
siplib.c: In function `parsePass1':
siplib.c:1625: error: structure has no member named `type'
siplib.c:1625: error: structure has no member named `type'
siplib.c: In function `createType':
siplib.c:2492: error: structure has no member named `type'
siplib.c: In function `createEnum':
siplib.c:2561: error: structure has no member named `type'
siplib.c: In function `getSelfFromArgs':
siplib.c:2684: error: structure has no member named `type'
siplib.c:2684: error: structure has no member named `type'
siplib.c: In function `sip_api_add_class_instance':
siplib.c:3458: error: structure has no member named `type'
siplib.c: In function `convertSubClass':
siplib.c:3780: error: structure has no member named `type'
siplib.c:3780: error: structure has no member named `type'
siplib.c: In function `sipWrapperType_init':
siplib.c:4365: error: structure has no member named `type'
siplib.c:4374: error: structure has no member named `type'
siplib.c: In function `sipWrapperType_getattro':
siplib.c:4409: error: structure has no member named `type'
siplib.c: In function `sipWrapper_new':
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4624: error: structure has no member named `type'
siplib.c:4633: error: structure has no member named `type'
siplib.c: In function `initSlots':
siplib.c:5134: error: structure has no member named `type'
siplib.c:5135: error: structure has no member named `type'
siplib.c:5281: error: structure has no member named `type'
siplib.c:5282: error: structure has no member named `type'
siplib.c:5306: error: structure has no member named `type'
siplib.c:5307: error: structure has no member named `type'
siplib.c:5311: error: structure has no member named `type'
siplib.c:5312: error: structure has no member named `type'
siplib.c:5326: error: structure has no member named `type'
siplib.c:5327: error: structure has no member named `type'
make[1]: *** [siplib.o] Error 1
make[1]: Leaving directory `/var/tmp/portage/sip-4.3.2/work/sip-4.3.2/siplib'
make: *** [all] Error 2

!!! ERROR: dev-python/sip-4.3.2 failed.
Comment 1 Krzysztof Pawlik (RETIRED) gentoo-dev 2006-09-20 01:08:43 UTC
See also bug #136160
Comment 2 Krzysztof Pawlik (RETIRED) gentoo-dev 2006-09-20 04:34:45 UTC
Created attachment 97529 [details]
sip-4.3.2-python2.5.patch

This patch fixes compilation for >= Python 2.5 but breaks it for < Python 2.5. It has to be applied only if building for >=dev-lang/python-2.5. Complete ebuild is available here: http://overlays.gentoo.org/dev/nelchael/browser/dev-python/sip
Comment 3 Krzysztof Pawlik (RETIRED) gentoo-dev 2006-09-20 05:34:18 UTC
Created attachment 97537 [details]
sip-4.3.2-python2.5.patch

The fix should be included also in code that is emited by sip - this fixes packages that use sip (see bug #148336 for an example).
Comment 4 Lukasz Ligowski 2006-09-25 14:24:16 UTC
(In reply to comment #3)
> Created an attachment (id=97537) [edit]
> sip-4.3.2-python2.5.patch
> 
> The fix should be included also in code that is emited by sip - this fixes
> packages that use sip (see bug #148336 for an example).
> 

I have installed ebuild from overlay.
I am not sure where it belongs to but:

x86_64-pc-linux-gnu-g++ -c -pipe -march=k8 -mtune=athlon64 -O2 -pipe -ftree-loop-linear -ftracer -ftree-vectorize -fPIC -march=k8 -mtune=athlon64 -O2 -pipe -fno-strict-aliasing -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_THREAD_SUPPORT -I. -I/usr/include/python2.5 -I/usr/qt/3/include -I/usr/X11R6/include -o sipqtQString.o sipqtQString.cpp
sip/qt/qstringlist.sip: In function &#8216;PyObject* slot_QStringList___getitem__(PyObject*, PyObject*)&#8217;:
sip/qt/qstringlist.sip:189: error: cannot convert &#8216;int*&#8217; to &#8216;Py_ssize_t*&#8217; for argument &#8216;3&#8217; to &#8216;int PySlice_GetIndicesEx(PySliceObject*, Py_ssize_t, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*)&#8217;
sip/qt/qstringlist.sip: In function &#8216;int slot_QStringList___delitem__(PyObject*, PyObject*)&#8217;:
sip/qt/qstringlist.sip:161: error: cannot convert &#8216;int*&#8217; to &#8216;Py_ssize_t*&#8217; for argument &#8216;3&#8217; to &#8216;int PySlice_GetIndicesEx(PySliceObject*, Py_ssize_t, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*)&#8217;
sip/qt/qstringlist.sip: In function &#8216;int slot_QStringList___setitem__(PyObject*, PyObject*)&#8217;:
sip/qt/qstringlist.sip:118: error: cannot convert &#8216;int*&#8217; to &#8216;Py_ssize_t*&#8217; for argument &#8216;3&#8217; to &#8216;int PySlice_GetIndicesEx(PySliceObject*, Py_ssize_t, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*)&#8217;
make[1]: *** [sipqtQStringList.o] Error 1
make[1]: *** Waiting for unfinished jobs....
sip/qt/qstring.sip: In function &#8216;PyObject* slot_QString___getitem__(PyObject*, PyObject*)&#8217;:
sip/qt/qstring.sip:757: error: cannot convert &#8216;int*&#8217; to &#8216;Py_ssize_t*&#8217; for argument &#8216;3&#8217; to &#8216;int PySlice_GetIndicesEx(PySliceObject*, Py_ssize_t, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*)&#8217;
make[1]: *** [sipqtQString.o] Error 1
make[1]: Leaving directory `/var/tmp/portage/PyQt-3.15.1/work/PyQt-x11-gpl-3.15.1/qt'
make: *** [all] Error 2

!!! ERROR: dev-python/PyQt-3.15.1 failed.

Portage 2.1.1 (default-linux/amd64/2006.1, gcc-4.1.1/amd64-vanilla, glibc-2.4-r3, 2.6.17-gentoo-r4 x86_64)
=================================================================
System uname: 2.6.17-gentoo-r4 x86_64 AMD Turion(tm) 64 Mobile Technology ML-28
Gentoo Base System version 1.12.5
Last Sync: Mon, 25 Sep 2006 18:29:01 +0000
ccache version 2.3 [enabled]
app-admin/eselect-compiler: 2.0.0_rc2-r1
dev-java/java-config: 1.3.7, 2.0.30
dev-lang/python:     2.3.5-r2, 2.4.3-r1, 2.5-r1
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     2.3
dev-util/confcache:  0.4.2-r1
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.59-r7
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2
sys-devel/binutils:  2.16.1-r3
sys-devel/gcc-config: [Not Present]
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="amd64"
AUTOCLEAN="yes"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=k8 -mtune=athlon64 -O2 -pipe -ftree-loop-linear -ftracer -ftree-vectorize"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/eselect/compiler /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo"
CXXFLAGS="-march=k8 -mtune=athlon64 -O2 -pipe -ftree-loop-linear -ftracer -ftree-vectorize"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig ccache distlocks fixpackages metadata-transfer parallel-fetch sandbox sfperms strict userfetch"
GENTOO_MIRRORS="http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror/ ftp://linux.rz.ruhr-uni-bochum.de/gentoo-mirror/ http://pandemonium.tiscali.de/pub/gentoo/ ftp://pandemonium.tiscali.de/pub/gentoo/ http://mirror.gentoo.no/ "
LANG="pl_PL@euro"
LC_ALL="pl_PL.UTF-8"
LINGUAS="pl en"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude='/distfiles' --exclude='/local' --exclude='/packages'"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="amd64 X a52 aac aalib acl acpi alsa apache2 avi bash-completion bitmap-fonts blas bzip2 cairo cdparanoia cdr cli crypt cscope cups divx4linux dlloader doc dri dvd dvdr dvdread elibc_glibc emul-linux-x86 encode examples fam fastcgi ffmpeg fftw flac fortran freetype gdbm gif gpm gtk2 guile hal iconv imagemagick imap input_devices_keyboard input_devices_mouse input_devices_synaptics ipv6 isdnlog jabber jikes jpeg kde kdeenablefinal kdehiddenvisibility kernel_linux lapack libg++ linguas_en linguas_pl lm_sensors mad memlimit mime mmap mp3 mpeg mpi nas ncurses netcdf nls nptl nptlonly ogg opengl pcmcia pcre pdf perl php pic plotutils png posix postgres ppds pppd python qt qt4 quicktime readline reflection ruby samba sasl session slang slp source speex spell spl sqlite ssl svg tcpd tetex theora tiff truetype truetype-fonts type1-fonts udev unicode usb userland_GNU userlocales vcd video_cards_fglrx vorbis wifi wmf xcomposite xinerama xml xorg xpm xv xvid zlib"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LDFLAGS, PORTAGE_RSYNC_EXTRA_OPTS

Comment 5 Chris Smith 2006-10-09 11:57:00 UTC
Just to note that the patch allows sip to emerge with python-2.5 but PyQT still does not emerge (at least on amd64):

sip/qt/qstringlist.sip: In function &#8216;PyObject* slot_QStringList___getitem__(PyObject*, PyObject*)&#8217;:
sip/qt/qstringlist.sip:189: error: cannot convert &#8216;int*&#8217; to &#8216;Py_ssize_t*&#8217; for argument &#8216;3&#8217; to &#8216;int PySlice_GetIndicesEx(PySliceObject*, Py_ssize_t, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*)&#8217;
sip/qt/qstringlist.sip: In function &#8216;int slot_QStringList___delitem__(PyObject*, PyObject*)&#8217;:
sip/qt/qstringlist.sip:161: error: cannot convert &#8216;int*&#8217; to &#8216;Py_ssize_t*&#8217; for argument &#8216;3&#8217; to &#8216;int PySlice_GetIndicesEx(PySliceObject*, Py_ssize_t, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*)&#8217;
sip/qt/qstringlist.sip: In function &#8216;int slot_QStringList___setitem__(PyObject*, PyObject*)&#8217;:
sip/qt/qstringlist.sip:118: error: cannot convert &#8216;int*&#8217; to &#8216;Py_ssize_t*&#8217; for argument &#8216;3&#8217; to &#8216;int PySlice_GetIndicesEx(PySliceObject*, Py_ssize_t, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*)&#8217;
make[1]: *** [sipqtQStringList.o] Error 1
make[1]: *** Waiting for unfinished jobs....
sip/qt/qstring.sip: In function &#8216;PyObject* slot_QString___getitem__(PyObject*, PyObject*)&#8217;:
sip/qt/qstring.sip:757: error: cannot convert &#8216;int*&#8217; to &#8216;Py_ssize_t*&#8217; for argument &#8216;3&#8217; to &#8216;int PySlice_GetIndicesEx(PySliceObject*, Py_ssize_t, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*, Py_ssize_t*)&#8217;
make[1]: *** [sipqtQString.o] Error 1
make[1]: Leaving directory `/var/tmp/portage/PyQt-3.15.1/work/PyQt-x11-gpl-3.15.1/qt'
make: *** [all] Error 2
Comment 6 Peter Alexander 2006-10-10 03:57:46 UTC
Created attachment 99271 [details, diff]
sip-4.2.1-python2.5.patch
Comment 7 Chris Smith 2006-10-10 13:56:19 UTC
FYI
The current snapshot at http://www.riverbankcomputing.com/Downloads/Snapshots/sip4/ emerges fine and once installed the current snapshot of PyQt (PyQt3) will emerge fine as well (litte choice after the python upgrade - had to get Luma working again).

Chris
Comment 8 Chris Smith 2006-10-11 09:42:37 UTC
(In reply to comment #7)
> The current snapshot at
> http://www.riverbankcomputing.com/Downloads/Snapshots/sip4/ emerges fine and
> once installed the current snapshot of PyQt (PyQt3) will emerge fine as well
> (litte choice after the python upgrade - had to get Luma working again).

Except that luma (the app I need and the only one I have installed that depends on PyQt) doesn't really work with these versions:
------------------------------------------
$ luma
Could not parse template file
*** glibc detected *** python: free(): invalid pointer: 0x00002b6880809c38 ***
------------------------------------------

Luma opens and provides the "Could not parse template file" message. When I try to connect to an LDAP server the "glibc..." error occurs.
Comment 9 Carsten Lohrke (RETIRED) gentoo-dev 2006-10-22 08:59:31 UTC
Please test sip-4.2.1-r1 PyQt-3.14-r2 and kde-base/pykde-3.5.5-r1. Newer versions will be masked as soon as possible, until the next upcoming upstream releases. 

I'm not going to support (weekly) snapshot releases.
Comment 10 Chris Smith 2006-10-24 08:29:34 UTC
(In reply to comment #9)
> Please test sip-4.2.1-r1 PyQt-3.14-r2 and kde-base/pykde-3.5.5-r1. Newer
> versions will be masked as soon as possible, until the next upcoming upstream
> releases. 

sip-4.2.1-r1 and PyQt-3.14.1-r2 emerge fine but luma still throws the glibc error

Luma is supposedly pure python, could it cause this error? or is it something else with 64 bit/python-2.5 and sip/PyQt

Until the move to python-2.5 luma was working fine.

> I'm not going to support (weekly) snapshot releases.

Don't blame you there. I was just looking for something that would work.

Chris
Comment 11 Jimmy.Jazz 2006-11-01 13:16:32 UTC
Created attachment 100999 [details, diff]
sip 4.4.3 patch for python 2.5

from http://mats.gmd.de/pipermail/pykde/2006-July/013678.html
Comment 12 Jimmy.Jazz 2006-11-01 13:19:04 UTC
Created attachment 101002 [details]
sip-4.4.3.ebuild for python 2.5

hi,

a modified sip 4.4.3 ebuild for python 2.5

Jj
Comment 13 Caleb Tennis (RETIRED) gentoo-dev 2006-11-15 10:11:36 UTC
sip-4.5 is now in portage.  Can someone test that against python-2.5 (the changelog says it should work) and if so I can get to work on unmasking it and PyQt*
Comment 14 Caleb Tennis (RETIRED) gentoo-dev 2006-11-15 11:03:05 UTC
Chris: your problem can probably be fixed (read, ignored) by using the "MALLOC_CHECK_" environment variable and setting it to 0.  That will cause glibc to not bork when it see badly free'd code.   

Your problem, however, could be PyQt or just simply python related.  Hard to tell.

Anyway, I'm un package.masking sip since this version seems to work okay with Python 2.5.  I'll unmask PyQt once I get more information on if it works with the new sip and python 2.5 or not.
Comment 15 Chris Smith 2006-11-15 15:16:36 UTC
(In reply to comment #13)
> sip-4.5 is now in portage.  Can someone test that against python-2.5 (the
> changelog says it should work) and if so I can get to work on unmasking it and
> PyQt*
> 

Emerges fine here (however doesn't solve my luma issue).

Chris
Comment 16 Chris Smith 2006-11-15 15:20:19 UTC
(In reply to comment #14)
> Chris: your problem can probably be fixed (read, ignored) by using the
> "MALLOC_CHECK_" environment variable and setting it to 0.  That will cause
> glibc to not bork when it see badly free'd code.   

That does it allow it to run. Thx.
 
> Your problem, however, could be PyQt or just simply python related.  Hard to
> tell.

Luma ran fine with python 2.4.

Chris
Comment 17 Chris Smith 2006-11-15 15:41:29 UTC
(In reply to comment #16)
> (In reply to comment #14)
> > Chris: your problem can probably be fixed (read, ignored) by using the
> > "MALLOC_CHECK_" environment variable and setting it to 0.  That will cause
> > glibc to not bork when it see badly free'd code.   
> 
> That does it allow it to run. Thx.

Runs, but alas doesn't work properly.
Comment 18 Chris Smith 2006-11-29 16:23:37 UTC
FYI: the problem with luma was due to python-ldap. I upgraded to python-ldap-2.2.1 (for some reason not in portage yet), and it works fine now.

Chris
Comment 19 Tiziano Müller (RETIRED) gentoo-dev 2006-12-26 14:04:24 UTC
Well, sip-4.5.2 actually does and sip-4.4* isn't in the tree anymore. Therefore this bug seems to be fixed.