Reputation: 659
I'm stuck in a very simple problem: I cannot manage to make work my simple code example in C++. I want to include the "curl" library but when I compile with the command:
g++ -o myprog.out myprog.cpp -L/curl/include/ -lcurl
I get the following error message:
myprog.cpp:3:71: fatal error: /curl/include/curl/curl.h: No such file or directory
My folder contains:
My headers file are configured in this way:
include<iostream> include<string> include<curl.h>
What I'm doing wrong? It's probably a very simple problem but it's driving me crazy :-/
Upvotes: 1
Views: 2415
Reputation: 136256
#include <curl.h>
to #include <curl/curl.h>
.-L/curl/include/
to -I/curl/include
.-L/curl/lib -Wl,-rpath=/curl/lib
(or whatever the path to curl built libraries).Upvotes: 1