ac3216c5b322caa31c09a7ac258b9afa76b687e4
[ira/wip.git] / source / torture / config.mk
1 # TORTURE subsystem
2 [LIBRARY::torture]
3 SO_VERSION = 0
4 VERSION = 0.0.1
5 PC_FILE = torture.pc
6 PUBLIC_HEADERS = torture.h ui.h
7 PUBLIC_PROTO_HEADER = proto.h
8 OBJ_FILES = \
9                 torture.o \
10                 ui.o
11 PUBLIC_DEPENDENCIES = \
12                 LIBSAMBA-CONFIG \
13                 LIBSAMBA-UTIL \
14                 LIBTALLOC 
15
16 [SUBSYSTEM::TORTURE_UTIL]
17 OBJ_FILES = util.o util_smb.o
18 PRIVATE_DEPENDENCIES = LIBCLI_RAW
19 PUBLIC_PROTO_HEADER = util.h
20 PUBLIC_DEPENDENCIES = POPT_CREDENTIALS
21
22 #################################
23 # Start SUBSYSTEM TORTURE_BASIC
24 [MODULE::TORTURE_BASIC]
25 SUBSYSTEM = torture
26 INIT_FUNCTION = torture_base_init
27 PRIVATE_PROTO_HEADER = \
28                 basic/proto.h
29 OBJ_FILES = \
30                 basic/base.o \
31                 basic/misc.o \
32                 basic/scanner.o \
33                 basic/utable.o \
34                 basic/charset.o \
35                 basic/mangle_test.o \
36                 basic/denytest.o \
37                 basic/aliases.o \
38                 basic/locking.o \
39                 basic/secleak.o \
40                 basic/rename.o \
41                 basic/dir.o \
42                 basic/delete.o \
43                 basic/unlink.o \
44                 basic/disconnect.o \
45                 basic/delaywrite.o \
46                 basic/attr.o \
47                 basic/properties.o 
48 PRIVATE_DEPENDENCIES = \
49                 LIBCLI_SMB POPT_CREDENTIALS \
50                 TORTURE_UTIL LIBCLI_RAW \
51                 TORTURE_RAW
52 # End SUBSYSTEM TORTURE_BASIC
53 #################################
54
55 #################################
56 # Start SUBSYSTEM TORTURE_RAW
57 [MODULE::TORTURE_RAW]
58 SUBSYSTEM = torture
59 INIT_FUNCTION = torture_raw_init
60 PRIVATE_PROTO_HEADER = \
61                 raw/proto.h
62 OBJ_FILES = \
63                 raw/qfsinfo.o \
64                 raw/qfileinfo.o \
65                 raw/setfileinfo.o \
66                 raw/search.o \
67                 raw/close.o \
68                 raw/open.o \
69                 raw/mkdir.o \
70                 raw/oplock.o \
71                 raw/notify.o \
72                 raw/mux.o \
73                 raw/ioctl.o \
74                 raw/chkpath.o \
75                 raw/unlink.o \
76                 raw/read.o \
77                 raw/context.o \
78                 raw/write.o \
79                 raw/lock.o \
80                 raw/pingpong.o \
81                 raw/lockbench.o \
82                 raw/openbench.o \
83                 raw/rename.o \
84                 raw/eas.o \
85                 raw/streams.o \
86                 raw/acls.o \
87                 raw/seek.o \
88                 raw/samba3hide.o \
89                 raw/samba3misc.o \
90                 raw/composite.o \
91                 raw/raw.o \
92                 raw/offline.o
93 PRIVATE_DEPENDENCIES = \
94                 LIBCLI_SMB LIBCLI_LSA LIBCLI_SMB_COMPOSITE \
95                 POPT_CREDENTIALS TORTURE_UTIL
96 # End SUBSYSTEM TORTURE_RAW
97 #################################
98
99 include smb2/config.mk
100 include winbind/config.mk
101
102 [SUBSYSTEM::TORTURE_NDR]
103 PRIVATE_PROTO_HEADER = ndr/proto.h
104 OBJ_FILES = ndr/ndr.o \
105                         ndr/winreg.o \
106                         ndr/atsvc.o \
107                         ndr/lsa.o \
108                         ndr/epmap.o \
109                         ndr/dfs.o \
110                         ndr/netlogon.o \
111                         ndr/drsuapi.o \
112                         ndr/spoolss.o \
113                         ndr/samr.o
114
115 [MODULE::torture_rpc]
116 # TORTURE_NET and TORTURE_NBT use functions from torture_rpc...
117 #OUTPUT_TYPE = INTEGRATED
118 SUBSYSTEM = torture
119 INIT_FUNCTION = torture_rpc_init
120 PRIVATE_PROTO_HEADER = \
121                 rpc/proto.h
122 OBJ_FILES = \
123                 rpc/join.o \
124                 rpc/lsa.o \
125                 rpc/lsa_lookup.o \
126                 rpc/session_key.o \
127                 rpc/echo.o \
128                 rpc/dfs.o \
129                 rpc/drsuapi.o \
130                 rpc/drsuapi_cracknames.o \
131                 rpc/dssync.o \
132                 rpc/spoolss.o \
133                 rpc/spoolss_notify.o \
134                 rpc/spoolss_win.o \
135                 rpc/unixinfo.o \
136                 rpc/samr.o \
137                 rpc/samr_accessmask.o \
138                 rpc/wkssvc.o \
139                 rpc/srvsvc.o \
140                 rpc/svcctl.o \
141                 rpc/atsvc.o \
142                 rpc/eventlog.o \
143                 rpc/epmapper.o \
144                 rpc/winreg.o \
145                 rpc/initshutdown.o \
146                 rpc/oxidresolve.o \
147                 rpc/remact.o \
148                 rpc/mgmt.o \
149                 rpc/scanner.o \
150                 rpc/autoidl.o \
151                 rpc/countcalls.o \
152                 rpc/testjoin.o \
153                 rpc/schannel.o \
154                 rpc/netlogon.o \
155                 rpc/samlogon.o \
156                 rpc/samsync.o \
157                 rpc/bind.o \
158                 rpc/dssetup.o \
159                 rpc/alter_context.o \
160                 rpc/bench.o \
161                 rpc/samba3rpc.o \
162                 rpc/rpc.o \
163                 rpc/async_bind.o \
164                 rpc/handles.o \
165                 rpc/frsapi.o
166 PRIVATE_DEPENDENCIES = \
167                 NDR_TABLE RPC_NDR_UNIXINFO dcerpc_samr RPC_NDR_WINREG RPC_NDR_INITSHUTDOWN \
168                 RPC_NDR_OXIDRESOLVER RPC_NDR_EVENTLOG RPC_NDR_ECHO RPC_NDR_SVCCTL \
169                 RPC_NDR_NETLOGON dcerpc_atsvc dcerpc_mgmt RPC_NDR_DRSUAPI \
170                 RPC_NDR_LSA RPC_NDR_EPMAPPER RPC_NDR_DFS RPC_NDR_FRSAPI RPC_NDR_SPOOLSS \
171                 RPC_NDR_SRVSVC RPC_NDR_WKSSVC RPC_NDR_ROT RPC_NDR_DSSETUP \
172                 RPC_NDR_REMACT RPC_NDR_OXIDRESOLVER WB_HELPER LIBSAMBA-NET \
173                 LIBCLI_AUTH POPT_CREDENTIALS TORTURE_LDAP TORTURE_UTIL TORTURE_RAP \
174                 dcerpc_server service process_model
175
176 #################################
177 # Start SUBSYSTEM TORTURE_RAP
178 [MODULE::TORTURE_RAP]
179 SUBSYSTEM = torture
180 INIT_FUNCTION = torture_rap_init
181 PRIVATE_PROTO_HEADER = \
182                 rap/proto.h
183 OBJ_FILES = \
184                 rap/rap.o
185 PRIVATE_DEPENDENCIES = TORTURE_UTIL LIBCLI_SMB
186 # End SUBSYSTEM TORTURE_RAP
187 #################################
188
189 #################################
190 # Start SUBSYSTEM TORTURE_AUTH
191 [MODULE::TORTURE_AUTH]
192 SUBSYSTEM = torture
193 PRIVATE_PROTO_HEADER = \
194                 auth/proto.h
195 OBJ_FILES = \
196                 auth/ntlmssp.o \
197                 auth/pac.o
198 PRIVATE_DEPENDENCIES = \
199                 LIBCLI_SMB gensec auth LIBSAMBA3 KERBEROS \
200                 POPT_CREDENTIALS
201 # End SUBSYSTEM TORTURE_AUTH
202 #################################
203
204 include local/config.mk
205
206 #################################
207 # Start MODULE TORTURE_NBENCH
208 [MODULE::TORTURE_NBENCH]
209 SUBSYSTEM = torture
210 INIT_FUNCTION = torture_nbench_init
211 PRIVATE_DEPENDENCIES = TORTURE_UTIL 
212 PRIVATE_PROTO_HEADER = \
213                 nbench/proto.h
214 OBJ_FILES = \
215                 nbench/nbio.o \
216                 nbench/nbench.o
217 # End MODULE TORTURE_NBENCH
218 #################################
219
220 #################################
221 # Start MODULE TORTURE_UNIX
222 [MODULE::TORTURE_UNIX]
223 SUBSYSTEM = torture
224 INIT_FUNCTION = torture_unix_init
225 PRIVATE_DEPENDENCIES = TORTURE_UTIL 
226 PRIVATE_PROTO_HEADER = \
227                 unix/proto.h
228 OBJ_FILES = \
229                 unix/unix.o \
230                 unix/whoami.o \
231                 unix/unix_info2.o
232 # End MODULE TORTURE_UNIX
233 #################################
234
235 #################################
236 # Start SUBSYSTEM TORTURE_LDAP
237 [MODULE::TORTURE_LDAP]
238 SUBSYSTEM = torture
239 INIT_FUNCTION = torture_ldap_init
240 PRIVATE_PROTO_HEADER = \
241                 ldap/proto.h
242 OBJ_FILES = \
243                 ldap/common.o \
244                 ldap/basic.o \
245                 ldap/schema.o \
246                 ldap/uptodatevector.o \
247                 ldap/cldap.o \
248                 ldap/cldapbench.o
249 PRIVATE_DEPENDENCIES = \
250                 LIBCLI_LDAP LIBCLI_CLDAP SAMDB POPT_CREDENTIALS
251 # End SUBSYSTEM TORTURE_LDAP
252 #################################
253
254 #################################
255 # Start SUBSYSTEM TORTURE_NBT
256 [MODULE::TORTURE_NBT]
257 SUBSYSTEM = torture
258 INIT_FUNCTION = torture_nbt_init
259 PRIVATE_PROTO_HEADER = \
260                 nbt/proto.h
261 OBJ_FILES = \
262                 nbt/query.o \
263                 nbt/register.o \
264                 nbt/wins.o \
265                 nbt/winsbench.o \
266                 nbt/winsreplication.o \
267                 nbt/dgram.o \
268                 nbt/nbt.o
269 PRIVATE_DEPENDENCIES = \
270                 LIBCLI_SMB LIBCLI_NBT LIBCLI_DGRAM LIBCLI_WREPL torture_rpc
271 # End SUBSYSTEM TORTURE_NBT
272 #################################
273
274 #################################
275 # Start SUBSYSTEM TORTURE_NET
276 [MODULE::TORTURE_NET]
277 SUBSYSTEM = torture
278 INIT_FUNCTION = torture_net_init
279 PRIVATE_PROTO_HEADER = \
280                 libnet/proto.h
281 OBJ_FILES = \
282                 libnet/libnet.o \
283                 libnet/utils.o \
284                 libnet/userinfo.o \
285                 libnet/userman.o \
286                 libnet/groupinfo.o \
287                 libnet/groupman.o \
288                 libnet/domain.o \
289                 libnet/libnet_lookup.o \
290                 libnet/libnet_user.o \
291                 libnet/libnet_group.o \
292                 libnet/libnet_share.o \
293                 libnet/libnet_rpc.o \
294                 libnet/libnet_domain.o \
295                 libnet/libnet_BecomeDC.o
296 PRIVATE_DEPENDENCIES = \
297                 LIBSAMBA-NET \
298                 smbcalls \
299                 POPT_CREDENTIALS \
300                 torture_rpc \
301                 LIBPYTHON
302 # End SUBSYSTEM TORTURE_NET
303 #################################
304
305 #################################
306 # Start BINARY smbtorture
307 [BINARY::smbtorture]
308 INSTALLDIR = BINDIR
309 OBJ_FILES = \
310                 smbtorture.o
311 PRIVATE_DEPENDENCIES = \
312                 torture \
313                 LIBPOPT \
314                 POPT_SAMBA \
315                 POPT_CREDENTIALS \
316                 dcerpc \
317                 LIBCLI_SMB \
318                 SMBREADLINE
319 MANPAGE = man/smbtorture.1
320 # End BINARY smbtorture
321 #################################
322
323 #################################
324 # Start BINARY gentest
325 [BINARY::gentest]
326 INSTALLDIR = BINDIR
327 OBJ_FILES = \
328                 gentest.o
329 PRIVATE_DEPENDENCIES = \
330                 LIBSAMBA-CONFIG \
331                 LIBSAMBA-UTIL \
332                 LIBPOPT \
333                 POPT_SAMBA \
334                 POPT_CREDENTIALS \
335                 LIBCLI_SMB \
336                 LIBCLI_RAW
337 MANPAGE = man/gentest.1
338 # End BINARY gentest
339 #################################
340
341 #################################
342 # Start BINARY masktest
343 [BINARY::masktest]
344 INSTALLDIR = BINDIR
345 OBJ_FILES = \
346                 masktest.o
347 PRIVATE_DEPENDENCIES = \
348                 LIBSAMBA-CONFIG \
349                 LIBSAMBA-UTIL \
350                 LIBPOPT \
351                 POPT_SAMBA \
352                 POPT_CREDENTIALS \
353                 LIBCLI_SMB
354 MANPAGE = man/masktest.1
355 # End BINARY masktest
356 #################################
357
358 #################################
359 # Start BINARY locktest
360 [BINARY::locktest]
361 INSTALLDIR = BINDIR
362 OBJ_FILES = \
363                 locktest.o
364 PRIVATE_DEPENDENCIES = \
365                 LIBSAMBA-UTIL \
366                 LIBCLI_SMB \
367                 LIBSAMBA-CONFIG
368 MANPAGE = man/locktest.1
369 # End BINARY locktest
370 #################################
371
372 GCOV_CFLAGS = -ftest-coverage -fprofile-arcs
373 GCOV_LDFLAGS = $(GCOV_CFLAGS) -lgcov
374
375 COV_TARGET = test
376
377 COV_VARS = \
378         CFLAGS="$(CFLAGS) $(GCOV_CFLAGS)" \
379         BNLD_FLAGS="$(BNLD_FLAGS) $(GCOV_LDFLAGS)" \
380         SHLD_FLAGS="$(SHLD_FLAGS) $(GCOV_LDFLAGS)" \
381         MDLD_FLAGS="$(MDLD_FLAGS) $(GCOV_LDFLAGS)" \
382         HOSTCC_FLAGS="$(HOSTCC_FLAGS) $(GCOV_CFLAGS)" \
383         HOSTLD_FLAGS="$(HOSTLD_FLAGS) $(GCOV_LDFLAGS)"
384
385 test_cov:
386         @$(MAKE) $(COV_TARGET) $(COV_VARS)
387
388 gcov: test_cov
389         for I in $(sort $(dir $(ALL_OBJS))); \
390                 do $(GCOV) -p -o $$I $$I/*.c; \
391         done
392
393 lcov-split: 
394         rm -f samba.info
395         @$(MAKE) $(COV_TARGET) $(COV_VARS) \
396                 TEST_OPTIONS="--analyse-cmd=\"lcov --base-directory `pwd` --directory . --capture --output-file samba.info -t\""
397         -rm heimdal/lib/*/{lex,parse}.{gcda,gcno}
398         genhtml -o coverage samba.info
399
400 lcov: test_cov
401         -rm heimdal/lib/*/{lex,parse}.{gcda,gcno}
402         lcov --base-directory `pwd` --directory . --capture --output-file samba.info
403         genhtml -o coverage samba.info
404
405 testcov-html:: lcov