s4-dns: dlz_bind9: Fix ipv6 updates
[samba.git] / source3 / wscript_build
1 #!/usr/bin/env python
2
3 from samba_utils import *
4 import samba_version, samba3
5
6 LIBS='ICONV'
7
8 config_h = "../include/config.h"
9
10 bld.SAMBA_BLDOPTIONS('smbd/build_options.c')
11
12 t = bld.SAMBA_GENERATOR('build_env.h',
13                         source='script/build_env.sh',
14                         target='include/build_env.h',
15                         rule='${SRC} ${SRCDIR} ${BUILDDIR} ${CC} > ${TGT}')
16 # todo: work out what is really wanted here
17 t.env.SRCDIR = bld.path.abspath()
18 t.env.BUILDDIR = bld.path.abspath()
19
20 bld.SETUP_BUILD_GROUPS()
21
22 ######################## SUBSYSTEMS #################################
23
24 bld.SAMBA3_LIBRARY('netapi',
25                     source='''lib/netapi/netapi.c
26                     lib/netapi/cm.c
27                     lib/netapi/libnetapi.c
28                     lib/netapi/joindomain.c
29                     lib/netapi/serverinfo.c
30                     lib/netapi/wkstainfo.c
31                     lib/netapi/getdc.c
32                     lib/netapi/user.c
33                     lib/netapi/group.c
34                     lib/netapi/localgroup.c
35                     lib/netapi/samr.c
36                     lib/netapi/sid.c
37                     lib/netapi/share.c
38                     lib/netapi/file.c
39                     lib/netapi/shutdown.c
40                     lib/netapi/netlogon.c''',
41                     public_deps='''
42                     talloc
43                     util_cmdline
44                     msrpc3
45                     ads
46                     NDR_LIBNETAPI
47                     LIBNET
48                     RPC_CLIENT_SCHANNEL
49                     libcli_netlogon3
50                     LIBCLI_SAMR
51                     INIT_SAMR
52                     auth
53                     ''',
54                     public_headers='../source3/lib/netapi/netapi.h',
55                     pc_files='libnet/netapi.pc',
56                     vnum='0')
57
58 bld.SAMBA3_LIBRARY('smbsharemodes',
59                     source='libsmb/smb_share_modes.c',
60                     public_deps='''talloc tdb_compat''',
61                     deps='''ccan-hash''',
62                     public_headers='include/smb_share_modes.h',
63                     pc_files='libsmb/smbsharemodes.pc',
64                     vnum='0')
65
66 bld.SAMBA3_LIBRARY('nss_wins',
67                   source='../nsswitch/wins.c',
68                   deps='''param libsmb LIBTSOCKET''',
69                   realname='libnss_wins.so.2',
70                   soname='libnss_wins.so',
71                   vnum='2')
72
73 bld.SAMBA3_LIBRARY('gse',
74                    source='librpc/crypto/gse_krb5.c librpc/crypto/gse.c',
75                    deps='krb5samba gensec param KRBCLIENT secrets3',
76                    private_library=True)
77
78 bld.SAMBA3_LIBRARY('msrpc3',
79                    source='''rpc_client/cli_pipe.c
80                    rpc_client/rpc_transport_np.c
81                    rpc_client/rpc_transport_sock.c
82                    rpc_client/rpc_transport_tstream.c
83                    librpc/rpc/dcerpc_helpers.c''',
84                    deps='''ndr ndr-standard
85                     RPC_NDR_EPMAPPER NTLMSSP_COMMON COMMON_SCHANNEL LIBCLI_AUTH
86                     LIBTSOCKET gse dcerpc-binding
87                     libsmb ndr-table NETLOGON_CREDS_CLI
88                    ''',
89                    private_library=True)
90
91 bld.SAMBA3_LIBRARY('gpo',
92                    source='''../libgpo/gpo_ldap.c
93                    ../libgpo/gpo_ini.c
94                    ../libgpo/gpo_util.c
95                    ../libgpo/gpo_fetch.c
96                    libgpo/gpo_filesync.c
97                    ../libgpo/gpo_sec.c
98                    libgpo/gpo_reg.c''',
99                    deps='talloc ads TOKEN_UTIL gpext auth',
100                    private_library=True)
101
102 bld.SAMBA3_SUBSYSTEM('AVAHI',
103                     source='lib/avahi.c smbd/avahi_register.c',
104                     deps='avahi-common avahi-client',
105                     enabled=bld.env.with_avahi)
106
107 bld.SAMBA3_SUBSYSTEM('GROUPDB',
108                     source='groupdb/mapping.c groupdb/mapping_tdb.c',
109                     deps='tdb_compat')
110
111 bld.SAMBA3_SUBSYSTEM('TLDAP',
112                     source='''lib/tldap.c
113                     lib/tldap_util.c
114                     lib/util_tsock.c''',
115                     deps='asn1util LIBTSOCKET')
116
117 # libpdb.so should not expose internal symbols that are only usable
118 # to the statically linked modules that are merged into libpdb.
119 # Note that we always filter these symbols out in libpdb, even
120 # when modules are not linked statically. In the latter case
121 # symbols will not be present in the libpdb anyway so no hurt is
122 # done to the version script.
123 static_pdb_match = ['tdbsam', 'smbpasswd', 'wbc_sam']
124 private_pdb_match = []
125
126 # AD DC module when linked statically will pull in few source4/winbind
127 # dependencies which are not used outside AD DC module
128 static_pdb_match.append('samba_dsdb')
129 private_pdb_match.append('!idmap_init')
130 private_pdb_match.append('!idmap_sids_to_xids')
131 private_pdb_match.append('!idmap_xids_to_sids')
132
133 # ldap module is actually three modules merged together: ldapsam, ipa, and nds
134 static_pdb_match = static_pdb_match + ['ldap', 'ipa', 'nds']
135 ldapsam_pdb_match = ['!priv2ld', '!smbldap_search_domain_info',
136                      '!ldapsam_*', '!groupmap_attr_list*', '!get_userattr_list',
137                      '!dominfo_attr_list', '!get_attr_key2string',
138                      '!sidmap_attr_list', '!attrib_map_*', '!idpool_attr_list',
139                      '!get_attr_list']
140 private_pdb_match.append('!pdb_nds_*')
141 private_pdb_match.append('!pdb_init_ldapsam')
142 private_pdb_match.append('!pdb_ldapsam_init*')
143 private_pdb_match = private_pdb_match + ldapsam_pdb_match
144
145 private_pdb_match = private_pdb_match + map(lambda x: '!pdb_%s_init' % x, static_pdb_match)
146
147 bld.SAMBA3_LIBRARY('pdb',
148                    source='''passdb/pdb_get_set.c
149                    passdb/passdb.c
150                    lib/util_wellknown.c
151                    lib/util_builtin.c
152                    passdb/pdb_compat.c
153                    lib/util_sid_passdb.c
154                    lib/util_unixsids.c
155                    passdb/lookup_sid.c
156                    passdb/login_cache.c
157                    passdb/account_pol.c
158                    lib/privileges.c
159                    lib/util_nscd.c
160                    lib/winbind_util.c
161                    passdb/pdb_util.c
162                    passdb/pdb_interface.c
163                    passdb/pdb_secrets.c
164                    passdb/pdb_unixid.c''',
165                    deps='secrets3 GROUPDB SERVER_MUTEX wbclient LIBCLI_AUTH flag_mapping',
166                    private_library=False,
167                    pc_files=[],
168                    public_headers_install=True,
169                    public_headers='''
170                    include/passdb.h
171                    passdb/machine_sid.h
172                    passdb/lookup_sid.h''',
173                    abi_match=private_pdb_match,
174                    abi_directory='passdb/ABI',
175                    vnum='0.1.0')
176
177 bld.SAMBA3_LIBRARY('smbldaphelper',
178                    source='passdb/pdb_ldap_schema.c passdb/pdb_ldap_util.c',
179                    deps='smbldap secrets3',
180                    allow_undefined_symbols=True,
181                    enabled=bld.CONFIG_SET('HAVE_LDAP'),
182                    private_library=True)
183
184 bld.SAMBA3_SUBSYSTEM('SERVER_MUTEX',
185                      source='lib/server_mutex.c',
186                      deps='talloc')
187
188 bld.SAMBA3_SUBSYSTEM('param',
189                    source='''param/loadparm.c
190                    lib/sharesec.c
191                    lib/ldap_debug_handler.c
192                    lib/util_names.c''',
193                    allow_warnings=True,
194                    deps='samba-util PARAM_UTIL ldap lber LOADPARM_CTX samba3core smbconf param_local.h param_global.h cups''')
195
196 # this includes only the low level parse code, not stuff
197 # that requires knowledge of security contexts
198 bld.SAMBA3_SUBSYSTEM('REG_PARSE_PRS',
199                      source='registry/reg_parse_prs.c')
200
201 bld.SAMBA3_SUBSYSTEM('REGFIO',
202                     source='registry/regfio.c',
203                     deps='samba-util REG_PARSE_PRS')
204
205 bld.SAMBA3_SUBSYSTEM('REG_API_REGF',
206                     source='registry/reg_api_regf.c',
207                     deps='samba-util')
208
209 bld.SAMBA3_LIBRARY('smbregistry',
210                    source='''registry/reg_api.c
211                    registry/reg_dispatcher.c
212                    registry/reg_cachehook.c
213                    registry/reg_objects.c
214                    registry/reg_util_internal.c
215                    lib/util_nttoken.c
216                    registry/reg_backend_db.c
217                    registry/reg_parse_internal.c
218                    lib/cbuf.c
219                    lib/srprs.c
220                    registry/reg_init_basic.c''',
221                    deps='''smbd_shim tdb-wrap3 NDR_SECURITY util_tdb talloc
222                    replace util_reg samba-util samba-security
223                    errors3 dbwrap samba3-util''',
224                    allow_undefined_symbols=True,
225                    allow_warnings=True,
226                    private_library=True)
227
228 bld.SAMBA3_SUBSYSTEM('REG_SMBCONF',
229                     source='''registry/reg_backend_smbconf.c
230                     registry/reg_init_smbconf.c
231                     registry/reg_util_token.c
232                     registry/reg_api_util.c''',
233                     deps='smbregistry')
234
235 bld.SAMBA3_SUBSYSTEM('REG_FULL',
236                     source='''registry/reg_backend_printing.c
237                     registry/reg_backend_shares.c
238                     registry/reg_backend_netlogon_params.c
239                     registry/reg_backend_prod_options.c
240                     registry/reg_backend_tcpip_params.c
241                     registry/reg_backend_hkpt_params.c
242                     registry/reg_backend_current_version.c
243                     registry/reg_backend_perflib.c
244                     registry/reg_init_full.c
245                     registry/reg_perfcount.c''',
246                     deps='REG_SMBCONF tdb-wrap3')
247
248 bld.SAMBA3_LIBRARY('popt_samba3',
249                    source='lib/popt_common.c',
250                    deps='popt samba-util util_cmdline',
251                    private_library=True)
252
253 bld.SAMBA3_LIBRARY('util_cmdline',
254                    source='lib/util_cmdline.c',
255                    deps='secrets3',
256                    private_library=True)
257
258 bld.SAMBA3_SUBSYSTEM('KRBCLIENT',
259                      source='libads/kerberos.c libads/ads_status.c',
260                      allow_warnings=True,
261                      public_deps='krb5samba k5crypto gssapi LIBTSOCKET CLDAP LIBNMB')
262
263 bld.SAMBA3_SUBSYSTEM('samba3util',
264                    source='''lib/system.c
265                    lib/sendfile.c
266                    lib/recvfile.c
267                    lib/time.c
268                    lib/util_sid.c
269                    lib/util_file.c
270                    lib/util.c
271                    lib/util_sock.c
272                    lib/util_transfer_file.c
273                    lib/sock_exec.c''',
274                    deps='ndr samba-security NDR_SECURITY samba-util util_tdb ccan-hash')
275
276 if bld.CONFIG_GET("CTDB_CFLAGS"):
277     SAMBA_CLUSTER_SUPPORT_SOURCES='''
278                      lib/cluster_support.c
279                      lib/dbwrap/dbwrap_ctdb.c
280                      lib/messages_ctdbd.c
281                      lib/ctdb_packet.c
282                      lib/ctdbd_conn.c
283                      lib/ctdb_conn.c
284                      torture/test_ctdbconn.c
285                    '''
286     SAMBA_CLUSTER_SUPPORT_DEPS='''
287                      talloc
288                      tevent
289                      tdb
290                    '''
291 else:
292     SAMBA_CLUSTER_SUPPORT_SOURCES='''
293                      lib/cluster_support.c
294                      lib/ctdb_dummy.c
295                    '''
296     SAMBA_CLUSTER_SUPPORT_DEPS='''
297                      talloc
298                      tevent
299                    '''
300
301 bld.SAMBA3_LIBRARY('samba-cluster-support',
302                    source=SAMBA_CLUSTER_SUPPORT_SOURCES,
303                    deps=SAMBA_CLUSTER_SUPPORT_DEPS,
304                    cflags=bld.CONFIG_GET("CTDB_CFLAGS"),
305                    allow_undefined_symbols=True,
306                    private_library=True)
307
308 bld.SAMBA3_SUBSYSTEM('TDB_LIB',
309                      source='''lib/dbwrap/dbwrap_open.c
310                      lib/dbwrap/dbwrap_watch.c
311                      lib/g_lock.c''',
312                      deps='dbwrap samba-cluster-support')
313
314 bld.SAMBA3_SUBSYSTEM('samba3core',
315                    source='''lib/messages.c
316                    lib/messages_dgm.c
317                    lib/util_cluster.c
318                    lib/id_cache.c
319                    lib/talloc_dict.c
320                    lib/serverid.c
321                    lib/addrchange.c
322                    ../lib/util/debug_s3.c
323                    lib/dumpcore.c
324                    lib/interface.c
325                    lib/username.c
326                    lib/access.c lib/smbrun.c
327                    lib/wins_srv.c
328                    lib/substitute.c
329                    lib/substitute_generic.c
330                    lib/ms_fnmatch.c
331                    lib/tallocmsg.c
332                    lib/dmallocmsg.c
333                    intl/lang_tdb.c
334                    lib/gencache.c
335                    lib/events.c
336                    lib/server_contexts.c
337                    lib/server_prefork.c
338                    lib/server_prefork_util.c
339                    lib/ldap_escape.c
340                    lib/fncall.c
341                    libads/krb5_errs.c
342                    lib/system_smbd.c
343                    lib/audit.c
344                    lib/tevent_wait.c
345                    lib/idmap_cache.c
346                    lib/util_ea.c
347                    lib/background.c''',
348                    deps='''
349                         samba3util
350                         LIBTSOCKET
351                         NDR_MESSAGING
352                         LIBASYNC_REQ
353                         UTIL_PW
354                         SAMBA_VERSION
355                         PTHREADPOOL
356                         UNIX_MSG
357                         POLL_FUNCS_TEVENT
358                         interfaces
359                         param
360                         dbwrap
361                         samba3-util
362                         errors3
363                         TDB_LIB''')
364
365 bld.SAMBA3_LIBRARY('smbd_shim',
366                    source='''lib/smbd_shim.c''',
367                    deps='talloc',
368                    private_library=True)
369
370 bld.SAMBA3_SUBSYSTEM('LIBNTLMSSP',
371                     source='''libsmb/ntlmssp.c
372                     libsmb/ntlmssp_wrap.c''',
373                     deps='NDR_NTLMSSP NTLMSSP_COMMON wbclient')
374
375 bld.SAMBA3_SUBSYSTEM('auth_generic',
376                     source='libsmb/auth_generic.c',
377                     deps='LIBNTLMSSP gse gensec')
378
379 bld.SAMBA3_LIBRARY('libsmb',
380                    source='''libsmb/clientgen.c
381                    libsmb/cliconnect.c
382                    libsmb/clifile.c
383                    libsmb/clispnego.c
384                    libsmb/clirap.c
385                    libsmb/clierror.c
386                    libsmb/climessage.c
387                    libsmb/clireadwrite.c
388                    libsmb/clilist.c
389                    libsmb/cliprint.c
390                    libsmb/clitrans.c
391                    libsmb/clisecdesc.c
392                    libsmb/clidgram.c
393                    libsmb/clistr.c
394                    libsmb/cliquota.c
395                    libsmb/clifsinfo.c
396                    libsmb/clidfs.c
397                    libsmb/clioplock.c
398                    libsmb/clirap2.c
399                    libsmb/async_smb.c
400                    libsmb/smb2cli_tcon.c
401                    libsmb/reparse_symlink.c
402                    libsmb/clisymlink.c
403                    libsmb/smbsock_connect.c
404                    libsmb/cli_smb2_fnum.c''',
405                    deps='''
406                    LIBNTLMSSP
407                    auth_generic
408                    CLDAP
409                    LIBNMB
410                    SPNEGO_PARSE
411                    LIBTSOCKET
412                    KRBCLIENT
413                    cli_smb_common
414                    util_cmdline
415                    tevent''',
416                    private_library=True)
417
418 bld.SAMBA3_SUBSYSTEM('CLDAP',
419                     source='libads/cldap.c',
420                     deps='cli-ldap-common cli_cldap LIBTSOCKET')
421
422 # NOTE: The secrets3 library is a low level library used by several subsystems.
423 # PLEASE DO NOT make it depend on high level libraries like PDB, if you are
424 # doing that your design is wrong and needs changing. -SSS
425 bld.SAMBA3_LIBRARY('secrets3',
426                    source='''passdb/secrets.c
427                    passdb/machine_account_secrets.c
428                    passdb/machine_sid.c
429                    passdb/secrets_lsa.c''',
430                    deps='NDR_SECRETS param samba3util dbwrap',
431                    private_library=True)
432
433 bld.SAMBA3_LIBRARY('smbldap',
434                     source='lib/smbldap.c',
435                     deps='ldap lber samba-util param',
436                     enabled=bld.CONFIG_SET("HAVE_LDAP"),
437                     private_library=False,
438                     abi_directory='lib/ABI',
439                     abi_match='smbldap_*',
440                     pc_files=[],
441                     vnum='0',
442                     public_headers='include/smbldap.h include/smb_ldap.h')
443
444 bld.SAMBA3_LIBRARY('ads',
445                    source='''libads/ldap.c
446                    libads/sasl.c
447                    libads/sasl_wrapping.c
448                    libads/krb5_setpw.c
449                    libads/kerberos_util.c
450                    libads/ldap_user.c
451                    libads/ads_struct.c
452                    libads/kerberos_keytab.c
453                    libads/disp_sec.c
454                    libads/ldap_utils.c
455                    libads/ldap_schema.c
456                    libads/util.c
457                    libads/ndr.c''',
458                    allow_warnings=True,
459                    deps='cli-ldap-common krb5samba ldap lber KRBCLIENT param LIBNMB libsmb DCUTIL smbldap',
460                    private_library=True)
461
462 bld.SAMBA3_SUBSYSTEM('LIBADS_SERVER',
463                      source='libads/authdata.c',
464                      deps='SERVER_MUTEX ndr-krb5pac krb5samba gssapi')
465
466 bld.SAMBA3_SUBSYSTEM('LIBADS_PRINTER',
467                     source='libads/ldap_printer.c',
468                     deps='samba-util krb5samba')
469
470 bld.SAMBA3_SUBSYSTEM('LIBAFS_SETTOKEN',
471                     source='lib/afs_settoken.c',
472                     deps='samba-util')
473
474 bld.SAMBA3_SUBSYSTEM('LIBAFS',
475                     source='lib/afs.c',
476                     deps='samba-util LIBAFS_SETTOKEN')
477
478 bld.SAMBA3_LIBRARY('smbconf',
479                    source='''lib/smbconf/smbconf_init.c
480                    lib/smbconf/smbconf_reg.c''',
481                    deps='''
482                    CHARSET3
483                    LIBSMBCONF
484                    REG_SMBCONF
485                    SAMBA_VERSION
486                    cap
487                    charset
488                    cli_smb_common
489                    errors3
490                    param
491                    samba-util
492                    smbregistry
493                    talloc
494                    util_reg''',
495                    public_headers='../lib/smbconf/smbconf.h',
496                    pc_files=[],
497                    vnum='0')
498
499 bld.SAMBA3_LIBRARY('smbd_conn',
500                    source='smbd/conn.c',
501                    deps='samba3-util samba-util',
502                    private_library=True)
503
504 bld.SAMBA3_SUBSYSTEM('sysquotas',
505                      source='''
506                         lib/sysquotas.c
507                         lib/sysquotas_linux.c
508                         lib/sysquotas_xfs.c
509                         lib/sysquotas_4A.c
510                         lib/sysquotas_4B.c
511                         lib/sysquotas_nfs.c
512                      ''',
513                      allow_warnings=True,
514                      deps='samba3-util samba-util')
515
516 bld.SAMBA3_LIBRARY('smbd_base',
517                    source='''
518                    smbd/server_reload.c
519                    smbd/files.c
520                    smbd/connection.c
521                    smbd/utmp.c
522                    smbd/session.c
523                    smbd/dfree.c
524                    smbd/dir.c
525                    smbd/password.c
526                    smbd/conn_msg.c
527                    smbd/conn_idle.c
528                    smbd/share_access.c
529                    smbd/fileio.c
530                    smbd/ipc.c
531                    smbd/lanman.c
532                    smbd/negprot.c
533                    smbd/message.c
534                    smbd/nttrans.c
535                    smbd/pipes.c
536                    smbd/reply.c
537                    smbd/sesssetup.c
538                    smbd/trans2.c
539                    smbd/uid.c
540                    smbd/dosmode.c
541                    smbd/filename.c
542                    smbd/open.c
543                    smbd/close.c
544                    smbd/blocking.c
545                    smbd/sec_ctx.c
546                    smbd/srvstr.c
547                    smbd/vfs.c
548                    smbd/perfcount.c
549                    smbd/statcache.c
550                    smbd/seal.c
551                    smbd/posix_acls.c
552                    lib/sysacls.c
553                    smbd/process.c
554                    smbd/service.c
555                    smbd/error.c
556                    printing/printspoolss.c
557                    printing/spoolssd.c
558                    lib/sessionid_tdb.c
559                    lib/conn_tdb.c
560                    smbd/fake_file.c
561                    smbd/quotas.c
562                    smbd/ntquotas.c
563                    smbd/msdfs.c
564                    smbd/aio.c smbd/statvfs.c
565                    smbd/dmapi.c
566                    smbd/signing.c
567                    smbd/file_access.c
568                    smbd/dnsregister.c smbd/globals.c
569                    smbd/smb2_server.c
570                    smbd/smb2_glue.c
571                    smbd/smb2_negprot.c
572                    smbd/smb2_sesssetup.c
573                    smbd/smb2_tcon.c
574                    smbd/smb2_create.c
575                    smbd/smb2_close.c
576                    smbd/smb2_flush.c
577                    smbd/smb2_read.c
578                    smbd/smb2_write.c
579                    smbd/smb2_lock.c
580                    smbd/smb2_ioctl.c
581                    smbd/smb2_ioctl_dfs.c
582                    smbd/smb2_ioctl_filesys.c
583                    smbd/smb2_ioctl_named_pipe.c
584                    smbd/smb2_ioctl_network_fs.c
585                    smbd/smb2_keepalive.c
586                    smbd/smb2_find.c
587                    smbd/smb2_notify.c
588                    smbd/smb2_getinfo.c
589                    smbd/smb2_setinfo.c
590                    smbd/smb2_break.c
591                    smbd/smbXsrv_version.c
592                    smbd/smbXsrv_session.c
593                    smbd/smbXsrv_tcon.c
594                    smbd/smbXsrv_open.c
595                    smbd/server_exit.c
596                    smbd/durable.c
597                    smbd/scavenger.c
598                    smbd/mangle.c
599                    smbd/mangle_hash.c
600                    smbd/mangle_hash2.c
601                    smbd/oplock.c
602                    smbd/oplock_irix.c
603                    smbd/oplock_linux.c
604                    smbd/notify.c
605                    smbd/notify_inotify.c
606                    smbd/notify_internal.c
607                    smbd/build_options.c''',
608                    deps='''
609                    talloc
610                    tevent
611                    pdb
612                    libsmb
613                    msrpc3
614                    vfs
615                    vfs_default
616                    vfs_posixacl
617                    inotify
618                    popt_samba3
619                    samba3core
620                    smbd_conn
621                    param_service
622                    AVAHI
623                    PRINTBASE
624                    PROFILE
625                    LOCKING
626                    LIBADS_SERVER
627                    LIBAFS
628                    RPC_SERVICE
629                    NDR_SMBXSRV
630                    LIBASYS
631                    sysquotas
632                    ccan-hash
633                    NDR_SMB_ACL
634                    netapi
635                    NDR_IOCTL
636                    ''' + bld.env['dmapi_lib'],
637                    private_library=True)
638
639 bld.SAMBA3_SUBSYSTEM('LOCKING',
640                     source='''locking/locking.c
641                     locking/brlock.c
642                     locking/posix.c
643                     locking/share_mode_lock.c''',
644                     deps='''
645                     tdb_compat
646                     talloc
647                     NDR_OPEN_FILES
648                     FNAME_UTIL''')
649
650 bld.SAMBA3_SUBSYSTEM('PROFILE',
651                     source='profile/profile.c',
652                     deps='samba-util')
653
654 bld.SAMBA3_SUBSYSTEM('PRINTBASE',
655                     source='''printing/notify.c printing/printing_db.c''',
656                     deps='samba-util tdb_compat')
657
658 bld.SAMBA3_SUBSYSTEM('PRINTBACKEND',
659                     source='''printing/printing.c
660                     printing/nt_printing.c
661                     printing/nt_printing_tdb.c
662                     printing/nt_printing_migrate_internal.c
663                     printing/nt_printing_ads.c
664                     printing/queue_process.c''',
665                     deps='PRINTBASE LIBADS_PRINTER tdb_compat printing_migrate')
666
667 bld.SAMBA3_LIBRARY('printing_migrate',
668                     source='printing/nt_printing_migrate.c rpc_client/cli_winreg_spoolss.c printing/nt_printing_os2.c',
669                     deps='NDR_NTPRINTING cli_spoolss RPC_NDR_WINREG LIBCLI_WINREG param',
670                     private_library=True)
671
672 bld.SAMBA3_SUBSYSTEM('PRINTING',
673                     source='''printing/pcap.c
674                     printing/print_svid.c
675                     printing/print_aix.c
676                     printing/print_cups.c
677                     printing/print_generic.c
678                     printing/lpq_parse.c
679                     printing/load.c
680                     printing/print_standard.c
681                     printing/print_iprint.c
682                     printing/printer_list.c''',
683                     deps='NDR_PRINTCAP tdb_compat cups')
684
685 bld.SAMBA3_SUBSYSTEM('PASSWD_UTIL',
686                     source='utils/passwd_util.c',
687                     deps='samba-util')
688
689 bld.SAMBA3_SUBSYSTEM('FNAME_UTIL',
690                     source='lib/filename_util.c',
691                     deps='samba-util')
692
693 bld.SAMBA3_SUBSYSTEM('LIBNET',
694                     source='libnet/libnet_join.c',
695                     deps='NDR_LIBNET_JOIN INIT_SAMR net_keytab pdb')
696
697 bld.SAMBA3_LIBRARY('net_keytab',
698                    source='libnet/libnet_keytab.c',
699                    deps='krb5samba ads',
700                    private_library=True)
701
702
703 bld.SAMBA3_SUBSYSTEM('LIBNET_DSSYNC',
704                     source='''libnet/libnet_dssync.c
705                     libnet/libnet_dssync_passdb.c
706                     libnet/libnet_dssync_keytab.c''',
707                     allow_warnings=True,
708                     deps='LIBNET RPC_NDR_DRSUAPI')
709
710 bld.SAMBA3_SUBSYSTEM('LIBNET_SAMSYNC',
711                     source='''libnet/libnet_samsync.c
712                     libnet/libnet_samsync_ldif.c
713                     libnet/libnet_samsync_passdb.c
714                     libnet/libnet_samsync_display.c
715                     libnet/libnet_samsync_keytab.c''',
716                     deps='LIBNET LIBCLI_SAMSYNC')
717
718 bld.SAMBA3_SUBSYSTEM('LIBEVENTLOG',
719                     source='lib/eventlog/eventlog.c',
720                     deps='NDR_EVENTLOG tdb_compat')
721
722 bld.SAMBA3_SUBSYSTEM('LIBNMB',
723                      source='''libsmb/unexpected.c
724                      libsmb/namecache.c
725                      libsmb/nmblib.c
726                      libsmb/namequery.c
727                      libsmb/conncache.c
728                      libads/sitename_cache.c''',
729                      deps='addns lmhosts resolv')
730
731 bld.SAMBA3_SUBSYSTEM('SERVICES',
732                     source='''services/svc_spoolss.c
733                     services/svc_rcinit.c
734                     services/svc_winreg_glue.c
735                     services/svc_netlogon.c
736                     services/svc_winreg.c
737                     services/svc_wins.c''',
738                     deps='samba-util')
739
740 bld.SAMBA3_SUBSYSTEM('PLAINTEXT_AUTH',
741                     source='''auth/pampass.c auth/pass_check.c''',
742                     deps='pam PAM_ERRORS')
743
744 bld.SAMBA3_SUBSYSTEM('PASSCHANGE',
745                     source='libsmb/passchange.c',
746                     deps='''LIBCLI_SAMR
747                     INIT_LSA
748                     msrpc3
749                     krb5samba''')
750
751 bld.SAMBA3_SUBSYSTEM('SAMBA_VERSION',
752                     source='lib/version.c',
753                     deps='samba-util')
754
755 bld.SAMBA3_SUBSYSTEM('SLCACHE',
756                     source='libsmb/samlogon_cache.c',
757                     deps='samba-util tdb_compat')
758
759 bld.SAMBA3_SUBSYSTEM('DCUTIL',
760                     source='''libsmb/namequery_dc.c
761                     libsmb/trustdom_cache.c
762                     libsmb/dsgetdcname.c''',
763                     deps='ads msrpc3 libcli_lsa3')
764
765 bld.SAMBA3_LIBRARY('trusts_util',
766                    source='libsmb/trusts_util.c',
767                    deps='libcli_netlogon3 msrpc3 pdb',
768                    private_library=True)
769
770 bld.SAMBA3_SUBSYSTEM('tdb-wrap3',
771                     source='lib/util_tdb.c',
772                     deps='talloc samba3-util')
773
774 bld.SAMBA3_LIBRARY('samba3-util',
775                    source='''lib/util_sec.c lib/util_str.c lib/adt_tree.c lib/util_malloc.c lib/memcache.c lib/namearray.c lib/file_id.c''',
776                    deps='samba-util charset',
777                    private_library=True)
778
779 bld.SAMBA_LIBRARY('xattr_tdb',
780                   source='lib/xattr_tdb.c',
781                   deps='NDR_XATTR dbwrap samba3-util',
782                   private_library=True)
783
784 bld.SAMBA3_LIBRARY('CHARSET3',
785                     source='''lib/charcnv.c lib/fstring.c''',
786                     public_deps='ICONV_WRAPPER charset',
787                     deps='samba-util samba3-util',
788                    private_library=True)
789
790 bld.SAMBA3_SUBSYSTEM('errors3',
791                      source='libsmb/errormap.c libsmb/smberr.c lib/errmap_unix.c',
792                      deps='errors')
793
794 bld.SAMBA3_SUBSYSTEM('LIBCLI_SAMR',
795                     source='rpc_client/cli_samr.c',
796                     deps='RPC_NDR_SAMR')
797
798 bld.SAMBA3_LIBRARY('libcli_lsa3',
799                    source='rpc_client/cli_lsarpc.c',
800                    deps='RPC_NDR_LSA INIT_LSA',
801                    private_library=True)
802
803 bld.SAMBA3_LIBRARY('libcli_netlogon3',
804                    source='rpc_client/cli_netlogon.c rpc_client/util_netlogon.c',
805                    deps='msrpc3 RPC_NDR_NETLOGON INIT_NETLOGON cliauth param NETLOGON_CREDS_CLI',
806                    private_library=True)
807
808 bld.SAMBA3_LIBRARY('cli_spoolss',
809                    source='''rpc_client/cli_spoolss.c
810                    rpc_client/init_spoolss.c''',
811                    deps='RPC_NDR_SPOOLSS param secrets3',
812                    private_library=True)
813
814 bld.SAMBA3_SUBSYSTEM('LIBCLI_WINREG',
815                     source='rpc_client/cli_winreg.c',
816                     deps='RPC_NDR_WINREG')
817
818 bld.SAMBA3_SUBSYSTEM('LIBCLI_WINREG_INTERNAL',
819                     source='rpc_client/cli_winreg_int.c',
820                     deps='LIBCLI_WINREG RPC_SERVER')
821
822 bld.SAMBA3_SUBSYSTEM('RPC_CLIENT_SCHANNEL',
823                     source='rpc_client/cli_pipe_schannel.c',
824                     deps='samba-util krb5samba')
825
826 bld.SAMBA3_SUBSYSTEM('INIT_LSA',
827                     source='rpc_client/init_lsa.c',
828                     deps='samba-util')
829
830 bld.SAMBA3_SUBSYSTEM('INIT_NETLOGON',
831                     source='rpc_client/init_netlogon.c',
832                     deps='samba-util')
833
834 bld.SAMBA3_SUBSYSTEM('INIT_SAMR',
835                     source='rpc_client/init_samr.c',
836                     deps='samba-util')
837
838 ########################## BINARIES #################################
839
840 bld.SAMBA3_BINARY('smbd/smbd',
841                  source='smbd/server.c',
842                  deps='smbd_base EPMD LSASD',
843                  install_path='${SBINDIR}')
844
845 bld.SAMBA3_BINARY('nmbd/nmbd',
846                  source='''nmbd/asyncdns.c nmbd/nmbd.c nmbd/nmbd_become_dmb.c
847                  nmbd/nmbd_become_lmb.c nmbd/nmbd_browserdb.c
848                  nmbd/nmbd_browsesync.c nmbd/nmbd_elections.c
849                  nmbd/nmbd_incomingdgrams.c nmbd/nmbd_incomingrequests.c
850                  nmbd/nmbd_lmhosts.c nmbd/nmbd_logonnames.c nmbd/nmbd_mynames.c
851                  nmbd/nmbd_namelistdb.c nmbd/nmbd_namequery.c
852                  nmbd/nmbd_nameregister.c nmbd/nmbd_namerelease.c
853                  nmbd/nmbd_nodestatus.c nmbd/nmbd_packets.c
854                  nmbd/nmbd_processlogon.c nmbd/nmbd_responserecordsdb.c
855                  nmbd/nmbd_sendannounce.c nmbd/nmbd_serverlistdb.c
856                  nmbd/nmbd_subnetdb.c nmbd/nmbd_winsproxy.c nmbd/nmbd_winsserver.c
857                  nmbd/nmbd_workgroupdb.c nmbd/nmbd_synclists.c''',
858                  deps='''
859                  talloc
860                  tevent
861                  param
862                  libsmb
863                  popt_samba3
864                  PROFILE''',
865                  install_path='${SBINDIR}')
866
867
868 bld.SAMBA3_SUBSYSTEM('TDB_VALIDATE',
869                      source='lib/tdb_validate.c',
870                      deps='samba-util')
871
872
873 bld.SAMBA3_BINARY('winbindd/winbindd',
874                  source='''winbindd/winbindd.c
875                  winbindd/winbindd_group.c
876                  winbindd/winbindd_util.c
877                  winbindd/winbindd_cache.c
878                  winbindd/winbindd_pam.c
879                  winbindd/winbindd_misc.c
880                  winbindd/winbindd_cm.c
881                  winbindd/winbindd_wins_byip.c
882                  winbindd/winbindd_wins_byname.c
883                  winbindd/winbindd_msrpc.c
884                  winbindd/winbindd_rpc.c
885                  winbindd/winbindd_reconnect.c
886                  winbindd/winbindd_ads.c
887                  winbindd/winbindd_samr.c
888                  winbindd/winbindd_dual.c
889                  winbindd/winbindd_dual_ndr.c
890                  winbindd/winbindd_dual_srv.c
891                  winbindd/winbindd_async.c
892                  winbindd/winbindd_creds.c
893                  winbindd/winbindd_cred_cache.c
894                  winbindd/winbindd_ccache_access.c
895                  winbindd/winbindd_domain.c
896                  winbindd/winbindd_idmap.c
897                  winbindd/winbindd_locator.c
898                  winbindd/winbindd_ndr.c
899                  winbindd/wb_ping.c
900                  winbindd/wb_lookupsid.c
901                  winbindd/wb_lookupsids.c
902                  winbindd/wb_lookupname.c
903                  winbindd/wb_uid2sid.c
904                  winbindd/wb_gid2sid.c
905                  winbindd/wb_sids2xids.c
906                  winbindd/wb_queryuser.c
907                  winbindd/wb_lookupuseraliases.c
908                  winbindd/wb_lookupusergroups.c
909                  winbindd/wb_getpwsid.c
910                  winbindd/wb_gettoken.c
911                  winbindd/wb_seqnum.c
912                  winbindd/wb_seqnums.c
913                  winbindd/wb_group_members.c
914                  winbindd/wb_getgrsid.c
915                  winbindd/wb_query_user_list.c
916                  winbindd/wb_fill_pwent.c
917                  winbindd/wb_next_pwent.c
918                  winbindd/wb_next_grent.c
919                  winbindd/wb_dsgetdcname.c
920                  winbindd/winbindd_lookupsid.c
921                  winbindd/winbindd_lookupsids.c
922                  winbindd/winbindd_lookupname.c
923                  winbindd/winbindd_sid_to_uid.c
924                  winbindd/winbindd_sid_to_gid.c
925                  winbindd/winbindd_uid_to_sid.c
926                  winbindd/winbindd_gid_to_sid.c
927                  winbindd/winbindd_sids_to_xids.c
928                  winbindd/winbindd_allocate_uid.c
929                  winbindd/winbindd_allocate_gid.c
930                  winbindd/winbindd_getpwsid.c
931                  winbindd/winbindd_getpwnam.c
932                  winbindd/winbindd_getpwuid.c
933                  winbindd/winbindd_getsidaliases.c
934                  winbindd/winbindd_getuserdomgroups.c
935                  winbindd/winbindd_getgroups.c
936                  winbindd/winbindd_show_sequence.c
937                  winbindd/winbindd_getgrgid.c
938                  winbindd/winbindd_getgrnam.c
939                  winbindd/winbindd_getusersids.c
940                  winbindd/winbindd_lookuprids.c
941                  winbindd/winbindd_setpwent.c
942                  winbindd/winbindd_getpwent.c
943                  winbindd/winbindd_endpwent.c
944                  winbindd/winbindd_setgrent.c
945                  winbindd/winbindd_getgrent.c
946                  winbindd/winbindd_endgrent.c
947                  winbindd/winbindd_dsgetdcname.c
948                  winbindd/winbindd_getdcname.c
949                  winbindd/winbindd_list_users.c
950                  winbindd/winbindd_list_groups.c
951                  winbindd/winbindd_check_machine_acct.c
952                  winbindd/winbindd_change_machine_acct.c
953                  winbindd/winbindd_ping_dc.c
954                  winbindd/winbindd_pam_auth.c
955                  winbindd/winbindd_pam_logoff.c
956                  winbindd/winbindd_pam_chauthtok.c
957                  winbindd/winbindd_pam_auth_crap.c
958                  winbindd/winbindd_pam_chng_pswd_auth_crap.c''',
959                  deps='''
960                  talloc
961                  tevent
962                  pdb
963                  popt_samba3
964                  idmap
965                  ads
966                  msrpc3
967                  nss_info
968                  LIBAFS
969                  LIBADS_SERVER
970                  LIBCLI_SAMR
971                  SLCACHE
972                  RPC_NDR_DSSETUP
973                  RPC_NDR_WBINT
974                  SRV_NDR_WBINT
975                  RPC_SAMR
976                  RPC_LSARPC
977                  RPC_SERVER
978                  WB_REQTRANS
979                  TDB_VALIDATE
980                  ''',
981                  enabled=bld.env.build_winbind,
982                  install_path='${SBINDIR}')
983
984 bld.SAMBA3_BINARY('rpcclient/rpcclient',
985                  source='''rpcclient/rpcclient.c
986                  rpcclient/cmd_lsarpc.c
987                  rpcclient/cmd_samr.c
988                  rpcclient/cmd_spoolss.c
989                  rpcclient/cmd_netlogon.c
990                  rpcclient/cmd_srvsvc.c
991                  rpcclient/cmd_dfs.c
992                  rpcclient/cmd_epmapper.c
993                  rpcclient/cmd_dssetup.c
994                  rpcclient/cmd_echo.c
995                  rpcclient/cmd_shutdown.c
996                  rpcclient/cmd_test.c
997                  rpcclient/cmd_wkssvc.c
998                  rpcclient/cmd_ntsvcs.c
999                  rpcclient/cmd_drsuapi.c
1000                  rpcclient/cmd_eventlog.c
1001                  rpcclient/cmd_winreg.c
1002                  rpcclient/cmd_fss.c
1003                  rpcclient/cmd_witness.c''',
1004                  deps='''
1005                  talloc
1006                  popt_samba3
1007                  pdb
1008                  libsmb
1009                  param
1010                  ndr-standard
1011                  msrpc3
1012                  SMBREADLINE
1013                  trusts_util
1014                  RPC_NDR_WINREG
1015                  RPC_NDR_ECHO
1016                  RPC_CLIENT_SCHANNEL
1017                  DCUTIL
1018                  LIBCLI_SAMR
1019                  libcli_lsa3
1020                  libcli_netlogon3
1021                  cli_spoolss
1022                  RPC_NDR_SRVSVC
1023                  RPC_NDR_WKSSVC
1024                  RPC_NDR_DSSETUP
1025                  RPC_NDR_DFS
1026                  RPC_NDR_DRSUAPI
1027                  RPC_NDR_NTSVCS
1028                  RPC_NDR_EVENTLOG
1029                  INIT_SAMR
1030                  RPC_NDR_FSRVP
1031                  RPC_NDR_WITNESS
1032                  ''')
1033
1034 bld.SAMBA3_BINARY('client/smbclient',
1035                  source='''client/client.c
1036                  client/clitar.c
1037                  client/dnsbrowse.c''',
1038                  deps='''
1039                  talloc
1040                  popt_samba3
1041                  param
1042                  ndr-standard
1043                  SMBREADLINE
1044                  libsmb
1045                  msrpc3
1046                  RPC_NDR_SRVSVC
1047                  cli_smb_common
1048                  ''' + bld.env['archive_lib'])
1049
1050 bld.SAMBA3_BINARY('net',
1051                  source='''utils/net.c
1052                  utils/net_ads.c
1053                  utils/net_help.c
1054                  utils/net_rap.c
1055                  utils/net_rpc.c
1056                  utils/net_rpc_samsync.c
1057                  utils/net_time.c
1058                  utils/net_lookup.c
1059                  utils/net_cache.c
1060                  utils/net_groupmap.c
1061                  utils/net_idmap.c
1062                  utils/net_idmap_check.c
1063                  utils/interact.c
1064                  utils/net_status.c
1065                  utils/net_rpc_printer.c
1066                  utils/net_rpc_rights.c
1067                  utils/net_rpc_service.c
1068                  utils/net_rpc_registry.c
1069                  utils/net_usershare.c
1070                  utils/netlookup.c
1071                  utils/net_sam.c
1072                  utils/net_rpc_shell.c
1073                  utils/net_util.c
1074                  utils/net_rpc_sh_acct.c
1075                  utils/net_rpc_audit.c
1076                  utils/net_dns.c
1077                  utils/net_ads_gpo.c
1078                  utils/net_conf.c
1079                  utils/net_conf_util.c
1080                  utils/net_join.c
1081                  utils/net_user.c
1082                  utils/net_group.c
1083                  utils/net_file.c
1084                  utils/net_registry.c
1085                  utils/net_registry_check.c
1086                  utils/net_dom.c
1087                  utils/net_share.c
1088                  utils/net_g_lock.c
1089                  utils/net_serverid.c
1090                  utils/net_eventlog.c
1091                  utils/net_printing.c
1092                  utils/net_rpc_trust.c
1093                  utils/net_rpc_conf.c
1094                  registry/reg_parse.c
1095                  registry/reg_format.c
1096                  registry/reg_import.c
1097                  utils/net_registry_util.c
1098                  utils/net_help_common.c''',
1099                  deps='''
1100                  talloc
1101                  netapi
1102                  addns
1103                  samba_intl
1104                  popt_samba3
1105                  pdb
1106                  libsmb
1107                  param
1108                  KRBCLIENT
1109                  ndr-standard
1110                  msrpc3
1111                  gpo
1112                  ads
1113                  smbd_base
1114                  LIBADS_SERVER
1115                  LIBADS_PRINTER
1116                  SMBREADLINE
1117                  PASSWD_UTIL
1118                  LIBNET
1119                  LIBNET_DSSYNC
1120                  LIBNET_SAMSYNC
1121                  LIBEVENTLOG
1122                  REGFIO
1123                  NDR_NTPRINTING
1124                  RPC_NDR_WINREG
1125                  RPC_CLIENT_SCHANNEL
1126                  LIBCLI_SAMR
1127                  libcli_lsa3
1128                  libcli_netlogon3
1129                  cli_spoolss
1130                  RPC_NDR_SRVSVC
1131                  RPC_NDR_SVCCTL
1132                  RPC_NDR_DSSETUP
1133                  RPC_NDR_INITSHUTDOWN
1134                  printing_migrate
1135                  trusts_util
1136                  IDMAP_AUTORID_TDB''')
1137
1138 bld.SAMBA3_BINARY('profiles',
1139                  source='utils/profiles.c',
1140                  deps='''
1141                  talloc
1142                  popt_samba3
1143                  param
1144                  REGFIO''')
1145
1146 bld.SAMBA3_BINARY('smbspool',
1147                  source='client/smbspool.c',
1148                  deps='''
1149                  talloc
1150                  popt_samba3
1151                  param
1152                  libsmb
1153                  samba3core''')
1154
1155 bld.SAMBA3_BINARY('testparm',
1156                  source='utils/testparm.c',
1157                  deps='''
1158                  talloc
1159                  param
1160                  popt_samba3''')
1161
1162 bld.SAMBA3_BINARY('smbta-util',
1163                  source='utils/smbta-util.c',
1164                  deps='''
1165                  talloc
1166                  secrets3
1167                  param''')
1168
1169 bld.SAMBA3_BINARY('smbstatus',
1170                  source='''utils/status.c
1171                  utils/status_profile.c
1172                  smbd/notify_internal.c''',
1173                  deps='''
1174                  talloc
1175                  param
1176                  popt_samba3
1177                  smbd_base
1178                  LOCKING
1179                  PROFILE''')
1180
1181 bld.SAMBA3_BINARY('smbcontrol',
1182                  source='utils/smbcontrol.c',
1183                  deps='''
1184                  talloc
1185                  param
1186                  popt_samba3
1187                  PRINTBASE''')
1188
1189 bld.SAMBA3_BINARY('smbtree',
1190                  source='utils/smbtree.c',
1191                  deps='''
1192                  talloc
1193                  param
1194                  libsmb
1195                  msrpc3
1196                  popt_samba3
1197                  PROFILE
1198                  RPC_NDR_SRVSVC''')
1199
1200 bld.SAMBA3_BINARY('smbpasswd',
1201                  source='utils/smbpasswd.c',
1202                  deps='''
1203                  talloc
1204                  param
1205                  pdb
1206                  PASSWD_UTIL
1207                  PASSCHANGE''')
1208
1209 bld.SAMBA3_BINARY('pdbedit',
1210                  source='utils/pdbedit.c',
1211                  deps='''
1212                  talloc
1213                  param
1214                  popt_samba3
1215                  pdb
1216                  PASSWD_UTIL''')
1217
1218 bld.SAMBA3_BINARY('smbget',
1219                  source='utils/smbget.c',
1220                  deps='''
1221                  talloc
1222                  popt_samba3
1223                  smbclient''')
1224
1225 bld.SAMBA3_BINARY('nmblookup',
1226                  source='utils/nmblookup.c',
1227                  deps='''
1228                  talloc
1229                  param
1230                  popt_samba3
1231                  LIBNMB''')
1232
1233 bld.SAMBA3_BINARY('smbtorture' + bld.env.suffix3,
1234                  source='''torture/torture.c
1235                  torture/nbio.c
1236                  torture/scanner.c
1237                  torture/utable.c
1238                  torture/denytest.c
1239                  torture/mangle_test.c
1240                  torture/nbench.c
1241                  torture/test_async_echo.c
1242                  torture/test_addrchange.c
1243                  torture/test_posix_append.c
1244                  torture/test_nttrans_create.c
1245                  torture/test_nttrans_fsctl.c
1246                  torture/test_case_insensitive.c
1247                  torture/test_notify_online.c
1248                  torture/test_chain3.c
1249                  torture/test_smb2.c
1250                  torture/test_authinfo_structs.c
1251                  torture/test_smbsock_any_connect.c
1252                  torture/test_cleanup.c
1253                  torture/test_notify.c
1254                  lib/tevent_barrier.c
1255                  torture/test_dbwrap_watch.c
1256                  torture/test_idmap_tdb_common.c
1257                  torture/test_dbwrap_ctdb.c
1258                  torture/test_buffersize.c
1259                  torture/test_messaging_read.c
1260                  torture/t_strappend.c
1261                  torture/bench_pthreadpool.c
1262                  torture/wbc_async.c''',
1263                  deps='''
1264                  talloc
1265                  param
1266                  libsmb
1267                  msrpc3
1268                  TLDAP
1269                  RPC_NDR_ECHO
1270                  WB_REQTRANS
1271                  LOCKING
1272                  NDR_OPEN_FILES
1273                  idmap
1274                  samba-cluster-support
1275                  ''',
1276                  cflags='-DWINBINDD_SOCKET_DIR=\"%s\"' % bld.env.WINBINDD_SOCKET_DIR,
1277                  install=False)
1278
1279 bld.SAMBA3_BINARY('smbconftort',
1280                  source='lib/smbconf/testsuite.c',
1281                  deps='''
1282                  talloc
1283                  param
1284                  popt_samba3''',
1285                  install=False)
1286
1287 bld.SAMBA3_BINARY('replacetort',
1288                  source='../lib/replace/test/main.c',
1289                  deps='replace replace-test',
1290                  install=False)
1291
1292 bld.SAMBA3_BINARY('msgtest',
1293                  source='torture/msgtest.c',
1294                  deps='''
1295                  talloc
1296                  param''',
1297                  install=False)
1298
1299 bld.SAMBA3_BINARY('smbcacls',
1300                  source='utils/smbcacls.c',
1301                  deps='''
1302                  talloc
1303                  popt_samba3
1304                  msrpc3
1305                  libcli_lsa3
1306                  krb5samba''')
1307
1308 bld.SAMBA3_BINARY('smbcquotas',
1309                  source='utils/smbcquotas.c',
1310                  deps='''
1311                  talloc
1312                  popt_samba3
1313                  libsmb
1314                  msrpc3
1315                  libcli_lsa3''')
1316
1317 bld.SAMBA3_BINARY('eventlogadm',
1318                  source='utils/eventlogadm.c',
1319                  deps='''
1320                  talloc
1321                  param
1322                  LIBEVENTLOG''')
1323
1324 bld.SAMBA3_BINARY('sharesec',
1325                  source='utils/sharesec.c',
1326                  deps='''
1327                  talloc
1328                  popt_samba3''')
1329
1330 bld.SAMBA3_BINARY('pdbtest',
1331                  source='torture/pdbtest.c',
1332                  deps='''
1333                  talloc
1334                  pdb
1335                  popt_samba3
1336                  AUTH_COMMON
1337                  auth''',
1338                  install=False)
1339
1340 bld.SAMBA3_BINARY('vfstest',
1341                  source='''torture/cmd_vfs.c
1342                  torture/vfstest.c
1343                  torture/vfstest_chain.c''',
1344                  deps='''
1345                  vfs
1346                  popt_samba3
1347                  SMBREADLINE''',
1348                  install=False)
1349
1350 bld.SAMBA3_BINARY('log2pcap',
1351                  source='utils/log2pcaphex.c',
1352                  deps='''talloc popt''',
1353                  install=False)
1354
1355 bld.SAMBA3_BINARY('locktest2',
1356                  source='torture/locktest2.c',
1357                  deps='''
1358                  talloc
1359                  param
1360                  libsmb
1361                  LOCKING''',
1362                  install=False)
1363
1364 bld.SAMBA3_BINARY('debug2html',
1365                  source='''utils/debug2html.c utils/debugparse.c''',
1366                  deps='''talloc popt''',
1367                  install=False)
1368
1369 bld.SAMBA3_BINARY('smbfilter',
1370                  source='utils/smbfilter.c',
1371                  deps='''
1372                  talloc
1373                  param
1374                  LIBNMB''',
1375                  install=False)
1376
1377 bld.SAMBA3_BINARY('versiontest',
1378                  source='lib/version_test.c',
1379                  deps='''
1380                  SAMBA_VERSION
1381                  param''',
1382                  install=False)
1383
1384 bld.SAMBA3_BINARY('ntlm_auth',
1385                  source='''utils/ntlm_auth.c utils/ntlm_auth_diagnostics.c''',
1386                  deps='''
1387                  talloc
1388                  krb5samba
1389                  iniparser
1390                  libsmb
1391                  popt_samba3
1392                  LIBNTLMSSP gse gensec''')
1393
1394 bld.SAMBA3_BINARY('timelimit',
1395                  source='script/tests/timelimit.c',
1396                  install=False)
1397
1398 bld.SAMBA3_BINARY('rpc_open_tcp',
1399                  source='torture/rpc_open_tcp.c',
1400                  deps='''
1401                  talloc
1402                  msrpc3''',
1403                  install=False)
1404
1405 bld.SAMBA3_BINARY('dbwrap_tool',
1406                  source='utils/dbwrap_tool.c',
1407                  deps='''
1408                  talloc
1409                  popt_samba3''')
1410
1411 bld.SAMBA3_BINARY('dbwrap_torture',
1412                  source='utils/dbwrap_torture.c',
1413                  deps='''
1414                  talloc
1415                  popt_samba3''',
1416                  install=False)
1417
1418 bld.SAMBA3_BINARY('split_tokens',
1419                  source='utils/split_tokens.c',
1420                  deps='''
1421                  talloc
1422                  popt_samba3''',
1423                  install=False)
1424
1425 bld.SAMBA3_BINARY('vlp',
1426                  source='printing/tests/vlp.c',
1427                  deps='''
1428                  talloc
1429                  param''',
1430                  install=False)
1431
1432 bld.SAMBA3_PYTHON('pysmbd',
1433                   source='smbd/pysmbd.c',
1434                   deps='smbd_base pyrpc_util',
1435                   realname='samba/samba3/smbd.so'
1436                   )
1437
1438 bld.SAMBA3_PYTHON('pylibsmb',
1439                   source='libsmb/pylibsmb.c',
1440                   deps='smbclient samba-credentials',
1441                   realname='samba/samba3/libsmb_samba_internal.so'
1442                   )
1443
1444 bld.SAMBA3_BINARY('samba-regedit',
1445                   source="""utils/regedit.c utils/regedit_samba3.c
1446                             utils/regedit_wrap.c utils/regedit_treeview.c
1447                             utils/regedit_valuelist.c utils/regedit_dialog.c
1448                             utils/regedit_hexedit.c""",
1449                   deps='ncurses menu panel form registry param popt_samba3 smbregistry',
1450                   enabled=bld.env.build_regedit)
1451
1452 ########################## INCLUDES #################################
1453
1454 bld.RECURSE('auth')
1455 bld.RECURSE('libgpo/gpext')
1456 bld.RECURSE('lib/pthreadpool')
1457 bld.RECURSE('lib/asys')
1458 bld.RECURSE('lib/poll_funcs')
1459 bld.RECURSE('lib/unix_msg')
1460 bld.RECURSE('librpc')
1461 bld.RECURSE('librpc/idl')
1462 bld.RECURSE('libsmb')
1463 bld.RECURSE('modules')
1464 bld.RECURSE('pam_smbpass')
1465 bld.RECURSE('param')
1466 bld.RECURSE('passdb')
1467 bld.RECURSE('rpc_server')
1468 bld.RECURSE('script')
1469 bld.RECURSE('winbindd')
1470 bld.RECURSE('../examples/auth')
1471 bld.RECURSE('../examples/libsmbclient')
1472 bld.RECURSE('../examples/pdb')
1473 bld.RECURSE('../examples/VFS')
1474 bld.RECURSE('lib/netapi/tests')
1475 bld.RECURSE('lib/netapi/examples')
1476
1477 bld.ENFORCE_GROUP_ORDERING()
1478 bld.CHECK_PROJECT_RULES()
1479