blob: bcd0c6205eafec1f2eb7dab5decfbd240678614e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
|
# This makefile builds the user-mode component
# of OpenVPN for WIN32 in the MSVC++ environment.
#
# Build Dependencies:
# OpenSSL (SSL/TLS/crypto library)
# LZO (real-time compression library)
#
# Targets:
# static -- link statically with OpenSSL
# dynamic -- link dynamically with OpenSSL
#
# Note that LZO is always linked statically.
# Change these to point to your OpenSSL and LZO top-level
# directories.
OPENSSL = \src\openssl-0.9.7d
OPENSSL_STATIC = libeay32s.lib ssleay32s.lib
#OPENSSL_STATIC = libeay32sd.lib ssleay32sd.lib
OPENSSL_DYNAMIC = libeay32.lib ssleay32.lib
#OPENSSL_DYNAMIC = libeay32d.lib ssleay32d.lib
LZO = \src\lzo-1.08.vc
INCLUDE_DIRS = -I$(OPENSSL)/include -I$(LZO)/include
LIBS = lzo.lib ws2_32.lib crypt32.lib iphlpapi.lib winmm.lib gdi32.lib advapi32.lib
LIB_DIRS = -LIBPATH:$(OPENSSL)\out -LIBPATH:$(LZO)
EXE = openvpn.exe
CPP=cl.exe
# release:
CPP_PROJ=/nologo /MD /W3 /G5 /O2 -DNDEBUG -DWIN32 -DWIN32_LEAN_AND_MEAN -D_CONSOLE -D_MBCS $(INCLUDE_DIRS) /FD /c
# debug:
#CPP_PROJ=/nologo /MDd /W3 /G5 /Zi /Od -D_DEBUG -DWIN32 -DWIN32_LEAN_AND_MEAN -D_CONSOLE -D_MBCS $(INCLUDE_DIRS) /FD /c
LINK32=link.exe
# release:
LINK32_FLAGS=/nologo /subsystem:console /incremental:no /out:"$(EXE)"
# debug:
#LINK32_FLAGS=/nologo /subsystem:console /incremental:no /debug /out:"$(EXE)"
# Make sure the HEADERS and OBJS definitions below match the same
# definitions in makefile.w32.
HEADERS = \
base64.h \
basic.h \
buffer.h \
circ_list.h common.h \
tap-win32/common.h \
config-win32.h \
crypto.h \
cryptoapi.h \
errlevel.h \
error.h \
event.h \
fdmisc.h \
forward-inline.h \
forward.h \
fragment.h \
gremlin.h \
helper.h \
init.h \
integer.h \
interval.h \
list.h \
lzo.h \
manage.h \
mbuf.h \
memdbg.h \
misc.h \
mroute.h \
mss.h \
mtcp.h \
mtu.h \
mudp.h \
multi.h \
ntlm.h \
occ-inline.h \
occ.h \
pkcs11.h \
openvpn.h \
openvpn-plugin.h \
options.h \
otime.h \
packet_id.h \
perf.h \
ping-inline.h \
ping.h \
plugin.h \
pool.h \
proto.h \
proxy.h \
push.h \
reliable.h \
route.h \
schedule.h \
session_id.h \
shaper.h \
sig.h \
socket.h \
socks.h \
ssl.h \
status.h \
syshead.h \
thread.h \
tun.h \
win32.h
OBJS = base64.obj \
buffer.obj \
crypto.obj \
cryptoapi.obj \
error.obj \
event.obj \
fdmisc.obj \
forward.obj \
fragment.obj \
gremlin.obj \
helper.obj \
init.obj \
interval.obj \
list.obj \
lzo.obj \
manage.obj \
mbuf.obj \
misc.obj \
mroute.obj \
mss.obj \
mtcp.obj \
mtu.obj \
mudp.obj \
multi.obj \
ntlm.obj \
occ.obj \
pkcs11.obj \
openvpn.obj \
options.obj \
otime.obj \
packet_id.obj \
perf.obj \
ping.obj \
plugin.obj \
pool.obj \
proto.obj \
proxy.obj \
push.obj \
reliable.obj \
route.obj \
schedule.obj \
session_id.obj \
shaper.obj \
sig.obj \
socket.obj \
socks.obj \
ssl.obj \
status.obj \
thread.obj \
tun.obj \
win32.obj
dynamic : $(OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LIB_DIRS) $(LIBS) $(OPENSSL_DYNAMIC) $(OBJS)
<<
static : $(OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LIB_DIRS) $(LIBS) $(OPENSSL_STATIC) $(OBJS)
<<
clean :
del /Q $(OBJS) $(EXE) *.idb *.pdb
.c.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
|