build: freeze passwd_proto.h from "make proto"
[ab/samba.git/.git] / source3 / Makefile.in
1 #########################################################################
2 # Makefile.in for Samba - rewritten for autoconf support
3 # Copyright Andrew Tridgell 1992-1998
4 # Copyright (C) 2001 by Martin Pool <mbp@samba.org>
5 # Copyright Andrew Bartlett 2002
6 # Copyright (C) 2003 Jim McDonough <jmcd@us.ibm.com>
7 # Copyright (C) 2002-2003 Jelmer Vernooij <jelmer@samba.org>
8 # Copyright (C) 2006 Lars Mueller <lars@samba.org>
9 # Copyright (C) 2007 James Peach <jpeach@samba.org>
10 # Copyright (C) 2008 Michael Adam <obnox@samba.org>
11 ###########################################################################
12
13 prefix=@prefix@
14 exec_prefix=@exec_prefix@
15 sysconfdir=@sysconfdir@
16 localstatedir=@localstatedir@
17 datarootdir=@datarootdir@
18
19 selftest_prefix=@selftest_prefix@
20 smbtorture4_path=@smbtorture4_path@
21
22 LIBS=@LIBS@
23 CC=@CC@
24 SHLD=@SHLD@
25 LIB_PATH_VAR=@LIB_PATH_VAR@
26
27 ## Dynamic shared libraries build settings
28 DSO_EXPORTS_CMD=-Wl,--version-script,$(srcdir)/exports/`basename $@ | sed 's/@SHLIBEXT@$$/syms/'`
29 DSO_EXPORTS=@DSO_EXPORTS@
30 SONAME_VER=`grep \^$@ $(builddir)/library-versions | cut -d: -f2`
31 SHLD_DSO = $(SHLD) $(LDSHFLAGS) $(DSO_EXPORTS) -o $@
32
33 # The MODULE_EXPORTS variable contains the platform-specific linker flags
34 # needed to restrict the exports for VFS, IDMAP, RPC and PASSDB modules.
35 MODULE_EXPORTS=@MODULE_EXPORTS@
36
37 # Add $(DEVELOPER_CFLAGS) to $(CFLAGS) to enable extra compiler
38 # (GCC) warnings. This is done automtically for --enable-developer
39 # and --enable-krb5developer.
40 DEVELOPER_CFLAGS=@DEVELOPER_CFLAGS@
41 CFLAGS=@CFLAGS@
42 CPPFLAGS=-DHAVE_CONFIG_H @CPPFLAGS@
43
44 EXEEXT=@EXEEXT@
45 AR=@AR@
46 LDSHFLAGS=@LDSHFLAGS@ @RELRO_LDFLAGS@ @LDFLAGS@
47 LDFLAGS=@PIE_LDFLAGS@ @RELRO_LDFLAGS@ @LDFLAGS@
48
49 WINBIND_NSS_LDSHFLAGS=@WINBIND_NSS_LDSHFLAGS@ @LDFLAGS@
50 AWK=@AWK@
51 PICFLAG=@PICFLAG@
52 DYNEXP=@DYNEXP@
53 PERL=@PERL@
54
55 PIDL_ARGS=@PIDL_ARGS@
56
57 TERMLDFLAGS=@TERMLDFLAGS@
58 TERMLIBS=@TERMLIBS@
59 PRINT_LIBS=@PRINT_LIBS@
60 AUTH_LIBS=@AUTH_LIBS@
61 ACL_LIBS=@ACL_LIBS@
62 PASSDB_LIBS=@PASSDB_LIBS@
63 IDMAP_LIBS=@IDMAP_LIBS@
64 KRB5LIBS=@KRB5_LIBS@
65 LDAP_LIBS=@LDAP_LIBS@
66 NSCD_LIBS=@NSCD_LIBS@
67 UUID_LIBS=@UUID_LIBS@
68 WINBIND_LIBS=@WINBIND_LIBS@
69 DNSSD_LIBS=@DNSSD_LIBS@
70
71 INSTALLCMD=@INSTALL@
72 INSTALLLIBCMD_SH=@INSTALLLIBCMD_SH@
73 INSTALLLIBCMD_A=@INSTALLLIBCMD_A@
74 UNINSTALLLIBCMD_SH=@UNINSTALLLIBCMD_SH@
75 UNINSTALLLIBCMD_A=@UNINSTALLLIBCMD_A@
76
77 VPATH=@srcdir@
78 srcdir=@abs_srcdir@
79 builddir=@abs_builddir@
80 SHELL=/bin/sh
81 DESTDIR=/
82
83 # XXX: Perhaps this should be @SHELL@ instead -- apparently autoconf
84 # will search for a POSIX-compliant shell, and that might not be
85 # /bin/sh on some platforms.  I guess it's not a big problem -- mbp
86
87 # See the autoconf manual "Installation Directory Variables" for a
88 # discussion of the subtle use of these variables.
89
90 BASEDIR= @prefix@
91 BINDIR = @bindir@
92 # sbindir is mapped to bindir when compiling SAMBA in 2.0.x compatibility mode.
93 SBINDIR = @sbindir@
94 ROOTSBINDIR = @rootsbindir@
95 LIBDIR = @libdir@
96 INCLUDEDIR=@includedir@
97 PAMMODULESDIR = @pammodulesdir@
98 VFSLIBDIR = $(LIBDIR)/vfs
99 PDBLIBDIR = $(LIBDIR)/pdb
100 RPCLIBDIR = $(LIBDIR)/rpc
101 IDMAPLIBDIR = $(LIBDIR)/idmap
102 NSSINFOLIBDIR = $(LIBDIR)/nss_info
103 CHARSETLIBDIR = $(LIBDIR)/charset
104 AUTHLIBDIR = $(LIBDIR)/auth
105 CONFIGLIBDIR = $(LIBDIR)/config
106 GPEXTLIBDIR = $(LIBDIR)/gpext
107 CONFIGDIR = @configdir@
108 VARDIR = @localstatedir@
109 MANDIR = @mandir@
110 DATADIR = @datadir@
111
112 # The permissions to give the executables and other data
113 INSTALLPERMS_BIN = 0755
114 INSTALLPERMS_DATA = 0644
115
116 # set these to where to find various files
117 # These can be overridden by command line switches (see smbd(8))
118 # or in smb.conf (see smb.conf(5))
119 LOGFILEBASE = @logfilebase@
120 CONFIGFILE = $(CONFIGDIR)/smb.conf
121 LMHOSTSFILE = $(CONFIGDIR)/lmhosts
122 CTDBDIR = @ctdbdir@
123
124 # This is where smbpasswd et al go
125 PRIVATEDIR = @privatedir@
126
127 SMB_PASSWD_FILE = $(PRIVATEDIR)/smbpasswd
128 PRIVATE_DIR = $(PRIVATEDIR)
129
130 # This is where SWAT images and help files go
131 SWATDIR = @swatdir@
132
133 # the directory where lock files go
134 LOCKDIR = @lockdir@
135
136 # FHS directories; equal to LOCKDIR if not using --with-fhs
137 CACHEDIR = @cachedir@
138 STATEDIR = @statedir@
139
140 # Where to look for (and install) codepage databases.
141 CODEPAGEDIR = @codepagedir@
142
143 # the directory where pid files go
144 PIDDIR = @piddir@
145
146 LIBTALLOC_SHARED_TARGET=@LIBTALLOC_SHARED_TARGET@
147 LIBTALLOC_STATIC_TARGET=@LIBTALLOC_STATIC_TARGET@
148 LIBTALLOC=$(LIBTALLOC_STATIC_TARGET) @LIBTALLOC_SHARED@
149
150 LIBTDB_SHARED_TARGET=@LIBTDB_SHARED_TARGET@
151 LIBTDB_STATIC_TARGET=@LIBTDB_STATIC_TARGET@
152 LIBTDB=$(LIBTDB_STATIC_TARGET) @LIBTDB_SHARED@
153 LIBTDB_SYMS=$(srcdir)/exports/libtdb.syms
154 LIBTDB_HEADERS=$(srcdir)/@tdbdir@/include/tdb.h
155
156 LIBSMBCLIENT=bin/libsmbclient.a @LIBSMBCLIENT_SHARED@
157 LIBSMBSHAREMODES=bin/libsmbsharemodes.a @LIBSMBSHAREMODES_SHARED@
158 LIBADDNS=bin/libaddns.a @LIBADDNS_SHARED@
159 LIBWBCLIENT=@LIBWBCLIENT_SHARED@
160
161 LIBNETAPI_SHARED_TARGET=@LIBNETAPI_SHARED_TARGET@
162 LIBNETAPI_STATIC_TARGET=@LIBNETAPI_STATIC_TARGET@
163 LIBNETAPI=$(LIBNETAPI_STATIC_TARGET) @LIBNETAPI_SHARED@
164
165 FLAGS1 = $(CFLAGS) @FLAGS1@ @SAMBA_CPPFLAGS@ $(CPPFLAGS)
166 FLAGS2 =
167 FLAGS3 =
168 FLAGS4 = -I$(CTDBDIR)/include
169 FLAGS5 = $(FLAGS1) $(FLAGS2) $(FLAGS3) $(FLAGS4)
170 FLAGS  = $(ISA) $(FLAGS5) -I$(srcdir)/lib -D_SAMBA_BUILD_=3
171
172 PATH_FLAGS = -DSMB_PASSWD_FILE=\"$(SMB_PASSWD_FILE)\" \
173         -DPRIVATE_DIR=\"$(PRIVATE_DIR)\" \
174         -DCONFIGFILE=\"$(CONFIGFILE)\" \
175         -DSBINDIR=\"$(SBINDIR)\" \
176         -DBINDIR=\"$(BINDIR)\" \
177         -DLMHOSTSFILE=\"$(LMHOSTSFILE)\" \
178         -DSWATDIR=\"$(SWATDIR)\" \
179         -DLOCKDIR=\"$(LOCKDIR)\" \
180         -DPIDDIR=\"$(PIDDIR)\" \
181         -DLIBDIR=\"$(LIBDIR)\" \
182         -DLOGFILEBASE=\"$(LOGFILEBASE)\" \
183         -DSHLIBEXT=\"@SHLIBEXT@\" \
184         -DCTDBDIR=\"$(CTDBDIR)\" \
185         -DCONFIGDIR=\"$(CONFIGDIR)\" \
186         -DCODEPAGEDIR=\"$(CODEPAGEDIR)\" \
187         -DCACHEDIR=\"$(CACHEDIR)\" \
188         -DSTATEDIR=\"$(STATEDIR)\"
189
190 # Note that all executable programs now provide for an optional executable suffix.
191
192 SBIN_PROGS = bin/smbd@EXEEXT@ bin/nmbd@EXEEXT@ @SWAT_SBIN_TARGETS@ @EXTRA_SBIN_PROGS@
193
194 ROOT_SBIN_PROGS = @CIFSMOUNT_PROGS@ @CIFSSPNEGO_PROGS@
195
196 BIN_PROGS1 = bin/smbclient@EXEEXT@ bin/net@EXEEXT@ bin/smbspool@EXEEXT@ \
197         bin/testparm@EXEEXT@ bin/smbstatus@EXEEXT@ bin/smbget@EXEEXT@
198 BIN_PROGS2 = bin/smbcontrol@EXEEXT@ bin/smbtree@EXEEXT@ bin/tdbbackup@EXEEXT@ \
199         bin/nmblookup@EXEEXT@ bin/pdbedit@EXEEXT@ bin/tdbdump@EXEEXT@ \
200         bin/tdbtool@EXEEXT@
201 BIN_PROGS3 = bin/smbpasswd@EXEEXT@ bin/rpcclient@EXEEXT@ bin/smbcacls@EXEEXT@ \
202         bin/profiles@EXEEXT@ bin/ntlm_auth@EXEEXT@ \
203         bin/smbcquotas@EXEEXT@ bin/eventlogadm@EXEEXT@
204 BIN_PROGS4 = bin/ldbedit@EXEEXT@ bin/ldbsearch@EXEEXT@ bin/ldbadd@EXEEXT@ \
205         bin/ldbdel@EXEEXT@ bin/ldbmodify@EXEEXT@
206
207 TORTURE_PROGS = bin/smbtorture@EXEEXT@ bin/msgtest@EXEEXT@ \
208         bin/masktest@EXEEXT@ bin/locktest@EXEEXT@ \
209         bin/locktest2@EXEEXT@ bin/nsstest@EXEEXT@ bin/vfstest@EXEEXT@ \
210         bin/pdbtest@EXEEXT@ bin/talloctort@EXEEXT@ bin/replacetort@EXEEXT@ \
211         bin/tdbtorture@EXEEXT@ \
212         bin/smbconftort@EXEEXT@
213
214 BIN_PROGS = @EXTRA_BIN_PROGS@ \
215         $(BIN_PROGS1) $(BIN_PROGS2) $(BIN_PROGS3) $(BIN_PROGS4) 
216
217 EVERYTHING_PROGS = bin/debug2html@EXEEXT@ bin/smbfilter@EXEEXT@ \
218         bin/talloctort@EXEEXT@ bin/replacetort@EXEEXT@ \
219         bin/log2pcap@EXEEXT@ bin/sharesec@EXEEXT@ bin/ndrdump@EXEEXT@ \
220         bin/vlp@EXEEXT@ bin/smbiconv@EXEEXT@
221
222 SHLIBS = libtalloc libtdb @LIBWBCLIENT@ @LIBSMBCLIENT@ @LIBSMBSHAREMODES@ @LIBADDNS@ libnetapi
223
224 PAM_MODULES = @PAM_MODULES@
225
226 NSS_MODULES = @NSS_MODULES@
227
228 SCRIPTS = $(srcdir)/script/smbtar $(builddir)/script/findsmb
229
230 VFS_MODULES = @VFS_MODULES@
231 PDB_MODULES = @PDB_MODULES@
232 RPC_MODULES = @RPC_MODULES@
233 IDMAP_MODULES = @IDMAP_MODULES@
234 CHARSET_MODULES = @CHARSET_MODULES@
235 AUTH_MODULES = @AUTH_MODULES@
236 NSS_INFO_MODULES = @NSS_INFO_MODULES@
237 GPEXT_MODULES = @GPEXT_MODULES@
238 MODULES = $(VFS_MODULES) $(PDB_MODULES) $(RPC_MODULES) $(IDMAP_MODULES) \
239           $(CHARSET_MODULES) $(AUTH_MODULES) $(NSS_INFO_MODULES) \
240           $(GPEXT_MODULES)
241
242 ######################################################################
243 # object file lists
244 ######################################################################
245
246 LIBTDB_OBJ0 = @TDB_OBJS@
247 LIBTDB_OBJ = $(LIBTDB_OBJ0) $(LIBREPLACE_OBJ)
248
249 TDB_OBJ = lib/util_tdb.o \
250           lib/dbwrap.o lib/dbwrap_tdb.o \
251           lib/dbwrap_tdb2.o lib/dbwrap_ctdb.o \
252           lib/dbwrap_rbt.o @LIBTDB_STATIC@
253
254 SMBLDAP_OBJ = @SMBLDAP@ @SMBLDAPUTIL@
255
256 VERSION_OBJ = lib/version.o
257
258 WBCOMMON_OBJ = nsswitch/wb_common.o
259
260 AFS_OBJ = lib/afs.o
261
262 AFS_SETTOKEN_OBJ = lib/afs_settoken.o
263
264 SERVER_MUTEX_OBJ = lib/server_mutex.o
265
266 PASSCHANGE_OBJ = libsmb/passchange.o
267
268
269 LIBNDR_OBJ = librpc/ndr/ndr_basic.o \
270              librpc/ndr/ndr.o \
271              librpc/ndr/ndr_misc.o \
272              librpc/gen_ndr/ndr_misc.o \
273              librpc/gen_ndr/ndr_security.o \
274              librpc/ndr/ndr_sec_helper.o \
275              librpc/ndr/ndr_string.o \
276              librpc/ndr/sid.o \
277              librpc/ndr/uuid.o
278
279 RPCCLIENT_NDR_OBJ = rpc_client/ndr.o
280
281 LIBNDR_GEN_OBJ = librpc/gen_ndr/ndr_wkssvc.o \
282                  librpc/gen_ndr/ndr_lsa.o \
283                  librpc/gen_ndr/ndr_dfs.o \
284                  librpc/gen_ndr/ndr_echo.o \
285                  librpc/gen_ndr/ndr_winreg.o \
286                  librpc/gen_ndr/ndr_initshutdown.o \
287                  librpc/gen_ndr/ndr_srvsvc.o \
288                  librpc/gen_ndr/ndr_eventlog.o \
289                  librpc/gen_ndr/ndr_netlogon.o \
290                  librpc/gen_ndr/ndr_samr.o \
291                  librpc/gen_ndr/ndr_dssetup.o \
292                  librpc/gen_ndr/ndr_notify.o \
293                  librpc/gen_ndr/ndr_xattr.o \
294                  librpc/gen_ndr/ndr_ntsvcs.o
295
296 RPC_PARSE_OBJ0 = rpc_parse/parse_prs.o rpc_parse/parse_misc.o
297
298 # this includes only the low level parse code, not stuff
299 # that requires knowledge of security contexts
300 RPC_PARSE_OBJ1 = $(RPC_PARSE_OBJ0) rpc_parse/parse_sec.o
301
302 RPC_PARSE_OBJ2 = rpc_parse/parse_rpc.o \
303                  rpc_client/init_netlogon.o \
304                  rpc_client/init_lsa.o \
305                  rpc_client/init_srvsvc.o
306
307 LIBREPLACE_OBJ = @LIBREPLACE_OBJS@
308
309 SOCKET_WRAPPER_OBJ = @SOCKET_WRAPPER_OBJS@
310 NSS_WRAPPER_OBJ = @NSS_WRAPPER_OBJS@
311
312 TALLOC_OBJ = @TALLOC_OBJS@
313
314
315 LIBTALLOC_OBJ0 = $(TALLOC_OBJ)
316 LIBTALLOC_OBJ = $(LIBTALLOC_OBJ0) $(LIBREPLACE_OBJ)
317
318 LIBSAMBAUTIL_OBJ = @LIBTALLOC_STATIC@ \
319                 $(LIBREPLACE_OBJ) \
320                 $(SOCKET_WRAPPER_OBJ) \
321                 $(NSS_WRAPPER_OBJ)
322
323 LIB_WITHOUT_PROTO_OBJ = $(LIBSAMBAUTIL_OBJ) \
324         lib/messages.o librpc/gen_ndr/ndr_messaging.o lib/messages_local.o \
325         lib/messages_ctdbd.o lib/packet.o lib/ctdbd_conn.o lib/talloc_stack.o \
326         lib/interfaces.o lib/rbtree.o lib/memcache.o \
327         lib/util_transfer_file.o lib/async_req.o \
328         $(TDB_OBJ)
329
330 LIB_WITH_PROTO_OBJ = $(VERSION_OBJ) lib/charcnv.o lib/debug.o lib/fault.o \
331           lib/interface.o lib/md4.o \
332           lib/pidfile.o \
333           lib/signal.o lib/system.o lib/sendfile.o lib/recvfile.o lib/time.o \
334           lib/ufc.o lib/genrand.o lib/username.o \
335           lib/util_pw.o lib/access.o lib/smbrun.o \
336           lib/bitmap.o lib/crc32.o lib/dprintf.o \
337           lib/xfile.o lib/wins_srv.o $(UTIL_REG_OBJ) \
338           lib/util_str.o lib/clobber.o lib/util_sid.o lib/util_uuid.o \
339           lib/util_unistr.o lib/util_file.o lib/data_blob.o \
340           lib/util.o lib/util_sock.o lib/sock_exec.o lib/util_sec.o \
341           lib/substitute.o lib/fsusage.o lib/dbwrap_util.o \
342           lib/ms_fnmatch.o lib/select.o lib/errmap_unix.o \
343           lib/tallocmsg.o lib/dmallocmsg.o libsmb/smb_signing.o \
344           lib/md5.o lib/hmacmd5.o lib/arc4.o lib/iconv.o \
345           lib/pam_errors.o intl/lang_tdb.o lib/conn_tdb.o \
346           lib/adt_tree.o lib/gencache.o \
347           lib/module.o lib/events.o lib/ldap_escape.o @CHARSET_STATIC@ \
348           lib/secdesc.o lib/util_seaccess.o lib/secace.o lib/secacl.o \
349           libads/krb5_errs.o lib/system_smbd.o lib/audit.o $(LIBNDR_OBJ) \
350           lib/file_id.o
351
352 LIB_OBJ = $(LIB_WITHOUT_PROTO_OBJ) $(LIB_WITH_PROTO_OBJ)
353
354 LIB_DUMMY_OBJ = lib/dummysmbd.o lib/dummyroot.o
355 LIB_NONSMBD_OBJ = $(LIB_OBJ) $(LIB_DUMMY_OBJ)
356
357 READLINE_OBJ = lib/readline.o
358
359 # Also depends on  $(SECRETS_OBJ) $(LIBSAMBA_OBJ)
360 # Be sure to include them into your application
361 POPT_LIB_OBJ = lib/popt_common.o
362
363 PARAM_WITHOUT_REG_OBJ = dynconfig.o param/loadparm.o param/params.o param/util.o lib/sharesec.o lib/ldap_debug_handler.o
364 PARAM_REG_ADD_OBJ = $(REG_SMBCONF_OBJ) $(LIBSMBCONF_OBJ) $(PRIVILEGES_BASIC_OBJ)
365 PARAM_OBJ = $(PARAM_WITHOUT_REG_OBJ) $(PARAM_REG_ADD_OBJ)
366
367 KRBCLIENT_OBJ = libads/kerberos.o libads/ads_status.o
368
369 LIBADDNS_OBJ0 = libaddns/dnsrecord.o libaddns/dnsutils.o  libaddns/dnssock.o \
370                libaddns/dnsgss.o libaddns/dnsmarshall.o
371 LIBADDNS_OBJ = $(LIBADDNS_OBJ0) @LIBTALLOC_STATIC@
372
373 LIBWBCLIENT_OBJ0 = nsswitch/libwbclient/wbclient.o \
374                   nsswitch/libwbclient/wbc_util.o \
375                   nsswitch/libwbclient/wbc_pwd.o \
376                   nsswitch/libwbclient/wbc_idmap.o \
377                   nsswitch/libwbclient/wbc_sid.o \
378                   nsswitch/libwbclient/wbc_pam.o
379 LIBWBCLIENT_OBJ = $(LIBWBCLIENT_OBJ0) \
380                   $(WBCOMMON_OBJ) \
381                   @LIBTALLOC_STATIC@ $(LIBREPLACE_OBJ)
382
383 GPEXT_OBJ = libgpo/gpext/gpext.o @GPEXT_STATIC@
384
385 LIBGPO_OBJ0 = libgpo/gpo_ldap.o libgpo/gpo_ini.o libgpo/gpo_util.o \
386               libgpo/gpo_fetch.o libgpo/gpo_filesync.o libgpo/gpo_sec.o \
387               libgpo/gpo_reg.o \
388               $(GPEXT_OBJ)
389 LIBGPO_OBJ = $(LIBGPO_OBJ0)
390
391 LIBADS_OBJ = libads/ldap.o libads/ldap_printer.o \
392              libads/sasl.o libads/sasl_wrapping.o \
393              libads/krb5_setpw.o libads/ldap_user.o \
394              libads/ads_struct.o libads/kerberos_keytab.o \
395              libads/disp_sec.o libads/ads_utils.o libads/ldap_utils.o \
396              libads/ldap_schema.o libads/util.o libads/ndr.o
397
398 LIBADS_SERVER_OBJ = libads/kerberos_verify.o libads/authdata.o \
399                     librpc/ndr/ndr_krb5pac.o \
400                     librpc/gen_ndr/ndr_krb5pac.o
401
402 SECRETS_OBJ = passdb/secrets.o passdb/machine_sid.o
403
404 LIBNBT_OBJ = libcli/nbt/nbtname.o \
405              librpc/gen_ndr/ndr_nbt.o \
406              librpc/gen_ndr/ndr_svcctl.o
407
408 LIBNMB_OBJ = libsmb/unexpected.o libsmb/namecache.o libsmb/nmblib.o \
409              libsmb/namequery.o libsmb/conncache.o libads/dns.o
410
411 NTERR_OBJ = libsmb/nterr.o
412 DOSERR_OBJ = libsmb/doserr.o
413 ERRORMAP_OBJ = libsmb/errormap.o
414 DCE_RPC_ERR_OBJ = libsmb/dcerpc_err.o
415
416 LIBSMB_ERR_OBJ0 = $(NTERR_OBJ) $(DOSERR_OBJ) $(ERRORMAP_OBJ) $(DCE_RPC_ERR_OBJ) \
417                   libsmb/smbdes.o libsmb/smbencrypt.o libsmb/ntlmssp_parse.o
418
419 LIBSMB_ERR_OBJ = $(LIBSMB_ERR_OBJ0) \
420                  $(RPC_PARSE_OBJ1) \
421                  $(SECRETS_OBJ)
422
423 LIBSMB_OBJ0 = \
424                libsmb/ntlm_check.o \
425                libsmb/ntlmssp.o \
426                libsmb/ntlmssp_sign.o
427
428 LIBSAMBA_OBJ = $(LIBSMB_OBJ0) \
429                $(LIBSMB_ERR_OBJ)
430
431 CLDAP_OBJ = libads/cldap.o
432
433 LIBSMB_OBJ = libsmb/clientgen.o libsmb/cliconnect.o libsmb/clifile.o \
434              libsmb/clikrb5.o libsmb/clispnego.o libsmb/asn1.o \
435              libsmb/clirap.o libsmb/clierror.o libsmb/climessage.o \
436              libsmb/clireadwrite.o libsmb/clilist.o libsmb/cliprint.o \
437              libsmb/clitrans.o libsmb/clisecdesc.o libsmb/clidgram.o \
438              libsmb/clistr.o libsmb/cliquota.o libsmb/clifsinfo.o libsmb/clidfs.o \
439              libsmb/smberr.o libsmb/credentials.o libsmb/pwd_cache.o \
440              libsmb/clioplock.o libsmb/clirap2.o \
441              libsmb/smb_seal.o libsmb/async_smb.o \
442              $(LIBSAMBA_OBJ) \
443              $(LIBNMB_OBJ) \
444              $(LIBNBT_OBJ) \
445              $(CLDAP_OBJ)
446
447 RPC_CLIENT_OBJ1 = rpc_client/cli_netlogon.o
448
449 LIBMSRPC_OBJ = rpc_client/cli_lsarpc.o rpc_client/cli_samr.o \
450                $(RPC_CLIENT_OBJ1) rpc_client/cli_reg.o $(RPC_CLIENT_OBJ) \
451                rpc_client/cli_spoolss.o rpc_client/cli_spoolss_notify.o  \
452                rpc_client/cli_svcctl.o \
453                rpc_client/init_samr.o \
454                    librpc/rpc/dcerpc.o \
455                    librpc/rpc/binding.o
456
457 LIBMSRPC_GEN_OBJ = librpc/gen_ndr/cli_lsa.o \
458                    librpc/gen_ndr/cli_dfs.o \
459                    librpc/gen_ndr/cli_echo.o \
460                    librpc/gen_ndr/cli_srvsvc.o \
461                    librpc/gen_ndr/cli_svcctl.o \
462                    librpc/gen_ndr/cli_winreg.o \
463                    librpc/gen_ndr/cli_initshutdown.o \
464                    librpc/gen_ndr/cli_eventlog.o \
465                    librpc/gen_ndr/cli_wkssvc.o \
466                    librpc/gen_ndr/cli_netlogon.o \
467                    librpc/gen_ndr/cli_samr.o \
468                    librpc/gen_ndr/cli_dssetup.o \
469                    librpc/gen_ndr/cli_ntsvcs.o \
470                    $(LIBNDR_GEN_OBJ) \
471                    $(RPCCLIENT_NDR_OBJ)
472
473 #
474 # registry-related objects
475 #
476 UTIL_REG_OBJ = lib/util_reg.o
477 UTIL_REG_API_OBJ = lib/util_reg_api.o
478
479 REG_INIT_BASIC_OBJ = registry/reg_init_basic.o
480 REG_INIT_SMBCONF_OBJ = registry/reg_init_smbconf.o
481 REG_INIT_FULL_OBJ = registry/reg_init_full.o
482
483 REGFIO_OBJ = registry/regfio.o
484
485 REGOBJS_OBJ = registry/reg_objects.o
486
487 REG_BACKENDS_BASE_OBJ = registry/reg_backend_db.o
488
489 REG_BACKENDS_SMBCONF_OBJ = registry/reg_backend_smbconf.o
490
491 REG_BACKENDS_EXTRA_OBJ = registry/reg_backend_printing.o \
492                          registry/reg_backend_shares.o \
493                          registry/reg_backend_netlogon_params.o \
494                          registry/reg_backend_prod_options.o \
495                          registry/reg_backend_tcpip_params.o \
496                          registry/reg_backend_hkpt_params.o \
497                          registry/reg_backend_current_version.o \
498                          registry/reg_backend_perflib.o
499
500 REG_BASE_OBJ = registry/reg_api.o \
501                registry/reg_dispatcher.o \
502                registry/reg_cachehook.o \
503                $(REGFIO_OBJ) \
504                $(REGOBJS_OBJ) \
505                registry/reg_util.o \
506                $(UTIL_REG_API_OBJ) \
507                lib/util_nttoken.o \
508                $(REG_BACKENDS_BASE_OBJ) \
509                $(REG_INIT_BASIC_OBJ)
510
511 REG_SMBCONF_OBJ = $(REG_BASE_OBJ) \
512                   $(REG_BACKENDS_SMBCONF_OBJ) \
513                   $(REG_INIT_SMBCONF_OBJ)
514
515 REG_FULL_OBJ = $(REG_SMBCONF_OBJ) \
516                $(REG_BACKENDS_EXTRA_OBJ) \
517                $(REG_INIT_FULL_OBJ) \
518                registry/reg_eventlog.o \
519                registry/reg_perfcount.o \
520                registry/reg_util_legacy.o
521
522
523 RPC_LSA_OBJ = rpc_server/srv_lsa_nt.o librpc/gen_ndr/srv_lsa.o
524
525 RPC_NETLOG_OBJ = rpc_server/srv_netlog_nt.o \
526                  librpc/gen_ndr/srv_netlogon.o
527
528 RPC_SAMR_OBJ = rpc_server/srv_samr_nt.o \
529                rpc_server/srv_samr_util.o \
530                librpc/gen_ndr/srv_samr.o
531
532 RPC_INITSHUTDOWN_OBJ =  librpc/gen_ndr/srv_initshutdown.o rpc_server/srv_initshutdown_nt.o
533
534 RPC_REG_OBJ =  rpc_server/srv_winreg_nt.o \
535                librpc/gen_ndr/srv_winreg.o
536
537 RPC_DSSETUP_OBJ =  rpc_server/srv_dssetup_nt.o librpc/gen_ndr/srv_dssetup.o
538
539 RPC_SVC_OBJ = rpc_server/srv_srvsvc_nt.o \
540               librpc/gen_ndr/srv_srvsvc.o
541
542 RPC_WKS_OBJ =  librpc/gen_ndr/srv_wkssvc.o rpc_server/srv_wkssvc_nt.o
543
544 RPC_SVCCTL_OBJ =  rpc_server/srv_svcctl.o rpc_server/srv_svcctl_nt.o \
545                   librpc/gen_ndr/srv_svcctl.o \
546                   services/svc_spoolss.o services/svc_rcinit.o services/services_db.o \
547                   services/svc_netlogon.o services/svc_winreg.o \
548                   services/svc_wins.o
549
550 RPC_NTSVCS_OBJ = rpc_server/srv_ntsvcs.o rpc_server/srv_ntsvcs_nt.o \
551                  librpc/gen_ndr/srv_ntsvcs.o
552
553 RPC_DFS_OBJ =  librpc/gen_ndr/srv_dfs.o rpc_server/srv_dfs_nt.o
554
555 RPC_SPOOLSS_OBJ = rpc_server/srv_spoolss.o rpc_server/srv_spoolss_nt.o
556
557 RPC_EVENTLOG_OBJ = rpc_server/srv_eventlog.o rpc_server/srv_eventlog_nt.o \
558                    rpc_server/srv_eventlog_lib.o librpc/gen_ndr/srv_eventlog.o
559
560 RPC_PIPE_OBJ = rpc_server/srv_pipe_hnd.o \
561                rpc_server/srv_pipe.o rpc_server/srv_lsa_hnd.o
562
563 RPC_ECHO_OBJ = rpc_server/srv_echo_nt.o librpc/gen_ndr/srv_echo.o
564
565 RPC_SERVER_OBJ = @RPC_STATIC@ $(RPC_PIPE_OBJ)
566
567 RPC_PARSE_OBJ = $(RPC_PARSE_OBJ2) \
568                 rpc_parse/parse_spoolss.o \
569                 rpc_parse/parse_eventlog.o rpc_parse/parse_buffer.o \
570                 rpc_parse/parse_ntsvcs.o rpc_parse/parse_svcctl.o
571
572 RPC_CLIENT_OBJ = rpc_client/cli_pipe.o
573
574 LOCKING_OBJ = locking/locking.o locking/brlock.o locking/posix.o
575
576 PRIVILEGES_BASIC_OBJ = lib/privileges_basic.o
577
578 PRIVILEGES_OBJ = lib/privileges.o
579
580 PASSDB_GET_SET_OBJ = passdb/pdb_get_set.o
581
582 PASSDB_OBJ = $(PASSDB_GET_SET_OBJ) passdb/passdb.o passdb/pdb_interface.o \
583                 passdb/util_wellknown.o passdb/util_builtin.o passdb/pdb_compat.o \
584                 passdb/util_unixsids.o passdb/lookup_sid.o \
585                 passdb/login_cache.o @PDB_STATIC@ \
586                 lib/account_pol.o $(PRIVILEGES_OBJ) \
587                 lib/util_nscd.o lib/winbind_util.o
588
589 DEVEL_HELP_WEIRD_OBJ = modules/weird.o
590 CP850_OBJ = modules/CP850.o
591 CP437_OBJ = modules/CP437.o
592 CHARSET_MACOSXFS_OBJ = modules/charset_macosxfs.o
593
594 GROUPDB_OBJ = groupdb/mapping.o groupdb/mapping_tdb.o groupdb/mapping_ldb.o
595
596 PROFILE_OBJ = profile/profile.o
597 PROFILES_OBJ = utils/profiles.o \
598                $(LIBSAMBA_OBJ) \
599                $(PARAM_OBJ) \
600                $(LIB_OBJ) $(LIB_DUMMY_OBJ) \
601                $(POPT_LIB_OBJ)
602
603 OPLOCK_OBJ = smbd/oplock.o smbd/oplock_irix.o smbd/oplock_linux.o
604
605 NOTIFY_OBJ = smbd/notify.o smbd/notify_inotify.o smbd/notify_internal.o
606
607 VFS_DEFAULT_OBJ = modules/vfs_default.o
608 VFS_AUDIT_OBJ = modules/vfs_audit.o
609 VFS_EXTD_AUDIT_OBJ = modules/vfs_extd_audit.o
610 VFS_FULL_AUDIT_OBJ = modules/vfs_full_audit.o
611 VFS_FAKE_PERMS_OBJ = modules/vfs_fake_perms.o
612 VFS_RECYCLE_OBJ = modules/vfs_recycle.o
613 VFS_NETATALK_OBJ = modules/vfs_netatalk.o
614 VFS_DEFAULT_QUOTA_OBJ = modules/vfs_default_quota.o
615 VFS_READONLY_OBJ = modules/vfs_readonly.o modules/getdate.o
616 VFS_CAP_OBJ = modules/vfs_cap.o
617 VFS_EXPAND_MSDFS_OBJ = modules/vfs_expand_msdfs.o
618 VFS_SHADOW_COPY_OBJ = modules/vfs_shadow_copy.o
619 VFS_SHADOW_COPY2_OBJ = modules/vfs_shadow_copy2.o
620 VFS_AFSACL_OBJ = modules/vfs_afsacl.o
621 VFS_XATTR_TDB_OBJ = modules/vfs_xattr_tdb.o
622 VFS_POSIXACL_OBJ = modules/vfs_posixacl.o
623 VFS_AIXACL_OBJ = modules/vfs_aixacl.o modules/vfs_aixacl_util.o
624 VFS_AIXACL2_OBJ = modules/vfs_aixacl2.o modules/vfs_aixacl_util.o modules/nfs4_acls.o
625 VFS_SOLARISACL_OBJ = modules/vfs_solarisacl.o
626 VFS_ZFSACL_OBJ = modules/vfs_zfsacl.o modules/nfs4_acls.o
627 VFS_HPUXACL_OBJ = modules/vfs_hpuxacl.o
628 VFS_IRIXACL_OBJ = modules/vfs_irixacl.o
629 VFS_TRU64ACL_OBJ = modules/vfs_tru64acl.o
630 VFS_CATIA_OBJ = modules/vfs_catia.o
631 VFS_STREAMS_XATTR_OBJ = modules/vfs_streams_xattr.o
632 VFS_STREAMS_DEPOT_OBJ = modules/vfs_streams_depot.o
633 VFS_CACHEPRIME_OBJ = modules/vfs_cacheprime.o
634 VFS_PREALLOC_OBJ = modules/vfs_prealloc.o
635 VFS_COMMIT_OBJ = modules/vfs_commit.o
636 VFS_GPFS_OBJ = modules/vfs_gpfs.o modules/gpfs.o modules/nfs4_acls.o
637 VFS_NOTIFY_FAM_OBJ = modules/vfs_notify_fam.o
638 VFS_READAHEAD_OBJ = modules/vfs_readahead.o
639 VFS_TSMSM_OBJ = modules/vfs_tsmsm.o
640 VFS_FILEID_OBJ = modules/vfs_fileid.o
641 VFS_AIO_FORK_OBJ = modules/vfs_aio_fork.o
642 VFS_SYNCOPS_OBJ = modules/vfs_syncops.o
643
644 PLAINTEXT_AUTH_OBJ = auth/pampass.o auth/pass_check.o
645
646 SLCACHE_OBJ = libsmb/samlogon_cache.o
647
648 DCUTIL_OBJ  = libsmb/namequery_dc.o libsmb/trustdom_cache.o libsmb/trusts_util.o libsmb/dsgetdcname.o
649
650 AUTH_BUILTIN_OBJ = auth/auth_builtin.o
651 AUTH_DOMAIN_OBJ = auth/auth_domain.o
652 AUTH_SAM_OBJ = auth/auth_sam.o
653 AUTH_SERVER_OBJ = auth/auth_server.o
654 AUTH_UNIX_OBJ = auth/auth_unix.o
655 AUTH_WINBIND_OBJ = auth/auth_winbind.o
656 AUTH_SCRIPT_OBJ = auth/auth_script.o
657
658 AUTH_OBJ = auth/auth.o @AUTH_STATIC@ auth/auth_util.o auth/token_util.o \
659            auth/auth_compat.o auth/auth_ntlmssp.o \
660            $(PLAINTEXT_AUTH_OBJ) $(SLCACHE_OBJ) $(DCUTIL_OBJ)
661
662 MANGLE_OBJ = smbd/mangle.o smbd/mangle_hash.o smbd/mangle_hash2.o
663
664 SMBD_OBJ_MAIN = smbd/server.o
665
666 BUILDOPT_OBJ = smbd/build_options.o
667
668 SMBD_OBJ_SRV = smbd/files.o smbd/chgpasswd.o smbd/connection.o \
669                smbd/utmp.o smbd/session.o smbd/map_username.o \
670                smbd/dfree.o smbd/dir.o smbd/password.o smbd/conn.o \
671                smbd/share_access.o smbd/fileio.o \
672                smbd/ipc.o smbd/lanman.o smbd/negprot.o \
673                smbd/message.o smbd/nttrans.o smbd/pipes.o \
674                smbd/reply.o smbd/sesssetup.o smbd/trans2.o smbd/uid.o \
675                smbd/dosmode.o smbd/filename.o smbd/open.o smbd/close.o \
676                smbd/blocking.o smbd/sec_ctx.o smbd/srvstr.o \
677                smbd/vfs.o smbd/statcache.o smbd/seal.o \
678                smbd/posix_acls.o lib/sysacls.o $(SERVER_MUTEX_OBJ) \
679                smbd/process.o smbd/service.o smbd/error.o \
680                printing/printfsp.o lib/sysquotas.o lib/sysquotas_linux.o \
681                lib/sysquotas_xfs.o lib/sysquotas_4A.o \
682                smbd/change_trust_pw.o smbd/fake_file.o \
683                smbd/quotas.o smbd/ntquotas.o $(AFS_OBJ) smbd/msdfs.o \
684                $(AFS_SETTOKEN_OBJ) smbd/aio.o smbd/statvfs.o \
685                smbd/dmapi.o \
686                smbd/file_access.o \
687                smbd/dnsregister.o \
688                $(MANGLE_OBJ) @VFS_STATIC@
689
690 SMBD_OBJ_BASE = $(PARAM_WITHOUT_REG_OBJ) $(SMBD_OBJ_SRV) $(LIBSMB_OBJ) \
691                 $(RPC_SERVER_OBJ) $(RPC_PARSE_OBJ) \
692                 $(LOCKING_OBJ) $(PASSDB_OBJ) $(PRINTING_OBJ) $(PROFILE_OBJ) \
693                 $(LIB_OBJ) $(PRINTBACKEND_OBJ) $(OPLOCK_OBJ) \
694                 $(NOTIFY_OBJ) $(GROUPDB_OBJ) $(AUTH_OBJ) \
695                 $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) \
696                 $(LIBADS_OBJ) $(KRBCLIENT_OBJ) $(LIBADS_SERVER_OBJ) \
697                 $(REG_FULL_OBJ) $(POPT_LIB_OBJ) $(BUILDOPT_OBJ) \
698                 $(SMBLDAP_OBJ) $(LDB_OBJ) $(LIBNET_OBJ) @LIBWBCLIENT_STATIC@ \
699                 $(LIBSMBCONF_OBJ) \
700                 $(PRIVILEGES_BASIC_OBJ)
701
702 PRINTING_OBJ = printing/pcap.o printing/print_svid.o printing/print_aix.o \
703                printing/print_cups.o printing/print_generic.o \
704                printing/lpq_parse.o printing/load.o \
705                printing/print_iprint.o
706
707 PRINTBASE_OBJ = printing/notify.o printing/printing_db.o
708 PRINTBACKEND_OBJ = printing/printing.o printing/nt_printing.o $(PRINTBASE_OBJ)
709
710 SMBD_OBJ = $(SMBD_OBJ_BASE) $(SMBD_OBJ_MAIN)
711
712 NMBD_OBJ1 = nmbd/asyncdns.o nmbd/nmbd.o nmbd/nmbd_become_dmb.o \
713             nmbd/nmbd_become_lmb.o nmbd/nmbd_browserdb.o \
714             nmbd/nmbd_browsesync.o nmbd/nmbd_elections.o \
715             nmbd/nmbd_incomingdgrams.o nmbd/nmbd_incomingrequests.o \
716             nmbd/nmbd_lmhosts.o nmbd/nmbd_logonnames.o nmbd/nmbd_mynames.o \
717             nmbd/nmbd_namelistdb.o nmbd/nmbd_namequery.o \
718             nmbd/nmbd_nameregister.o nmbd/nmbd_namerelease.o \
719             nmbd/nmbd_nodestatus.o nmbd/nmbd_packets.o \
720             nmbd/nmbd_processlogon.o nmbd/nmbd_responserecordsdb.o \
721             nmbd/nmbd_sendannounce.o nmbd/nmbd_serverlistdb.o \
722             nmbd/nmbd_subnetdb.o nmbd/nmbd_winsproxy.o nmbd/nmbd_winsserver.o \
723             nmbd/nmbd_workgroupdb.o nmbd/nmbd_synclists.o smbd/connection.o
724
725 NMBD_OBJ = $(NMBD_OBJ1) $(PARAM_OBJ) $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
726            $(PROFILE_OBJ) $(LIB_NONSMBD_OBJ) $(POPT_LIB_OBJ) \
727            librpc/gen_ndr/ndr_samr.o librpc/gen_ndr/ndr_lsa.o
728
729 SWAT_OBJ1 = web/cgi.o web/diagnose.o web/startstop.o web/statuspage.o \
730            web/swat.o web/neg_lang.o
731
732 SWAT_OBJ = $(SWAT_OBJ1) $(PARAM_OBJ) $(PRINTING_OBJ) $(LIBSMB_OBJ) \
733            $(LOCKING_OBJ) $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ $(KRBCLIENT_OBJ) \
734            $(LIB_NONSMBD_OBJ) $(GROUPDB_OBJ) $(PLAINTEXT_AUTH_OBJ) \
735            $(POPT_LIB_OBJ) $(SMBLDAP_OBJ) $(RPC_PARSE_OBJ) $(LIBMSRPC_GEN_OBJ) $(LIBMSRPC_OBJ) \
736            $(PASSCHANGE_OBJ) $(LDB_OBJ)
737
738 STATUS_OBJ = utils/status.o utils/status_profile.o \
739              $(LOCKING_OBJ) $(PARAM_OBJ) \
740              $(PROFILE_OBJ) $(LIB_NONSMBD_OBJ) $(POPT_LIB_OBJ) \
741              $(LIBSAMBA_OBJ)
742
743 SMBCONTROL_OBJ = utils/smbcontrol.o $(LOCKING_OBJ) $(PARAM_OBJ) \
744         $(PROFILE_OBJ) $(LIB_NONSMBD_OBJ) $(POPT_LIB_OBJ) \
745         $(LIBSAMBA_OBJ) \
746         $(PRINTBASE_OBJ)
747
748 SMBTREE_OBJ = utils/smbtree.o $(PARAM_OBJ) \
749              $(PROFILE_OBJ) $(LIB_NONSMBD_OBJ) $(LIBSMB_OBJ) \
750              $(KRBCLIENT_OBJ) $(POPT_LIB_OBJ) \
751              rpc_client/cli_pipe.o $(RPC_PARSE_OBJ2) \
752              $(RPC_CLIENT_OBJ1) \
753              $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ $(SMBLDAP_OBJ) $(LDB_OBJ) $(GROUPDB_OBJ) \
754              $(LIBMSRPC_GEN_OBJ)
755
756 TESTPARM_OBJ = utils/testparm.o \
757                $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) $(POPT_LIB_OBJ) \
758                $(LIBSAMBA_OBJ)
759
760 PASSWD_UTIL_OBJ = utils/passwd_util.o
761
762 SMBPASSWD_OBJ = utils/smbpasswd.o $(PASSWD_UTIL_OBJ) $(PASSCHANGE_OBJ) \
763                 $(PARAM_OBJ) $(LIBSMB_OBJ) $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ \
764                 $(GROUPDB_OBJ) $(LIB_NONSMBD_OBJ) $(KRBCLIENT_OBJ) \
765                 $(POPT_LIB_OBJ) $(SMBLDAP_OBJ) $(RPC_PARSE_OBJ) \
766                 $(LIBMSRPC_GEN_OBJ) $(LIBMSRPC_OBJ) $(LDB_OBJ)
767
768 PDBEDIT_OBJ = utils/pdbedit.o $(PASSWD_UTIL_OBJ) $(PARAM_OBJ) $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ \
769                 $(LIBSAMBA_OBJ) \
770                 $(LIB_NONSMBD_OBJ) $(GROUPDB_OBJ) \
771                 $(POPT_LIB_OBJ) $(SMBLDAP_OBJ) libsmb/asn1.o \
772                 $(LDB_OBJ)
773
774 SMBGET_OBJ = utils/smbget.o $(POPT_LIB_OBJ) $(LIBSMBCLIENT_OBJ0) @LIBWBCLIENT_STATIC@
775
776 DISPLAY_SEC_OBJ= lib/display_sec.o
777
778 RPCCLIENT_OBJ1 = rpcclient/rpcclient.o rpcclient/cmd_lsarpc.o \
779                  rpcclient/cmd_samr.o rpcclient/cmd_spoolss.o \
780                  rpcclient/cmd_netlogon.o rpcclient/cmd_srvsvc.o \
781                  rpcclient/cmd_dfs.o \
782                  rpcclient/cmd_dssetup.o rpcclient/cmd_echo.o \
783                  rpcclient/cmd_shutdown.o rpcclient/cmd_test.o \
784                  rpcclient/cmd_wkssvc.o rpcclient/cmd_ntsvcs.o \
785                  $(DISPLAY_SEC_OBJ)
786
787 RPCCLIENT_OBJ = $(RPCCLIENT_OBJ1) \
788              $(PARAM_OBJ) $(LIBSMB_OBJ) $(LIB_NONSMBD_OBJ) \
789              $(RPC_PARSE_OBJ) $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ $(LIBMSRPC_GEN_OBJ) $(LIBMSRPC_OBJ) \
790              $(READLINE_OBJ) $(GROUPDB_OBJ) $(KRBCLIENT_OBJ) \
791              $(LIBADS_OBJ) $(POPT_LIB_OBJ) \
792              $(SMBLDAP_OBJ) $(DCUTIL_OBJ) $(LDB_OBJ) 
793
794 PAM_WINBIND_OBJ = nsswitch/pam_winbind.o $(WBCOMMON_OBJ) \
795                   $(LIBREPLACE_OBJ) @BUILD_INIPARSER@
796
797 LIBSMBCLIENT_OBJ0 = \
798                     libsmb/libsmb_cache.o \
799                     libsmb/libsmb_compat.o \
800                     libsmb/libsmb_context.o \
801                     libsmb/libsmb_dir.o \
802                     libsmb/libsmb_file.o \
803                     libsmb/libsmb_misc.o \
804                     libsmb/libsmb_path.o \
805                     libsmb/libsmb_printjob.o \
806                     libsmb/libsmb_server.o \
807                     libsmb/libsmb_stat.o \
808                     libsmb/libsmb_xattr.o \
809                     libsmb/libsmb_setget.o \
810                     $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
811                     $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
812                     $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) $(RPC_PARSE_OBJ) \
813                     $(PASSDB_OBJ) $(SMBLDAP_OBJ) $(GROUPDB_OBJ) $(LDB_OBJ)
814
815 LIBSMBCLIENT_OBJ = $(LIBSMBCLIENT_OBJ0) @LIBWBCLIENT_STATIC@
816
817 LIBSMBSHAREMODES_OBJ = libsmb/smb_share_modes.o @LIBTDB_STATIC@
818
819 # This shared library is intended for linking with unit test programs
820 # to test Samba internals.  It's called libbigballofmud.so to
821 # discourage casual usage.
822
823 LIBBIGBALLOFMUD_MAJOR = 0
824
825 LIBBIGBALLOFMUD_OBJ = $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
826         $(LIBSMB_OBJ) $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) $(RPC_PARSE_OBJ) $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ \
827         $(GROUPDB_OBJ) $(KRBCLIENT_OBJ) $(SMBLDAP_OBJ) $(LDB_OBJ)
828
829 CLIENT_OBJ1 = client/client.o client/clitar.o rpc_client/cli_pipe.o \
830               client/dnsbrowse.o \
831               $(RPC_CLIENT_OBJ1) \
832               $(RPC_PARSE_OBJ2)
833
834 CLIENT_OBJ = $(CLIENT_OBJ1) $(PARAM_OBJ) $(LIBSMB_OBJ) \
835              $(LIB_NONSMBD_OBJ) $(KRBCLIENT_OBJ) $(LIBMSRPC_GEN_OBJ) \
836              $(READLINE_OBJ) $(POPT_LIB_OBJ) \
837              $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ $(SMBLDAP_OBJ) $(GROUPDB_OBJ) $(LDB_OBJ) \
838              $(DISPLAY_SEC_OBJ) 
839
840 LIBNETAPI_OBJ1 = lib/netapi/netapi.o \
841                  lib/netapi/cm.o \
842                  librpc/gen_ndr/ndr_libnetapi.o \
843                  lib/netapi/libnetapi.o \
844                  lib/netapi/joindomain.o \
845                  lib/netapi/serverinfo.o \
846                  lib/netapi/getdc.o \
847                  lib/netapi/user.o
848
849 LIBNETAPI_OBJ  = $(LIBNETAPI_OBJ1) $(LIBNET_OBJ) \
850                  $(LIBSMBCONF_OBJ) \
851                  $(REG_SMBCONF_OBJ) \
852                  $(PARAM_WITHOUT_REG_OBJ) $(LIB_NONSMBD_OBJ) \
853                  $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
854                  $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) $(RPC_PARSE_OBJ) \
855                  $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ $(SMBLDAP_OBJ) $(GROUPDB_OBJ) $(LDB_OBJ) \
856                  $(DCUTIL_OBJ) $(LIBADS_OBJ) $(PRIVILEGES_BASIC_OBJ)
857
858 LIBSMBCONF_OBJ = lib/smbconf/smbconf.o lib/smbconf/smbconf_util.o \
859                  lib/smbconf/smbconf_reg.o \
860                  lib/smbconf/smbconf_txt.o \
861                  lib/smbconf/smbconf_init.o
862
863 SMBCONFTORT_OBJ0 = lib/smbconf/testsuite.o
864
865 SMBCONFTORT_OBJ = $(SMBCONFTORT_OBJ0) \
866                   $(LIB_NONSMBD_OBJ) \
867                   $(PARAM_OBJ) \
868                   $(LIBSMB_ERR_OBJ) \
869                   $(POPT_LIB_OBJ)
870
871 LIBNET_OBJ = libnet/libnet_join.o \
872              librpc/gen_ndr/ndr_libnet_join.o
873
874 NET_OBJ1 = utils/net.o utils/net_ads.o utils/net_help.o \
875            utils/net_rap.o utils/net_rpc.o utils/net_rpc_samsync.o \
876            utils/net_rpc_join.o utils/net_time.o utils/net_lookup.o \
877            utils/net_cache.o utils/net_groupmap.o utils/net_idmap.o \
878            utils/net_status.o utils/net_rpc_printer.o utils/net_rpc_rights.o \
879            utils/net_rpc_service.o utils/net_rpc_registry.o utils/net_usershare.o \
880            utils/netlookup.o utils/net_sam.o utils/net_rpc_shell.o \
881            utils/net_util.o utils/net_rpc_sh_acct.o utils/net_rpc_audit.o \
882            $(PASSWD_UTIL_OBJ) utils/net_dns.o utils/net_ads_gpo.o \
883            utils/net_conf.o \
884            utils/net_registry.o \
885            auth/token_util.o utils/net_dom.o
886
887 # these are not processed by make proto
888 NET_OBJ2 = utils/net_registry_util.o
889
890 NET_OBJ = $(NET_OBJ1) \
891           $(NET_OBJ2) \
892           $(PARAM_WITHOUT_REG_OBJ) $(LIBSMB_OBJ) \
893           $(RPC_PARSE_OBJ) $(PASSDB_OBJ) $(GROUPDB_OBJ) \
894           $(KRBCLIENT_OBJ) $(LIB_NONSMBD_OBJ) $(LIBADDNS_OBJ0) \
895           $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) \
896           $(LIBADS_OBJ) $(LIBADS_SERVER_OBJ) $(POPT_LIB_OBJ) \
897           $(SMBLDAP_OBJ) $(DCUTIL_OBJ) $(SERVER_MUTEX_OBJ) \
898           $(AFS_OBJ) $(AFS_SETTOKEN_OBJ) $(READLINE_OBJ) \
899           $(LDB_OBJ) $(LIBGPO_OBJ) @BUILD_INIPARSER@ $(DISPLAY_SEC_OBJ) \
900           $(REG_SMBCONF_OBJ) @LIBNETAPI_STATIC@ $(LIBNET_OBJ) \
901           $(LIBSMBCONF_OBJ) \
902           @LIBWBCLIENT_STATIC@ \
903           $(PRIVILEGES_BASIC_OBJ)
904
905 CUPS_OBJ = client/smbspool.o $(PARAM_OBJ) $(LIBSMB_OBJ) \
906           $(LIB_NONSMBD_OBJ) $(KRBCLIENT_OBJ) $(POPT_LIB_OBJ) \
907           librpc/gen_ndr/ndr_samr.o librpc/gen_ndr/ndr_lsa.o
908
909 CIFS_MOUNT_OBJ = client/mount.cifs.o
910
911 CIFS_UMOUNT_OBJ = client/umount.cifs.o
912
913 CIFS_SPNEGO_OBJ = client/cifs.spnego.o
914
915 NMBLOOKUP_OBJ = utils/nmblookup.o $(PARAM_OBJ) $(LIBNMB_OBJ) \
916                $(LIB_NONSMBD_OBJ) $(POPT_LIB_OBJ) $(LIBSAMBA_OBJ)
917
918 SMBTORTURE_OBJ1 = torture/torture.o torture/nbio.o torture/scanner.o torture/utable.o \
919                 torture/denytest.o torture/mangle_test.o
920
921 SMBTORTURE_OBJ = $(SMBTORTURE_OBJ1) $(PARAM_OBJ) \
922         $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) $(LIB_NONSMBD_OBJ) \
923         librpc/gen_ndr/ndr_samr.o librpc/gen_ndr/ndr_lsa.o
924
925 MASKTEST_OBJ = torture/masktest.o $(PARAM_OBJ) $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
926                  $(LIB_NONSMBD_OBJ) \
927                  librpc/gen_ndr/ndr_samr.o librpc/gen_ndr/ndr_lsa.o
928
929 MSGTEST_OBJ = torture/msgtest.o $(PARAM_OBJ) $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
930                  $(LIB_NONSMBD_OBJ) \
931                  librpc/gen_ndr/ndr_samr.o librpc/gen_ndr/ndr_lsa.o
932
933 LOCKTEST_OBJ = torture/locktest.o $(PARAM_OBJ) $(LOCKING_OBJ) $(KRBCLIENT_OBJ) \
934                $(LIBSMB_OBJ) $(LIB_NONSMBD_OBJ) \
935                librpc/gen_ndr/ndr_samr.o librpc/gen_ndr/ndr_lsa.o
936
937 NSSTEST_OBJ = torture/nsstest.o $(PARAM_OBJ) $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
938                  $(LIB_NONSMBD_OBJ) \
939                  librpc/gen_ndr/ndr_samr.o librpc/gen_ndr/ndr_lsa.o
940
941 PDBTEST_OBJ = torture/pdbtest.o $(PARAM_OBJ) $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
942                 $(LIB_NONSMBD_OBJ) $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ $(GROUPDB_OBJ) \
943                 $(SMBLDAP_OBJ) $(POPT_LIB_OBJ) $(LDB_OBJ) \
944                 librpc/gen_ndr/ndr_samr.o librpc/gen_ndr/ndr_lsa.o
945
946 VFSTEST_OBJ = torture/cmd_vfs.o torture/vfstest.o $(SMBD_OBJ_BASE) $(READLINE_OBJ)
947
948 SMBICONV_OBJ = $(PARAM_OBJ) torture/smbiconv.o $(LIB_NONSMBD_OBJ) $(POPT_LIB_OBJ) $(LIBSAMBA_OBJ)
949
950 LOG2PCAP_OBJ = utils/log2pcaphex.o
951
952 LOCKTEST2_OBJ = torture/locktest2.o $(PARAM_OBJ) $(LOCKING_OBJ) $(LIBSMB_OBJ) \
953                 $(KRBCLIENT_OBJ) $(LIB_NONSMBD_OBJ) \
954                 librpc/gen_ndr/ndr_samr.o librpc/gen_ndr/ndr_lsa.o
955
956 SMBCACLS_OBJ = utils/smbcacls.o $(PARAM_OBJ) $(LIBSMB_OBJ) \
957                 $(KRBCLIENT_OBJ) $(LIB_NONSMBD_OBJ) $(RPC_PARSE_OBJ) \
958                 $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ $(GROUPDB_OBJ) $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) \
959                 $(POPT_LIB_OBJ) $(DCUTIL_OBJ) $(LIBADS_OBJ) $(SMBLDAP_OBJ) $(LDB_OBJ)
960
961 SMBCQUOTAS_OBJ = utils/smbcquotas.o $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
962                 $(PARAM_OBJ) \
963                 $(LIB_NONSMBD_OBJ) $(RPC_PARSE_OBJ) \
964                 $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) $(POPT_LIB_OBJ) \
965                 $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ $(SMBLDAP_OBJ) $(GROUPDB_OBJ) $(LDB_OBJ)
966
967 EVTLOGADM_OBJ0  = utils/eventlogadm.o
968
969 EVTLOGADM_OBJ   = $(EVTLOGADM_OBJ0) $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
970                 $(LIBSAMBA_OBJ) \
971                 registry/reg_eventlog.o rpc_server/srv_eventlog_lib.o
972
973 SHARESEC_OBJ0 = utils/sharesec.o
974 SHARESEC_OBJ  = $(SHARESEC_OBJ0) $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
975                 $(LIBSAMBA_OBJ) \
976                 $(POPT_LIB_OBJ)
977
978 TALLOCTORT_OBJ = @tallocdir@/testsuite.o $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
979                  $(LIBSAMBA_OBJ)
980
981 REPLACETORT_OBJ = lib/replace/test/testsuite.o \
982                 lib/replace/test/getifaddrs.o \
983                 lib/replace/test/os2_delete.o \
984                 lib/replace/test/strptime.o \
985                 $(LIBREPLACE_OBJ)
986
987 NDRDUMP_OBJ = librpc/tools/ndrdump.o \
988               $(PARAM_OBJ) $(LIBNDR_GEN_OBJ) \
989               $(LIBSAMBA_OBJ) $(LIB_NONSMBD_OBJ) $(POPT_LIB_OBJ) \
990               librpc/gen_ndr/ndr_svcctl.o
991
992 DEBUG2HTML_OBJ = utils/debug2html.o utils/debugparse.o
993
994 SMBFILTER_OBJ = utils/smbfilter.o $(PARAM_OBJ) $(LIBSMB_OBJ) \
995                  $(LIB_NONSMBD_OBJ) $(KRBCLIENT_OBJ) \
996                  librpc/gen_ndr/ndr_samr.o librpc/gen_ndr/ndr_lsa.o
997
998 PROTO_OBJ = $(SMBD_OBJ_MAIN) $(LIBNDR_OBJ) $(LIBNDR_GEN_OBJ) \
999             $(SMBD_OBJ_SRV) $(NMBD_OBJ1) $(LIBSMB_OBJ) \
1000             $(SMBTORTURE_OBJ1) $(RPCCLIENT_OBJ1) \
1001             $(LIBMSRPC_OBJ) \
1002             $(LIB_WITH_PROTO_OBJ) \
1003             $(RPC_PIPE_OBJ) $(RPC_PARSE_OBJ) $(KRBCLIENT_OBJ) \
1004             $(AUTH_OBJ) $(PARAM_WITHOUT_REG_OBJ) $(LOCKING_OBJ) \
1005             $(PRINTING_OBJ) $(PRINTBACKEND_OBJ) $(OPLOCK_OBJ) $(NOTIFY_OBJ) \
1006             $(PASSDB_OBJ) $(GROUPDB_OBJ) \
1007             $(READLINE_OBJ) $(PROFILE_OBJ) $(LIBADS_OBJ) $(LIBADS_SERVER_OBJ) \
1008             $(AUTH_SAM_OBJ) $(REG_FULL_OBJ) $(POPT_LIB_OBJ) \
1009             $(RPC_LSA_OBJ) $(RPC_NETLOG_OBJ) $(RPC_SAMR_OBJ) $(RPC_REG_OBJ) $(RPC_DSSETUP_OBJ) \
1010             $(RPC_SVC_OBJ) $(RPC_WKS_OBJ) $(RPC_DFS_OBJ) $(RPC_SPOOLSS_OBJ) \
1011             $(RPC_ECHO_OBJ) $(RPC_SVCCTL_OBJ) $(RPC_EVENTLOG_OBJ) $(SMBLDAP_OBJ) \
1012             $(IDMAP_OBJ) libsmb/spnego.o $(PASSCHANGE_OBJ) \
1013             $(RPC_NTSVCS_OBJ) $(RPC_INITSHUTDOWN_OBJ) \
1014             utils/passwd_util.o $(LIBGPO_OBJ) $(NSS_INFO_OBJ) \
1015             $(RPCCLIENT_NDR_OBJ) \
1016             $(PRIVILEGES_BASIC_OBJ)
1017
1018 WINBIND_WINS_NSS_OBJ = nsswitch/wins.o $(PARAM_OBJ) \
1019         $(LIBSMB_OBJ) $(LIB_NONSMBD_OBJ) $(NSSWINS_OBJ) $(KRBCLIENT_OBJ) \
1020         librpc/gen_ndr/ndr_samr.o librpc/gen_ndr/ndr_lsa.o
1021
1022 PAM_SMBPASS_OBJ_0 = pam_smbpass/pam_smb_auth.o pam_smbpass/pam_smb_passwd.o \
1023                 pam_smbpass/pam_smb_acct.o pam_smbpass/support.o
1024 PAM_SMBPASS_OBJ = $(PAM_SMBPASS_OBJ_0) $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ $(GROUPDB_OBJ) \
1025                 $(SMBLDAP_OBJ) $(LIBSAMBA_OBJ) \
1026                 $(LDB_OBJ)
1027
1028 IDMAP_OBJ     = winbindd/idmap.o winbindd/idmap_cache.o winbindd/idmap_util.o @IDMAP_STATIC@
1029
1030 NSS_INFO_OBJ = winbindd/nss_info.o @NSS_INFO_STATIC@
1031
1032 WINBINDD_OBJ1 = \
1033                 winbindd/winbindd.o       \
1034                 winbindd/winbindd_user.o  \
1035                 winbindd/winbindd_group.o \
1036                 winbindd/winbindd_util.o  \
1037                 winbindd/winbindd_cache.o \
1038                 winbindd/winbindd_pam.o   \
1039                 winbindd/winbindd_sid.o   \
1040                 winbindd/winbindd_misc.o  \
1041                 winbindd/winbindd_cm.o    \
1042                 winbindd/winbindd_wins.o  \
1043                 winbindd/winbindd_rpc.o   \
1044                 winbindd/winbindd_reconnect.o \
1045                 winbindd/winbindd_ads.o   \
1046                 winbindd/winbindd_passdb.o \
1047                 winbindd/winbindd_dual.o  \
1048                 winbindd/winbindd_async.o \
1049                 winbindd/winbindd_creds.o \
1050                 winbindd/winbindd_cred_cache.o \
1051                 winbindd/winbindd_ccache_access.o \
1052                 winbindd/winbindd_domain.o \
1053                 winbindd/winbindd_idmap.o \
1054                 winbindd/winbindd_locator.o \
1055                 winbindd/winbindd_ndr.o \
1056                 auth/token_util.o \
1057                 smbd/connection.o
1058
1059 WINBINDD_OBJ = \
1060                 $(WINBINDD_OBJ1) $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ $(GROUPDB_OBJ) \
1061                 $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
1062                 $(LIBSMB_OBJ) $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) $(RPC_PARSE_OBJ) \
1063                 $(PROFILE_OBJ) $(SLCACHE_OBJ) $(SMBLDAP_OBJ) \
1064                 $(LIBADS_OBJ) $(KRBCLIENT_OBJ) $(POPT_LIB_OBJ) \
1065                 $(DCUTIL_OBJ) $(IDMAP_OBJ) $(NSS_INFO_OBJ) \
1066                 $(AFS_OBJ) $(AFS_SETTOKEN_OBJ) \
1067                 $(LIBADS_SERVER_OBJ) $(SERVER_MUTEX_OBJ) $(LDB_OBJ) 
1068
1069 WBINFO_OBJ = nsswitch/wbinfo.o $(LIBSAMBA_OBJ) $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
1070                 $(POPT_LIB_OBJ) $(AFS_SETTOKEN_OBJ) \
1071                 lib/winbind_util.o $(WBCOMMON_OBJ) @LIBWBCLIENT_STATIC@
1072
1073 WINBIND_NSS_OBJ = $(WBCOMMON_OBJ) $(LIBREPLACE_OBJ) @WINBIND_NSS_EXTRA_OBJS@
1074
1075 LDB_COMMON_OBJ=lib/ldb/common/ldb.o lib/ldb/common/ldb_ldif.o \
1076           lib/ldb/common/ldb_parse.o lib/ldb/common/ldb_msg.o lib/ldb/common/ldb_utf8.o \
1077           lib/ldb/common/ldb_debug.o lib/ldb/common/ldb_modules.o \
1078           lib/ldb/common/ldb_dn.o lib/ldb/common/ldb_match.o lib/ldb/common/ldb_attributes.o \
1079           lib/ldb/common/attrib_handlers.o lib/ldb/common/ldb_controls.o lib/ldb/common/qsort.o
1080
1081 LDB_TDB_OBJ=lib/ldb/ldb_tdb/ldb_tdb.o \
1082        lib/ldb/ldb_tdb/ldb_pack.o lib/ldb/ldb_tdb/ldb_search.o lib/ldb/ldb_tdb/ldb_index.o \
1083        lib/ldb/ldb_tdb/ldb_cache.o lib/ldb/ldb_tdb/ldb_tdb_wrap.o
1084
1085 LDB_MODULES_OBJ=lib/ldb/modules/operational.o lib/ldb/modules/rdn_name.o \
1086           lib/ldb/modules/objectclass.o \
1087           lib/ldb/modules/paged_results.o lib/ldb/modules/sort.o lib/ldb/modules/asq.o
1088
1089 # enabled in configure.in
1090 LDB_LDAP_OBJ=@LDBLDAP@
1091
1092 LDB_OBJ = ${LDB_COMMON_OBJ} ${LDB_TDB_OBJ} ${LDB_LDAP_OBJ} ${LDB_MODULES_OBJ}
1093
1094 LDB_CMDLINE_OBJ = $(PARAM_OBJ) $(LIBSMB_OBJ) \
1095           $(RPC_PARSE_OBJ) $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ $(GROUPDB_OBJ) \
1096           $(KRBCLIENT_OBJ) $(LIB_NONSMBD_OBJ) $(LIBADDNS_OBJ0) \
1097           $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) \
1098           $(LIBADS_OBJ) $(LIBADS_SERVER_OBJ) $(POPT_LIB_OBJ) \
1099           $(SMBLDAP_OBJ) $(DCUTIL_OBJ) $(SERVER_MUTEX_OBJ) \
1100           $(AFS_OBJ) $(AFS_SETTOKEN_OBJ) $(READLINE_OBJ) \
1101           $(LDB_OBJ) lib/ldb/tools/cmdline.o 
1102
1103
1104 LDBEDIT_OBJ = $(LDB_CMDLINE_OBJ) lib/ldb/tools/ldbedit.o
1105 LDBSEARCH_OBJ = $(LDB_CMDLINE_OBJ) lib/ldb/tools/ldbsearch.o
1106 LDBADD_OBJ = $(LDB_CMDLINE_OBJ) lib/ldb/tools/ldbadd.o
1107 LDBDEL_OBJ = $(LDB_CMDLINE_OBJ) lib/ldb/tools/ldbdel.o
1108 LDBMODIFY_OBJ = $(LDB_CMDLINE_OBJ) lib/ldb/tools/ldbmodify.o
1109
1110 WINBIND_KRB5_LOCATOR_OBJ1 = nsswitch/winbind_krb5_locator.o
1111 WINBIND_KRB5_LOCATOR_OBJ = $(WINBIND_KRB5_LOCATOR_OBJ1) $(WBCOMMON_OBJ) $(LIBREPLACE_OBJ)
1112
1113 POPT_OBJ=popt/findme.o popt/popt.o popt/poptconfig.o \
1114           popt/popthelp.o popt/poptparse.o
1115
1116 INIPARSER_OBJ = iniparser_build/iniparser.o iniparser_build/dictionary.o \
1117                 iniparser_build/strlib.o
1118
1119 TDBBACKUP_OBJ = @tdbdir@/tools/tdbbackup.o $(LIBREPLACE_OBJ) \
1120         @LIBTDB_STATIC@ $(SOCKET_WRAPPER_OBJ)
1121
1122 TDBTOOL_OBJ = @tdbdir@/tools/tdbtool.o @LIBTDB_STATIC@ $(LIBREPLACE_OBJ) \
1123         $(SOCKET_WRAPPER_OBJ)
1124
1125 TDBDUMP_OBJ = @tdbdir@/tools/tdbdump.o @LIBTDB_STATIC@ $(LIBREPLACE_OBJ) \
1126         $(SOCKET_WRAPPER_OBJ)
1127
1128 TDBTORTURE_OBJ = @tdbdir@/tools/tdbtorture.o @LIBTDB_STATIC@ $(LIBREPLACE_OBJ) \
1129         $(SOCKET_WRAPPER_OBJ)
1130
1131
1132 NTLM_AUTH_OBJ1 = utils/ntlm_auth.o utils/ntlm_auth_diagnostics.o
1133
1134 NTLM_AUTH_OBJ = ${NTLM_AUTH_OBJ1} $(LIBSAMBA_OBJ) $(POPT_LIB_OBJ) \
1135                 libsmb/asn1.o libsmb/spnego.o libsmb/clikrb5.o libads/kerberos.o \
1136                 $(SERVER_MUTEX_OBJ) $(LIBADS_SERVER_OBJ) \
1137                 $(PASSDB_OBJ) $(GROUPDB_OBJ) \
1138                 $(SMBLDAP_OBJ) $(LIBNMB_OBJ) \
1139                 $(LDB_OBJ) $(WBCOMMON_OBJ) @LIBWBCLIENT_STATIC@ \
1140                 librpc/gen_ndr/ndr_samr.o \
1141                 librpc/gen_ndr/ndr_lsa.o \
1142                 librpc/gen_ndr/ndr_netlogon.o
1143
1144
1145 VLP_OBJ1 = ../testsuite/printing/vlp.o $(RPC_CLIENT_OBJ1) $(RPC_PARSE_OBJ2) $(RPC_CLIENT_OBJ)
1146
1147 VLP_OBJ = $(VLP_OBJ1) $(PARAM_OBJ) $(LIBSMB_OBJ) \
1148           $(LIB_NONSMBD_OBJ) $(KRBCLIENT_OBJ) $(LIBMSRPC_GEN_OBJ) \
1149           $(READLINE_OBJ) $(POPT_LIB_OBJ) \
1150           $(PASSDB_OBJ) @LIBWBCLIENT_STATIC@ $(SMBLDAP_OBJ) $(GROUPDB_OBJ) $(LDB_OBJ) \
1151           $(DISPLAY_SEC_OBJ)
1152
1153 ######################################################################
1154 # now the rules...
1155 ######################################################################
1156 all : SHOWFLAGS $(SHLIBS) $(SBIN_PROGS) $(BIN_PROGS) $(ROOT_SBIN_PROGS) \
1157         $(MODULES) $(NSS_MODULES) $(PAM_MODULES) @EXTRA_ALL_TARGETS@
1158
1159 nss_modules : $(NSS_MODULES)
1160
1161 pam_modules : $(PAM_MODULES)
1162
1163 gpext_modules : SHOWFLAGS $(GPEXT_MODULES)
1164
1165 pam_smbpass : SHOWFLAGS bin/pam_smbpass.@SHLIBEXT@
1166
1167 pam_winbind : SHOWFLAGS bin/pam_winbind.@SHLIBEXT@
1168
1169 torture : SHOWFLAGS $(TORTURE_PROGS)
1170
1171 smbtorture : SHOWFLAGS bin/smbtorture@EXEEXT@
1172
1173 masktest : SHOWFLAGS bin/masktest@EXEEXT@
1174
1175 msgtest : SHOWFLAGS bin/msgtest@EXEEXT@
1176
1177 locktest : SHOWFLAGS bin/locktest@EXEEXT@
1178
1179 smbcacls : SHOWFLAGS bin/smbcacls@EXEEXT@
1180
1181 smbcquotas : SHOWFLAGS bin/smbcquotas@EXEEXT@
1182
1183 locktest2 : SHOWFLAGS bin/locktest2@EXEEXT@
1184
1185 debug2html : SHOWFLAGS bin/debug2html@EXEEXT@
1186
1187 smbfilter : SHOWFLAGS bin/smbfilter@EXEEXT@
1188
1189 eventlogadm: SHOWFLAGS bin/eventlogadm@EXEEXT@
1190
1191 sharesec: SHOWFLAGS bin/sharesec@EXEEXT@
1192
1193 talloctort : SHOWFLAGS bin/talloctort@EXEEXT@
1194
1195 replacetort : SHOWFLAGS bin/replacetort@EXEEXT@
1196
1197 smbconftort : SHOWFLAGS bin/smbconftort@EXEEXT@
1198
1199 timelimit : SHOWFLAGS bin/timelimit@EXEEXT@
1200
1201 nsswitch : SHOWFLAGS bin/winbindd@EXEEXT@ bin/wbinfo@EXEEXT@ @WINBIND_NSS@ \
1202         @WINBIND_WINS_NSS@ @WINBIND_KRB5_LOCATOR@ \
1203         bin/pam_winbind.@SHLIBEXT@ bin/smbcontrol@EXEEXT@
1204
1205 wins : SHOWFLAGS @WINBIND_WINS_NSS@
1206
1207 modules: SHOWFLAGS $(MODULES)
1208
1209 #####################################################################
1210 ## Perl IDL Compiler
1211 IDL_FILES = lsa.idl dfs.idl echo.idl winreg.idl initshutdown.idl \
1212         srvsvc.idl svcctl.idl eventlog.idl wkssvc.idl netlogon.idl notify.idl \
1213         epmapper.idl messaging.idl xattr.idl misc.idl samr.idl security.idl \
1214         dssetup.idl krb5pac.idl ntsvcs.idl libnetapi.idl drsuapi.idl nbt.idl
1215
1216 idl:
1217         @IDL_FILES="$(IDL_FILES)" CPP="$(CPP)" PERL="$(PERL)" \
1218          srcdir="$(srcdir)" $(srcdir)/script/build_idl.sh $(PIDL_ARGS)
1219
1220
1221 #####################################################################
1222
1223
1224 everything: all libtalloc libsmbclient libnetapi debug2html smbfilter talloctort replacetort smbconftort modules torture \
1225         $(EVERYTHING_PROGS)
1226
1227 .SUFFIXES:
1228 .SUFFIXES: .c .o .lo
1229
1230 SHOWFLAGS:
1231         @echo "Using FLAGS      = $(FLAGS)"
1232         @echo "      PICFLAG    = $(PICFLAG)"
1233         @echo "      LIBS       = $(LIBS)"
1234         @echo "      LDFLAGS    = $(LDFLAGS)"
1235         @echo "      DYNEXP     = $(DYNEXP)"
1236         @echo "      LDSHFLAGS  = $(LDSHFLAGS)"
1237         @echo "      SHLIBEXT   = @SHLIBEXT@"
1238         @echo "      SONAMEFLAG = @SONAMEFLAG@"
1239
1240 MAKEDIR = || exec false; \
1241           if test -d "$$dir"; then :; else \
1242           echo mkdir "$$dir"; \
1243           mkdir -p "$$dir" >/dev/null 2>&1 || \
1244           test -d "$$dir" || \
1245           mkdir "$$dir" || \
1246           exec false; fi || exec false
1247
1248 # Run a static checker.
1249 CHECK_CC = $(CC_CHECKER) -I. -I$(srcdir) $(FLAGS) $(PICFLAG) -c $< -o $@
1250 # Compile a source file.
1251 COMPILE_CC = $(CC) -I. -I$(srcdir) $(FLAGS) $(PICFLAG) -c $< -o $@
1252 # Compile a source file with the installation paths defined.
1253 COMPILE_CC_PATH = $(CC) -I. -I$(srcdir) $(PATH_FLAGS) $(FLAGS) $(PICFLAG) -c $< -o $@
1254
1255 COMPILE = $(COMPILE_CC)
1256
1257 .c.o:
1258         @if (: >> $@ || : > $@) >/dev/null 2>&1; then rm -f $@; else \
1259          dir=`echo $@ | sed 's,/[^/]*$$,,;s,^$$,.,'` $(MAKEDIR); fi
1260         @if test -n "$(CC_CHECKER)"; then \
1261           echo "Checking  $*.c with '$(CC_CHECKER)'";\
1262           $(CHECK_CC); \
1263          fi
1264         @echo Compiling $*.c
1265         @$(COMPILE) && exit 0;\
1266                 echo "The following command failed:" 1>&2;\
1267                 echo "$(COMPILE_CC)" 1>&2;\
1268                 $(COMPILE_CC) >/dev/null 2>&1
1269 @BROKEN_CC@     -mv `echo $@ | sed 's%^.*/%%g'` $@
1270
1271 PRECOMPILED_HEADER = $(builddir)/include/includes.h.gch
1272
1273 # this adds support for precompiled headers. To use it, install a snapshot
1274 # of gcc-3.4 and run 'make pch' before you do the main build.
1275 pch: proto_exists
1276         rm -f $(PRECOMPILED_HEADER)
1277         $(MAKE) $(PRECOMPILED_HEADER)
1278
1279 $(PRECOMPILED_HEADER): $(srcdir)/include/includes.h
1280         $(COMPILE)
1281
1282 BINARY_PREREQS = proto_exists bin/.dummy
1283
1284 # These dependencies are only approximately correct: we want to make
1285 # sure Samba's paths are updated if ./configure is re-run.  Really it
1286 # would be nice if "make prefix=/opt/samba all" also rebuilt things,
1287 # but since we also require "make install prefix=/opt/samba" *not* to
1288 # rebuild it's a bit hard.
1289
1290 dynconfig.o: dynconfig.c Makefile
1291         @echo Compiling $*.c
1292         @$(COMPILE_CC_PATH) && exit 0;\
1293                 echo "The following command failed:" 1>&2;\
1294                 echo "$(COMPILE_CC_PATH)" 1>&2;\
1295                 $(COMPILE_CC_PATH) >/dev/null 2>&1
1296
1297 lib/pidfile.o: lib/pidfile.c
1298         @echo Compiling $*.c
1299         @$(COMPILE_CC_PATH) && exit 0;\
1300                 echo "The following command failed:" 1>&2;\
1301                 echo "$(COMPILE_CC_PATH)" 1>&2;\
1302                 $(COMPILE_CC_PATH) >/dev/null 2>&1
1303
1304 lib/version.o: lib/version.c include/version.h
1305         @echo Compiling $*.c
1306         @$(COMPILE_CC_PATH) && exit 0;\
1307                 echo "The following command failed:" 1>&2;\
1308                 echo "$(COMPILE_CC_PATH)" 1>&2;\
1309                 $(COMPILE_CC_PATH) >/dev/null 2>&1
1310
1311 smbd/build_options.o: smbd/build_options.c Makefile include/config.h include/build_env.h include/proto.h
1312         @echo Compiling $*.c
1313         @$(COMPILE_CC_PATH) && exit 0;\
1314                 echo "The following command failed:" 1>&2;\
1315                 echo "$(COMPILE_CC_PATH)" 1>&2;\
1316                 $(COMPILE_CC_PATH) >/dev/null 2>&1
1317
1318 smbd/build_options.c: include/config.h.in script/mkbuildoptions.awk
1319         @echo Generating $@
1320         @dir=smbd $(MAKEDIR) && $(AWK) -f $(srcdir)/script/mkbuildoptions.awk > $(builddir)/smbd/build_options.c < $(srcdir)/include/config.h.in
1321
1322 bin/.dummy:
1323         @if (: >> $@ || : > $@) >/dev/null 2>&1; then :; else \
1324           dir=bin $(MAKEDIR); fi
1325         @: >> $@ || : > $@ # what a fancy emoticon!
1326
1327 bin/smbd@EXEEXT@: $(BINARY_PREREQS) $(SMBD_OBJ) @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@ @BUILD_POPT@
1328         @echo Linking $@
1329         @$(CC) $(FLAGS) -o $@ $(SMBD_OBJ) $(LDFLAGS) $(LDAP_LIBS) \
1330                 $(KRB5LIBS) $(DYNEXP) $(PRINT_LIBS) $(AUTH_LIBS) \
1331                 $(ACL_LIBS) $(PASSDB_LIBS) $(LIBS) $(DNSSD_LIBS) \
1332                 @POPTLIBS@ @SMBD_LIBS@ @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ \
1333                 @WINBIND_LIBS@
1334
1335 bin/nmbd@EXEEXT@: $(BINARY_PREREQS) $(NMBD_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1336         @echo Linking $@
1337         @$(CC) $(FLAGS) -o $@ $(NMBD_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1338                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @POPTLIBS@ \
1339                 $(KRB5LIBS) $(LDAP_LIBS)
1340
1341 bin/swat@EXEEXT@: $(BINARY_PREREQS) $(SWAT_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1342         @echo Linking $@
1343         @$(CC) $(FLAGS) -o $@ $(SWAT_OBJ) $(LDFLAGS) $(DYNEXP) $(PRINT_LIBS) \
1344           $(AUTH_LIBS) $(LIBS) $(PASSDB_LIBS) @POPTLIBS@ $(KRB5LIBS) \
1345           $(LDAP_LIBS) @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
1346
1347 bin/rpcclient@EXEEXT@: $(BINARY_PREREQS) $(RPCCLIENT_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1348         @echo Linking $@
1349         @$(CC) $(FLAGS) -o $@ $(LDFLAGS) $(PASSDB_LIBS) $(RPCCLIENT_OBJ) \
1350                 $(DYNEXP) $(TERMLDFLAGS) $(TERMLIBS) $(LIBS) @POPTLIBS@ \
1351                 $(KRB5LIBS) $(LDAP_LIBS) @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ \
1352                 @WINBIND_LIBS@
1353
1354 bin/smbclient@EXEEXT@: $(BINARY_PREREQS) $(CLIENT_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1355         @echo Linking $@
1356         @$(CC) $(FLAGS) -o $@ $(CLIENT_OBJ) $(LDFLAGS) $(DYNEXP) \
1357                 $(TERMLDFLAGS) $(TERMLIBS) $(LIBS) @POPTLIBS@ \
1358                 $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) $(DNSSD_LIBS) \
1359                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
1360
1361 bin/net@EXEEXT@: $(BINARY_PREREQS) $(NET_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@ @LIBNETAPI_SHARED@
1362         @echo Linking $@
1363         @$(CC) $(FLAGS) -o $@ $(NET_OBJ) $(DYNEXP) $(LDFLAGS) $(LIBS) \
1364                 @POPTLIBS@ $(KRB5LIBS) $(UUID_LIBS) $(LDAP_LIBS) \
1365                 $(PASSDB_LIBS) $(TERMLDFLAGS) $(TERMLIBS) $(NSCD_LIBS) \
1366                 @INIPARSERLIBS@ @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@ @LIBNETAPI_LIBS@
1367
1368 bin/profiles@EXEEXT@: $(BINARY_PREREQS) $(PROFILES_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1369         @echo Linking $@
1370         @$(CC) $(FLAGS) -o $@ $(PROFILES_OBJ) $(DYNEXP) $(LDFLAGS) $(LIBS) \
1371                 $(LDAP_LIBS) @POPTLIBS@ @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1372
1373 bin/smbspool@EXEEXT@: $(BINARY_PREREQS) $(CUPS_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1374         @echo Linking $@
1375         @$(CC) $(FLAGS) -o $@ $(CUPS_OBJ) $(DYNEXP) $(LDFLAGS) $(LIBS) \
1376                 $(KRB5LIBS) $(LDAP_LIBS) @POPTLIBS@ @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1377
1378 bin/mount.cifs@EXEEXT@: $(BINARY_PREREQS) $(CIFS_MOUNT_OBJ) @BUILD_POPT@
1379         @echo Linking $@
1380         @$(CC) $(FLAGS) -o $@ $(CIFS_MOUNT_OBJ) $(DYNEXP) $(LDFLAGS) @POPTLIBS@
1381
1382 bin/umount.cifs@EXEEXT@: $(BINARY_PREREQS) $(CIFS_UMOUNT_OBJ) @BUILD_POPT@
1383         @echo Linking $@
1384         @$(CC) $(FLAGS) -o $@ $(CIFS_UMOUNT_OBJ) $(DYNEXP) $(LDFLAGS) @POPTLIBS@
1385
1386 bin/cifs.spnego@EXEEXT@: $(BINARY_PREREQS) $(CIFS_SPNEGO_OBJ) $(LIBSMBCLIENT_OBJ0) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1387         @echo Linking $@
1388         @$(CC) $(FLAGS) -o $@ $(CIFS_SPNEGO_OBJ) $(DYNEXP) $(LDFLAGS) \
1389                 -lkeyutils $(LIBS) $(LIBSMBCLIENT_OBJ0) $(KRB5LIBS) \
1390                 $(LDAP_LIBS) @POPTLIBS@ @LIBTALLOC_LIBS@ @LIBWBCLIENT_SHARED@ \
1391                 @LIBTDB_LIBS@
1392
1393 bin/testparm@EXEEXT@: $(BINARY_PREREQS) $(TESTPARM_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1394         @echo Linking $@
1395         @$(CC) $(FLAGS) -o $@ $(TESTPARM_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1396                 $(LDAP_LIBS) @POPTLIBS@ @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1397
1398 bin/smbstatus@EXEEXT@: $(BINARY_PREREQS) $(STATUS_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1399         @echo Linking $@
1400         @$(CC) $(FLAGS) -o $@ $(STATUS_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1401                 $(LDAP_LIBS) @POPTLIBS@ @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1402
1403 bin/smbcontrol@EXEEXT@: $(BINARY_PREREQS) $(SMBCONTROL_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1404         @echo Linking $@
1405         @$(CC) -DUSING_SMBCONTROL $(FLAGS) -o $@ \
1406                 $(SMBCONTROL_OBJ) $(DYNEXP) $(LDFLAGS) \
1407                 $(LIBS) $(LDAP_LIBS) @LIBUNWIND_PTRACE@ @POPTLIBS@ \
1408                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1409
1410 bin/smbtree@EXEEXT@: $(BINARY_PREREQS) $(SMBTREE_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1411         @echo Linking $@
1412         @$(CC) $(FLAGS) -o $@ $(SMBTREE_OBJ) $(LDFLAGS) $(DYNEXP) \
1413                 $(LIBS) @POPTLIBS@ $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) \
1414                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
1415
1416 bin/smbpasswd@EXEEXT@: $(BINARY_PREREQS) $(SMBPASSWD_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1417         @echo Linking $@
1418         @$(CC) $(FLAGS) -o $@ $(SMBPASSWD_OBJ) $(LDFLAGS) $(PASSDB_LIBS) \
1419                 $(DYNEXP) $(LIBS) @POPTLIBS@ $(KRB5LIBS) $(LDAP_LIBS) \
1420                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
1421
1422 bin/pdbedit@EXEEXT@: $(BINARY_PREREQS) $(PDBEDIT_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1423         @echo Linking $@
1424         @$(CC) $(FLAGS) -o $@ $(PDBEDIT_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1425                 @POPTLIBS@ $(PASSDB_LIBS) $(LDAP_LIBS) @LIBTALLOC_LIBS@ \
1426                 @LIBTDB_LIBS@ @WINBIND_LIBS@
1427
1428 bin/smbget@EXEEXT@: $(BINARY_PREREQS) $(SMBGET_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1429         @echo Linking $@
1430         @$(CC) $(FLAGS) -o $@ $(SMBGET_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1431                 @POPTLIBS@  $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) \
1432                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
1433
1434 bin/nmblookup@EXEEXT@: $(BINARY_PREREQS) $(NMBLOOKUP_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1435         @echo Linking $@
1436         @$(CC) $(FLAGS) -o $@ $(NMBLOOKUP_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1437                 @POPTLIBS@ $(LDAP_LIBS) @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1438
1439 bin/smbtorture@EXEEXT@: $(BINARY_PREREQS) $(SMBTORTURE_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1440         @echo Linking $@
1441         @$(CC) $(FLAGS) -o $@ $(SMBTORTURE_OBJ) $(LDFLAGS) $(DYNEXP) \
1442                 $(LIBS) $(KRB5LIBS) $(LDAP_LIBS) @POPTLIBS@ @LIBTALLOC_LIBS@ \
1443                 @LIBTDB_LIBS@
1444
1445 bin/talloctort@EXEEXT@: $(BINARY_PREREQS) $(TALLOCTORT_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1446         @echo Linking $@
1447         @$(CC) $(FLAGS) -o $@ $(TALLOCTORT_OBJ) $(LDFLAGS) \
1448                 $(DYNEXP) $(LIBS) $(LDAP_LIBS) @POPTLIBS@ \
1449                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1450
1451 bin/replacetort@EXEEXT@: $(REPLACETORT_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@
1452         @echo Linking $@
1453         @$(CC) $(FLAGS) @PIE_LDFLAGS@ -o $@ $(REPLACETORT_OBJ) $(LDFLAGS) \
1454                 $(DYNEXP) $(LIBS) @POPTLIBS@ @LIBTALLOC_LIBS@
1455
1456 bin/smbconftort@EXEEXT@: $(SMBCONFTORT_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1457         @echo Linking $@
1458         @$(CC) $(FLAGS) @PIE_LDFLAGS@ -o $@ $(SMBCONFTORT_OBJ) $(LDFLAGS) \
1459                 $(DYNEXP) $(LIBS) $(LDAP_LIBS) @POPTLIBS@ \
1460                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1461
1462 bin/masktest@EXEEXT@: $(BINARY_PREREQS) $(MASKTEST_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1463         @echo Linking $@
1464         @$(CC) $(FLAGS) -o $@ $(MASKTEST_OBJ) $(LDFLAGS) $(DYNEXP) \
1465                 $(LIBS) $(KRB5LIBS) $(LDAP_LIBS) @POPTLIBS@ \
1466                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1467
1468 bin/msgtest@EXEEXT@: $(BINARY_PREREQS) $(MSGTEST_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1469         @echo Linking $@
1470         @$(CC) $(FLAGS) -o $@ $(MSGTEST_OBJ) $(LDFLAGS) $(DYNEXP) \
1471                 $(LIBS) $(KRB5LIBS) $(LDAP_LIBS) @POPTLIBS@ \
1472                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1473
1474 bin/smbcacls@EXEEXT@: $(BINARY_PREREQS) $(SMBCACLS_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1475         @echo Linking $@
1476         @$(CC) $(FLAGS) -o $@ $(SMBCACLS_OBJ) $(DYNEXP) $(LDFLAGS) \
1477                 $(LIBS) @POPTLIBS@ $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) \
1478                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
1479
1480 bin/smbcquotas@EXEEXT@: $(BINARY_PREREQS) $(SMBCQUOTAS_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1481         @echo Linking $@
1482         @$(CC) $(FLAGS) -o $@ $(SMBCQUOTAS_OBJ) $(DYNEXP) $(LDFLAGS) \
1483                 $(LIBS) @POPTLIBS@ $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) \
1484                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
1485
1486 bin/eventlogadm@EXEEXT@: $(BINARY_PREREQS) $(EVTLOGADM_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1487         @echo Linking $@
1488         @$(CC) $(FLAGS) -o $@ $(EVTLOGADM_OBJ) $(DYNEXP) $(LDFLAGS) \
1489                 $(LIBS) $(LDAP_LIBS) @POPTLIBS@ @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1490
1491 bin/sharesec@EXEEXT@: $(BINARY_PREREQS) $(SHARESEC_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1492         @echo Linking $@
1493         @$(CC) $(FLAGS) -o $@ $(SHARESEC_OBJ) $(DYNEXP) $(LDFLAGS) \
1494                 $(LIBS) $(LDAP_LIBS) @POPTLIBS@ @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1495
1496 bin/locktest@EXEEXT@: $(BINARY_PREREQS) $(LOCKTEST_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1497         @echo Linking $@
1498         @$(CC) $(FLAGS) -o $@ $(LOCKTEST_OBJ) $(LDFLAGS) $(DYNEXP) \
1499                 $(LIBS) $(KRB5LIBS) $(LDAP_LIBS) @POPTLIBS@ \
1500                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1501
1502 bin/nsstest@EXEEXT@: $(BINARY_PREREQS) $(NSSTEST_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1503         @echo Linking $@
1504         @$(CC) $(FLAGS) -o $@ $(NSSTEST_OBJ) $(LDFLAGS) $(DYNEXP) \
1505                 $(LIBS) $(KRB5LIBS)  $(LDAP_LIBS) @POPTLIBS@ \
1506                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1507
1508 bin/pdbtest@EXEEXT@: $(BINARY_PREREQS) $(PDBTEST_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1509         @echo Linking $@
1510         @$(CC) $(FLAGS) -o $@ $(PDBTEST_OBJ) $(LDFLAGS) $(DYNEXP) \
1511                 $(LIBS) $(KRB5LIBS) $(LDAP_LIBS) $(PASSDB_LIBS) \
1512                 @POPTLIBS@ @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @LIBWBCLIENT_SHARED@
1513
1514 bin/vfstest@EXEEXT@: $(BINARY_PREREQS) $(VFSTEST_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1515         @echo Linking $@
1516         @$(CC) $(FLAGS) -o $@ $(VFSTEST_OBJ) $(LDFLAGS) $(TERMLDFLAGS) \
1517                 $(TERMLIBS) $(DYNEXP) $(PRINT_LIBS) $(AUTH_LIBS) \
1518                 $(ACL_LIBS) $(LIBS) @POPTLIBS@ $(KRB5LIBS) $(LDAP_LIBS) \
1519                 @SMBD_LIBS@ $(NSCD_LIBS) @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ \
1520                 @LIBWBCLIENT_SHARED@
1521
1522 bin/smbiconv@EXEEXT@: $(BINARY_PREREQS) $(SMBICONV_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1523         @echo Linking $@
1524         @$(CC) $(FLAGS) -o $@ $(SMBICONV_OBJ) $(LDFLAGS) $(TERMLDFLAGS) \
1525                 $(TERMLIBS) $(DYNEXP) $(LIBS) $(LDAP_LIBS) @POPTLIBS@ \
1526                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1527
1528 bin/log2pcap@EXEEXT@: $(BINARY_PREREQS) $(LOG2PCAP_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@
1529         @echo Linking $@
1530         @$(CC) $(FLAGS) -o $@ $(LOG2PCAP_OBJ) $(LDFLAGS) $(DYNEXP) \
1531                 @POPTLIBS@ $(LIBS) @LIBTALLOC_LIBS@
1532
1533 bin/locktest2@EXEEXT@: $(BINARY_PREREQS) $(LOCKTEST2_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1534         @echo Linking $@
1535         @$(CC) $(FLAGS) -o $@ $(LOCKTEST2_OBJ) $(LDFLAGS) $(DYNEXP) \
1536                 $(LIBS) $(KRB5LIBS) $(LDAP_LIBS) @POPTLIBS@ \
1537                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1538
1539 bin/ndrdump@EXEEXT@: $(BINARY_PREREQS) $(NDRDUMP_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1540         @echo Linking $@
1541         @$(CC) $(FLAGS) -o $@ $(NDRDUMP_OBJ) $(DYNEXP) $(LDFLAGS) $(LIBS) \
1542                 @POPTLIBS@ @LDAP_LIBS@ @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1543
1544 bin/debug2html@EXEEXT@: $(BINARY_PREREQS) $(DEBUG2HTML_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@
1545         @echo Linking $@
1546         @$(CC) $(FLAGS) -o $@ $(DEBUG2HTML_OBJ) $(LDFLAGS) $(DYNEXP) \
1547                 $(LIBS) @LIBTALLOC_LIBS@
1548
1549 bin/smbfilter@EXEEXT@: $(BINARY_PREREQS) $(SMBFILTER_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1550         @echo Linking $@
1551         @$(CC) $(FLAGS) -o $@ $(SMBFILTER_OBJ) $(LDFLAGS) $(LIBS) \
1552                 $(KRB5LIBS) $(LDAP_LIBS) @POPTLIBS@ \
1553                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
1554
1555 bin/ldbedit: $(BINARY_PREREQS) $(LDBEDIT_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1556         @echo Linking $@
1557         @$(CC) $(FLAGS) -o $@ $(LDBEDIT_OBJ) $(DYNEXP) $(LDFLAGS) \
1558                 $(LIBS) @POPTLIBS@ $(KRB5LIBS) $(UUID_LIBS) $(LDAP_LIBS) \
1559                 $(PASSDB_LIBS) $(TERMLDFLAGS) $(TERMLIBS) $(NSCD_LIBS) \
1560                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
1561
1562 bin/ldbsearch: $(BINARY_PREREQS) $(LDBSEARCH_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1563         @echo Linking $@
1564         @$(CC) $(FLAGS) -o $@ $(LDBSEARCH_OBJ) $(DYNEXP) $(LDFLAGS) \
1565                 $(LIBS) @POPTLIBS@ $(KRB5LIBS) $(UUID_LIBS) $(LDAP_LIBS) \
1566                 $(PASSDB_LIBS) $(TERMLDFLAGS) $(TERMLIBS) $(NSCD_LIBS) \
1567                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
1568
1569 bin/ldbadd: $(BINARY_PREREQS) $(LDBADD_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1570         @echo Linking $@
1571         @$(CC) $(FLAGS) -o $@ $(LDBADD_OBJ) $(DYNEXP) $(LDFLAGS) $(LIBS) \
1572                 @POPTLIBS@ $(KRB5LIBS) $(UUID_LIBS) $(LDAP_LIBS) \
1573                 $(PASSDB_LIBS) $(TERMLDFLAGS) $(TERMLIBS) $(NSCD_LIBS) \
1574                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
1575
1576 bin/ldbmodify: $(BINARY_PREREQS) $(LDBMODIFY_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1577         @echo Linking $@
1578         @$(CC) $(FLAGS) -o $@ $(LDBMODIFY_OBJ) $(DYNEXP) $(LDFLAGS) $(LIBS) \
1579                 @POPTLIBS@ $(KRB5LIBS) $(UUID_LIBS) $(LDAP_LIBS) \
1580                 $(PASSDB_LIBS) $(TERMLDFLAGS) $(TERMLIBS) $(NSCD_LIBS) \
1581                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
1582
1583 bin/ldbdel: $(BINARY_PREREQS) $(LDBDEL_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1584         @echo Linking $@
1585         @$(CC) $(FLAGS) -o $@ $(LDBDEL_OBJ) $(DYNEXP) $(LDFLAGS) $(LIBS) \
1586                 @POPTLIBS@ $(KRB5LIBS) $(UUID_LIBS) $(LDAP_LIBS) \
1587                 $(PASSDB_LIBS) $(TERMLDFLAGS) $(TERMLIBS) $(NSCD_LIBS) \
1588                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
1589
1590 $(LIBTALLOC_SHARED_TARGET): $(BINARY_PREREQS) $(LIBTALLOC_OBJ)
1591         @echo Linking shared library $@
1592         @$(SHLD_DSO) $(LIBTALLOC_OBJ) \
1593                 @SONAMEFLAG@`basename $@`.$(SONAME_VER)
1594         @ln -s -f `basename $@` $@.$(SONAME_VER)
1595
1596 $(LIBTALLOC_STATIC_TARGET): $(BINARY_PREREQS) $(LIBTALLOC_OBJ0)
1597         @echo Linking non-shared library $@
1598         @-$(AR) -rc $@ $(LIBTALLOC_OBJ0)
1599
1600 MKSYMS_SH = $(srcdir)/script/mksyms.sh
1601
1602 $(LIBTDB_SYMS): $(LIBTDB_HEADERS)
1603         @$(MKSYMS_SH) $(AWK) $@ $(LIBTDB_HEADERS)
1604
1605 $(LIBTDB_SHARED_TARGET): $(BINARY_PREREQS) $(LIBTDB_OBJ) $(LIBTDB_SYMS)
1606         @echo Linking shared library $@
1607         @$(SHLD_DSO) $(LIBTDB_OBJ) \
1608                 @SONAMEFLAG@`basename $@`.$(SONAME_VER)
1609         @ln -s -f `basename $@` $@.$(SONAME_VER)
1610
1611 $(LIBTDB_STATIC_TARGET): $(BINARY_PREREQS) $(LIBTDB_OBJ0)
1612         @echo Linking non-shared library $@
1613         @-$(AR) -rc $@ $(LIBTDB_OBJ0)
1614
1615 bin/libwbclient.@SHLIBEXT@: $(BINARY_PREREQS) $(LIBWBCLIENT_OBJ) @LIBTALLOC_SHARED@
1616         @echo Linking shared library $@
1617         @$(SHLD_DSO) @LIBTALLOC_LIBS@ $(LIBWBCLIENT_OBJ) \
1618                 @SONAMEFLAG@`basename $@`.$(SONAME_VER)
1619         @ln -s -f `basename $@` $@.$(SONAME_VER)
1620
1621 bin/libwbclient.a: $(BINARY_PREREQS) $(LIBWBCLIENT_OBJ0) $(WBCOMMON_OBJ)
1622         @echo Linking non-shared library $@
1623         @-$(AR) -rc $@ $(LIBWBCLIENT_OBJ0) $(WBCOMMON_OBJ)
1624
1625 bin/libaddns.@SHLIBEXT@: $(BINARY_PREREQS) $(LIBADDNS_OBJ) @LIBTALLOC_SHARED@
1626         @echo Linking shared library $@
1627         @$(SHLD_DSO) $(LIBADDNS_OBJ) $(LIBS) \
1628                 $(KRB5LIBS) $(UUID_LIBS) @LIBTALLOC_LIBS@ \
1629                 @SONAMEFLAG@`basename $@`.$(SONAME_VER)
1630
1631 bin/libaddns.a: $(BINARY_PREREQS) $(LIBADDNS_OBJ)
1632         @echo Linking non-shared library $@
1633         @-$(AR) -rc $@ $(LIBADDNS_OBJ)
1634
1635 $(LIBNETAPI_SHARED_TARGET): $(BINARY_PREREQS) $(LIBNETAPI_OBJ) @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1636         @echo Linking shared library $@
1637         @$(SHLD_DSO) $(LIBNETAPI_OBJ) \
1638                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @LIBWBCLIENT_SHARED@ $(LIBS) \
1639                 $(LDAP_LIBS) $(KRB5LIBS) $(NSCD_LIBS) \
1640                 @SONAMEFLAG@`basename $@`.$(SONAME_VER)
1641         @ln -s -f `basename $@` $@.$(SONAME_VER)
1642
1643 $(LIBNETAPI_STATIC_TARGET): $(BINARY_PREREQS) $(LIBNETAPI_OBJ1)
1644         @echo Linking non-shared library $@
1645         @-$(AR) -rc $@ $(LIBNETAPI_OBJ1)
1646
1647 bin/libsmbclient.@SHLIBEXT@: $(BINARY_PREREQS) $(LIBSMBCLIENT_OBJ) @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1648         @echo Linking shared library $@
1649         @$(SHLD_DSO) $(LIBSMBCLIENT_OBJ) \
1650                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @LIBWBCLIENT_SHARED@ $(LIBS) \
1651                 $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) \
1652                 @SONAMEFLAG@`basename $@`.$(SONAME_VER)
1653
1654 bin/libsmbclient.a: $(BINARY_PREREQS) $(LIBSMBCLIENT_OBJ0)
1655         @echo Linking non-shared library $@
1656         @-$(AR) -rc $@ $(LIBSMBCLIENT_OBJ0)
1657
1658 bin/libsmbsharemodes.@SHLIBEXT@: $(BINARY_PREREQS) $(LIBSMBSHAREMODES_OBJ) @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1659         @echo Linking shared library $@
1660         @$(SHLD_DSO) $(LIBSMBSHAREMODES_OBJ) \
1661                 $(LIBS) @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ \
1662                 $(KRB5LIBS) $(LDAP_LIBS) \
1663                 @SONAMEFLAG@`basename $@`.$(SONAME_VER)
1664
1665 bin/libsmbsharemodes.a: $(BINARY_PREREQS) $(LIBSMBSHAREMODES_OBJ)
1666         @echo Linking non-shared library $@
1667         @-$(AR) -rc $@ $(LIBSMBSHAREMODES_OBJ)
1668
1669 # This is probably wrong for anything other than the GNU linker.
1670 bin/libbigballofmud.@SHLIBEXT@: $(BINARY_PREREQS) $(LIBBIGBALLOFMUD_OBJ) @LIBTALLOC_SHARED@
1671         @echo Linking shared library $@
1672         @$(SHLD) $(LDSHFLAGS) -o $@ $(LIBBIGBALLOFMUD_OBJ) \
1673                 $(LIBS) @LIBTALLOC_LIBS@ \
1674                 $(PASSDB_LIBS) $(IDMAP_LIBS) $(KRB5LIBS) $(LDAP_LIBS) \
1675                 @SONAMEFLAG@`basename $@`.$(LIBBIGBALLOFMUD_MAJOR)
1676         ln -snf libbigballofmud.so bin/libbigballofmud.so.0
1677
1678 # It would be nice to build a static bigballofmud too, but when I try
1679 # I get linker errors about dl_open and similar things.  I'm not sure if
1680 # it can be fixed or if they just can't be called from a static
1681 # library.
1682
1683 libtalloc: $(LIBTALLOC)
1684 libtdb: $(LIBTDB)
1685 libsmbclient: $(LIBSMBCLIENT)
1686 libsmbsharemodes: $(LIBSMBSHAREMODES)
1687 libaddns: $(LIBADDNS)
1688 libwbclient: $(LIBWBCLIENT)
1689 libnetapi: $(LIBNETAPI)
1690
1691 # Linker command to link a RPC, VFS, AUTH, CHARSET or PASSDB module.
1692 SHLD_MODULE = $(SHLD) $(LDSHFLAGS) $(MODULE_EXPORTS) \
1693               -o $@ @SONAMEFLAG@`basename $@`
1694
1695 bin/librpc_lsarpc.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_LSA_OBJ)
1696         @echo "Linking $@"
1697         @$(SHLD_MODULE) $(RPC_LSA_OBJ)
1698
1699 bin/librpc_samr.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_SAMR_OBJ)
1700         @echo "Linking $@"
1701         @$(SHLD_MODULE) $(RPC_SAMR_OBJ)
1702
1703 bin/librpc_srvsvc.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_SVC_OBJ)
1704         @echo "Linking $@"
1705         @$(SHLD_MODULE) $(RPC_SVC_OBJ)
1706
1707 bin/librpc_svcctl.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_SVCCTL_OBJ)
1708         @echo "Linking $@"
1709         @$(SHLD_MODULE) $(RPC_SVCCTL_OBJ)
1710
1711 bin/librpc_ntsvcs.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_NTSVCS_OBJ)
1712         @echo "Linking $@"
1713         @$(SHLD_MODULE) $(RPC_NTSVCS_OBJ)
1714
1715 bin/librpc_wkssvc.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_WKS_OBJ)
1716         @echo "Linking $@"
1717         @$(SHLD_MODULE) $(RPC_WKS_OBJ)
1718
1719 bin/librpc_NETLOGON.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_NETLOG_OBJ)
1720         @echo "Linking $@"
1721         @$(SHLD_MODULE) $(RPC_NETLOG_OBJ)
1722
1723 bin/librpc_winreg.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_REG_OBJ)
1724         @echo "Linking $@"
1725         @$(SHLD_MODULE) $(RPC_REG_OBJ)
1726
1727 bin/librpc_initshutdown.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_INITSHUTDOWN_OBJ)
1728         @echo "Linking $@"
1729         @$(SHLD_MODULE) $(RPC_INITSHUTDOWN_OBJ)
1730
1731 bin/librpc_dssetup.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_DSSETUP_OBJ)
1732         @echo "Linking $@"
1733         @$(SHLD_MODULE) $(RPC_DSSETUP_OBJ)
1734
1735 bin/librpc_spoolss.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_SPOOLSS_OBJ)
1736         @echo "Linking $@"
1737         @$(SHLD_MODULE) $(RPC_SPOOLSS_OBJ)
1738
1739 bin/librpc_eventlog.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_EVENTLOG_OBJ)
1740         @echo "Linking $@"
1741         @$(SHLD_MODULE) $(RPC_EVENTLOG_OBJ)
1742
1743 bin/librpc_netdfs.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_DFS_OBJ)
1744         @echo "Linking $@"
1745         @$(SHLD_MODULE) $(RPC_DFS_OBJ)
1746
1747 bin/librpc_echo.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_ECHO_OBJ)
1748         @echo "Linking $@"
1749         @$(SHLD_MODULE) $(RPC_ECHO_OBJ)
1750
1751 bin/winbindd@EXEEXT@: $(BINARY_PREREQS) $(WINBINDD_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1752         @echo "Linking $@"
1753         @$(CC) $(FLAGS) -o $@ $(WINBINDD_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1754                 @POPTLIBS@ $(KRB5LIBS) $(LDAP_LIBS) \
1755                 $(PASSDB_LIBS) @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
1756
1757 bin/vlp@EXEEXT@: $(BINARY_PREREQS) $(VLP_OBJ) @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
1758         @echo "Linking $@"
1759         @$(CC) $(FLAGS) -o $@ $(VLP_OBJ) $(LDFLAGS) $(DYNEXP) \
1760                 $(TERMLDFLAGS) $(TERMLIBS) $(LIBS) @POPTLIBS@ \
1761                 $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) \
1762                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @LIBWBCLIENT_SHARED@
1763
1764 @WINBIND_NSS@: $(BINARY_PREREQS) $(WINBIND_NSS_OBJ)
1765         @echo "Linking $@"
1766         @$(SHLD) $(WINBIND_NSS_LDSHFLAGS) -o $@ $(WINBIND_NSS_OBJ) \
1767                 @WINBIND_NSS_EXTRA_LIBS@ @WINBIND_NSS_PTHREAD@ \
1768                 @SONAMEFLAG@`basename $@`@NSSSONAMEVERSIONSUFFIX@
1769
1770 @WINBIND_WINS_NSS@: $(BINARY_PREREQS) $(WINBIND_WINS_NSS_OBJ) @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
1771         @echo "Linking $@"
1772         @$(SHLD) $(LDSHFLAGS) -o $@ $(WINBIND_WINS_NSS_OBJ) \
1773                 $(LDAP_LIBS) $(KRB5LIBS) $(LIBS) @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ \
1774                 @SONAMEFLAG@`basename $@`@NSSSONAMEVERSIONSUFFIX@
1775
1776 bin/winbind_krb5_locator.@SHLIBEXT@: $(BINARY_PREREQS) $(WINBIND_KRB5_LOCATOR_OBJ)
1777         @echo "Linking $@"
1778         @$(SHLD) $(LDSHFLAGS) -o $@ $(WINBIND_KRB5_LOCATOR_OBJ) \
1779                 @SONAMEFLAG@`basename $@`
1780
1781 bin/pam_winbind.@SHLIBEXT@: $(BINARY_PREREQS) $(PAM_WINBIND_OBJ)
1782         @echo "Linking shared library $@"
1783         @$(SHLD) $(LDSHFLAGS) -o $@ $(PAM_WINBIND_OBJ) -lpam @INIPARSERLIBS@ \
1784                 @PAM_WINBIND_EXTRA_LIBS@ @SONAMEFLAG@`basename $@`
1785
1786 bin/builtin.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_BUILTIN_OBJ)
1787         @echo "Building plugin $@"
1788         @$(SHLD_MODULE) $(AUTH_BUILTIN_OBJ)
1789
1790 bin/domain.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_DOMAIN_OBJ)
1791         @echo "Building plugin $@"
1792         @$(SHLD_MODULE) $(AUTH_DOMAIN_OBJ)
1793
1794 bin/script.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_SCRIPT_OBJ)
1795         @echo "Building plugin $@"
1796         @$(SHLD_MODULE) $(AUTH_SCRIPT_OBJ)
1797
1798 bin/smbserver.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_SERVER_OBJ)
1799         @echo "Building plugin $@"
1800         @$(SHLD_MODULE) $(AUTH_SERVER_OBJ)
1801
1802 bin/winbind.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_WINBIND_OBJ)
1803         @echo "Building plugin $@"
1804         @$(SHLD_MODULE) $(AUTH_WINBIND_OBJ)
1805
1806 bin/unix.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_UNIX_OBJ)
1807         @echo "Building plugin $@"
1808         @$(SHLD_MODULE) $(AUTH_UNIX_OBJ)
1809
1810 bin/sam.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_SAM_OBJ)
1811         @echo "Building plugin $@"
1812         @$(SHLD_MODULE) $(AUTH_SAM_OBJ)
1813
1814 bin/ldapsam.@SHLIBEXT@: $(BINARY_PREREQS) passdb/pdb_ldap.o passdb/pdb_nds.o
1815         @echo "Building plugin $@"
1816         @$(SHLD_MODULE) passdb/pdb_ldap.o passdb/pdb_nds.o $(LDAP_LIBS)
1817
1818 bin/tdbsam.@SHLIBEXT@: $(BINARY_PREREQS) passdb/pdb_tdb.o
1819         @echo "Building plugin $@"
1820         @$(SHLD_MODULE) passdb/pdb_tdb.o
1821
1822 bin/smbpasswd.@SHLIBEXT@: $(BINARY_PREREQS) passdb/pdb_smbpasswd.o
1823         @echo "Building plugin $@"
1824         @$(SHLD_MODULE) passdb/pdb_smbpasswd.o
1825
1826 bin/rid.@SHLIBEXT@: $(BINARY_PREREQS) winbindd/idmap_rid.o
1827         @echo "Building plugin $@"
1828         @$(SHLD_MODULE) winbindd/idmap_rid.o
1829
1830 bin/ad.@SHLIBEXT@: $(BINARY_PREREQS) winbindd/idmap_ad.o
1831         @echo "Building plugin $@"
1832         @$(SHLD_MODULE) winbindd/idmap_ad.o
1833
1834 bin/tdb2.@SHLIBEXT@: $(BINARY_PREREQS) winbindd/idmap_tdb2.o
1835         @echo "Building plugin $@"
1836         @$(SHLD_MODULE) winbindd/idmap_tdb2.o
1837
1838 bin/ldap.@SHLIBEXT@: $(BINARY_PREREQS) winbindd/idmap_ldap.o
1839         @echo "Building plugin $@"
1840         @$(SHLD_MODULE) winbindd/idmap_ldap.o
1841
1842 bin/weird.@SHLIBEXT@: $(BINARY_PREREQS) $(DEVEL_HELP_WEIRD_OBJ)
1843         @echo "Building plugin $@"
1844         @$(SHLD_MODULE) $(DEVEL_HELP_WEIRD_OBJ)
1845
1846 bin/CP850.@SHLIBEXT@: $(BINARY_PREREQS) $(CP850_OBJ)
1847         @echo "Building plugin $@"
1848         @$(SHLD_MODULE) $(CP850_OBJ)
1849
1850 bin/CP437.@SHLIBEXT@: $(BINARY_PREREQS) $(CP437_OBJ)
1851         @echo "Building plugin $@"
1852         @$(SHLD_MODULE) $(CP437_OBJ)
1853
1854 bin/macosxfs.@SHLIBEXT@: $(BINARY_PREREQS) $(CHARSET_MACOSXFS_OBJ)
1855         @echo "Building plugin $@"
1856         @$(SHLD_MODULE) $(CHARSET_MACOSXFS_OBJ) -framework CoreFoundation
1857
1858 # NOTE, there is no build rule for a dynamic default VFS module because
1859 # this one MUST MUST MUST be built statically.
1860
1861 bin/audit.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_AUDIT_OBJ)
1862         @echo "Building plugin $@"
1863         @$(SHLD_MODULE) $(VFS_AUDIT_OBJ)
1864
1865 bin/extd_audit.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_EXTD_AUDIT_OBJ)
1866         @echo "Building plugin $@"
1867         @$(SHLD_MODULE) $(VFS_EXTD_AUDIT_OBJ)
1868
1869 bin/full_audit.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_FULL_AUDIT_OBJ)
1870         @echo "Building plugin $@"
1871         @$(SHLD_MODULE) $(VFS_FULL_AUDIT_OBJ)
1872
1873 bin/recycle.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_RECYCLE_OBJ)
1874         @echo "Building plugin $@"
1875         @$(SHLD_MODULE) $(VFS_RECYCLE_OBJ)
1876
1877 bin/netatalk.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_NETATALK_OBJ)
1878         @echo "Building plugin $@"
1879         @$(SHLD_MODULE) $(VFS_NETATALK_OBJ)
1880
1881 bin/fake_perms.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_FAKE_PERMS_OBJ)
1882         @echo "Building plugin $@"
1883         @$(SHLD_MODULE) $(VFS_FAKE_PERMS_OBJ)
1884
1885 bin/default_quota.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_DEFAULT_QUOTA_OBJ)
1886         @echo "Building plugin $@"
1887         @$(SHLD_MODULE) $(VFS_DEFAULT_QUOTA_OBJ)
1888
1889 bin/readonly.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_READONLY_OBJ)
1890         @echo "Building plugin $@"
1891         @$(SHLD_MODULE) $(VFS_READONLY_OBJ)
1892
1893 bin/shadow_copy.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_SHADOW_COPY_OBJ)
1894         @echo "Building plugin $@"
1895         @$(SHLD_MODULE) $(VFS_SHADOW_COPY_OBJ)
1896
1897 bin/shadow_copy2.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_SHADOW_COPY2_OBJ)
1898         @echo "Building plugin $@"
1899         @$(SHLD_MODULE) $(VFS_SHADOW_COPY2_OBJ)
1900
1901 bin/syncops.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_SYNCOPS_OBJ)
1902         @echo "Building plugin $@"
1903         @$(SHLD_MODULE) $(VFS_SYNCOPS_OBJ)
1904
1905 bin/cap.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_CAP_OBJ)
1906         @echo "Building plugin $@"
1907         @$(SHLD_MODULE) $(VFS_CAP_OBJ)
1908
1909 bin/expand_msdfs.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_EXPAND_MSDFS_OBJ)
1910         @echo "Building plugin $@"
1911         @$(SHLD_MODULE) $(VFS_EXPAND_MSDFS_OBJ)
1912
1913 bin/afsacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_AFSACL_OBJ)
1914         @echo "Building plugin $@"
1915         @$(SHLD_MODULE) $(VFS_AFSACL_OBJ)
1916
1917 bin/xattr_tdb.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_XATTR_TDB_OBJ)
1918         @echo "Building plugin $@"
1919         @$(SHLD_MODULE) $(VFS_XATTR_TDB_OBJ)
1920
1921 bin/posixacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_POSIXACL_OBJ)
1922         @echo "Building plugin $@"
1923         @$(SHLD_MODULE) $(VFS_POSIXACL_OBJ)
1924
1925 bin/aixacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_AIXACL_OBJ)
1926         @echo "Building plugin $@"
1927         @$(SHLD_MODULE) $(VFS_AIXACL_OBJ)
1928
1929 bin/aixacl2.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_AIXACL2_OBJ)
1930         @echo "Building plugin $@"
1931         @$(SHLD_MODULE) $(VFS_AIXACL2_OBJ)
1932
1933 bin/solarisacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_SOLARISACL_OBJ)
1934         @echo "Building plugin $@"
1935         @$(SHLD_MODULE) $(VFS_SOLARISACL_OBJ)
1936
1937 bin/zfsacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_ZFSACL_OBJ)
1938         @echo "Building plugin $@"
1939         @$(SHLD_MODULE) $(VFS_ZFSACL_OBJ)
1940
1941 bin/irixacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_IRIXACL_OBJ)
1942         @echo "Building plugin $@"
1943         @$(SHLD_MODULE) $(VFS_IRIXACL_OBJ)
1944
1945 bin/hpuxacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_HPUXACL_OBJ)
1946         @echo "Building plugin $@"
1947         @$(SHLD_MODULE) $(VFS_HPUXACL_OBJ)
1948
1949 bin/tru64acl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_TRU64ACL_OBJ)
1950         @echo "Building plugin $@"
1951         @$(SHLD_MODULE) $(VFS_TRU64ACL_OBJ)
1952
1953 bin/catia.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_CATIA_OBJ)
1954         @echo "Building plugin $@"
1955         @$(SHLD_MODULE) $(VFS_CATIA_OBJ)
1956
1957 bin/streams_xattr.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_STREAMS_XATTR_OBJ)
1958         @echo "Building plugin $@"
1959         @$(SHLD_MODULE) $(VFS_STREAMS_XATTR_OBJ)
1960
1961 bin/streams_depot.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_STREAMS_DEPOT_OBJ)
1962         @echo "Building plugin $@"
1963         @$(SHLD_MODULE) $(VFS_STREAMS_DEPOT_OBJ)
1964
1965 bin/cacheprime.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_CACHEPRIME_OBJ)
1966         @echo "Building plugin $@"
1967         @$(SHLD_MODULE) $(VFS_CACHEPRIME_OBJ)
1968
1969 bin/prealloc.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_PREALLOC_OBJ)
1970         @echo "Building plugin $@"
1971         @$(SHLD_MODULE) $(VFS_PREALLOC_OBJ)
1972
1973 bin/commit.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_COMMIT_OBJ)
1974         @echo "Building plugin $@"
1975         @$(SHLD_MODULE) $(VFS_COMMIT_OBJ)
1976
1977 bin/gpfs.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_GPFS_OBJ)
1978         @echo "Building plugin $@"
1979         @$(SHLD_MODULE) $(VFS_GPFS_OBJ)
1980
1981 bin/notify_fam.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_NOTIFY_FAM_OBJ)
1982         @echo "Building plugin $@"
1983         @$(SHLD_MODULE) $(VFS_NOTIFY_FAM_OBJ) @SMB_FAM_LIBS@
1984
1985 bin/readahead.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_READAHEAD_OBJ)
1986         @echo "Building plugin $@"
1987         @$(SHLD_MODULE) $(VFS_READAHEAD_OBJ)
1988
1989 bin/tsmsm.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_TSMSM_OBJ)
1990         @echo "Building plugin $@"
1991         @$(SHLD_MODULE) $(VFS_TSMSM_OBJ)
1992
1993 bin/fileid.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_FILEID_OBJ)
1994         @echo "Building plugin $@"
1995         @$(SHLD_MODULE) $(VFS_FILEID_OBJ)
1996
1997 bin/aio_fork.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_AIO_FORK_OBJ)
1998         @echo "Building plugin $@"
1999         @$(SHLD_MODULE) $(VFS_AIO_FORK_OBJ)
2000
2001 bin/registry.@SHLIBEXT@: $(BINARY_PREREQS) libgpo/gpext/registry.o
2002         @echo "Building plugin $@"
2003         @$(SHLD_MODULE) libgpo/gpext/registry.o
2004
2005 bin/scripts.@SHLIBEXT@: $(BINARY_PREREQS) libgpo/gpext/scripts.o
2006         @echo "Building plugin $@"
2007         @$(SHLD_MODULE) libgpo/gpext/scripts.o
2008
2009 #########################################################
2010 ## IdMap NSS plugins
2011
2012 ## None here right now
2013 #########################################################
2014
2015 bin/wbinfo@EXEEXT@: $(BINARY_PREREQS) $(WBINFO_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
2016         @echo Linking $@
2017         @$(CC) $(FLAGS) -o $@ $(LDFLAGS) $(WBINFO_OBJ) $(DYNEXP) $(LIBS) \
2018                 $(LDAP_LIBS) @POPTLIBS@ @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ \
2019                 @WINBIND_LIBS@
2020
2021 bin/ntlm_auth@EXEEXT@: $(BINARY_PREREQS) $(NTLM_AUTH_OBJ) $(PARAM_OBJ) \
2022         $(LIB_NONSMBD_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @LIBWBCLIENT_SHARED@
2023         @echo Linking $@
2024         @$(CC) $(FLAGS) -o $@ $(LDFLAGS) $(DYNEXP) $(NTLM_AUTH_OBJ) \
2025                 $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) $(LIBS) \
2026                 @POPTLIBS@ $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) \
2027                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
2028
2029 bin/pam_smbpass.@SHLIBEXT@: $(BINARY_PREREQS) $(PAM_SMBPASS_OBJ) @LIBTALLOC_SHARED@ @LIBWBCLIENT_SHARED@ @LIBTDB_SHARED@
2030         @echo "Linking shared library $@"
2031         @$(SHLD) $(LDSHFLAGS) -o $@ $(PAM_SMBPASS_OBJ) -lpam $(DYNEXP) \
2032                 $(LIBS) $(LDAP_LIBS) $(KRB5LIBS) $(NSCD_LIBS) \
2033                 @LIBTALLOC_LIBS@ @LIBTDB_LIBS@ @WINBIND_LIBS@
2034
2035 bin/tdbbackup@EXEEXT@: $(BINARY_PREREQS) $(TDBBACKUP_OBJ) @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
2036         @echo Linking $@
2037         @$(CC) $(FLAGS) -o $@ $(LDFLAGS) $(TDBBACKUP_OBJ) $(DYNEXP) \
2038                 $(LIBS) @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
2039
2040 bin/tdbtool@EXEEXT@: $(BINARY_PREREQS) $(TDBTOOL_OBJ) @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
2041         @echo Linking $@
2042         @$(CC) $(FLAGS) -o $@ $(LDFLAGS) $(TDBTOOL_OBJ) $(DYNEXP) \
2043                 $(LIBS) @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
2044
2045 bin/tdbdump@EXEEXT@: $(BINARY_PREREQS) $(TDBDUMP_OBJ) @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
2046         @echo Linking $@
2047         @$(CC) $(FLAGS) -o $@ $(LDFLAGS) $(TDBDUMP_OBJ) $(DYNEXP) \
2048                 $(LIBS) @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
2049
2050 bin/tdbtorture@EXEEXT@: $(BINARY_PREREQS) $(TDBTORTURE_OBJ) @LIBTALLOC_SHARED@ @LIBTDB_SHARED@
2051         @echo Linking $@
2052         @$(CC) $(FLAGS) -o $@ $(LDFLAGS) $(TDBTORTURE_OBJ) $(DYNEXP) \
2053                 $(LIBS) @LIBTALLOC_LIBS@ @LIBTDB_LIBS@
2054
2055 bin/t_strcmp@EXEEXT@: $(BINARY_PREREQS) @LIBTALLOC_SHARED@ bin/libbigballofmud.@SHLIBEXT@ torture/t_strcmp.o
2056         $(CC) $(FLAGS) -o $@ $(DYNEXP) $(LIBS) @LIBTALLOC_LIBS@ \
2057                 torture/t_strcmp.o -L ./bin -lbigballofmud
2058
2059 bin/t_strstr@EXEEXT@: $(BINARY_PREREQS) @LIBTALLOC_SHARED@ bin/libbigballofmud.@SHLIBEXT@ torture/t_strstr.o
2060         $(CC) $(FLAGS) -o $@ $(DYNEXP) $(LIBS) @LIBTALLOC_LIBS@ \
2061                 torture/t_strstr.o -L ./bin -lbigballofmud
2062
2063 bin/t_strappend@EXEEXT@: $(BINARY_PREREQS) @LIBTALLOC_SHARED@ bin/libbigballofmud.@SHLIBEXT@ torture/t_strappend.o
2064         $(CC) $(FLAGS) -o $@ $(DYNEXP) $(LIBS) @LIBTALLOC_LIBS@ \
2065                 torture/t_strappend.o -L ./bin -lbigballofmud
2066
2067 bin/t_stringoverflow@EXEEXT@: $(BINARY_PREREQS) bin/libbigballofmud.@SHLIBEXT@ torture/t_stringoverflow.o
2068         $(CC) $(FLAGS) -o $@ $(DYNEXP) torture/t_stringoverflow.o \
2069                 -L./bin -lbigballofmud
2070
2071 bin/timelimit@EXEEXT@: script/tests/timelimit.o
2072         @echo Linking $@
2073         @$(CC) $(FLAGS) -o $@ $(DYNEXP) script/tests/timelimit.o
2074
2075 install: installservers installbin @INSTALL_CIFSMOUNT@ @INSTALL_CIFSSPNEGO@ installman \
2076                 installscripts installdat installmodules @SWAT_INSTALL_TARGETS@ \
2077                 installlibtalloc \
2078                 installlibtdb \
2079                 @INSTALL_LIBSMBCLIENT@ @INSTALL_PAM_MODULES@ \
2080                 @INSTALL_LIBSMBSHAREMODES@ @INSTALL_LIBWBCLIENT@ installlibnetapi
2081
2082 install-everything: install installmodules
2083
2084 # DESTDIR is used here to prevent packagers wasting their time
2085 # duplicating the Makefile. Remove it and you will have the privelege
2086 # of package each samba release for muliple versions of multiple
2087 # distributions and operating systems, or at least supplying patches
2088 # to all the packaging files required for this, prior to committing
2089 # the removal of DESTDIR. Do not remove it even though you think it
2090 # is not used
2091
2092 installdirs:
2093         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(BINDIR) $(SBINDIR) $(LIBDIR) $(VARDIR) $(PRIVATEDIR) $(PIDDIR) $(LOCKDIR) $(MANDIR)
2094
2095 installservers: all installdirs
2096         @$(SHELL) script/installbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(SBINDIR) $(SBIN_PROGS)
2097
2098 installbin: all installdirs
2099         @$(SHELL) script/installbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(BINDIR) $(BIN_PROGS)
2100
2101 installcifsmount: @CIFSMOUNT_PROGS@
2102         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(ROOTSBINDIR)
2103         @$(SHELL) script/installbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(ROOTSBINDIR) @CIFSMOUNT_PROGS@
2104
2105 installcifsspnego: @CIFSSPNEGO_PROGS@
2106         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(ROOTSBINDIR)
2107         @$(SHELL) script/installbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(ROOTSBINDIR) @CIFSSPNEGO_PROGS@
2108
2109 # Some symlinks are required for the 'probing' of modules.
2110 # This mechanism should go at some point..
2111 installmodules: modules installdirs
2112         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(VFSLIBDIR) $(VFS_MODULES)
2113         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(PDBLIBDIR) $(PDB_MODULES)
2114         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(RPCLIBDIR) $(RPC_MODULES)
2115         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(IDMAPLIBDIR) $(IDMAP_MODULES)
2116         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(NSSINFOLIBDIR) $(NSS_INFO_MODULES)
2117         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(CHARSETLIBDIR) $(CHARSET_MODULES)
2118         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(AUTHLIBDIR) $(AUTH_MODULES)
2119         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(GPEXTLIBDIR) $(GPEXT_MODULES)
2120         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(PDBLIBDIR) ldapsam.@SHLIBEXT@ NDS_ldapsam.@SHLIBEXT@
2121         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(PDBLIBDIR) ldapsam.@SHLIBEXT@ NDS_ldapsam_compat.@SHLIBEXT@
2122         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(PDBLIBDIR) ldapsam.@SHLIBEXT@ ldapsam_compat.@SHLIBEXT@
2123         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(AUTHLIBDIR) rhosts.@SHLIBEXT@ hostsequiv.@SHLIBEXT@
2124         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(AUTHLIBDIR) sam.@SHLIBEXT@ sam_ignoredomain.@SHLIBEXT@
2125         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(AUTHLIBDIR) domain.@SHLIBEXT@ trustdomain.@SHLIBEXT@ ntdomain.@SHLIBEXT@
2126         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(AUTHLIBDIR) builtin.@SHLIBEXT@ guest.@SHLIBEXT@ fixed_challenge.@SHLIBEXT@ name_to_ntstatus.@SHLIBEXT@
2127         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(NSSINFOLIBDIR) ../idmap/ad.@SHLIBEXT@ rfc2307.@SHLIBEXT@ sfu.@SHLIBEXT@ sfu20.@SHLIBEXT@
2128
2129 installscripts: installdirs
2130         @$(SHELL) $(srcdir)/script/installscripts.sh $(INSTALLPERMS_BIN) $(DESTDIR)$(BINDIR) $(SCRIPTS)
2131
2132 installdat: installdirs
2133         @$(SHELL) $(srcdir)/script/installdat.sh $(DESTDIR) $(CODEPAGEDIR) $(srcdir)
2134
2135 installmsg: installdirs
2136         @$(SHELL) $(srcdir)/script/installmsg.sh $(DESTDIR) $(CODEPAGEDIR) $(srcdir)
2137
2138 installswat: installdirs installmsg
2139         @$(SHELL) $(srcdir)/script/installswat.sh $(DESTDIR) $(SWATDIR) $(srcdir)
2140
2141 installclientlib: installdirs libsmbclient
2142         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2143         -$(INSTALLLIBCMD_SH) bin/libsmbclient.@SHLIBEXT@ $(DESTDIR)$(LIBDIR)
2144         -$(INSTALLLIBCMD_A) bin/libsmbclient.a $(DESTDIR)$(LIBDIR)
2145         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) ${prefix}/include
2146         -$(INSTALLCMD) -m $(INSTALLPERMS_DATA) $(srcdir)/include/libsmbclient.h $(DESTDIR)${prefix}/include
2147
2148 installlibtalloc: installdirs libtalloc
2149         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2150         -$(INSTALLLIBCMD_SH) $(LIBTALLOC_SHARED_TARGET) $(DESTDIR)$(LIBDIR)
2151         -$(INSTALLLIBCMD_A) $(LIBTALLOC_STATIC_TARGET) $(DESTDIR)$(LIBDIR)
2152         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) ${prefix}/include
2153         -$(INSTALLCMD) -m $(INSTALLPERMS_DATA) $(srcdir)/@tallocdir@/talloc.h $(DESTDIR)${prefix}/include
2154
2155 installlibtdb: installdirs libtdb
2156         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2157         -$(INSTALLLIBCMD_SH) $(LIBTDB_SHARED_TARGET) $(DESTDIR)$(LIBDIR)
2158         -$(INSTALLLIBCMD_A) $(LIBTDB_STATIC_TARGET) $(DESTDIR)$(LIBDIR)
2159         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) ${prefix}/include
2160         -$(INSTALLCMD) -m $(INSTALLPERMS_DATA) $(LIBTDB_HEADERS) $(DESTDIR)${prefix}/include
2161
2162 installlibsmbsharemodes: installdirs libsmbsharemodes
2163         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2164         -$(INSTALLLIBCMD_SH) bin/libsmbsharemodes.@SHLIBEXT@ $(DESTDIR)$(LIBDIR)
2165         -$(INSTALLLIBCMD_A) bin/libsmbsharemodes.a $(DESTDIR)$(LIBDIR)
2166         -$(INSTALLCMD) -m $(INSTALLPERMS_DATA) $(srcdir)/include/smb_share_modes.h $(DESTDIR)${prefix}/include
2167
2168 installlibaddns: installdirs libaddns
2169         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2170         -$(INSTALLLIBCMD_SH) bin/libaddns.@SHLIBEXT@ $(DESTDIR)$(LIBDIR)
2171         -$(INSTALLLIBCMD_A) bin/libaddns.a $(DESTDIR)$(LIBDIR)
2172
2173 installlibwbclient: installdirs libwbclient
2174         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2175         -$(INSTALLLIBCMD_SH) bin/libwbclient.@SHLIBEXT@ $(DESTDIR)$(LIBDIR)
2176         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) ${prefix}/include
2177         -$(INSTALLCMD) -m $(INSTALLPERMS_DATA) $(srcdir)/nsswitch/libwbclient/wbclient.h $(DESTDIR)${prefix}/include
2178
2179 installlibnetapi: installdirs libnetapi
2180         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2181         -$(INSTALLLIBCMD_SH) $(LIBNETAPI_SHARED_TARGET) $(DESTDIR)$(LIBDIR)
2182         -$(INSTALLLIBCMD_A) $(LIBNETAPI_STATIC_TARGET) $(DESTDIR)$(LIBDIR)
2183         -$(INSTALLCMD) -m $(INSTALLPERMS_DATA) $(srcdir)/lib/netapi/netapi.h $(DESTDIR)${prefix}/include
2184
2185 installpammodules: $(PAM_MODULES)
2186         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(PAMMODULESDIR)
2187         @for module in $(PAM_MODULES); do \
2188                 echo "Installing module $${module} as $(DESTDIR)/$(PAMMODULESDIR)/$${module}.@SHLIBEXT@ "; \
2189                 $(INSTALLCMD) -m $(INSTALLPERMS_BIN) bin/$${module}.@SHLIBEXT@ \
2190                         "$(DESTDIR)/$(PAMMODULESDIR)"; \
2191         done
2192
2193 # revert to the previously installed version
2194 revert:
2195         @$(SHELL) $(srcdir)/script/revert.sh $(SBINDIR) $(SBIN_PROGS)
2196         @$(SHELL) $(srcdir)/script/revert.sh $(BINDIR) $(BIN_PROGS) $(SCRIPTS)
2197
2198 installman: installdirs
2199         @$(SHELL) $(srcdir)/script/installman.sh $(DESTDIR)$(MANDIR) $(srcdir) C "@ROFF@"
2200
2201 .PHONY: showlayout
2202
2203 showlayout:
2204         @echo "Samba will be installed into:"
2205         @echo "  prefix:      $(prefix)"
2206         @echo "  bindir:      $(BINDIR)"
2207         @echo "  sbindir:     $(SBINDIR)"
2208         @echo "  libdir:      $(LIBDIR)"
2209         @echo "  vardir:      $(VARDIR)"
2210         @echo "  mandir:      $(MANDIR)"
2211         @echo "  privatedir:  $(PRIVATE_DIR)"
2212         @echo "  configdir:   $(CONFIGDIR)"
2213         @echo "  lockdir:     $(LOCKDIR)"
2214         @echo "  piddir:      $(PIDDIR)"
2215         @echo "  swatdir:     $(SWATDIR)"
2216
2217
2218 uninstall: uninstallman uninstallservers uninstallbin @UNINSTALL_CIFSMOUNT@ @UNINSTALL_CIFSSPNEGO@ uninstallscripts uninstalldat uninstallswat uninstallmodules uninstalllibtalloc uninstalllibtdb @UNINSTALL_LIBSMBCLIENT@ @UNINSTALL_PAM_MODULES@ @UNINSTALL_LIBSMBSHAREMODES@ uninstalllibnetapi
2219
2220 uninstallman:
2221         @$(SHELL) $(srcdir)/script/uninstallman.sh $(DESTDIR)$(MANDIR) $(srcdir) C
2222
2223 uninstallservers:
2224         @$(SHELL) script/uninstallbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(SBINDIR) $(SBIN_PROGS)
2225
2226 uninstallbin:
2227         @$(SHELL) script/uninstallbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(BINDIR) $(BIN_PROGS)
2228
2229 uninstallcifsmount:
2230         @$(SHELL) script/uninstallbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(ROOTSBINDIR) @CIFSMOUNT_PROGS@
2231
2232 uninstallcifsspnego:
2233         @$(SHELL) script/uninstallbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(ROOTSBINDIR) @CIFSSPNEGO_PROGS@
2234
2235 uninstallmodules:
2236         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(VFSLIBDIR) $(VFS_MODULES)
2237         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(PDBLIBDIR) $(PDB_MODULES)
2238         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(RPCLIBDIR) $(RPC_MODULES)
2239         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(IDMAPLIBDIR) $(IDMAP_MODULES)
2240         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(CHARSETLIBDIR) $(CHARSET_MODULES)
2241         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(AUTHLIBDIR) $(AUTH_MODULES)
2242         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(GPEXTLIBDIR) $(GPEXT_MODULES)
2243
2244 uninstallscripts:
2245         @$(SHELL) $(srcdir)/script/uninstallscripts.sh $(INSTALLPERMS_BIN) $(DESTDIR)$(BINDIR) $(SCRIPTS)
2246
2247 uninstalldat:
2248         @$(SHELL) $(srcdir)/script/uninstalldat.sh $(DESTDIR) $(LIBDIR) $(srcdir)
2249
2250 uninstallmsg:
2251         @$(SHELL) $(srcdir)/script/uninstallmsg.sh $(DESTDIR) $(LIBDIR) $(srcdir)
2252
2253 uninstallswat: uninstallmsg
2254         @$(SHELL) $(srcdir)/script/uninstallswat.sh $(DESTDIR) $(SWATDIR) $(srcdir)
2255
2256 uninstallclientlib:
2257         -$(UNINSTALLLIBCMD_SH) $(DESTDIR)$(LIBDIR)/libsmbclient.@SHLIBEXT@
2258         -$(UNINSTALLLIBCMD_A) $(DESTDIR)$(LIBDIR)/libsmbclient.a
2259         -rm -f $(DESTDIR)${prefix}/include/libsmbclient.h
2260
2261 uninstalllibsmbsharemodes:
2262         -$(UNINSTALLLIBCMD_SH) $(DESTDIR)$(LIBDIR)/libsmbsharemodes.@SHLIBEXT@
2263         -$(UNINSTALLLIBCMD_A) $(DESTDIR)$(LIBDIR)/libsmbsharemodes.a
2264
2265 uninstalllibaddns:
2266         -$(UNINSTALLLIBCMD_SH) $(DESTDIR)$(LIBDIR)/libaddns.@SHLIBEXT@
2267         -$(UNINSTALLLIBCMD_A) $(DESTDIR)$(LIBDIR)/libaddns.a
2268
2269 uninstalllibnetapi:
2270         -$(UNINSTALLLIBCMD_SH) $(DESTDIR)$(LIBDIR)/libnetapi.@SHLIBEXT@
2271         -$(UNINSTALLLIBCMD_A) $(DESTDIR)$(LIBDIR)/libnetapi.a
2272         -rm -f $(DESTDIR)${prefix}/include/netapi.h
2273
2274 uninstallpammodules:
2275         @for module in $(PAM_MODULES); do \
2276                 echo "Removing $(DESTDIR)/$(PAMMODULESDIR)/$${module}.@SHLIBEXT@ "; \
2277                 rm -f "$(DESTDIR)/$(PAMMODULESDIR)/$${module}.@SHLIBEXT@"; \
2278         done
2279
2280 # Toplevel clean files
2281 TOPFILES=dynconfig.o
2282
2283 clean: delheaders 
2284         -rm -f $(PRECOMPILED_HEADER)
2285         -rm -f core */*~ *~ \
2286                 */*.o */*/*.o */*/*/*.o \
2287                 ../testsuite/*/*.o \
2288                 */*.@SHLIBEXT@ */*/*.@SHLIBEXT@ */*/*/*.@SHLIBEXT@ \
2289                 $(TOPFILES) $(BIN_PROGS) $(SBIN_PROGS) $(ROOT_SBIN_PROGS) \
2290                 $(MODULES) $(TORTURE_PROGS) \
2291                 $(LIBTALLOC) $(LIBSMBCLIENT) $(LIBADDNS) \
2292                 $(LIBSMBSHAREMODES) $(EVERYTHING_PROGS) $(LIBNETAPI) \
2293                 bin/libwbclient.so.0 bin/timelimit \
2294                 .headers.stamp */src/*.o proto_exists \
2295                 $(LIBTDB_SYMS)
2296         -rm -rf t_dir
2297
2298 # Making this target will just make sure that the prototype files
2299 # exist, not necessarily that they are up to date.  Since they're
2300 # removed by "make clean" this will always be run when you do anything
2301 # afterwards.
2302 proto_exists: include/build_env.h \
2303         libnet/libnet_proto.h \
2304         smbd/build_options.c
2305         @touch proto_exists
2306
2307 delheaders:
2308         @echo Removing prototype headers
2309         @rm -f include/build_env.h \
2310                 smbd/build_options.c \
2311                 libnet/libnet_proto.h
2312
2313 MKPROTO_SH = $(srcdir)/script/mkproto.sh
2314
2315 include/build_env.h: script/build_env.sh
2316         @echo Building include/build_env.h
2317         @$(SHELL) $(srcdir)/script/build_env.sh $(srcdir) $(builddir) $(CC) \
2318           > $(builddir)/include/build_env.h
2319
2320 libnet/libnet_proto.h:
2321         @cd $(srcdir) && $(SHELL) $(MKPROTO_SH) $(AWK) \
2322           -h _LIBNET_PROTO_H_ $(builddir)/libnet/libnet_proto.h \
2323           $(LIBNET_OBJ)
2324
2325 # "make headers" or "make proto" calls a subshell because we need to
2326 # make sure these commands are executed in sequence even for a
2327 # parallel make.
2328 headers:
2329         $(MAKE) delheaders; \
2330         $(MAKE) smbd/build_options.c; \
2331         $(MAKE) include/build_env.h; \
2332         $(MAKE) libnet/libnet_proto.h;
2333
2334 proto: headers
2335
2336 .PHONY: headers proto
2337
2338 etags:
2339         etags `find $(srcdir) -name "*.[ch]" | grep -v /.svn/`
2340
2341 ctags:
2342         ctags `find $(srcdir) -name "*.[ch]" | grep -v /.svn/`
2343
2344 realclean: clean delheaders
2345         -rm -f config.log bin/.dummy script/findsmb script/gen-8bit-gap.sh
2346         -rm -f script/installbin.sh script/uninstallbin.sh
2347
2348 distclean: realclean
2349         -rm -f smbadduser
2350         -rm -f include/config.h Makefile
2351         -rm -f config.status config.cache so_locations
2352         -rm -rf .deps TAGS
2353
2354 realdistclean: distclean
2355         -rm -f include/config.h.in
2356         -rm -f include/version.h
2357         -rm -f configure
2358
2359 # this target is really just for my use. It only works on a limited
2360 # range of machines and is used to produce a list of potentially
2361 # dead (ie. unused) functions in the code. (tridge)
2362 finddead:
2363         nm */*.o |grep 'U ' | awk '{print $$2}' | sort -u > nmused.txt
2364         nm */*.o |grep 'T ' | awk '{print $$3}' | sort -u > nmfns.txt
2365         comm -13 nmused.txt nmfns.txt
2366
2367
2368 # when configure.in is updated, reconfigure
2369 $(srcdir)/configure: $(srcdir)/configure.in
2370         @echo "WARNING: you need to rerun ./autogen.sh"
2371
2372 config.status: $(srcdir)/configure
2373         @echo "WARNING: you need to run ./configure"
2374
2375 Makefile: $(srcdir)/Makefile.in config.status
2376         @echo "WARNING: you need to run ./config.status"
2377
2378 ######################################################################
2379 # Samba Testing Framework
2380
2381 # Check shared libs for unresolved symbols
2382 test_shlibs: $(SHLIBS)
2383         @echo "Testing $(SHLIBS) "
2384         @export $(LIB_PATH_VAR)=./bin && \
2385         for module in $(SHLIBS); do \
2386                 ./script/tests/dlopen.sh bin/$${module}.@SHLIBEXT@ \
2387                         || exit 1; \
2388         done
2389
2390 # Check for NSS module problems.
2391 test_nss_modules: nss_modules
2392         @echo "Testing $(NSS_MODULES) "
2393         @export $(LIB_PATH_VAR)=./bin && \
2394         for module in $(NSS_MODULES); do \
2395                 ./script/tests/dlopen.sh $${module} \
2396                         || exit 1; \
2397         done
2398
2399 # Check for PAM module problems.  Specifically, check that every module we
2400 # built can actually be loaded by a minimal PAM-aware application.
2401 test_pam_modules: pam_modules
2402         @echo "Testing $(PAM_MODULES) "
2403         @export $(LIB_PATH_VAR)=./bin && \
2404         for module in $(PAM_MODULES); do \
2405                 ./script/tests/dlopen.sh -lpam -ldl bin/$${module}.@SHLIBEXT@ \
2406                         || exit 1; \
2407         done
2408
2409
2410 ##
2411 ## Targets for 'make test'
2412 ##
2413 test: all torture timelimit
2414         @echo Running Test suite
2415         @LIB_PATH_VAR=$(LIB_PATH_VAR) PERL="$(PERL)" $(srcdir)/script/tests/selftest.sh ${selftest_prefix} all "${smbtorture4_path}"
2416
2417 valgrindtest: all torture timelimit
2418         @echo Running Test suite with valgrind
2419         @LIB_PATH_VAR=$(LIB_PATH_VAR) \
2420          NMBD_VALGRIND="xterm -n nmbd -e valgrind -q --db-attach=yes --num-callers=30" \
2421          WINBINDD_VALGRIND="xterm -n winbindd -e valgrind -q --db-attach=yes --num-callers=30" \
2422          SMBD_VALGRIND="xterm -n smbd -e valgrind -q --db-attach=yes --num-callers=30" \
2423          VALGRIND="valgrind -q --num-callers=30 --log-file=${selftest_prefix}/valgrind.log" \
2424          PERL="$(PERL)" $(srcdir)/script/tests/selftest.sh ${selftest_prefix} all "${smbtorture4_path}"