Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 192898 - alsa-lib-1.0.15_rc2 fails to compile - Python.h: No such file or directory
Summary: alsa-lib-1.0.15_rc2 fails to compile - Python.h: No such file or directory
Status: RESOLVED DUPLICATE of bug 188029
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo ALSA team
URL:
Whiteboard:
Keywords:
: 193130 193407 194460 195972 197463 206480 211090 213816 (view as bug list)
Depends on:
Blocks:
 
Reported: 2007-09-18 07:33 UTC by ierdnah
Modified: 2008-06-07 13:14 UTC (History)
14 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description ierdnah 2007-09-18 07:33:28 UTC
/bin/sh ../../../libtool --tag=CC --mode=compile i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../../include -I../../../include   -g -O2 -W -Wall -O3 -march=prescott -mtune=prescott -mfpmath=sse -pipe -fomit-frame-pointer -ffast-math -c -o hda.lo hda.c
 i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../../include -I../../../include -g -O2 -W -Wall -O3 -march=prescott -mtune=prescott -mfpmath=sse -pipe -fomit-frame-pointer -ffast-math -c sbase.c -o sbase.o >/dev/null 2>&1
/bin/sh ../../../libtool --tag=CC --mode=compile i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../../include -I../../../include   -lpython2.4 -lm -L/usr/lib/python2.4/config  -O3 -march=prescott -mtune=prescott -mfpmath=sse -pipe -fomit-frame-pointer -ffast-math -c -o smixer_python_la-python.lo `test -f 'python.c' || echo './'`python.c
 i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../../include -I../../../include -g -O2 -W -Wall -O3 -march=prescott -mtune=prescott -mfpmath=sse -pipe -fomit-frame-pointer -ffast-math -c hda.c  -fPIC -DPIC -o .libs/hda.o
 i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../../include -I../../../include -g -O2 -W -Wall -O3 -march=prescott -mtune=prescott -mfpmath=sse -pipe -fomit-frame-pointer -ffast-math -c hda.c -o hda.o >/dev/null 2>&1
 i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../../include -I../../../include -lpython2.4 -lm -L/usr/lib/python2.4/config -O3 -march=prescott -mtune=prescott -mfpmath=sse -pipe -fomit-frame-pointer -ffast-math -c python.c  -fPIC -DPIC -o .libs/smixer_python_la-python.o
python.c:22:20: error: Python.h: No such file or directory
python.c:30: error: expected specifier-qualifier-list before 'PyObject'
python.c:38: error: expected specifier-qualifier-list before 'PyObject_HEAD'
python.c:45: error: expected specifier-qualifier-list before 'PyObject_HEAD'
python.c:57: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
python.c:59: error: expected ')' before '*' token
python.c: In function 'melem_to_pymelem':
python.c:77: error: 'struct pymelem' has no member named 'selem'
python.c: At top level:
python.c:80: error: expected declaration specifiers or '...' before 'PyObject'
python.c:80: error: expected declaration specifiers or '...' before 'PyObject'
python.c: In function 'pcall':
python.c:82: error: 'PyObject' undeclared (first use in this function)
python.c:82: error: (Each undeclared identifier is reported only once
python.c:82: error: for each function it appears in.)
python.c:82: error: 'obj' undeclared (first use in this function)
python.c:82: error: expected expression before ')' token
python.c:85: error: '_res' undeclared (first use in this function)

installed python version: dev-lang/python-2.4.4-r4
ierdnac ~ # emerge -pv python

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild   R   ] dev-lang/python-2.4.4-r4  USE="berkdb gdbm ncurses readline ssl tk -bootstrap -build -doc -examples -ipv6 -nocxx -nothreads -ucs2" 7,976 kB

Total: 1 package (1 reinstall), Size of downloads: 7,976 kB


ierdnac ~ # emerge -pv alsa-lib

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild     U ] media-libs/alsa-lib-1.0.15_rc2 [1.0.14a-r1] USE="midi -alisp -debug -doc" ALSA_PCM_PLUGINS="adpcm alaw copy dshare dsnoop extplug file hooks ladspa lfloat linear meter mulaw multi null rate route share shm (-asym%*) (-dmix%*) (-empty%*) (-iec958%*) (-ioplug%*) (-plug%*) (-softvol%*)" 0 kB

Total: 1 package (1 upgrade), Size of downloads: 0 kB
ierdnac ~ #                                                          

