7
7
# 'BCCDIR' has to be set up to point to the base directory
8
8
# of the compiler, i.e. SET BCCDIR = c:\Borland\BCC55
9
# where c:\Borland\BCC55 is the compiler is installed
11
# Written by Jaepil Kim, pit@paradise.net.nz
10
# Initially written by Jaepil Kim, pit@paradise.net.nz
12
11
############################################################
13
!if "$(__MAKE__)" == ""
14
!error __MAKE__ not defined. Use Borlands's MAKE to process this makefile.
17
# Borland's $(MAKEDIR) expands to the path where make.exe is located,
18
# use this feature to define BCCDIR when user has not defined BCCDIR.
20
BCCDIR = $(MAKEDIR)\..
14
23
# Edit the path below to point to the base of your Zlib sources.
16
ZLIB_PATH = ../../zlib-1.2.1
25
ZLIB_PATH = ..\..\zlib-1.2.5
19
28
# Edit the path below to point to the base of your OpenSSL package.
20
29
!ifndef OPENSSL_PATH
21
OPENSSL_PATH = ../../openssl-0.9.7d
30
OPENSSL_PATH = ..\..\openssl-0.9.8q
24
33
# Set libcurl static lib, dll and import lib
27
36
LIBCURL_IMPLIB = libcurl_imp.lib
29
38
# Setup environment
44
RMDIR = rmdir /s /q 2>NUL
37
CXXFLAGS = -q -5 -O2 -w-aus -w-ccc -w-csu -w-par -w-pia -w-rch -w-inl -w-ngu -w-pro -tWM
48
CC_FLAGS = -5 -O2 -tWM -w -w-aus -w-ccc -w-dup -w-prc -w-pro -w-rch -w-sig -w-spa -Dinline=__inline
39
50
LDFLAGS = -q -lq -laa -tWD
41
INCDIRS = -I.;../include
42
LINKLIB = $(BCCDIR)/lib/cw32mt.lib
44
# If you build with SSL support, set WITH_SSL=1
45
DEFINES = -DNDEBUG -DWIN32 -D_CONSOLE -D_MBCS -DBUILDING_LIBCURL
54
INCDIRS = -I.;..\include
55
LINKLIB = $(BCCDIR)\lib\cw32mt.lib
56
DEFINES = -DNDEBUG -DWIN32 -DBUILDING_LIBCURL
58
# By default SSPI support is enabled for BCC
60
DEFINES = $(DEFINES) -DUSE_WINDOWS_SSPI
63
# By default LDAP support is disabled for BCC
65
DEFINES = $(DEFINES) -DCURL_DISABLE_LDAP
68
# ZLIB support is enabled setting WITH_ZLIB=1
48
70
DEFINES = $(DEFINES) -DHAVE_LIBZ -DHAVE_ZLIB_H
49
71
INCDIRS = $(INCDIRS);$(ZLIB_PATH)
50
LINKLIB = $(LINKLIB) $(ZLIB_PATH)/zlib.lib
72
LINKLIB = $(LINKLIB) $(ZLIB_PATH)\zlib.lib
75
# SSL support is enabled setting WITH_SSL=1
54
77
DEFINES = $(DEFINES) -DUSE_SSLEAY
55
INCDIRS = $(INCDIRS);$(OPENSSL_PATH)/inc32;$(OPENSSL_PATH)/inc32/openssl
56
LINKLIB = $(LINKLIB) $(OPENSSL_PATH)/out32/ssleay32.lib $(OPENSSL_PATH)/out32/libeay32.lib
78
INCDIRS = $(INCDIRS);$(OPENSSL_PATH)\inc32;$(OPENSSL_PATH)\inc32\openssl
79
LINKLIB = $(LINKLIB) $(OPENSSL_PATH)\out32\ssleay32.lib $(OPENSSL_PATH)\out32\libeay32.lib
61
87
# Makefile.inc provides the CSOURCES and HHEADERS defines
62
88
!include Makefile.inc
64
90
OBJECTS = $(CSOURCES:.c=.obj)
67
$(CXX) -c $(INCDIRS) $(CXXFLAGS) $(DEFINES) $<
94
$(PP_CMD) $(CC_FLAGS) $(INCDIRS) $(DEFINES) -o$(@R).int $(<)
95
$(CC_CMD) $(CC_FLAGS) -o$(@) $(@R).int
69
all: $(LIBCURL_LIB) $(LIBCURL_DLL)
97
all: $(OBJDIR) $(LIBCURL_LIB) $(LIBCURL_DLL)
73
-$(RM) $(LIBCURL_IMPLIB)
101
@-$(RM) $(LIBCURL_LIB)
102
@-$(RM) $(LIBCURL_IMPLIB)
77
109
$(LIBCURL_LIB): $(OBJECTS)
110
@-$(RM) $(LIBCURL_LIB)
79
111
$(LIB) $(LIBFLAGS) $@ @&&!