I installed curl this command (i use Ubuntu):
sudo apt-get install curl
When I test simple program using g++ test.cpp
g++ test.cpp
Instead of downloading curl, down libcurl.
curl is just the application, libcurl is what you need for your C++ program
http://packages.ubuntu.com/quantal/curl