xml 如何在 unix 中安装 libxml2
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/7950857/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
How to install libxml2 in unix
提问by holbond
can anybody tell me how to install libxml2 in Unix? I am using windows for browsing net and Unix for writing my C programs. I also dont know whether it is already installed. Please tell me guys how to install libxml2 and use it for parsing.
谁能告诉我如何在 Unix 中安装 libxml2?我使用 Windows 浏览网络,使用 Unix 编写我的 C 程序。我也不知道它是否已经安装。请告诉我如何安装 libxml2 并使用它进行解析。
采纳答案by Jens
Read the installation instructions that come with libxml2 in the file INSTALL.
If you find any file or directory with the substring libxml2in /usr/local/includeor /usr/local/lib(such as /usr/local/lib/libxml2.so) then it is already installed.
阅读文件中 libxml2 附带的安装说明INSTALL。如果您libxml2在/usr/local/include或 中找到任何带有子字符串的文件或目录/usr/local/lib(例如/usr/local/lib/libxml2.so),则它已经安装。
Depending on the particular Unix brand (which you did not tell us), you might need to look in other directories as well.
根据特定的 Unix 品牌(您没有告诉我们),您可能还需要查看其他目录。
回答by David Kim
Here's a way to install from source - given by good folks at Cypress project.
这是一种从源代码安装的方法 - 由 Cypress 项目的好人提供。
https://github.com/projectcypress/cypress/wiki/Cypress-v2.0-Installation-Guide
https://github.com/projectcypress/cypress/wiki/Cypress-v2.0-Installation-Guide
---- for easy reading: copied from above URL ----
---- 为方便阅读:复制自上述网址 ----
cd /tmp
wget ftp://xmlsoft.org/libxml2/libxml2-2.8.0.tar.gz
tar xzf libxml2-2.8.0.tar.gz
cd libxml2-2.8.0/
./configure
make
sudo make install
cd

