2010-03-28 01:48:49 +03:00
#!/usr/bin/env python
2018-08-03 17:52:12 +03:00
provision = bld.pyembed_libname('PROVISION')
2024-05-27 10:44:38 +03:00
samba_net_join = bld.pyembed_libname('samba-net-join')
2010-03-17 14:07:42 +03:00
bld.SAMBA_SUBSYSTEM('TORTURE_UTIL',
source='util_smb.c',
2020-12-02 19:24:22 +03:00
public_deps='torture',
2021-12-06 20:13:58 +03:00
deps='smbclient-raw CMDLINE_S4 CREDENTIALS_KRB5'
2010-03-17 14:07:42 +03:00
)
bld.SAMBA_MODULE('TORTURE_BASIC',
2010-03-17 12:12:16 +03:00
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',
2010-03-17 14:07:42 +03:00
subsystem='smbtorture',
2020-12-02 19:24:22 +03:00
deps='LIBCLI_SMB TORTURE_UTIL smbclient-raw TORTURE_RAW',
2010-03-17 12:12:16 +03:00
internal_module=True,
2010-03-17 14:07:42 +03:00
autoproto='basic/proto.h',
2017-01-28 06:53:39 +03:00
init_function='torture_base_init',
enabled=bld.PYTHON_BUILD_IS_ENABLED()
2010-03-17 14:07:42 +03:00
)
bld.SAMBA_MODULE('TORTURE_RAW',
2012-03-07 16:53:24 +04:00
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',
2010-03-17 14:07:42 +03:00
autoproto='raw/proto.h',
subsystem='smbtorture',
init_function='torture_raw_init',
2020-12-02 19:24:22 +03:00
deps='LIBCLI_SMB LIBCLI_LSA LIBCLI_SMB_COMPOSITE TORTURE_UTIL',
2017-01-28 06:53:39 +03:00
internal_module=True,
enabled=bld.PYTHON_BUILD_IS_ENABLED()
2010-03-17 14:07:42 +03:00
)
2010-04-04 07:08:05 +04:00
bld.RECURSE('smb2')
bld.RECURSE('winbind')
bld.RECURSE('libnetapi')
bld.RECURSE('libsmbclient')
2017-03-03 22:54:30 +03:00
bld.RECURSE('gpo')
2010-03-17 14:07:42 +03:00
2015-10-09 23:30:17 +03:00
ntvfs_specific = dict(source='', deps='')
2015-03-09 22:37:45 +03:00
2015-10-09 23:30:17 +03:00
# Yes, the spoolss_notify test uses the NTVFS file server to run the SMB server expected
# to handle the RPC callback!
if bld.CONFIG_SET('WITH_NTVFS_FILESERVER'):
ntvfs_specific['source'] += ' rpc/spoolss_notify.c'
ntvfs_specific['deps'] += ' SMB_SERVER dcerpc_server ntvfs'
2012-05-02 22:16:01 +04:00
2010-03-17 14:07:42 +03:00
bld.SAMBA_SUBSYSTEM('TORTURE_NDR',
2015-07-14 16:55:57 +03:00
source='''ndr/ndr.c
2023-08-04 14:57:12 +03:00
ndr/dcerpc.c
2015-07-14 16:55:57 +03:00
ndr/winreg.c
ndr/atsvc.c
ndr/lsa.c
ndr/epmap.c
ndr/dfs.c
ndr/netlogon.c
ndr/drsuapi.c
ndr/spoolss.c
ndr/ntprinting.c
ndr/samr.c
ndr/dfsblob.c
ndr/drsblobs.c
2019-05-24 18:39:17 +03:00
ndr/dnsp.c
2015-07-14 16:55:57 +03:00
ndr/nbt.c
ndr/ntlmssp.c
ndr/string.c
ndr/backupkey.c
ndr/witness.c
ndr/clusapi.c
2015-12-18 15:16:28 +03:00
ndr/negoex.c
2012-12-13 15:28:19 +04:00
ndr/krb5pac.c
2013-05-16 20:20:20 +04:00
ndr/winspool.c
2016-09-23 18:18:12 +03:00
ndr/cabinet.c
2017-01-13 15:16:22 +03:00
ndr/charset.c
2020-03-05 22:42:21 +03:00
ndr/svcctl.c
2021-02-08 18:08:10 +03:00
ndr/odj.c
2015-07-14 16:55:57 +03:00
''',
2010-03-17 14:07:42 +03:00
autoproto='ndr/proto.h',
2017-01-28 06:53:39 +03:00
deps='torture krb5samba',
enabled=bld.PYTHON_BUILD_IS_ENABLED()
2010-03-17 14:07:42 +03:00
)
2018-08-23 20:16:40 +03:00
bld.SAMBA_SUBSYSTEM('IREMOTEWINSPOOL_COMMON',
source='rpc/iremotewinspool_common.c',
deps='talloc',
enabled=bld.PYTHON_BUILD_IS_ENABLED())
2010-03-17 14:07:42 +03:00
bld.SAMBA_MODULE('torture_rpc',
2015-07-08 18:03:18 +03:00
source='''
rpc/join.c
rpc/lsa.c
rpc/forest_trust.c
rpc/lsa_lookup.c
rpc/session_key.c
rpc/echo.c
rpc/dfs.c
rpc/drsuapi.c
2016-05-25 02:50:09 +03:00
rpc/drsuapi_w2k8.c
2015-07-08 18:03:18 +03:00
rpc/drsuapi_cracknames.c
rpc/dsgetinfo.c
rpc/spoolss.c
rpc/spoolss_win.c
rpc/spoolss_access.c
rpc/unixinfo.c
rpc/samr.c
rpc/samr_accessmask.c
2020-05-08 13:40:55 +03:00
rpc/samr_handletype.c
2015-07-08 18:03:18 +03:00
rpc/samr_priv.c
rpc/wkssvc.c
rpc/srvsvc.c
rpc/svcctl.c
rpc/atsvc.c
rpc/eventlog.c
rpc/epmapper.c
rpc/winreg.c
rpc/initshutdown.c
rpc/mgmt.c
rpc/scanner.c
rpc/countcalls.c
rpc/testjoin.c
rpc/schannel.c
rpc/netlogon.c
2021-07-26 11:18:05 +03:00
rpc/netlogon_crypto.c
2015-07-08 18:03:18 +03:00
rpc/remote_pac.c
rpc/samlogon.c
rpc/samsync.c
rpc/dssetup.c
rpc/alter_context.c
rpc/bench.c
rpc/samba3rpc.c
rpc/rpc.c
rpc/async_bind.c
rpc/handles.c
rpc/frsapi.c
rpc/object_uuid.c
rpc/ntsvcs.c
rpc/browser.c
rpc/bind.c
rpc/fsrvp.c
rpc/clusapi.c
2015-03-09 22:37:45 +03:00
rpc/witness.c
2013-01-15 18:23:58 +04:00
rpc/iremotewinspool.c
2018-08-24 21:28:05 +03:00
rpc/iremotewinspool_driver.c
2019-04-16 17:54:21 +03:00
rpc/mdssvc.c
2019-07-31 07:13:38 +03:00
rpc/backupkey.c''' + ntvfs_specific['source'],
2015-07-08 18:03:18 +03:00
autoproto='rpc/proto.h',
subsystem='smbtorture',
init_function='torture_rpc_init',
deps='''
ndr-table
RPC_NDR_UNIXINFO
dcerpc-samr
RPC_NDR_WINREG
RPC_NDR_INITSHUTDOWN
RPC_NDR_EVENTLOG
RPC_NDR_ECHO
RPC_NDR_SVCCTL
RPC_NDR_NETLOGON
2016-01-28 18:21:21 +03:00
RPC_NDR_ATSVC
2015-07-08 18:03:18 +03:00
RPC_NDR_DRSUAPI
RPC_NDR_LSA
RPC_NDR_EPMAPPER
RPC_NDR_DFS
RPC_NDR_FRSAPI
RPC_NDR_SPOOLSS
RPC_NDR_SRVSVC
RPC_NDR_WKSSVC
RPC_NDR_DSSETUP
RPC_NDR_NTSVCS
2018-08-03 17:52:12 +03:00
%s
2015-07-08 18:03:18 +03:00
LIBCLI_AUTH
2024-02-27 11:14:24 +03:00
INIT_LSA
2015-07-08 18:03:18 +03:00
popt
2020-12-02 19:24:22 +03:00
CMDLINE_S4
2015-07-08 18:03:18 +03:00
TORTURE_LDAP
TORTURE_UTIL
TORTURE_RAP
service
process_model
RPC_NDR_BROWSER
LIBCLI_DRSUAPI
TORTURE_DFS
RPC_NDR_FSRVP
RPC_NDR_CLUSAPI
RPC_NDR_WITNESS
2015-03-09 22:37:45 +03:00
RPC_NDR_BACKUPKEY
2013-01-15 18:23:58 +04:00
RPC_NDR_WINSPOOL
2018-08-23 20:16:40 +03:00
IREMOTEWINSPOOL_COMMON
2018-10-08 18:14:37 +03:00
printer_driver
2019-05-04 09:53:48 +03:00
RPC_NDR_MDSSVC
mdssvc
2024-05-27 10:44:38 +03:00
''' % samba_net_join + ntvfs_specific['deps'],
2017-01-28 06:53:39 +03:00
internal_module=True,
enabled=bld.PYTHON_BUILD_IS_ENABLED())
2010-03-17 14:07:42 +03:00
2010-04-04 07:08:05 +04:00
bld.RECURSE('drs')
2012-09-06 08:26:57 +04:00
bld.RECURSE('dns')
2010-03-17 14:07:42 +03:00
bld.SAMBA_MODULE('TORTURE_RAP',
2010-05-07 17:45:23 +04:00
source='rap/rap.c rap/rpc.c rap/printing.c rap/sam.c',
2010-03-17 14:07:42 +03:00
autoproto='rap/proto.h',
subsystem='smbtorture',
init_function='torture_rap_init',
2011-03-15 19:28:51 +03:00
deps='TORTURE_UTIL LIBCLI_SMB NDR_RAP LIBCLI_RAP',
2017-01-28 06:53:39 +03:00
internal_module=True,
enabled=bld.PYTHON_BUILD_IS_ENABLED()
2010-03-17 14:07:42 +03:00
)
2010-05-10 01:39:27 +04:00
bld.SAMBA_MODULE('TORTURE_DFS',
source='dfs/domaindfs.c dfs/common.c',
autoproto='dfs/proto.h',
subsystem='smbtorture',
init_function='torture_dfs_init',
deps='TORTURE_UTIL LIBCLI_SMB',
internal_module=True
)
2010-03-17 14:07:42 +03:00
bld.SAMBA_MODULE('TORTURE_AUTH',
2011-04-13 08:40:27 +04:00
source='auth/ntlmssp.c auth/pac.c auth/smbencrypt.c',
2010-03-17 14:07:42 +03:00
autoproto='auth/proto.h',
subsystem='smbtorture',
2021-06-16 05:58:27 +03:00
deps='LIBCLI_SMB gensec auth4 authkrb5 smbpasswdparser torture com_err gensec_ntlmssp CMDLINE_S4',
2010-03-17 12:12:16 +03:00
internal_module=True
2010-03-17 14:07:42 +03:00
)
2010-04-04 07:08:05 +04:00
bld.RECURSE('local')
2015-01-05 04:54:45 +03:00
bld.RECURSE('krb5')
2010-03-17 14:07:42 +03:00
bld.SAMBA_MODULE('TORTURE_NBENCH',
source='nbench/nbio.c nbench/nbench.c',
autoproto='nbench/proto.h',
subsystem='smbtorture',
init_function='torture_nbench_init',
deps='TORTURE_UTIL',
2010-03-17 12:12:16 +03:00
internal_module=True
2010-03-17 14:07:42 +03:00
)
bld.SAMBA_MODULE('TORTURE_UNIX',
source='unix/unix.c unix/whoami.c unix/unix_info2.c',
autoproto='unix/proto.h',
subsystem='smbtorture',
init_function='torture_unix_init',
deps='TORTURE_UTIL',
2010-03-17 12:12:16 +03:00
internal_module=True
2010-03-17 14:07:42 +03:00
)
bld.SAMBA_MODULE('TORTURE_LDAP',
2020-08-12 16:48:01 +03:00
source='''
ldap/common.c
ldap/basic.c
ldap/schema.c
ldap/uptodatevector.c
ldap/cldap.c
ldap/netlogon.c
ldap/cldapbench.c
ldap/ldap_sort.c
ldap/nested_search.c
2020-08-12 16:50:58 +03:00
ldap/session_expiry.c
2020-08-12 16:48:01 +03:00
''',
2010-03-17 14:07:42 +03:00
subsystem='smbtorture',
2021-06-16 05:58:27 +03:00
deps='cli-ldap cli_cldap samdb torture ldbsamba CMDLINE_S4',
2010-03-17 12:12:16 +03:00
internal_module=True,
2010-03-17 14:07:42 +03:00
autoproto='ldap/proto.h',
init_function='torture_ldap_init'
)
bld.SAMBA_MODULE('TORTURE_NBT',
source='nbt/query.c nbt/register.c nbt/wins.c nbt/winsbench.c nbt/winsreplication.c nbt/dgram.c nbt/nbt.c',
autoproto='nbt/proto.h',
subsystem='smbtorture',
init_function='torture_nbt_init',
2010-10-24 22:26:09 +04:00
deps='LIBCLI_SMB cli-nbt LIBCLI_DGRAM LIBCLI_WREPL torture_rpc',
2017-01-28 06:53:39 +03:00
internal_module=True,
enabled=bld.PYTHON_BUILD_IS_ENABLED()
2010-03-17 14:07:42 +03:00
)
bld.SAMBA_MODULE('TORTURE_NET',
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',
autoproto='libnet/proto.h',
subsystem='smbtorture',
init_function='torture_net_init',
2024-05-27 10:44:38 +03:00
deps='%s torture_rpc %s' % (provision, samba_net_join),
2017-01-28 06:53:39 +03:00
internal_module=True,
enabled=bld.PYTHON_BUILD_IS_ENABLED()
2010-03-17 14:07:42 +03:00
)
bld.SAMBA_MODULE('TORTURE_NTP',
source='ntp/ntp_signd.c',
autoproto='ntp/proto.h',
subsystem='smbtorture',
init_function='torture_ntp_init',
2020-12-02 19:24:22 +03:00
deps='torture_rpc',
2017-01-28 06:53:39 +03:00
internal_module=True,
enabled=bld.PYTHON_BUILD_IS_ENABLED()
2010-03-17 14:07:42 +03:00
)
2014-07-08 07:36:46 +04:00
bld.SAMBA_MODULE('TORTURE_VFS',
2016-08-25 17:30:24 +03:00
source='vfs/vfs.c vfs/fruit.c vfs/acl_xattr.c',
2014-07-08 07:36:46 +04:00
subsystem='smbtorture',
2020-12-02 19:24:22 +03:00
deps='LIBCLI_SMB TORTURE_UTIL smbclient-raw TORTURE_RAW',
2014-07-08 07:36:46 +04:00
internal_module=True,
autoproto='vfs/proto.h',
init_function='torture_vfs_init'
)
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'
2010-03-17 14:07:42 +03:00
2010-04-29 01:47:57 +04:00
bld.SAMBA_SUBSYSTEM('torturemain',
2010-03-20 07:24:15 +03:00
source='smbtorture.c torture.c shell.c',
2010-04-29 01:47:57 +04:00
subsystem_name='smbtorture',
2020-12-02 19:24:22 +03:00
deps='torture dcerpc LIBCLI_SMB SMBREADLINE ' + TORTURE_MODULES,
2017-01-28 06:53:39 +03:00
enabled=bld.PYTHON_BUILD_IS_ENABLED()
2010-04-29 01:47:57 +04:00
)
2010-03-17 14:07:42 +03:00
bld.SAMBA_BINARY('smbtorture',
2010-04-29 01:47:57 +04:00
source=[],
manpages='man/smbtorture.1',
2016-01-28 18:21:21 +03:00
private_headers='smbtorture.h',
2020-12-02 19:24:22 +03:00
deps='torturemain torture popt CMDLINE_S4 dcerpc LIBCLI_SMB SMBREADLINE ' + TORTURE_MODULES,
2017-01-28 06:53:39 +03:00
pyembed=True,
enabled=bld.PYTHON_BUILD_IS_ENABLED()
2010-04-29 01:47:57 +04:00
)
2010-03-17 14:07:42 +03:00
bld.SAMBA_BINARY('gentest',
source='gentest.c',
manpages='man/gentest.1',
2020-12-17 18:25:08 +03:00
deps='samba-hostconfig samba-util popt CMDLINE_S4 LIBCLI_SMB smbclient-raw param_options'
2010-03-17 14:07:42 +03:00
)
bld.SAMBA_BINARY('masktest',
source='masktest.c',
manpages='man/masktest.1',
2020-12-17 19:12:10 +03:00
deps='samba-hostconfig samba-util popt CMDLINE_S4 LIBCLI_SMB param_options'
2010-03-17 14:07:42 +03:00
)
bld.SAMBA_BINARY('locktest',
source='locktest.c',
# COV_TARGET='test',
2010-03-17 12:12:16 +03:00
#ldflags='--coverage',
#cflags='--coverage',
2010-03-17 14:07:42 +03:00
# GCOV='1',
2010-03-17 12:12:16 +03:00
manpages='man/locktest.1',
2020-12-17 19:05:51 +03:00
deps='popt CMDLINE_S4 samba-util LIBCLI_SMB samba-hostconfig param_options',
2010-03-17 14:07:42 +03:00
)
2019-03-25 03:13:33 +03:00
bld.SAMBA_MODULE('TORTURE_DSDB',
source="../../source4/dsdb/common/tests/dsdb.c",
autoproto='dsdb_proto.h',
subsystem='smbtorture',
init_function='torture_dsdb_init',
deps="TORTURE_UTIL samba-util",
internal_module=True,
enabled=bld.PYTHON_BUILD_IS_ENABLED()
)