libxml2-2.10.3 is failed to compile on Oracle Linux 6 Update 1
libxml2-2.10.3 is failed to compile on Oracle Linux 6 Update 1 with below error,
make[2]: Entering directory `/BUILDS/WORKAREA/libxml2-2.10.3/python'
make all-recursive
make[3]: Entering directory `/BUILDS/WORKAREA/libxml2-2.10.3/python'
Making all in .
make[4]: Entering directory `/BUILDS/WORKAREA/libxml2-2.10.3/python'
CC libxml2-py.lo
libxml2-py.c:196: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:324: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:1557: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:1578: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:2331: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:2358: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:3270: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:3283: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:3330: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:3541: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:6377: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:6464: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:6734: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:6937: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:7020: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
libxml2-py.c:13533: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyObject’
make[4]: *** [libxml2-py.lo] Error 1
make[4]: Leaving directory `/BUILDS/WORKAREA/libxml2-2.10.3/python'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/BUILDS/WORKAREA/libxml2-2.10.3/python'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/BUILDS/WORKAREA/libxml2-2.10.3/python'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/BUILDS/WORKAREA/libxml2-2.10.3'
make: *** [all] Error 2
I have created "/usr/share/pkgconfig/python-2.6.pc" with below content,
prefix=/usr
exec_prefix=${prefix}
includedir=${prefix}/include
bindir=${exec_prefix}/bin
libdir=${exec_prefix}/lib64
Name: Python
Description: Python
Version: 2.6.6
Cflags: -I${includedir}/python2.6
Libs: -L${libdir} -lpython2.6
python-2.6dir=${bindir}/python
Edited by Nick Wellnhofer