GNOME Bugzilla – Bug 327475
__xmlRaiseError doesn't print line numbers from xmllint on Cygwin
Last modified: 2017-06-14 11:31:12 UTC
Please describe the problem: Due (it seems) to DLL linking problems, on Cygwin, calls to __xmlRaiseError in xmllint don't print the file and line numbers, instead printing only the message. Steps to reproduce: 1. Install the Cygwin libxml2 package. 2. For the tests below, obtain and unpack the libxml2 source code. 3. xmllint -noout -schema libxml2-2.6.22/test/schemas/all_2.xsd libxml2-2.6.22/test/schemas/all_2.xml Actual results: Element 'c': This element is not expected. libxml2-2.6.22/test/schemas/all_2.xml fails to validate Expected results: libxml2-2.6.22/test/schemas/all_2.xml:1: element c: Schemas validity error : Element 'c': This element is not expected. libxml2-2.6.22/test/schemas/all_2.xml fails to validate Does this happen every time? Yes. Other information: If xmllint is compiled statically, i.e. -static is passed to the libtool command line when xmllint is compiled, the problem goes away. The problem seems to occur because fprintf in a DLL has a different address than fprintf in a main program, on Windows.
Closing 10 year old Cygwin issue as "obsolete".