Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 297576 - emerge sys-libs/tdb-1.1.5-r1 failed. python3.1/pyconfig.h warning: "_POSIX_C_SOURCE" redefined, 'Py_TPFLAGS_HAVE_ITER' undeclared etc
Summary: emerge sys-libs/tdb-1.1.5-r1 failed. python3.1/pyconfig.h warning: "_POSIX_C_...
Status: RESOLVED DUPLICATE of bug 316959
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High major (vote)
Assignee: Patrick Lauer
URL:
Whiteboard:
Keywords:
: 326169 347858 348662 (view as bug list)
Depends on:
Blocks:
 
Reported: 2009-12-19 21:24 UTC by Vitaly A. Repin
Modified: 2010-12-25 15:16 UTC (History)
4 users (show)

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


Attachments
emerge --info =sys-libs/tdb-1.1.5-r1 (info,4.25 KB, text/plain)
2009-12-19 21:25 UTC, Vitaly A. Repin
Details
Build log (build.log,21.61 KB, text/plain)
2009-12-19 21:28 UTC, Vitaly A. Repin
Details
emerge --info (info,3.90 KB, text/plain)
2009-12-19 21:29 UTC, Vitaly A. Repin
Details
Ebuild which forces python version (tdb-1.2.1-r1.ebuild,2.12 KB, text/plain)
2010-11-30 16:13 UTC, John Keeping
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Vitaly A. Repin 2009-12-19 21:24:37 UTC
emerge tdb

 * Messages for package sys-libs/tdb-1.1.5-r1:

 * ERROR: sys-libs/tdb-1.1.5-r1 failed:
 *   emake shared-build failed
 *
 * Call stack:
 *     ebuild.sh, line  61:  Called src_compile
 *   environment, line 3062:  Called die
 * The specific snippet of code:
 *       emake shared-build || die "emake shared-build failed";


The last messages:

i686-pc-linux-gnu-gcc -fPIC -c ./pytdb.c -I./include -Iinclude  -O2 -march=i686 -pipe -I./libreplace `/usr/bin/python-config --cflags`                                      
In file included from /usr/include/python3.1/Python.h:8,                                                                                                                    
                 from ./pytdb.c:30:                                                                                                                                         
/usr/include/python3.1/pyconfig.h:1111:1: warning: "_POSIX_C_SOURCE" redefined                                                                                              
In file included from /usr/include/stdio.h:28,                                                                                                                              
                 from ./libreplace/replace.h:39,                                                                                                                            
                 from ./pytdb.c:27:                                                                                                                                         
/usr/include/features.h:158:1: warning: this is the location of the previous definition                                                                                     
In file included from /usr/include/python3.1/Python.h:8,                                                                                                                    
                 from ./pytdb.c:30:                                                                                                                                         
/usr/include/python3.1/pyconfig.h:1133:1: warning: "_XOPEN_SOURCE" redefined                                                                                                
In file included from /usr/include/stdio.h:28,                                                                                                                              
                 from ./libreplace/replace.h:39,                                                                                                                            
                 from ./pytdb.c:27:                                                                                                                                         
/usr/include/features.h:160:1: warning: this is the location of the previous definition                                                                                     
./pytdb.c: In function 'PyString_FromTDB_DATA':                                                                                                                             
./pytdb.c:66: warning: initialization makes pointer from integer without a cast                                                                                             
./pytdb.c: In function 'obj_get_hash_size':                                                                                                                                 
./pytdb.c:362: warning: return makes pointer from integer without a cast                                                                                                    
./pytdb.c: In function 'obj_get_map_size':                                                                                                                                  
./pytdb.c:375: warning: return makes pointer from integer without a cast                                                                                                    
./pytdb.c: In function 'obj_get_flags':                                                                                                                                     
./pytdb.c:380: warning: return makes pointer from integer without a cast                                                                                                    
./pytdb.c: In function 'obj_get_filename':                                                                                                                                  
./pytdb.c:385: warning: return makes pointer from integer without a cast                                                                                                    
./pytdb.c: In function 'tdb_object_repr':                                                                                                                                   
./pytdb.c:399: warning: return makes pointer from integer without a cast                                                                                                    
./pytdb.c: At top level:                                                                                                                                                    
./pytdb.c:475: error: 'Py_TPFLAGS_HAVE_ITER' undeclared here (not in a function)                                                                                            
./pytdb.c: In function 'inittdb':                                                                                                                                           
./pytdb.c:495: warning: assignment makes pointer from integer without a cast                                                                                                
./pytdb.c:499: warning: passing argument 3 of 'PyModule_AddObject' makes pointer from integer without a cast                                                                
/usr/include/python3.1/modsupport.h:40: note: expected 'struct PyObject *' but argument is of type 'int'                                                                    
./pytdb.c:500: warning: passing argument 3 of 'PyModule_AddObject' makes pointer from integer without a cast                                                                
/usr/include/python3.1/modsupport.h:40: note: expected 'struct PyObject *' but argument is of type 'int'                                                                    
./pytdb.c:501: warning: passing argument 3 of 'PyModule_AddObject' makes pointer from integer without a cast                                                                
/usr/include/python3.1/modsupport.h:40: note: expected 'struct PyObject *' but argument is of type 'int'                                                                    
./pytdb.c:503: warning: passing argument 3 of 'PyModule_AddObject' makes pointer from integer without a cast                                                                
/usr/include/python3.1/modsupport.h:40: note: expected 'struct PyObject *' but argument is of type 'int'                                                                    
./pytdb.c:504: warning: passing argument 3 of 'PyModule_AddObject' makes pointer from integer without a cast
/usr/include/python3.1/modsupport.h:40: note: expected 'struct PyObject *' but argument is of type 'int'
./pytdb.c:505: warning: passing argument 3 of 'PyModule_AddObject' makes pointer from integer without a cast
/usr/include/python3.1/modsupport.h:40: note: expected 'struct PyObject *' but argument is of type 'int'
./pytdb.c:506: warning: passing argument 3 of 'PyModule_AddObject' makes pointer from integer without a cast
/usr/include/python3.1/modsupport.h:40: note: expected 'struct PyObject *' but argument is of type 'int'
./pytdb.c:507: warning: passing argument 3 of 'PyModule_AddObject' makes pointer from integer without a cast
/usr/include/python3.1/modsupport.h:40: note: expected 'struct PyObject *' but argument is of type 'int'
./pytdb.c:508: warning: passing argument 3 of 'PyModule_AddObject' makes pointer from integer without a cast
/usr/include/python3.1/modsupport.h:40: note: expected 'struct PyObject *' but argument is of type 'int'
./pytdb.c:509: warning: passing argument 3 of 'PyModule_AddObject' makes pointer from integer without a cast
/usr/include/python3.1/modsupport.h:40: note: expected 'struct PyObject *' but argument is of type 'int'
./pytdb.c:510: warning: passing argument 3 of 'PyModule_AddObject' makes pointer from integer without a cast
/usr/include/python3.1/modsupport.h:40: note: expected 'struct PyObject *' but argument is of type 'int'
make: *** [pytdb.o] Error 1


