Re: [xml] #define IN_LIBXML, a link error and a couple of warnings...

Hi there,

Just downloaded the new build, libxml2-2.4.18.tar.gz.
When compiling the libxml2 library, (Win2000, VC++ 6 Pro) you now get the
"warning C4005: 'IN_LIBXML' : macro redefinition"
for *every* C file instead of the one warning in libxml.h you used to get,
which could beoverridden with a #ifdef easily...

Yes, this is the correct behaviour now :-) The MSVC project file defines
this macro on the compiler command-line and that is one definition too much.
If this is removed from the project file, the warning will go away.

By the way, to fix this through the IDE is even easier than putting an
#ifdef in libxml.h. It seems there are far too many people out there who
feel overtaxed by anything except the click-next, click-next, click-finish

Come on, have some practice, post a fixed .dsp file :-)

On a side note, there are now 3 new warnings from nanohttp.c:
C:\libxml\libxml2-2.4.18\nanohttp.c(453) : warning C4018: '==' :
signed/unsigned mismatch
C:\libxml\libxml2-2.4.18\nanohttp.c(552) : warning C4018: '==' :
signed/unsigned mismatch
C:\libxml\libxml2-2.4.18\nanohttp.c(779) : warning C4018: '==' :
signed/unsigned mismatch

This is a common warning caused by few socket data types being defined
differently on Unix and Windows, I think. It is harmless.

and an error linking xmlcatalog:
xmlcatalog.obj : error LNK2001: unresolved external symbol _xmlFree
xmlcatalog/xmlcatalog.exe : fatal error LNK1120: 1 unresolved externals

This is caused by the first warning. Somehow, IN_LIBXML is defined while
conpiling xmlcatalog and that prevents the xmlFree (which is a variable, not
a function) from being imported properly.

The other external test programs compile and link fine.

Well, at least something works :-)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]