Command line curl is separate to libcurl that you can use in programs.

Install curl

Installing the OpenSSL version

sudo apt-get install libcurl4-openssl-dev

Using the Library In A NetBeans Project

Including the library header file

#include <curl/curl.h>

When you compile you also need to include -lcurl so the libraries object file is added to the final compilation.

Right click the project > Properties > Build > Linker > In the ‘Libraries’ section press the ‘…’ button > Add Option… > Other Option > Enter: -lcurl

Current version

Seems hard to identify for the install command!

Current version: https://curl.haxx.se/changes.html

However install libcurl7-openssl-dev does not work even though its at version 7 currently. Using command : sudo apt-get install libcurl-dev
Gave a response of:

  • Package libcurl-dev is a virtual package provided by:
  • libcurl4-openssl-dev 7.38.0-4+deb8u16
  • libcurl4-nss-dev 7.38.0-4+deb8u16
  • libcurl4-gnutls-dev 7.38.0-4+deb8u16
  • You should explicitly select one to install.

So libcurl4 it seems to be.

Removing curl

sudo apt remove curl
USEFUL?
We benefit hugely from resources on the web so we decided we should try and give back some of our knowledge and resources to the community by opening up many of our company’s internal notes and libraries through mini sites like this. We hope you find the site helpful.
Please feel free to comment if you can add help to this page or point out issues and solutions you have found, but please note that we do not provide support on this site. If you need help with a problem please use one of the many online forums.

Comments

Your email address will not be published. Required fields are marked *