Bug #517
closedPython bindings compilation error
100%
Description
When enabling python bindings, compilation fails with this error message:
lttng_wrap.c:125:20: fatal error: Python.h: No such file or directory
The Python.h file is installed properly.
Here is the compilation command:
[francis@blob python]$ /bin/bash ../../../../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I../../../.. -I../../../.. -I../../../../src -I../../../../include -include config.h -I-I/usr/include/python2.7 -I/usr/include/x86_64-linux-gnu/python2.7 -I../../../../lib/lttng-ctl -I../common -Wall -g -O2 -g -fno-strict-aliasing -MT lttng_wrap.lo -MD -MP -MF .deps/lttng_wrap.Tpo -c -o lttng_wrap.lo lttng_wrap.c
We see an include error with duplicated -I-I that prevent the include to works correctly.
python-config --libraries output already prepends "-I" to includes on ubuntu 13.04 and confirmed for 12.04 also
Updated by Francis Giraldeau almost 11 years ago
<fgiraldeau> ubuntu 12.04: gcc -I$(python-config --includes) main.c WORKS
<fgiraldeau> ubuntu 13.04: gcc -I$(python-config --includes) main.c FAILS
GCC 4.6.3 do not fails with duplicated -I-I, but GCC 4.7.3 does.
Updated by David Goulet almost 11 years ago
- Status changed from New to Resolved
- % Done changed from 0 to 100
Applied in changeset f7cbc765ad2526667f1f20b3a89c596b3422ac34.