View Full Version : [ubuntu] could not be find the libxml2

June 21st, 2008, 12:04 PM
hi, when i configure dictconvert in dictconvert folder with ./configure command, then i get an error, it as follows:

checking for libxml - version >= 2.5.0... no
*** The xml2-config script installed by LIBXML could not be found
*** If libxml was installed in PREFIX, make sure PREFIX/bin is in
*** your path, or set the XML2_CONFIG environment variable to the
*** full path to xml2-config.
configure: error: You must have libxml2 >= 2.5.0 installed

would you give any advice to solve this? thanx

June 21st, 2008, 12:48 PM

First, update the package index (package list) in your pc.
sudo apt-get update

Then use the apt-cache command to search for dependencies (missing packages). In your case:

apt-cache search libxml
apt-cache search libxml | grep dev
libxml2-dev - Development files for the GNOME XML library

Install it.
sudo apt-get install libxml2-dev

libxml2 in Ubuntu has version 2.6.31 so that's no problem.
apt-cache show libxml2-dev

Compilation from source needs the header files (*.h), therefore you must install the xxx-dev package. That's why I limited the listing with | grep dev. Dev package will in turn pull out all necessary runtime libraries.