VERSION: Disable GIT_SNAPSHOT for the Samba 4.18.0rc1 release.
[Samba.git] / source4 / torture / wscript_build
blobd870a3ab807641666b01c5cbdf0b23cce2953e58
1 #!/usr/bin/env python
3 provision = bld.pyembed_libname('PROVISION')
4 samba_net = bld.pyembed_libname('samba-net')
6 bld.SAMBA_SUBSYSTEM('TORTURE_UTIL',
7 source='util_smb.c',
8 public_deps='torture',
9 deps='smbclient-raw CMDLINE_S4 CREDENTIALS_KRB5'
13 bld.SAMBA_MODULE('TORTURE_BASIC',
14 source='basic/base.c basic/misc.c basic/scanner.c basic/utable.c basic/charset.c basic/mangle_test.c basic/denytest.c basic/aliases.c basic/locking.c basic/secleak.c basic/rename.c basic/dir.c basic/delete.c basic/unlink.c basic/disconnect.c basic/delaywrite.c basic/attr.c basic/properties.c',
15 subsystem='smbtorture',
16 deps='LIBCLI_SMB TORTURE_UTIL smbclient-raw TORTURE_RAW',
17 internal_module=True,
18 autoproto='basic/proto.h',
19 init_function='torture_base_init',
20 enabled=bld.PYTHON_BUILD_IS_ENABLED()
24 bld.SAMBA_MODULE('TORTURE_RAW',
25 source='raw/qfsinfo.c raw/qfileinfo.c raw/setfileinfo.c raw/search.c raw/close.c raw/open.c raw/mkdir.c raw/oplock.c raw/notify.c raw/mux.c raw/ioctl.c raw/chkpath.c raw/unlink.c raw/read.c raw/context.c raw/session.c raw/write.c raw/lock.c raw/pingpong.c raw/lockbench.c raw/lookuprate.c raw/tconrate.c raw/openbench.c raw/rename.c raw/eas.c raw/streams.c raw/acls.c raw/seek.c raw/samba3hide.c raw/samba3misc.c raw/composite.c raw/raw.c raw/offline.c',
26 autoproto='raw/proto.h',
27 subsystem='smbtorture',
28 init_function='torture_raw_init',
29 deps='LIBCLI_SMB LIBCLI_LSA LIBCLI_SMB_COMPOSITE TORTURE_UTIL',
30 internal_module=True,
31 enabled=bld.PYTHON_BUILD_IS_ENABLED()
34 bld.RECURSE('smb2')
35 bld.RECURSE('winbind')
36 bld.RECURSE('libnetapi')
37 bld.RECURSE('libsmbclient')
38 bld.RECURSE('gpo')
40 ntvfs_specific = dict(source='', deps='')
42 # Yes, the spoolss_notify test uses the NTVFS file server to run the SMB server expected
43 # to handle the RPC callback!
44 if bld.CONFIG_SET('WITH_NTVFS_FILESERVER'):
45 ntvfs_specific['source'] += ' rpc/spoolss_notify.c'
46 ntvfs_specific['deps'] += ' SMB_SERVER dcerpc_server ntvfs'
48 bld.SAMBA_SUBSYSTEM('TORTURE_NDR',
49 source='''ndr/ndr.c
50 ndr/winreg.c
51 ndr/atsvc.c
52 ndr/lsa.c
53 ndr/epmap.c
54 ndr/dfs.c
55 ndr/netlogon.c
56 ndr/drsuapi.c
57 ndr/spoolss.c
58 ndr/ntprinting.c
59 ndr/samr.c
60 ndr/dfsblob.c
61 ndr/drsblobs.c
62 ndr/dnsp.c
63 ndr/nbt.c
64 ndr/ntlmssp.c
65 ndr/string.c
66 ndr/backupkey.c
67 ndr/witness.c
68 ndr/clusapi.c
69 ndr/negoex.c
70 ndr/krb5pac.c
71 ndr/winspool.c
72 ndr/cabinet.c
73 ndr/charset.c
74 ndr/svcctl.c
75 ndr/odj.c
76 ''',
77 autoproto='ndr/proto.h',
78 deps='torture krb5samba',
79 enabled=bld.PYTHON_BUILD_IS_ENABLED()
82 bld.SAMBA_SUBSYSTEM('IREMOTEWINSPOOL_COMMON',
83 source='rpc/iremotewinspool_common.c',
84 deps='talloc',
85 enabled=bld.PYTHON_BUILD_IS_ENABLED())
87 bld.SAMBA_MODULE('torture_rpc',
88 source='''
89 rpc/join.c
90 rpc/lsa.c
91 rpc/forest_trust.c
92 rpc/lsa_lookup.c
93 rpc/session_key.c
94 rpc/echo.c
95 rpc/dfs.c
96 rpc/drsuapi.c
97 rpc/drsuapi_w2k8.c
98 rpc/drsuapi_cracknames.c
99 rpc/dsgetinfo.c
100 rpc/spoolss.c
101 rpc/spoolss_win.c
102 rpc/spoolss_access.c
103 rpc/unixinfo.c
104 rpc/samr.c
105 rpc/samr_accessmask.c
106 rpc/samr_handletype.c
107 rpc/samr_priv.c
108 rpc/wkssvc.c
109 rpc/srvsvc.c
110 rpc/svcctl.c
111 rpc/atsvc.c
112 rpc/eventlog.c
113 rpc/epmapper.c
114 rpc/winreg.c
115 rpc/initshutdown.c
116 rpc/oxidresolve.c
117 rpc/remact.c
118 rpc/mgmt.c
119 rpc/scanner.c
120 rpc/countcalls.c
121 rpc/testjoin.c
122 rpc/schannel.c
123 rpc/netlogon.c
124 rpc/netlogon_crypto.c
125 rpc/remote_pac.c
126 rpc/samlogon.c
127 rpc/samsync.c
128 rpc/dssetup.c
129 rpc/alter_context.c
130 rpc/bench.c
131 rpc/samba3rpc.c
132 rpc/rpc.c
133 rpc/async_bind.c
134 rpc/handles.c
135 rpc/frsapi.c
136 rpc/object_uuid.c
137 rpc/ntsvcs.c
138 rpc/browser.c
139 rpc/bind.c
140 rpc/fsrvp.c
141 rpc/clusapi.c
142 rpc/witness.c
143 rpc/iremotewinspool.c
144 rpc/iremotewinspool_driver.c
145 rpc/mdssvc.c
146 rpc/backupkey.c''' + ntvfs_specific['source'],
147 autoproto='rpc/proto.h',
148 subsystem='smbtorture',
149 init_function='torture_rpc_init',
150 deps='''
151 ndr-table
152 RPC_NDR_UNIXINFO
153 dcerpc-samr
154 RPC_NDR_WINREG
155 RPC_NDR_INITSHUTDOWN
156 RPC_NDR_OXIDRESOLVER
157 RPC_NDR_EVENTLOG
158 RPC_NDR_ECHO
159 RPC_NDR_SVCCTL
160 RPC_NDR_NETLOGON
161 RPC_NDR_ATSVC
162 RPC_NDR_DRSUAPI
163 RPC_NDR_LSA
164 RPC_NDR_EPMAPPER
165 RPC_NDR_DFS
166 RPC_NDR_FRSAPI
167 RPC_NDR_SPOOLSS
168 RPC_NDR_SRVSVC
169 RPC_NDR_WKSSVC
170 RPC_NDR_DSSETUP
171 RPC_NDR_REMACT
172 RPC_NDR_OXIDRESOLVER
173 RPC_NDR_NTSVCS
175 LIBCLI_AUTH
176 popt
177 CMDLINE_S4
178 TORTURE_LDAP
179 TORTURE_UTIL
180 TORTURE_RAP
181 service
182 process_model
183 RPC_NDR_BROWSER
184 LIBCLI_DRSUAPI
185 TORTURE_DFS
186 RPC_NDR_FSRVP
187 RPC_NDR_CLUSAPI
188 RPC_NDR_WITNESS
189 RPC_NDR_BACKUPKEY
190 RPC_NDR_WINSPOOL
191 IREMOTEWINSPOOL_COMMON
192 printer_driver
193 RPC_NDR_MDSSVC
194 mdssvc
195 ''' % samba_net + ntvfs_specific['deps'],
196 internal_module=True,
197 enabled=bld.PYTHON_BUILD_IS_ENABLED())
199 bld.RECURSE('drs')
200 bld.RECURSE('dns')
202 bld.SAMBA_MODULE('TORTURE_RAP',
203 source='rap/rap.c rap/rpc.c rap/printing.c rap/sam.c',
204 autoproto='rap/proto.h',
205 subsystem='smbtorture',
206 init_function='torture_rap_init',
207 deps='TORTURE_UTIL LIBCLI_SMB NDR_RAP LIBCLI_RAP',
208 internal_module=True,
209 enabled=bld.PYTHON_BUILD_IS_ENABLED()
212 bld.SAMBA_MODULE('TORTURE_DFS',
213 source='dfs/domaindfs.c dfs/common.c',
214 autoproto='dfs/proto.h',
215 subsystem='smbtorture',
216 init_function='torture_dfs_init',
217 deps='TORTURE_UTIL LIBCLI_SMB',
218 internal_module=True
222 bld.SAMBA_MODULE('TORTURE_AUTH',
223 source='auth/ntlmssp.c auth/pac.c auth/smbencrypt.c',
224 autoproto='auth/proto.h',
225 subsystem='smbtorture',
226 deps='LIBCLI_SMB gensec auth4 authkrb5 smbpasswdparser torture com_err gensec_ntlmssp CMDLINE_S4',
227 internal_module=True
230 bld.RECURSE('local')
231 bld.RECURSE('krb5')
233 bld.SAMBA_MODULE('TORTURE_NBENCH',
234 source='nbench/nbio.c nbench/nbench.c',
235 autoproto='nbench/proto.h',
236 subsystem='smbtorture',
237 init_function='torture_nbench_init',
238 deps='TORTURE_UTIL',
239 internal_module=True
243 bld.SAMBA_MODULE('TORTURE_UNIX',
244 source='unix/unix.c unix/whoami.c unix/unix_info2.c',
245 autoproto='unix/proto.h',
246 subsystem='smbtorture',
247 init_function='torture_unix_init',
248 deps='TORTURE_UTIL',
249 internal_module=True
253 bld.SAMBA_MODULE('TORTURE_LDAP',
254 source='''
255 ldap/common.c
256 ldap/basic.c
257 ldap/schema.c
258 ldap/uptodatevector.c
259 ldap/cldap.c
260 ldap/netlogon.c
261 ldap/cldapbench.c
262 ldap/ldap_sort.c
263 ldap/nested_search.c
264 ldap/session_expiry.c
265 ''',
266 subsystem='smbtorture',
267 deps='cli-ldap cli_cldap samdb torture ldbsamba CMDLINE_S4',
268 internal_module=True,
269 autoproto='ldap/proto.h',
270 init_function='torture_ldap_init'
274 bld.SAMBA_MODULE('TORTURE_NBT',
275 source='nbt/query.c nbt/register.c nbt/wins.c nbt/winsbench.c nbt/winsreplication.c nbt/dgram.c nbt/nbt.c',
276 autoproto='nbt/proto.h',
277 subsystem='smbtorture',
278 init_function='torture_nbt_init',
279 deps='LIBCLI_SMB cli-nbt LIBCLI_DGRAM LIBCLI_WREPL torture_rpc',
280 internal_module=True,
281 enabled=bld.PYTHON_BUILD_IS_ENABLED()
285 bld.SAMBA_MODULE('TORTURE_NET',
286 source='libnet/libnet.c libnet/utils.c libnet/userinfo.c libnet/userman.c libnet/groupinfo.c libnet/groupman.c libnet/domain.c libnet/libnet_lookup.c libnet/libnet_user.c libnet/libnet_group.c libnet/libnet_share.c libnet/libnet_rpc.c libnet/libnet_domain.c libnet/libnet_BecomeDC.c',
287 autoproto='libnet/proto.h',
288 subsystem='smbtorture',
289 init_function='torture_net_init',
290 deps='%s torture_rpc %s' % (provision, samba_net),
291 internal_module=True,
292 enabled=bld.PYTHON_BUILD_IS_ENABLED()
296 bld.SAMBA_MODULE('TORTURE_NTP',
297 source='ntp/ntp_signd.c',
298 autoproto='ntp/proto.h',
299 subsystem='smbtorture',
300 init_function='torture_ntp_init',
301 deps='torture_rpc',
302 internal_module=True,
303 enabled=bld.PYTHON_BUILD_IS_ENABLED()
306 bld.SAMBA_MODULE('TORTURE_VFS',
307 source='vfs/vfs.c vfs/fruit.c vfs/acl_xattr.c',
308 subsystem='smbtorture',
309 deps='LIBCLI_SMB TORTURE_UTIL smbclient-raw TORTURE_RAW',
310 internal_module=True,
311 autoproto='vfs/proto.h',
312 init_function='torture_vfs_init'
315 TORTURE_MODULES = 'TORTURE_BASIC TORTURE_RAW torture_rpc TORTURE_RAP TORTURE_AUTH TORTURE_NBENCH TORTURE_UNIX TORTURE_LDAP TORTURE_NBT TORTURE_NET TORTURE_NTP torture_registry TORTURE_VFS'
317 bld.SAMBA_SUBSYSTEM('torturemain',
318 source='smbtorture.c torture.c shell.c',
319 subsystem_name='smbtorture',
320 deps='torture dcerpc LIBCLI_SMB SMBREADLINE ' + TORTURE_MODULES,
321 enabled=bld.PYTHON_BUILD_IS_ENABLED()
324 bld.SAMBA_BINARY('smbtorture',
325 source=[],
326 manpages='man/smbtorture.1',
327 private_headers='smbtorture.h',
328 deps='torturemain torture popt CMDLINE_S4 dcerpc LIBCLI_SMB SMBREADLINE ' + TORTURE_MODULES,
329 pyembed=True,
330 enabled=bld.PYTHON_BUILD_IS_ENABLED()
333 bld.SAMBA_BINARY('gentest',
334 source='gentest.c',
335 manpages='man/gentest.1',
336 deps='samba-hostconfig samba-util popt CMDLINE_S4 LIBCLI_SMB smbclient-raw param_options'
340 bld.SAMBA_BINARY('masktest',
341 source='masktest.c',
342 manpages='man/masktest.1',
343 deps='samba-hostconfig samba-util popt CMDLINE_S4 LIBCLI_SMB param_options'
347 bld.SAMBA_BINARY('locktest',
348 source='locktest.c',
349 # COV_TARGET='test',
350 #ldflags='--coverage',
351 #cflags='--coverage',
352 # GCOV='1',
353 manpages='man/locktest.1',
354 deps='popt CMDLINE_S4 samba-util LIBCLI_SMB samba-hostconfig param_options',
357 bld.SAMBA_MODULE('TORTURE_DSDB',
358 source="../../source4/dsdb/common/tests/dsdb.c",
359 autoproto='dsdb_proto.h',
360 subsystem='smbtorture',
361 init_function='torture_dsdb_init',
362 deps="TORTURE_UTIL samba-util",
363 internal_module=True,
364 enabled=bld.PYTHON_BUILD_IS_ENABLED()