Reproducible: Always
Comment 1 Michele Martone 2007-09-18 08:17:21 UTC
(In reply to comment #0)
>  ...
Hello.
seems like I have this problem, too.
It appears like the include file for python (Python.h) is not found.
However, I have it, like you probably too.
So, I executed the "python-config --includes" program, and it produced :

-lpython2.4 -lm -L/usr/lib/python2.4/config

without adding the necessary -I/usr/include/python2.4/ .

For experiment, I added -I/usr/include/python2.4/ at line 360 of the configure.in file:
    PYTHON_INCDIR="$pythonincdir -I/usr/include/python2.4/"
and resulted in a clean make.

Comment 2 Stefan Wimmer 2007-09-18 08:31:00 UTC
Same here on 4 different PC's:

* Linux PC1 2.6.22-gentoo-r4 #2 SMP PREEMPT Fri Aug 17 14:25:53 CEST 2007 x86_64 AMD Athlon(tm) 64 Processor 3500+ AuthenticAMD GNU/Linux
* Linux PC2 2.6.22-gentoo-r3 #1 PREEMPT Tue Aug 14 18:11:31 CEST 2007 i686 Intel(R) Pentium(R) M processor 1.50GHz GenuineIntel GNU/Linux
* Linux PC3 2.6.22-gentoo-r1 #2 PREEMPT Fri Jul 27 00:01:59 CEST 2007 x86_64 AMD Athlon(tm) 64 Processor 3000+ AuthenticAMD GNU/Linux                                                               
* Linux PC4 2.6.22-gentoo-r6 #18 SMP PREEMPT Mon Sep 17 18:17:20 CEST 2007 i686 Intel(R) Core(TM)2 Duo CPU T7100 @ 1.80GHz GenuineIntel GNU/Linux

You want me to include 'emerge --info'?
Comment 3 Michele Martone 2007-09-18 09:22:50 UTC
(In reply to comment #2)
> Same here on 4 different PC's:
> 
> [...]
> 
> You want me to include 'emerge --info'?

Stefan, I think the information you gave is not relevant, and the output of `python-config --includes` would be more appropriate.
Comment 4 Stefan Wimmer 2007-09-18 09:38:28 UTC
(In reply to comment #3)
> Stefan, I think the information you gave is not relevant, and the output of
> `python-config --includes` would be more appropriate.

My apologies :-/

Here comes the output of 'python-config --includes':

PC1: -lpython2.4 -lm -L/usr/lib64/python2.4/config 
PC2: -lpython2.4 -lm -L/usr/lib/python2.4/config
PC3: -lpython2.4 -lm -L/usr/lib64/python2.4/config 
PC4: -lpython2.4 -lm -L/usr/lib/python2.4/config 

Seems the same problem ...

Hope this helps more
Stefan


Comment 5 Hamlet 2007-09-18 12:15:53 UTC
Same here.
I'm using dev-lang/python-2.4.4-r4 (-~amd64 for python, ~amd64 for almost the rest).
Comment 6 Jakub Moc (RETIRED) gentoo-dev 2007-09-21 06:05:56 UTC
*** Bug 193130 has been marked as a duplicate of this bug. ***
Comment 7 Jakub Moc (RETIRED) gentoo-dev 2007-09-21 06:11:24 UTC
Not an alsa-lib bug, this is our craptastic homebrewed python-config script. Upgrade to python-2.4.4-r5 or newer and it will work.


*** This bug has been marked as a duplicate of bug 188029 ***
Comment 8 Peter Ruskin 2007-09-21 13:10:18 UTC
Agreed. Perhaps python-2.4.4-r5 should be made stable?
Comment 9 Jakub Moc (RETIRED) gentoo-dev 2007-09-22 11:45:25 UTC
*** Bug 193407 has been marked as a duplicate of this bug. ***
Comment 10 Jakub Moc (RETIRED) gentoo-dev 2007-10-02 06:31:01 UTC
*** Bug 194460 has been marked as a duplicate of this bug. ***
Comment 11 Jakub Moc (RETIRED) gentoo-dev 2007-10-15 18:23:02 UTC
*** Bug 195972 has been marked as a duplicate of this bug. ***
Comment 12 Dominique Michel 2007-10-15 18:48:24 UTC
According to the changes for alsa-lib v1.0.15rc3, it have been fixed upstream in alsa-lib:
http://www.alsa-project.org/main/index.php/Changes_v1.0.15rc2_v1.0.15rc3#alsa-lib
Comment 13 Dominique Michel 2007-10-15 19:03:04 UTC
(In reply to comment #12)
> According to the changes for alsa-lib v1.0.15rc3, it have been fixed upstream
> in alsa-lib:
> http://www.alsa-project.org/main/index.php/Changes_v1.0.15rc2_v1.0.15rc3#alsa-lib
> 

Forget this, I try to bump the ebuild. I don't get the missing header error, but the following ones was still here. Sorry for the noise.
Comment 14 Jakub Moc (RETIRED) gentoo-dev 2007-10-30 07:26:52 UTC
*** Bug 197463 has been marked as a duplicate of this bug. ***
Comment 15 Jakub Moc (RETIRED) gentoo-dev 2008-01-17 23:59:21 UTC
*** Bug 206480 has been marked as a duplicate of this bug. ***
Comment 16 Jakub Moc (RETIRED) gentoo-dev 2008-02-22 10:13:12 UTC
*** Bug 211090 has been marked as a duplicate of this bug. ***
Comment 17 Jakub Moc (RETIRED) gentoo-dev 2008-03-18 12:00:24 UTC
*** Bug 213816 has been marked as a duplicate of this bug. ***
Comment 18 Boyan Ivanov 2008-03-19 11:18:50 UTC
Well, I have python-2.4.4-r6 installed, but I still get the same error. Perhaps the status of the bug should be changed?

Also here's the output of my python-config --includes :
-lpython2.3 -lm -L/usr/lib/python2.3/config

Maybe I should remove python2.3, but if it's installed, there might be a reason for that.
Comment 19 mickael chazaux 2008-04-15 11:18:59 UTC
(In reply to comment #18)
> Well, I have python-2.4.4-r6 installed, but I still get the same error. Perhaps
> the status of the bug should be changed?
> 
> Also here's the output of my python-config --includes :
> -lpython2.3 -lm -L/usr/lib/python2.3/config
> 
> Maybe I should remove python2.3, but if it's installed, there might be a reason

I just ctrl+Zed the emerge, then replaced the line 
#include "Python.h"
by the line 
#include <python2.4/Python.h> in the blocking file : python.c
and resumed build.
Not a clean solution but it worked.



> for that.
> 

Comment 20 Jamie Mack 2008-05-08 14:19:39 UTC
For those who don't have a clue which file needs editing..

emerge alsa-utils

.. wait until emerge unpacks the source and starts to compile.

hit CTRL+Z (this pauses it)

edit /var/tmp/portage/media-libs/alsa-lib-1.0.16/work/alsa-lib-1.0.16/modules/mixer/simple/python.c

Change the line that says: #include "Python.h" to: #include <python2.4/Python.h>'

type in 'fg' and hit enter, it should continue to compile with no errors.