Environment:
- Windows 10 64 bit
- Visual Studio 2015 Update 3
-
vcvarsall x64
already executed successfully
-
nmake /f Makefile.msvc clean already
executed
successfully
When I tried to compile libxml2 with lzma included, I got the following errors (no error if I did not include
lzma):
Generating Code...
link.exe /nologo /VERSION:2.9 /LIBPATH:bin.msvc /LIBPATH:E:\3rd-parties\libxml2-2.9.8\install_\lib /DLL /IMPLIB:bin.msvc\libxml2.lib /OUT:bin.msvc\libxml2.dll int.msvc\buf.obj int.msvc\c14n.obj int.msvc\catalog.obj int.msvc\chvalid.obj int.msvc\debugXML.obj int.msvc\dict.obj int.msvc\DOCBparser.obj int.msvc\encoding.obj int.msvc\entities.obj int.msvc\error.obj int.msvc\globals.obj int.msvc\hash.obj int.msvc\HTMLparser.obj int.msvc\HTMLtree.obj int.msvc\legacy.obj int.msvc\list.obj int.msvc\nanoftp.obj int.msvc\nanohttp.obj int.msvc\parser.obj int.msvc\parserInternals.obj int.msvc\pattern.obj int.msvc\relaxng.obj int.msvc\SAX2.obj int.msvc\SAX.obj int.msvc\schematron.obj int.msvc\threads.obj int.msvc\tree.obj int.msvc\uri.obj int.msvc\valid.obj int.msvc\xinclude.obj int.msvc\xlink.obj int.msvc\xmlIO.obj int.msvc\xmlmemory.obj int.msvc\xmlreader.obj int.msvc\xmlregexp.obj int.msvc\xmlmodule.obj int.msvc\xmlsave.obj int.msvc\xmlschemas.obj int.msvc\xmlschemastypes.obj int.msvc\xmlunicode.obj int.msvc\xmlwriter.obj int.msvc\xpath.obj int.msvc\xpointer.obj int.msvc\xmlstring.obj int.msvc\libxml2.res wsock32.lib ws2_32.lib iconv.lib zlib.lib liblzma.lib kernel32.lib
Creating library bin.msvc\libxml2.lib and object bin.msvc\libxml2.exp
xmlIO.obj : error LNK2019: unresolved external symbol __libxml2_xzopen referenced in function xmlXzfileOpen_real
xmlIO.obj : error LNK2019: unresolved external symbol __libxml2_xzdopen referenced in function xmlXzfileOpen_real
xmlIO.obj : error LNK2019: unresolved external symbol __libxml2_xzread referenced in function xmlXzfileRead
xmlIO.obj : error LNK2019: unresolved external symbol __libxml2_xzclose referenced in function xmlXzfileClose
xmlIO.obj : error LNK2019: unresolved external symbol __libxml2_xzcompressed referenced in function __xmlParserInputBufferCreateFilename
bin.msvc\libxml2.dll : fatal error LNK1120: 5 unresolved externals
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\amd64\link.exe"' : return code '0x460'
Stop.
The command line configuration is:
cscript configure.js zlib=yes lzma=yes
prefix=E:\3rd-parties\libxml2-2.9.8\install_
include=E:\3rd-parties\iconv-1.14-win32-x86_64\include;E:\3rd-parties\zlib-1.2.11\install\include;E:\3rd-parties\xz-5.2.4\src\liblzma\api
lib=E:\3rd-parties\iconv-1.14-win32-x86_64\lib;E:\3rd-parties\zlib-1.2.11\install\lib;E:\3rd-parties\xz-5.2.4\windows\vs2017\Release\x64\liblzma_dll
I have checked everything I could but of no avail. Can you help me fix this issue? Please let me know if you need info to troubleshoot. Thanks a lot!