137
MingW32 (GCC-2.95) style
138
------------------------
139
Run the 'mingw32.bat' file to get the proper environment variables
140
set, then run 'make mingw32' in the root dir.
142
If you have any problems linking libraries or finding header files, be
143
sure to verify that the provided "Makefile.m32" files use the proper
144
paths, and adjust as necessary.
148
Almost identical to the unix installation. Run the configure script in
149
the curl root with 'sh configure'. Make sure you have the sh
150
executable in /bin/ or you'll see the configure fail towards the end.
154
Microsoft command line style
155
----------------------------
156
Run the 'vcvars32.bat' file to get the proper environment variables
157
set, then run 'nmake vc' in the root dir.
159
The vcvars32.bat file is part of the Microsoft development
163
-------------------------
164
If you use VC++, Borland or similar compilers. Include all lib source
165
files in a static lib "project" (all .c and .h files that is).
166
(you should name it libcurl or similar)
168
Make the sources in the src/ drawer be a "win32 console application"
169
project. Name it curl.
171
For VC++ 6, there's an included Makefile.vc6 that should be possible
172
to use out-of-the-box.
177
MingW32 (GCC-2.95) style
178
------------------------
179
Run the 'mingw32.bat' file to get the proper environment variables
180
set, then run 'make mingw32-ssl' in the root dir.
182
If you have any problems linking libraries or finding header files, be
183
sure to look at the provided "Makefile.m32" files for the proper
184
paths, and adjust as necessary.
188
Haven't done, nor got any reports on how to do. It should although be
189
identical to the unix setup for the same purpose. See above.
191
Microsoft command line style
192
----------------------------
194
Run the 'vcvars32.bat' file to get a proper environment. The
195
vcvars32.bat file is part of the Microsoft development environment and
196
you may find it in 'C:\Program Files\Microsoft Visual Studio\vc98\bin'
197
provided that you installed Visual C/C++ 6 in the default directory.
199
Then run 'nmake vc' in curl's root directory.
201
If you want to compile with zlib support, you will need to build
202
zlib (http://www.gzip.org/zlib/) as well. Please read the zlib
203
documentation on how to compile zlib. Define the ZLIB_PATH environment
204
variable to the location of zlib.h and zlib.lib, for example:
206
set ZLIB_PATH=c:\zlib-1.2.1
208
Then run 'nmake vc-zlib' in curl's root directory.
210
If you want to compile with SSL support you need the OpenSSL package.
211
Please read the OpenSSL documentation on how to compile and install
212
the OpenSSL libraries. The build process of OpenSSL generates the
213
libeay32.dll and ssleay32.dll files in the out32dll subdirectory in
214
the OpenSSL home directory. OpenSSL static libraries (libeay32.lib,
215
ssleay32.lib, RSAglue.lib) are created in the out32 subdirectory.
217
Before running nmake define the OPENSSL_PATH environment variable with
218
the root/base directory of OpenSSL, for example:
220
set OPENSSL_PATH=c:\openssl-0.9.7d
222
Then run 'nmake vc-ssl' or 'nmake vc-ssl-dll' in curl's root
223
directory. 'nmake vc-ssl' will create a libcurl static and dynamic
224
libraries in the lib subdirectory, as well as a statically linked
225
version of curl.exe in the src subdirectory. This statically linked
226
version is a standalone executable not requiring any DLL at
227
runtime. This make method requires that you have the static OpenSSL
228
libraries available in OpenSSL's out32 subdirectory.
229
'nmake vc-ssl-dll' creates the libcurl dynamic library and
230
links curl.exe against libcurl and OpenSSL dynamically.
231
This executable requires libcurl.dll and the OpenSSL DLLs
233
Run 'nmake vc-ssl-zlib' to build with both ssl and zlib support.
235
Microsoft / Borland style
236
-------------------------
237
If you have OpenSSL, and want curl to take advantage of it, edit your
238
project properties to use the SSL include path, link with the SSL libs
239
and define the USE_SSLEAY symbol.
241
Using Borland C++ compiler version 5.5.1 (available as free download
243
---------------------------------------------------------------------
247
Make sure you include the paths to curl/include and openssl/inc32 in
251
eg : -I"c:\Bcc55\include;c:\path_curl\include;c:\path_openssl\inc32"
253
Check to make sure that all of the sources listed in lib/Makefile.b32
254
are present in the /path_to_curl/lib directory. (Check the src
255
directory for missing ones.)
257
Make sure the environment variable "BCCDIR" is set to the install
258
location for the compiler eg : c:\Borland\BCC55
261
make -f /path_to_curl/lib/Makefile-ssl.b32
263
compile simplessl.c with appropriate links
265
c:\curl\docs\examples\> bcc32 -L c:\path_to_curl\lib\libcurl.lib
266
-L c:\borland\bcc55\lib\psdk\ws2_32.lib
267
-L c:\openssl\out32\libeay32.lib
268
-L c:\openssl\out32\ssleay32.lib
271
Disabling Specific Protocols:
273
The configure utility, unfortunately, is not available for the Windows
274
environment, therefore, you cannot use the various disable-protocol
275
options of the configure utility on this platform.
277
However, you can use the following defines to disable specific
280
HTTP_ONLY disables all protocols except HTTP
281
CURL_DISABLE_FTP disables FTP
282
CURL_DISABLE_LDAP disables LDAP
283
CURL_DISABLE_TELNET disables TELNET
284
CURL_DISABLE_DICT disables DICT
285
CURL_DISABLE_FILE disables FILE
286
CURL_DISABLE_GOPHER disables GOPHER
288
If you want to set any of these defines you have the following
292
- Modify lib/Makefile.vc6
293
- Add defines to Project/Settings/C/C++/General/Preprocessor Definitions
294
in the curllib.dsw/curllib.dsp Visual C++ 6 IDE project.
297
Important (with SSL or not):
298
When building an application that uses the static libcurl library, you
299
must add '-DCURL_STATICLIB' to your CFLAGS. Otherwise the linker will
300
look for dynamic import symbols.
138
Run the 'mingw32.bat' file to get the proper environment variables set,
139
then run 'make mingw32' in the root dir. Use 'make mingw32-ssl' to build
142
If you have any problems linking libraries or finding header files, be sure
143
to verify that the provided "Makefile.m32" files use the proper paths, and
149
Almost identical to the unix installation. Run the configure script in the
150
curl root with 'sh configure'. Make sure you have the sh executable in
151
/bin/ or you'll see the configure fail towards the end.
158
See the separate INSTALL.devcpp file for details.
160
MSVC from command line
161
----------------------
163
Run the 'vcvars32.bat' file to get a proper environment. The
164
vcvars32.bat file is part of the Microsoft development environment and
165
you may find it in 'C:\Program Files\Microsoft Visual Studio\vc98\bin'
166
provided that you installed Visual C/C++ 6 in the default directory.
168
Then run 'nmake vc' in curl's root directory.
170
If you want to compile with zlib support, you will need to build
171
zlib (http://www.gzip.org/zlib/) as well. Please read the zlib
172
documentation on how to compile zlib. Define the ZLIB_PATH environment
173
variable to the location of zlib.h and zlib.lib, for example:
175
set ZLIB_PATH=c:\zlib-1.2.1
177
Then run 'nmake vc-zlib' in curl's root directory.
179
If you want to compile with SSL support you need the OpenSSL package.
180
Please read the OpenSSL documentation on how to compile and install
181
the OpenSSL libraries. The build process of OpenSSL generates the
182
libeay32.dll and ssleay32.dll files in the out32dll subdirectory in
183
the OpenSSL home directory. OpenSSL static libraries (libeay32.lib,
184
ssleay32.lib, RSAglue.lib) are created in the out32 subdirectory.
186
Before running nmake define the OPENSSL_PATH environment variable with
187
the root/base directory of OpenSSL, for example:
189
set OPENSSL_PATH=c:\openssl-0.9.7d
191
Then run 'nmake vc-ssl' or 'nmake vc-ssl-dll' in curl's root
192
directory. 'nmake vc-ssl' will create a libcurl static and dynamic
193
libraries in the lib subdirectory, as well as a statically linked
194
version of curl.exe in the src subdirectory. This statically linked
195
version is a standalone executable not requiring any DLL at
196
runtime. This make method requires that you have the static OpenSSL
197
libraries available in OpenSSL's out32 subdirectory.
198
'nmake vc-ssl-dll' creates the libcurl dynamic library and
199
links curl.exe against libcurl and OpenSSL dynamically.
200
This executable requires libcurl.dll and the OpenSSL DLLs
202
Run 'nmake vc-ssl-zlib' to build with both ssl and zlib support.
205
---------------------
209
Make sure you include the paths to curl/include and openssl/inc32 in
212
eg : -I"c:\Bcc55\include;c:\path_curl\include;c:\path_openssl\inc32"
214
Check to make sure that all of the sources listed in lib/Makefile.b32
215
are present in the /path_to_curl/lib directory. (Check the src
216
directory for missing ones.)
218
Make sure the environment variable "BCCDIR" is set to the install
219
location for the compiler eg : c:\Borland\BCC55
222
make -f /path_to_curl/lib/Makefile-ssl.b32
224
compile simplessl.c with appropriate links
226
c:\curl\docs\examples\> bcc32 -L c:\path_to_curl\lib\libcurl.lib
227
-L c:\borland\bcc55\lib\psdk\ws2_32.lib
228
-L c:\openssl\out32\libeay32.lib
229
-L c:\openssl\out32\ssleay32.lib
236
If you use VC++, Borland or similar compilers. Include all lib source
237
files in a static lib "project" (all .c and .h files that is).
238
(you should name it libcurl or similar)
240
Make the sources in the src/ drawer be a "win32 console application"
241
project. Name it curl.
243
For VC++ 6, there's an included Makefile.vc6 that should be possible
244
to use out-of-the-box.
247
Disabling Specific Protocols in Win32 builds
248
--------------------------------------------
250
The configure utility, unfortunately, is not available for the Windows
251
environment, therefore, you cannot use the various disable-protocol
252
options of the configure utility on this platform.
254
However, you can use the following defines to disable specific
257
HTTP_ONLY disables all protocols except HTTP
258
CURL_DISABLE_FTP disables FTP
259
CURL_DISABLE_LDAP disables LDAP
260
CURL_DISABLE_TELNET disables TELNET
261
CURL_DISABLE_DICT disables DICT
262
CURL_DISABLE_FILE disables FILE
263
CURL_DISABLE_GOPHER disables GOPHER
265
If you want to set any of these defines you have the following
269
- Modify lib/Makefile.vc6
270
- Add defines to Project/Settings/C/C++/General/Preprocessor Definitions
271
in the curllib.dsw/curllib.dsp Visual C++ 6 IDE project.
274
Important static libcurl usage note
275
-----------------------------------
277
When building an application that uses the static libcurl library, you must
278
add '-DCURL_STATICLIB' to your CFLAGS. Otherwise the linker will look for
279
dynamic import symbols.