#65891 closed defect (fixed)

py39-libxml2 @2.10.2 does not build on PPC Tiger, Mac OS X 10.4.11, because gcc-apple-4.2 expected in libxml2-py.c something different

Reported by: ballapete (Peter "Pete" Dyballa) Owned by: MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Priority: Normal Milestone:
Component: ports Version: 2.7.2
Keywords: tiger ppc Cc: ryandesign (Ryan Carsten Schmidt)
Port: py-libxml2

Description

/opt/local/bin/gcc-apple-4.2 -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -pipe -Os -arch ppc -isysroot/ -D_REENTRANT=1 -I/opt/local/include/libxml2 -I/opt/local/Library/Frameworks/Python.framework/Versions/3.9/include/python3.9 -c libxml2-py.c -o build/temp.macosx-10.4-ppc-cpython-39/libxml2-py.o
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:3776: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'PyObject'
libxml2-py.c:3791: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'PyObject'
libxml2-py.c:3806: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'PyObject'
libxml2-py.c:3829: 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'
error: command '/opt/local/bin/gcc-apple-4.2' failed with exit code 1
Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_python_py-libxml2/py39-libxml2/work/libxml2-2.10.2/python" && /opt/local/Library/Frameworks/Python.framework/Versions/3.9/bin/python3.9 setup.py --no-user-cfg build -j1 
Exit code: 1

It seems to be connected with

#if defined(LIBXML_HTML_ENABLED)
XML_IGNORE_DEPRECATION_WARNINGS
PyObject *

with XML_IGNORE_DEPRECATION_WARNINGS causing the failure.

Attachments (1)

main.log (21.9 KB) - added by ballapete (Peter "Pete" Dyballa) 18 months ago.
Main.log from PPC Tiger, Mac OS X 10.4.11

Download all attachments as: .zip

Change History (6)

Changed 18 months ago by ballapete (Peter "Pete" Dyballa)

Attachment: main.log added

Main.log from PPC Tiger, Mac OS X 10.4.11

comment:1 Changed 18 months ago by ballapete (Peter "Pete" Dyballa)

In case of the first error, the pre-processed output has declared

PyObject * libxml_htmlDefaultSAXHandlerInit(PyObject *self, PyObject *args);

and later we have:

XML_IGNORE_DEPRECATION_WARNINGS
PyObject *
libxml_htmlDefaultSAXHandlerInit(PyObject *self __attribute__ ((__unused__)), PyObject *args __attribute__ ((__unused__))) {

    if (libxml_deprecationWarning("htmlDefaultSAXHandlerInit") == -1)
        return(((void *)0));

    htmlDefaultSAXHandlerInit();
    _Py_INCREF(((PyObject*)((&_Py_NoneStruct))));
    return((&_Py_NoneStruct));
}

So it's probably the text string XML_IGNORE_DEPRECATION_WARNINGS in front of PyObject * which is nowhere #defined. So a simple line like

#define XML_IGNORE_DEPRECATION_WARNINGS 

added somewhere should suffice at first instance.

comment:2 Changed 18 months ago by ryandesign (Ryan Carsten Schmidt)

Cc: ryandesign added; mcalhoun@… removed
Owner: set to MarcusCalhoun-Lopez
Port: py-libxml2 added; py39-libxml2 removed
Status: newassigned

comment:3 Changed 18 months ago by ballapete (Peter "Pete" Dyballa)

The same failure happens on PPC Mac OS X 10.5.8, Leopard with py27-libxml2 and py39-libxml2.

comment:4 Changed 16 months ago by ballapete (Peter "Pete" Dyballa)

py310-libxml2 @2.10.2 builds with only a few warnings. It can be closed (for Tiger).

comment:5 Changed 16 months ago by kencu (Ken)

Resolution: fixed
Status: assignedclosed
Note: See TracTickets for help on using tickets.