Question

On Ubuntu I use this command:

apt-get install libcurl4-openssl-dev

On FreeBSD, I've tried this, which doesn't work:

pkg_add -r libcurl4-openssl-dev

I've tried looking through the list of ports here, and didn't see anything obvious:

http://ftp.freebsd.org/pub/FreeBSD/ports/amd64/packages-9.2-release/Latest

What's the equivalent install package for FreeBSD (9.2 specifically)?

Was it helpful?

Solution

The library libcurl is installed by the port ftp/curl:

pkg which -o /usr/local/lib/libcurl.so.7 
/usr/local/lib/libcurl.so.7 was installed by package ftp/curl

(N.B: I'm using FreeBSD 10.0 which uses a newer package management program. On 9.2 you can use pkg_which instead)

As you can see on the curl freshports page, OpenSSL is enabled by default.

So installing a package would be enough unless you want to use another SSL implementation or if you want to change any of the other options. In that case you'll have to install it from ports by running the following commands as the root user;

# cd /usr/ports/ftp/curl
# make config
# make install clean

If you have never installed this port before, you can skip the make config step because it will be done anyway.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top