I have the libcurl header files in a folder in my working directory. I also have libcurl.dll in my working directory. I can't seem to compile the following program:
Code:
#include <stdio.h>
#include "curl/curl.h"
int main(void)
{
CURL *curl;
CURLcode res;
curl = curl_easy_init();
if(curl) {
curl_easy_setopt(curl, CURLOPT_URL, "curl.haxx.se");
res = curl_easy_perform(curl);
/* always cleanup */
curl_easy_cleanup(curl);
}
return 0;
}
I type
and I get all this stuff about undefined references:
"undefined reference to '_imp__curl_easy_setopt'"
"undefined reference to '_imp__curl_easy_init'"
"undefined reference to '_imp__curl_easy_perform'"
"undefined reference to '_imp__curl_easy_cleanup'"