• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# libcurl examples
2
3This directory is for libcurl programming examples. They are meant to show
4some simple steps on how you can build your own application to take full
5advantage of libcurl.
6
7If you end up with other small but still useful example sources, please mail
8them for submission in future packages and on the website.
9
10## Building
11
12The Makefile.example is an example makefile that could be used to build these
13examples. Just edit the file according to your system and requirements first.
14
15Most examples should build fine using a command line like this:
16
17    `curl-config --cc --cflags --libs` -o example example.c
18
19Some compilers don't like having the arguments in this order but instead
20want you do reorganize them like:
21
22    `curl-config --cc` -o example example.c `curl-config --cflags --libs`
23
24**Please** do not use the `curl.se` site as a test target for your
25libcurl applications/experiments. Even if some of the examples use that site
26as a URL at some places, it doesn't mean that the URLs work or that we expect
27you to actually torture our website with your tests!  Thanks.
28
29## Examples
30
31Each example source code file is designed to be and work stand-alone and
32rather self-explanatory. The examples may at times lack the level of error
33checks you need in a real world, but that is then only for the sake of
34readability: to make the code smaller and easier to follow.
35