-
Notifications
You must be signed in to change notification settings - Fork 10
/
Makefile
320 lines (291 loc) · 15 KB
/
Makefile
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
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
#
# The contents of this file are subject to the terms of the Common Development and
# Distribution License (the License). You may not use this file except in compliance with the
# License.
#
# You can obtain a copy of the License at legal/CDDLv1.0.txt. See the License for the
# specific language governing permission and limitations under the License.
#
# When distributing Covered Software, include this CDDL Header Notice in each file and include
# the License file at legal/CDDLv1.0.txt. If applicable, add the following below the CDDL
# Header, with the fields enclosed by brackets [] replaced by your own identifying
# information: "Portions copyright [year] [name of copyright owner]".
#
# Copyright 2014 - 2016 ForgeRock AS.
#
# make options:
# 64=1 builds 64bit binary
# DEBUG=1 builds debug binary version
64=1
# DEBUG=1
VERSION := 4.1.0
ifneq ("$(PROGRAMFILES)$(ProgramFiles)","")
OS_ARCH := WINNT
RMALL := cmd /c del /F /Q
RMDIR := cmd /c rmdir /S /Q
SED := cmd /c sed.exe
ECHO := cmd /c echo
MKDIR := cmd /c mkdir
CP := cmd /c copy /Y
CD := cd
EXEC :=
REVISION := Revision: $(shell git rev-parse --short HEAD)
BUILD_MACHINE := $(shell hostname)
IDENT_DATE := $(shell powershell get-date -format "{dd.MM.yyyy}")
PATHSEP=\\
SUB=/
COMPILEFLAG=/
COMPILEOPTS=/[email protected] /Fo$(dir $@)
OBJ=obj
else
OS_ARCH := $(shell uname -s)
OS_MARCH := $(shell uname -m)
RMALL := rm -fr
RMDIR := $(RMALL)
SED := sed
ECHO := echo
MKDIR := mkdir -p
CP := cp
CD := cd
EXEC := ./
REVISION := Revision: $(shell git rev-parse --short HEAD)
BUILD_MACHINE := $(shell hostname)
IDENT_DATE := $(shell date +'%d.%m.%y')
PATHSEP=/
SUB=%
COMPILEFLAG=-
COMPILEOPTS=-c -o $@
OBJ=o
endif
SED_ROPT := r
OS_ARCH_EXT :=
ifdef 64
OS_BITS := _64bit
else
OS_BITS :=
endif
PS=$(strip $(PATHSEP))
CFLAGS := $(COMPILEFLAG)I.$(PS)source $(COMPILEFLAG)I.$(PS)zlib $(COMPILEFLAG)I.$(PS)expat $(COMPILEFLAG)I.$(PS)pcre \
$(COMPILEFLAG)DHAVE_EXPAT_CONFIG_H $(COMPILEFLAG)DHAVE_PCRE_CONFIG_H $(COMPILEFLAG)DAM_BINARY_LICENSE
OBJDIR := build
APACHE_SOURCES := source/apache/agent.c
APACHE22_SOURCES := source/apache/agent22.c
IIS_SOURCES := source/iis/agent.c
VARNISH_SOURCES := source/varnish/agent.c source/varnish/vcc_if.c
VARNISH_ASM_SOURCES := source/varnish/remap_64.s
VARNISH3_SOURCES := source/varnish3/agent.c source/varnish3/vcc_if.c
VARNISH3_ASM_SOURCES := source/varnish3/remap_64.s
ADMIN_SOURCES := source/admin.c source/admin_iis.c
SOURCES := $(filter-out $(ADMIN_SOURCES), $(wildcard source/*.c)) $(wildcard expat/*.c) $(wildcard pcre/*.c) $(wildcard zlib/*.c)
OBJECTS := $(SOURCES:.c=.$(OBJ))
OUT_OBJS := $(addprefix $(OBJDIR)/,$(OBJECTS))
ADMIN_OBJECTS := $(ADMIN_SOURCES:.c=.$(OBJ))
ADMIN_OUT_OBJS := $(addprefix $(OBJDIR)/,$(ADMIN_OBJECTS))
APACHE_OBJECTS := $(APACHE_SOURCES:.c=.$(OBJ))
APACHE22_OBJECTS := $(APACHE22_SOURCES:.c=.$(OBJ))
APACHE_OUT_OBJS := $(addprefix $(OBJDIR)/,$(APACHE_OBJECTS))
APACHE22_OUT_OBJS := $(addprefix $(OBJDIR)/,$(APACHE22_OBJECTS))
IIS_OBJECTS := $(IIS_SOURCES:.c=.$(OBJ))
IIS_OUT_OBJS := $(addprefix $(OBJDIR)/,$(IIS_OBJECTS))
VARNISH_OBJECTS := $(VARNISH_SOURCES:.c=.$(OBJ))
VARNISH_OUT_OBJS := $(addprefix $(OBJDIR)/,$(VARNISH_OBJECTS))
VARNISH_ASM_OBJS := $(addprefix $(OBJDIR)/,$(VARNISH_ASM_SOURCES:.s=.$(OBJ)))
VARNISH3_OBJECTS := $(VARNISH3_SOURCES:.c=.$(OBJ))
VARNISH3_ASM_OBJS := $(addprefix $(OBJDIR)/,$(VARNISH3_ASM_SOURCES:.s=.$(OBJ)))
VARNISH3_OUT_OBJS := $(addprefix $(OBJDIR)/,$(VARNISH3_OBJECTS))
ifdef TESTS
TEST_FILES := $(addprefix tests/,$(addsuffix .c,$(TESTS)))
else
TEST_FILES := $(filter-out test_MAIN.c, $(wildcard tests/*.c))
endif
TEST_SOURCES := $(wildcard cmocka/*.c) $(wildcard tests/*.c)
TEST_OBJECTS := $(addprefix $(OBJDIR)/,$(TEST_SOURCES:.c=.$(OBJ)))
$(APACHE_OUT_OBJS): CFLAGS += $(COMPILEFLAG)Iextlib/$(OS_ARCH)_$(OS_MARCH)/apache24/include \
$(COMPILEFLAG)Iextlib/$(OS_ARCH)$(OS_MARCH)/apache24/include \
$(COMPILEFLAG)Iextlib/$(OS_ARCH)/apache24/include $(COMPILEFLAG)DAPACHE2 $(COMPILEFLAG)DAPACHE24
$(VARNISH_OUT_OBJS): CFLAGS += $(COMPILEFLAG)Iextlib/$(OS_ARCH)/varnish/include
$(VARNISH3_OUT_OBJS): CFLAGS += $(COMPILEFLAG)Iextlib/$(OS_ARCH)/varnish3/include
$(APACHE22_OUT_OBJS): CFLAGS += $(COMPILEFLAG)Iextlib/$(OS_ARCH)_$(OS_MARCH)/apache22/include \
$(COMPILEFLAG)Iextlib/$(OS_ARCH)$(OS_MARCH)/apache22/include \
$(COMPILEFLAG)Iextlib/$(OS_ARCH)/apache22$(VENDOR_EXT)/include $(COMPILEFLAG)DAPACHE2
$(TEST_OBJECTS): CFLAGS += $(COMPILEFLAG)I.$(PS)cmocka $(COMPILEFLAG)I.$(PS)tests $(COMPILEFLAG)I.$(PS)$(OBJDIR)$(PS)tests \
$(COMPILEFLAG)DHAVE_SIGNAL_H $(COMPILEFLAG)DUNIT_TEST
ifeq ($(OS_ARCH), Linux)
include Makefile.linux.mk
endif
ifeq ($(OS_ARCH), SunOS)
include Makefile.solaris.mk
endif
ifeq ($(OS_ARCH), AIX)
include Makefile.aix.mk
endif
ifeq ($(OS_ARCH), Darwin)
include Makefile.macos.mk
SED_ROPT := E
endif
ifeq ($(OS_ARCH), WINNT)
include Makefile.windows.mk
endif
VERSION_NUM := $(shell $(ECHO) $(VERSION) | $(SED) "s/[^-\.0-9]*//g" | $(SED) "s/[\.-]/,/g" | $(SED) "/.*,$$/ s/$$/0/")
$(OBJDIR)/%.$(OBJ): %.c
@$(ECHO) "[*** Compiling "$<" ***]"
$(CC) $(CFLAGS) $< $(COMPILEOPTS)
$(OBJDIR)/%.$(OBJ): %.s
@$(ECHO) "[*** Compiling "$<" ***]"
$(CC) $(CFLAGS) $< $(COMPILEOPTS)
.DEFAULT_GOAL := all
all: apachezip
build:
$(MKDIR) $(OBJDIR)$(PS)expat
$(MKDIR) $(OBJDIR)$(PS)pcre
$(MKDIR) $(OBJDIR)$(PS)zlib
$(MKDIR) $(OBJDIR)$(PS)cmocka
$(MKDIR) $(OBJDIR)$(PS)tests
$(MKDIR) $(OBJDIR)$(PS)dist
$(MKDIR) $(OBJDIR)$(PS)64
$(MKDIR) $(OBJDIR)$(PS)64$(PS)expat
$(MKDIR) $(OBJDIR)$(PS)64$(PS)pcre
$(MKDIR) $(OBJDIR)$(PS)64$(PS)zlib
$(MKDIR) $(OBJDIR)$(PS)64$(PS)source
$(MKDIR) $(OBJDIR)$(PS)source$(PS)apache
$(MKDIR) $(OBJDIR)$(PS)source$(PS)iis
$(MKDIR) $(OBJDIR)$(PS)64$(PS)source$(PS)iis
$(MKDIR) $(OBJDIR)$(PS)source$(PS)varnish
$(MKDIR) $(OBJDIR)$(PS)source$(PS)varnish3
version:
@$(ECHO) "[***** Updating version.h *****]"
-$(RMALL) source$(PS)version.h
$(SED) -e "s$(SUB)_REVISION_$(SUB)$(REVISION)$(SUB)g" \
-e "s$(SUB)_IDENT_DATE_$(SUB)$(IDENT_DATE)$(SUB)g" \
-e "s$(SUB)_BUILD_MACHINE_$(SUB)$(BUILD_MACHINE)$(SUB)g" \
-e "s$(SUB)_VERSION_NUM_$(SUB)$(VERSION_NUM)$(SUB)g" \
-e "s$(SUB)_CONTAINER_$(SUB)$(CONTAINER)$(SUB)g" \
-e "s$(SUB)_VERSION_$(SUB)$(VERSION)$(SUB)g" < source$(PS)version.template > source$(PS)version.h
clean:
-$(RMDIR) $(OBJDIR)
-$(RMALL) source$(PS)version.h
test_includes:
@$(ECHO) "[***** Creating tests.h *****]"
-$(MKDIR) $(OBJDIR)$(PS)tests
-$(RMALL) $(OBJDIR)$(PS)tests$(PS)tests.h
$(SED) -$(SED_ROPT) "/.*static.+/d" $(TEST_FILES) | $(SED) -$(SED_ROPT)n "/.*\(void[ \t]*\*\*[ \t]*state\)/p" | sed -$(SED_ROPT) "s/\{/\;/g" > $(OBJDIR)$(PS)tests$(PS)tests.h.template
$(CP) $(OBJDIR)$(PS)tests$(PS)tests.h.template $(OBJDIR)$(PS)tests$(PS)tests.h
$(ECHO) "const struct CMUnitTest tests[] = {" >> $(OBJDIR)$(PS)tests$(PS)tests.h
$(SED) -$(SED_ROPT)n "s/void (test_.*[^\(])\(.*/cmocka_unit_test(\1),/p" $(OBJDIR)$(PS)tests$(PS)tests.h.template >> $(OBJDIR)$(PS)tests$(PS)tests.h
$(ECHO) "};" >> $(OBJDIR)$(PS)tests$(PS)tests.h
$(SED) -ie "s$(SUB)\"$(SUB) $(SUB)g" $(OBJDIR)$(PS)tests$(PS)tests.h
apachezip: CFLAGS += $(COMPILEFLAG)DSERVER_VERSION='"2.4.x"'
apachezip: CONTAINER = $(strip Apache 2.4 $(OS_ARCH)$(OS_ARCH_EXT) $(subst _,,$(OS_BITS)))
apachezip: clean build version apache agentadmin
@$(ECHO) "[***** Building Apache 2.4 agent archive *****]"
-$(MKDIR) $(OBJDIR)$(PS)web_agents
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache24_agent
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache24_agent$(PS)bin
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache24_agent$(PS)lib
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache24_agent$(PS)legal
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache24_agent$(PS)instances
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache24_agent$(PS)log
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache24_agent$(PS)config
-$(CP) $(OBJDIR)$(PS)agentadmin* $(OBJDIR)$(PS)web_agents$(PS)apache24_agent$(PS)bin$(PS)
-$(CP) $(OBJDIR)$(PS)mod_openam.so $(OBJDIR)$(PS)web_agents$(PS)apache24_agent$(PS)lib$(PS)
-$(CP) $(OBJDIR)$(PS)mod_openam.dll $(OBJDIR)$(PS)web_agents$(PS)apache24_agent$(PS)lib$(PS)
-$(CP) $(OBJDIR)$(PS)mod_openam.pdb $(OBJDIR)$(PS)web_agents$(PS)apache24_agent$(PS)lib$(PS)
-$(CP) config$(PS)* $(OBJDIR)$(PS)web_agents$(PS)apache24_agent$(PS)config$(PS)
-$(CP) legal$(PS)* $(OBJDIR)$(PS)web_agents$(PS)apache24_agent$(PS)legal$(PS)
$(CD) $(OBJDIR) && $(EXEC)agentadmin --a Apache_v24_$(OS_ARCH)$(OS_ARCH_EXT)$(OS_BITS)_$(VERSION).zip web_agents
apache22_pre:
-$(CP) source$(PS)apache$(PS)agent.c source$(PS)apache$(PS)agent22.c
apache22_post:
-$(RMALL) source$(PS)apache$(PS)agent22.c
apache22zip: CFLAGS += $(COMPILEFLAG)DSERVER_VERSION='"2.2.x"'
apache22zip: CONTAINER = $(strip Apache 2.2 $(OS_ARCH)$(OS_ARCH_EXT) $(subst _,,$(OS_BITS)))
apache22zip: clean build version apache22 agentadmin
@$(ECHO) "[***** Building Apache 2.2 agent archive *****]"
-$(MKDIR) $(OBJDIR)$(PS)web_agents
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache22_agent
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache22_agent$(PS)bin
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache22_agent$(PS)lib
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache22_agent$(PS)legal
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache22_agent$(PS)instances
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache22_agent$(PS)log
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)apache22_agent$(PS)config
-$(CP) $(OBJDIR)$(PS)agentadmin* $(OBJDIR)$(PS)web_agents$(PS)apache22_agent$(PS)bin$(PS)
-$(CP) $(OBJDIR)$(PS)mod_openam.so $(OBJDIR)$(PS)web_agents$(PS)apache22_agent$(PS)lib$(PS)
-$(CP) $(OBJDIR)$(PS)mod_openam.dll $(OBJDIR)$(PS)web_agents$(PS)apache22_agent$(PS)lib$(PS)
-$(CP) $(OBJDIR)$(PS)mod_openam.pdb $(OBJDIR)$(PS)web_agents$(PS)apache22_agent$(PS)lib$(PS)
-$(CP) config$(PS)* $(OBJDIR)$(PS)web_agents$(PS)apache22_agent$(PS)config$(PS)
-$(CP) legal$(PS)* $(OBJDIR)$(PS)web_agents$(PS)apache22_agent$(PS)legal$(PS)
$(CD) $(OBJDIR) && $(EXEC)agentadmin --a Apache_v22_$(OS_ARCH)$(OS_ARCH_EXT)$(OS_BITS)_$(VERSION).zip web_agents
ibmhttp7zip: CFLAGS += $(COMPILEFLAG)DSERVER_VERSION='"2.2.x (IBM HTTP Server 7)"'
ibmhttp7zip: VENDOR_EXT = _ibmhttp
ibmhttp7zip: CONTAINER = $(strip IBM HTTP Server 7 $(OS_ARCH)$(OS_ARCH_EXT) $(subst _,,$(OS_BITS)))
ibmhttp7zip: clean build version apache22 agentadmin
@$(ECHO) "[***** Building IBM HTTP Server 7 agent archive *****]"
-$(MKDIR) $(OBJDIR)$(PS)web_agents
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)httpserver7_agent
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)httpserver7_agent$(PS)bin
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)httpserver7_agent$(PS)lib
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)httpserver7_agent$(PS)legal
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)httpserver7_agent$(PS)instances
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)httpserver7_agent$(PS)log
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)httpserver7_agent$(PS)config
-$(CP) $(OBJDIR)$(PS)agentadmin* $(OBJDIR)$(PS)web_agents$(PS)httpserver7_agent$(PS)bin$(PS)
-$(CP) $(OBJDIR)$(PS)mod_openam.so $(OBJDIR)$(PS)web_agents$(PS)httpserver7_agent$(PS)lib$(PS)
-$(CP) $(OBJDIR)$(PS)mod_openam.dll $(OBJDIR)$(PS)web_agents$(PS)httpserver7_agent$(PS)lib$(PS)
-$(CP) $(OBJDIR)$(PS)mod_openam.pdb $(OBJDIR)$(PS)web_agents$(PS)httpserver7_agent$(PS)lib$(PS)
-$(CP) config$(PS)* $(OBJDIR)$(PS)web_agents$(PS)httpserver7_agent$(PS)config$(PS)
-$(CP) legal$(PS)* $(OBJDIR)$(PS)web_agents$(PS)httpserver7_agent$(PS)legal$(PS)
$(CD) $(OBJDIR) && $(EXEC)agentadmin --a IBMHTTP_v7_$(OS_ARCH)$(OS_ARCH_EXT)$(OS_BITS)_$(VERSION).zip web_agents
iiszip: CFLAGS += $(COMPILEFLAG)DSERVER_VERSION='"7.5, 8.x"'
iiszip: CONTAINER = $(strip IIS 7.5, 8.x $(OS_ARCH)$(OS_ARCH_EXT) 32\/64bit)
iiszip: clean build version iis
@$(ECHO) "[***** Building IIS agent archive *****]"
-$(MKDIR) $(OBJDIR)$(PS)web_agents
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)iis_agent
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)iis_agent$(PS)bin
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)iis_agent$(PS)lib
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)iis_agent$(PS)legal
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)iis_agent$(PS)instances
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)iis_agent$(PS)log
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)iis_agent$(PS)config
-$(CP) $(OBJDIR)$(PS)dist$(PS)agentadmin* $(OBJDIR)$(PS)web_agents$(PS)iis_agent$(PS)bin$(PS)
-$(CP) $(OBJDIR)$(PS)dist$(PS)mod_iis_openam* $(OBJDIR)$(PS)web_agents$(PS)iis_agent$(PS)lib$(PS)
-$(CP) config$(PS)* $(OBJDIR)$(PS)web_agents$(PS)iis_agent$(PS)config$(PS)
-$(CP) legal$(PS)* $(OBJDIR)$(PS)web_agents$(PS)iis_agent$(PS)legal$(PS)
$(CD) $(OBJDIR) && $(EXEC)agentadmin --a IIS_$(OS_ARCH)_$(VERSION).zip web_agents
varnishzip: CFLAGS += $(COMPILEFLAG)DSERVER_VERSION='"4.1.x"'
varnishzip: CONTAINER = $(strip Varnish 4.1.x $(OS_ARCH)$(OS_ARCH_EXT) $(subst _,,$(OS_BITS)))
varnishzip: clean build version varnish agentadmin
@$(ECHO) "[***** Building Varnish agent archive *****]"
-$(MKDIR) $(OBJDIR)$(PS)web_agents
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish_agent
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish_agent$(PS)bin
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish_agent$(PS)lib
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish_agent$(PS)legal
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish_agent$(PS)instances
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish_agent$(PS)log
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish_agent$(PS)config
-$(CP) $(OBJDIR)$(PS)agentadmin* $(OBJDIR)$(PS)web_agents$(PS)varnish_agent$(PS)bin$(PS)
-$(CP) $(OBJDIR)$(PS)libvmod_am.so $(OBJDIR)$(PS)web_agents$(PS)varnish_agent$(PS)lib$(PS)
-$(CP) config$(PS)* $(OBJDIR)$(PS)web_agents$(PS)varnish_agent$(PS)config$(PS)
-$(CP) legal$(PS)* $(OBJDIR)$(PS)web_agents$(PS)varnish_agent$(PS)legal$(PS)
$(CD) $(OBJDIR) && $(EXEC)agentadmin --a Varnish_v4_$(OS_ARCH)$(OS_ARCH_EXT)$(OS_BITS)_$(VERSION).zip web_agents
varnish3zip: CFLAGS += $(COMPILEFLAG)DSERVER_VERSION='"3.0.x"'
varnish3zip: CONTAINER = $(strip Varnish 3.0.x $(OS_ARCH)$(OS_ARCH_EXT) $(subst _,,$(OS_BITS)))
varnish3zip: clean build version varnish3 agentadmin
@$(ECHO) "[***** Building Varnish agent archive *****]"
-$(MKDIR) $(OBJDIR)$(PS)web_agents
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent$(PS)bin
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent$(PS)lib
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent$(PS)legal
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent$(PS)instances
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent$(PS)log
-$(MKDIR) $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent$(PS)config
-$(CP) $(OBJDIR)$(PS)agentadmin* $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent$(PS)bin$(PS)
-$(CP) $(OBJDIR)$(PS)libvmod_am.so $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent$(PS)lib$(PS)
-$(CP) config$(PS)* $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent$(PS)config$(PS)
-$(CP) $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent$(PS)config$(PS)agent.vcl3.template $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent$(PS)config$(PS)agent.vcl.template
-$(RMALL) $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent$(PS)config$(PS)agent.vcl3.template
-$(CP) legal$(PS)* $(OBJDIR)$(PS)web_agents$(PS)varnish3_agent$(PS)legal$(PS)
$(CD) $(OBJDIR) && $(EXEC)agentadmin --a Varnish_v3_$(OS_ARCH)$(OS_ARCH_EXT)$(OS_BITS)_$(VERSION).zip web_agents