Reproducible: Always

Steps to Reproduce:
Try to emerge tdb

Actual Results:  
It fails

Expected Results:  
Emerge is successfull

Can not complete update of python because of this issue
Comment 1 Vitaly A. Repin 2009-12-19 21:25:38 UTC
Created attachment 213499 [details]
emerge --info =sys-libs/tdb-1.1.5-r1
Comment 2 Vitaly A. Repin 2009-12-19 21:28:23 UTC
Created attachment 213500 [details]
Build log
Comment 3 Vitaly A. Repin 2009-12-19 21:29:57 UTC
Created attachment 213501 [details]
emerge --info
Comment 4 Johan Bergström 2009-12-19 23:26:25 UTC
Does it compile on Python 2.x? In that case this thing needs to mask against Python 3.x. By the way, tdb 1.2 is out. Probably still won't support Py3 but still…
Comment 5 Vitaly A. Repin 2009-12-19 23:48:02 UTC
(In reply to comment #4)
> Does it compile on Python 2.x? 

I suppose yes, as the library was installed before I have upgraded python.
How can I check this?

> Python 3.x. By the way, tdb 1.2 is out.

Not in gentoo yet?  I just have done "emerge --sync" and do not see it there.  only 1.1.5-r1.

> Probably still won't support Py3 but still…

Any idea for workaround?  I am not python guy.  I just want my bittorrent client to work again :-) 

Comment 6 Johan Bergström 2009-12-21 11:08:45 UTC
(In reply to comment #5)
> (In reply to comment #4)
> > Does it compile on Python 2.x? 
> 
> I suppose yes, as the library was installed before I have upgraded python.
> How can I check this?
> 
> > Python 3.x. By the way, tdb 1.2 is out.
> 
> Not in gentoo yet?  I just have done "emerge --sync" and do not see it there. 
> only 1.1.5-r1.
> 
> > Probably still won't support Py3 but still…
> 
> Any idea for workaround?  I am not python guy.  I just want my bittorrent
> client to work again :-) 
> 

Vitaly: Everything in my comment wasn't directed towards you :-) Patrick/the python herd will fix this when they have the time.
Comment 7 Patrick Lauer gentoo-dev 2010-01-04 18:20:42 UTC
Ah. Stupid package uses python-config directly, so it will pick up the system python by default. I see no easy way to fix this, so for now I'll just say "don't do that then" and think of non-violent ways to make it work.
Comment 8 Rafał Mużyło 2010-06-29 15:40:34 UTC
*** Bug 326169 has been marked as a duplicate of this bug. ***
Comment 9 rebel 2010-07-08 13:03:46 UTC
still no solution ?
Comment 10 rebel 2010-07-08 13:20:08 UTC
hmm ..
eselect python set 1
emerge tdb ..

thx
Comment 11 John Keeping 2010-11-30 16:13:58 UTC
Created attachment 255961 [details]
Ebuild which forces python version

This updated ebuild passes PYTHON and PYTHON_CONFIG to tdb's configure script so that it used the values we tell it to instead of searching its list.

I've tested this with both python 2.7 and python 3.1 set as my system python and it works for me, although I suspect that there's a better way of getting the path to the correct python-config script.
Comment 12 Matthias Liebig 2010-12-06 00:08:12 UTC
*** Bug 347858 has been marked as a duplicate of this bug. ***
Comment 13 Rafał Mużyło 2010-12-13 22:41:49 UTC
*** Bug 348662 has been marked as a duplicate of this bug. ***
Comment 14 Arfrever Frehtes Taifersar Arahesis (RETIRED) gentoo-dev 2010-12-25 15:16:23 UTC

*** This bug has been marked as a duplicate of bug 316959 ***