Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to install libxml2-dev libxslt-dev on Mac os

I have installed both libxml2 and libxslt with homebrew, but it doesn't want to install libxml2-dev or libxslt-dev: Error: No available formula for libxml2-dev

I have pip, port, and all I could found. I even installed the Xcode command line tools, but with no luck. What is the way to install libxml2-dev & libxslt-dev on Mac 10.10?

like image 602
A1exandr Avatar asked Oct 20 '14 19:10

A1exandr


People also ask

Where is libxml2 installed Mac?

OS X comes with libxml2 installed, but it's in /usr/include/libxml2 . So that needs to be added to the include path with a -I/usr/include/libxml2 . The headers contain the definitions of the various functions, but the real code lies in shared libraries.

How do I download libxml2?

Locate where you can get the latest version of the software. (From google, libxml2 webpage is here: http://www.xmlsoft.org/downloads.html. From there, you can find the ftp location where you can download the software.

Where do I put libxml2?

You can use an existing directory which is already in the path, such as C:\WINDOWS . You can also create a new directory for libxml and place the files there, but be sure to modify the PATH environment variable and add that new directory to its list.


1 Answers

Try adding STATIC_DEPS, like this

STATIC_DEPS=true sudo pip install lxml

like image 160
Parker Avatar answered Sep 18 '22 07:09

Parker