r24937: Merge tests spoolss RPC callbacks.
[sfrench/samba-autobuild/.git] / source4 / torture / config.mk
1 # TORTURE subsystem
2 [LIBRARY::torture]
3 DESCRIPTION = Samba torture (test) suite
4 SO_VERSION = 0
5 VERSION = 0.0.1
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 PRIVATE_DEPENDENCIES = \
93                 LIBCLI_SMB LIBCLI_LSA LIBCLI_SMB_COMPOSITE \
94                 POPT_CREDENTIALS TORTURE_UTIL
95 # End SUBSYSTEM TORTURE_RAW
96 #################################
97
98 include smb2/config.mk
99
100 [SUBSYSTEM::TORTURE_NDR]
101 PRIVATE_PROTO_HEADER = ndr/proto.h
102 OBJ_FILES = ndr/ndr.o \
103                         ndr/winreg.o \
104                         ndr/atsvc.o \
105                         ndr/lsa.o \
106                         ndr/epmap.o \
107                         ndr/dfs.o \
108                         ndr/netlogon.o \
109                         ndr/drsuapi.o \
110                         ndr/spoolss.o \
111                         ndr/samr.o
112
113 [MODULE::torture_rpc]
114 # TORTURE_NET and TORTURE_NBT use functions from torture_rpc...
115 #OUTPUT_TYPE = INTEGRATED
116 SUBSYSTEM = torture
117 INIT_FUNCTION = torture_rpc_init
118 PRIVATE_PROTO_HEADER = \
119                 rpc/proto.h
120 OBJ_FILES = \
121                 rpc/join.o \
122                 rpc/lsa.o \
123                 rpc/lsa_lookup.o \
124                 rpc/session_key.o \
125                 rpc/echo.o \
126                 rpc/dfs.o \
127                 rpc/drsuapi.o \
128                 rpc/drsuapi_cracknames.o \
129                 rpc/dssync.o \
130                 rpc/spoolss.o \
131                 rpc/spoolss_notify.o \
132                 rpc/unixinfo.o \
133                 rpc/samr.o \
134                 rpc/wkssvc.o \
135                 rpc/srvsvc.o \
136                 rpc/svcctl.o \
137                 rpc/atsvc.o \
138                 rpc/eventlog.o \
139                 rpc/epmapper.o \
140                 rpc/winreg.o \
141                 rpc/initshutdown.o \
142                 rpc/oxidresolve.o \
143                 rpc/remact.o \
144                 rpc/mgmt.o \
145                 rpc/scanner.o \
146                 rpc/autoidl.o \
147                 rpc/countcalls.o \
148                 rpc/testjoin.o \
149                 rpc/schannel.o \
150                 rpc/netlogon.o \
151                 rpc/samlogon.o \
152                 rpc/samsync.o \
153                 rpc/bind.o \
154                 rpc/dssetup.o \
155                 rpc/alter_context.o \
156                 rpc/bench.o \
157                 rpc/samba3rpc.o \
158                 rpc/rpc.o \
159                 rpc/async_bind.o \
160                 rpc/handles.o
161 PRIVATE_DEPENDENCIES = \
162                 NDR_TABLE RPC_NDR_UNIXINFO dcerpc_samr RPC_NDR_WINREG RPC_NDR_INITSHUTDOWN \
163                 RPC_NDR_OXIDRESOLVER RPC_NDR_EVENTLOG RPC_NDR_ECHO RPC_NDR_SVCCTL \
164                 RPC_NDR_NETLOGON dcerpc_atsvc dcerpc_mgmt RPC_NDR_DRSUAPI \
165                 RPC_NDR_LSA RPC_NDR_EPMAPPER RPC_NDR_DFS RPC_NDR_SPOOLSS \
166                 RPC_NDR_SRVSVC RPC_NDR_WKSSVC RPC_NDR_ROT RPC_NDR_DSSETUP \
167                 RPC_NDR_REMACT RPC_NDR_OXIDRESOLVER WB_HELPER LIBSAMBA-NET \
168                 LIBCLI_AUTH POPT_CREDENTIALS TORTURE_LDAP TORTURE_UTIL TORTURE_RAP \
169                 dcerpc_server service process_model
170
171 #################################
172 # Start SUBSYSTEM TORTURE_RAP
173 [MODULE::TORTURE_RAP]
174 SUBSYSTEM = torture
175 INIT_FUNCTION = torture_rap_init
176 PRIVATE_PROTO_HEADER = \
177                 rap/proto.h
178 OBJ_FILES = \
179                 rap/rap.o
180 PRIVATE_DEPENDENCIES = TORTURE_UTIL LIBCLI_SMB
181 # End SUBSYSTEM TORTURE_RAP
182 #################################
183
184 #################################
185 # Start SUBSYSTEM TORTURE_AUTH
186 [MODULE::TORTURE_AUTH]
187 SUBSYSTEM = torture
188 PRIVATE_PROTO_HEADER = \
189                 auth/proto.h
190 OBJ_FILES = \
191                 auth/ntlmssp.o \
192                 auth/pac.o
193 PRIVATE_DEPENDENCIES = \
194                 LIBCLI_SMB gensec auth LIBSAMBA3 KERBEROS \
195                 POPT_CREDENTIALS
196 # End SUBSYSTEM TORTURE_AUTH
197 #################################
198
199 include local/config.mk
200
201 #################################
202 # Start MODULE TORTURE_NBENCH
203 [MODULE::TORTURE_NBENCH]
204 SUBSYSTEM = torture
205 INIT_FUNCTION = torture_nbench_init
206 PRIVATE_DEPENDENCIES = TORTURE_UTIL 
207 PRIVATE_PROTO_HEADER = \
208                 nbench/proto.h
209 OBJ_FILES = \
210                 nbench/nbio.o \
211                 nbench/nbench.o
212 # End MODULE TORTURE_NBENCH
213 #################################
214
215 #################################
216 # Start MODULE TORTURE_UNIX
217 [MODULE::TORTURE_UNIX]
218 SUBSYSTEM = torture
219 INIT_FUNCTION = torture_unix_init
220 PRIVATE_DEPENDENCIES = TORTURE_UTIL 
221 PRIVATE_PROTO_HEADER = \
222                 unix/proto.h
223 OBJ_FILES = \
224                 unix/unix.o \
225                 unix/whoami.o \
226                 unix/unix_info2.o
227 # End MODULE TORTURE_UNIX
228 #################################
229
230 #################################
231 # Start SUBSYSTEM TORTURE_LDAP
232 [MODULE::TORTURE_LDAP]
233 SUBSYSTEM = torture
234 INIT_FUNCTION = torture_ldap_init
235 PRIVATE_PROTO_HEADER = \
236                 ldap/proto.h
237 OBJ_FILES = \
238                 ldap/common.o \
239                 ldap/basic.o \
240                 ldap/schema.o \
241                 ldap/uptodatevector.o \
242                 ldap/cldap.o \
243                 ldap/cldapbench.o
244 PRIVATE_DEPENDENCIES = \
245                 LIBCLI_LDAP LIBCLI_CLDAP SAMDB POPT_CREDENTIALS
246 # End SUBSYSTEM TORTURE_LDAP
247 #################################
248
249 #################################
250 # Start SUBSYSTEM TORTURE_NBT
251 [MODULE::TORTURE_NBT]
252 SUBSYSTEM = torture
253 INIT_FUNCTION = torture_nbt_init
254 PRIVATE_PROTO_HEADER = \
255                 nbt/proto.h
256 OBJ_FILES = \
257                 nbt/query.o \
258                 nbt/register.o \
259                 nbt/wins.o \
260                 nbt/winsbench.o \
261                 nbt/winsreplication.o \
262                 nbt/dgram.o \
263                 nbt/nbt.o
264 PRIVATE_DEPENDENCIES = \
265                 LIBCLI_SMB LIBCLI_NBT LIBCLI_DGRAM LIBCLI_WREPL torture_rpc
266 # End SUBSYSTEM TORTURE_NBT
267 #################################
268
269 #################################
270 # Start SUBSYSTEM TORTURE_NET
271 [MODULE::TORTURE_NET]
272 SUBSYSTEM = torture
273 INIT_FUNCTION = torture_net_init
274 PRIVATE_PROTO_HEADER = \
275                 libnet/proto.h
276 OBJ_FILES = \
277                 libnet/libnet.o \
278                 libnet/userinfo.o \
279                 libnet/userman.o \
280                 libnet/groupinfo.o \
281                 libnet/domain.o \
282                 libnet/libnet_lookup.o \
283                 libnet/libnet_user.o \
284                 libnet/libnet_group.o \
285                 libnet/libnet_share.o \
286                 libnet/libnet_rpc.o \
287                 libnet/libnet_domain.o \
288                 libnet/libnet_BecomeDC.o
289 PRIVATE_DEPENDENCIES = \
290                 LIBSAMBA-NET \
291                 smbcalls \
292                 POPT_CREDENTIALS \
293                 torture_rpc
294 # End SUBSYSTEM TORTURE_NET
295 #################################
296
297 #################################
298 # Start BINARY smbtorture
299 [BINARY::smbtorture]
300 INSTALLDIR = BINDIR
301 OBJ_FILES = \
302                 smbtorture.o
303 PRIVATE_DEPENDENCIES = \
304                 torture \
305                 LIBPOPT \
306                 POPT_SAMBA \
307                 POPT_CREDENTIALS \
308                 dcerpc \
309                 LIBCLI_SMB \
310                 SMBREADLINE
311 MANPAGE = man/smbtorture.1
312 # End BINARY smbtorture
313 #################################
314
315 #################################
316 # Start BINARY gentest
317 [BINARY::gentest]
318 INSTALLDIR = BINDIR
319 OBJ_FILES = \
320                 gentest.o
321 PRIVATE_DEPENDENCIES = \
322                 LIBSAMBA-CONFIG \
323                 LIBSAMBA-UTIL \
324                 LIBPOPT \
325                 POPT_SAMBA \
326                 POPT_CREDENTIALS \
327                 LIBCLI_SMB \
328                 LIBCLI_RAW
329 MANPAGE = man/gentest.1
330 # End BINARY gentest
331 #################################
332
333 #################################
334 # Start BINARY masktest
335 [BINARY::masktest]
336 INSTALLDIR = BINDIR
337 OBJ_FILES = \
338                 masktest.o
339 PRIVATE_DEPENDENCIES = \
340                 LIBSAMBA-CONFIG \
341                 LIBSAMBA-UTIL \
342                 LIBPOPT \
343                 POPT_SAMBA \
344                 POPT_CREDENTIALS \
345                 LIBCLI_SMB
346 MANPAGE = man/masktest.1
347 # End BINARY masktest
348 #################################
349
350 #################################
351 # Start BINARY locktest
352 [BINARY::locktest]
353 INSTALLDIR = BINDIR
354 OBJ_FILES = \
355                 locktest.o
356 PRIVATE_DEPENDENCIES = \
357                 LIBSAMBA-UTIL \
358                 LIBCLI_SMB \
359                 LIBSAMBA-CONFIG
360 MANPAGE = man/locktest.1
361 # End BINARY locktest
362 #################################
363
364 GCOV_FLAGS = -ftest-coverage -fprofile-arcs
365 GCOV_LIBS = -lgcov
366
367 COV_TARGET = test
368
369 test_cov:
370         @$(MAKE) $(COV_TARGET) \
371                 HOSTCC_CFLAGS="$(HOSTCC_CFLAGS) $(GCOV_FLAGS)" \
372                 CFLAGS="$(CFLAGS) $(GCOV_FLAGS)" \
373                 LDFLAGS="$(LDFLAGS) $(GCOV_FLAGS) $(GCOV_LIBS)" \
374                 SHLD_FLAGS="$(SHLD_FLAGS) $(GCOV_FLAGS) $(GCOV_LIBS)"
375
376 gcov: test_cov
377         for I in $(sort $(dir $(ALL_OBJS))); \
378                 do $(GCOV) -p -o $$I $$I/*.c; \
379         done
380
381 lcov-split: 
382         rm -f samba.info
383         @$(MAKE) $(COV_TARGET) \
384                 HOSTCC_CFLAGS="$(HOSTCC_CFLAGS) $(GCOV_FLAGS)" \
385                 CFLAGS="$(CFLAGS) $(GCOV_FLAGS)" \
386                 LDFLAGS="$(LDFLAGS) $(GCOV_FLAGS) $(GCOV_LIBS)" \
387                 SHLD_FLAGS="$(SHLD_FLAGS) $(GCOV_FLAGS) $(GCOV_LIBS)" \
388                 TEST_OPTIONS="--analyse-cmd=\"lcov --base-directory `pwd` --directory . --capture --output-file samba.info -t\""
389         -rm heimdal/lib/*/{lex,parse}.{gcda,gcno}
390         genhtml -o coverage samba.info
391
392 lcov: test_cov
393         -rm heimdal/lib/*/{lex,parse}.{gcda,gcno}
394         lcov --base-directory `pwd` --directory . --capture --output-file samba.info
395         genhtml -o coverage samba.info
396
397 testcov-html:: lcov