new
[libcurl.git] / INSTALL
bloba2e389433fe611840b3a6ead63d9f2055c2815ed
1                                   _   _ ____  _     
2                               ___| | | |  _ \| |    
3                              / __| | | | |_) | |    
4                             | (__| |_| |  _ <| |___ 
5                              \___|\___/|_| \_\_____|
7                                 How To Compile
9 UNIX
10 ====
12    The configure script *always* tries to find a working SSL library unless
13    explicitely told not to.  If you have SSLeay or OpenSSL installed in the
14    default search path for your compiler/linker, you don't need to do anything
15    special.
17    If you have SSLeay or OpenSSL installed in /usr/local/ssl, you can
18    run configure like so:
20         ./configure --with-ssl
22    If you have SSLeay or OpenSSL installed somewhere else (for example,
23    /opt/OpenSSL,) you can run configure like this:
25         ./configure --with-ssl=/opt/OpenSSL
27    If you insist on forcing a build *without* SSL support, even though you may
28    have it installed in your system, you can run configure like this:
30         ./configure --without-ssl
32    If you have SSLeay or OpenSSL installed, but with the libraries in
33    one place and the header files somewhere else, you'll have to set the
34    LDFLAGS and CPPFLAGS environment variables prior to running configure.
35    Something like this should work:
37      (with the Bourne shell and its clones):
39        CPPFLAGS="-I/path/to/ssl/include" LDFLAGS="-L/path/to/ssl/lib" \
40            ./configure
42      (with csh, tcsh and their clones):
43      
44        env CPPFLAGS="-I/path/to/ssl/include" LDFLAGS="-L/path/to/ssl/lib" \
45        ./configure
47    If your SSL library was compiled with rsaref (usually for use in
48    the United States), you may also need to set:
50      LIBS=-lRSAglue -lrsaref
51      (from Doug Kaufman <dkaufman@rahul.net>)
53    Without SSL support, just run:
55      ./configure
57    Then run:
59      make
61    Use the executable `curl` in src/ directory.
63    'make install' copies the curl file to /usr/local/bin/ (or $prefix/bin
64    if you used the --prefix option to configure) and copies the curl.1
65    man page to a suitable place too.
67    KNOWN PROBLEMS
69      If you happen to have autoconf installed, but a version older than
70      2.12 you will get into trouble. Then you can still build curl by
71      issuing these commands: (from Ralph Beckmann <rabe@uni-paderborn.de>)
73        ./configure [...]
74        cd lib; make; cd ..
75        cd src; make; cd ..
76        cp src/curl elsewhere/bin/
78    OPTIONS
80      Remember, to force configure to use the standard cc compiler if both
81      cc and gcc are present, run configure like
83        CC=cc ./configure
84          or
85        env Cc=cc ./configure
88 Win32
89 =====
91    Without SSL:
93       MingW32 (GCC-2.95) style
94       ------------------------
95         Run the 'mingw32.bat' file to get the proper environment variables
96         set, then run 'make -f Makefile.m32' in the lib/ dir and then
97         'make -f Makefile.m32' in the src/ dir.
99         If you have any problems linking libraries or finding header files,
100         be sure to look at the provided "Makefile.m32" files for the proper
101         paths, and adjust as necessary.
103       Cygwin style
104       ------------
105         Almost identical to the unix installation. Run the configure script
106         in the curl root with 'sh configure'. Make sure you have the sh
107         executable in /bin/ or you'll see the configure fail towards the
108         end.
110         Run 'make'
112       Microsoft command line style
113       ----------------------------
114         Run the 'vcvars32.bat' file to get the proper environment variables
115         set, then run 'nmake -f Makefile.vc6' in the lib/ dir and then
116         'nmake -f Makefile.vc6' in the src/ dir.
118       IDE-style
119       -------------------------
120         If you use VC++, Borland or similar compilers. Include all lib source
121         files in a static lib "project" (all .c and .h files that is).
122         (you should name it libcurl or similar)
124         Make the sources in the src/ drawer be a "win32 console application"
125         project. Name it curl.
127         With VC++, add 'wsock32.lib' to the link libs when you build curl!
128         Borland seems to do that itself magically. Of course you have to
129         make sure it links with the libcurl too!
131         For VC++ 6, there's an included Makefile.vc6 that should be possible
132         to use out-of-the-box.
134         Microsoft note: add /Zm200 to the compiler options, as the hugehelp.c
135         won't compile otherwise due to "too long puts string" or something
136         like that!
139    With SSL:
141       MingW32 (GCC-2.95) style
142       ------------------------
143         Run the 'mingw32.bat' file to get the proper environment variables
144         set, then run 'make -f Makefile.m32 SSL=1' in the lib/ dir and then
145         'make -f Makefile.m32 SSL=1' in the src/ dir.
147         If you have any problems linking libraries or finding header files,
148         be sure to look at the provided "Makefile.m32" files for the proper
149         paths, and adjust as necessary.
151       Cygwin style
152       ------------
154         Haven't done, nor got any reports on how to do. It should although be
155         identical to the unix setup for the same purpose. See above.
157       Microsoft command line style
158       ----------------------------
159         Run the 'vcvars32.bat' file to get the proper environment variables
160         set, then run 'nmake -f Makefile.vc6 release-ssl' in the lib/ dir and
161         then 'nmake -f Makefile.vc6' in the src/ dir.
163       Microsoft / Borland style
164       -------------------------
165         If you have OpenSSL/SSLeay, and want curl to take advantage of it,
166         edit your project properties to use the SSL include path, link with
167         the SSL libs and define the USE_SSLEAY symbol.
170 OpenSSL/SSLeay
171 ==============
173    You'll find OpenSSL information at:
175       http://www.openssl.org
178 MingW32/Cygwin
179 ==============
181    You'll find MingW32 and Cygwin information at:
183       http://www.xraylith.wisc.edu/~khan/software/gnu-win32/index.html
185 OpenLDAP
186 ========
188    You'll find OpenLDAP information at:
190       http://www.openldap.org
192    You need to install it with shared libraries, which is enabled when running
193    the ldap configure script with "--enable-shared". With my linux 2.0.36
194    kernel I also had to disable using threads (with --without-threads),
195    because the configure script couldn't figure out my system.