windows平台vs2010编译64位libiconv与libxml2

(一)安装libiconv
下载路径https://ftp.gnu.org/pub/gnu/libiconv/
注意这里选择libiconv-1.11.1版本,因为之后的版本没有Makefile.msvc文件了。不解。。。
cd D:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\amd64
vcvars64.bat
cd PREFIX=D:\espa-product-formatter\XML2\libiconv-1.11.1
nmake -f Makefile.msvc DLL=1 MFLAGS=-MT NO_NLS=1 PREFIX=D:\espa-product-formatter\XML2\libiconv-1.11.1\hu
nmake -f Makefile.msvc install DLL=1 MFLAGS=-MT NO_NLS=1 PREFIX=D:\espa-product-formatter\XML2\libiconv-1.11.1\hu
nmake -f Makefile.msvc all install DLL=1 MFLAGS=-MT NO_NLS=1 PREFIX=D:\espa-product-formatter\XML2\libiconv-1.11.1\hu
生成的lib、bin、include文件在上面hu文件夹下,hu文件夹是自己新建的,保证目录存在。


(二)libxml2
下载libxml2,官网是:http://www.xmlsoft.org/downloads.html,下载地址是:ftp://gd.tuwien.ac.at/pub/libxml/.
版本是:libxml2-sources-2.9.0.tar.gz

解压文件,把安装libiconv生成的lib、include文件夹拷贝到libxml2文件夹里。
进入 Visual Studio 2008 Command Prompt;
cd D:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\amd64
vcvars64.bat
cd D:\espa-product-formatter\XML2\libxml2-2.9.0\win32
cscript configure.js compiler=msvc prefix=D:\espa-product-formatter\XML2\libxml2-2.9.0\win32\hu include=D:\espa-product-formatter\XML2\libxml2-2.9.0\include lib=D:\espa-product-formatter\XML2\libxml2-2.9.0\lib
nmake /f Makefile.msvc
nmake /f Makefile.msvc install
生成的lib、bin、include文件在上面hu文件夹下,hu文件夹是自己新建的,保证目录存在。

posted on 2017-09-19 11:27  吴长明  阅读(2855)  评论(0编辑  收藏  举报