cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: how to get the libcurl up and running in my C code.

From: Kamil Dudka <kdudka_at_redhat.com>
Date: Thu, 3 Feb 2011 21:12:24 +0100

On Thursday 03 February 2011 20:52:04 goeie spullen wrote:
> Hi Alan, thanx for you quick reply. The issue is that I don't get the
> complilation up and running:
>
> I downloaded the following file and tried to compile it:
> https://github.com/bagder/curl/raw/master/docs/examples/ftpupload.c
>
>
> itops_at_itops-laptop:~/development/preventel/code/ftpclient$ cc ftptest4.c
> /tmp/ccvb2cjd.o: In function `main':
> ftptest4.c:(.text+0x178): undefined reference to `curl_global_init'

This is not about compilation. The error message above comes from the
linker. You need to link against libcurl. Try to append -lcurl.

Kamil
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-02-03