build: Move generated version.h to a waf-invisible location
[kai/samba.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 # the following vars come from ../dynconfig/config.m4
20 BINDIR=@BINDIR@
21 SBINDIR=@SBINDIR@
22 LIBDIR=@LIBDIR@
23 #LIBEXECDIR=@LIBEXECDIR@
24 MANDIR=@MANDIR@
25 DATADIR=@DATADIR@
26 LOCALEDIR=@LOCALEDIR@
27 #SCRIPTSBINDIR=@SCRIPTSBINDIR@
28 #PYTHONDIR=@PYTHONDIR@
29 #PYTHONARCHDIR=@PYTHONARCHDIR@
30 MODULESDIR=@MODULESDIR@
31 INCLUDEDIR=@INCLUDEDIR@
32 SETUPDIR=@SETUPDIR@
33 #PKGCONFIGDIR=@PKGCONFIGDIR@
34 SWATDIR=@SWATDIR@
35 CODEPAGEDIR=@CODEPAGEDIR@
36 PAMMODULESDIR=@PAMMODULESDIR@
37 CONFIGDIR=@CONFIGDIR@
38 PRIVATE_DIR=@PRIVATE_DIR@
39 LOCKDIR=@LOCKDIR@
40 PIDDIR=@PIDDIR@
41 STATEDIR=@STATEDIR@
42 CACHEDIR=@CACHEDIR@
43 LOGFILEBASE=@LOGFILEBASE@
44 SOCKET_DIR=@SOCKET_DIR@
45 PRIVILEGED_SOCKET_DIR=@PRIVILEGED_SOCKET_DIR@
46 WINBINDD_SOCKET_DIR=@WINBINDD_SOCKET_DIR@
47 WINBINDD_PRIVILEGED_SOCKET_DIR=@WINBINDD_PRIVILEGED_SOCKET_DIR@
48 NMBDSOCKETDIR=@NMBDSOCKETDIR@
49 #NTP_SIGND_SOCKET_DIR=@NTP_SIGND_SOCKET_DIR@
50 NCALRPCDIR=@NCALRPCDIR@
51 CONFIGFILE=@CONFIGFILE@
52 LMHOSTSFILE=@LMHOSTSFILE@
53 SMB_PASSWD_FILE=@SMB_PASSWD_FILE@
54
55 selftest_prefix=@selftest_prefix@
56
57 LIBS=@LIBS@
58 CC=@CC@
59 SHLD=@SHLD@
60 LIB_PATH_VAR=@LIB_PATH_VAR@
61
62 ## Dynamic shared libraries build settings
63 DSO_EXPORTS_CMD=-Wl,--version-script,$(srcdir)/exports/`basename $@ | sed 's:\.@SHLIBEXT@[\.0-9]*$$:.@SYMSEXT@:'`
64 DSO_EXPORTS=@DSO_EXPORTS@
65 SHLD_DSO = $(SHLD) $(LDSHFLAGS) $(DSO_EXPORTS) -o $@
66
67 # The MODULE_EXPORTS variable contains the platform-specific linker flags
68 # needed to restrict the exports for VFS, IDMAP, RPC and PASSDB modules.
69 MODULE_EXPORTS=@MODULE_EXPORTS@
70
71 # Add $(DEVELOPER_CFLAGS) to $(CFLAGS) to enable extra compiler
72 # (GCC) warnings. This is done automatically for --enable-developer,
73 # --enable-picky-developer and --enable-krb5developer.
74 DEVELOPER_CFLAGS=@DEVELOPER_CFLAGS@
75 CFLAGS=@CFLAGS@
76 CPP=@CPP@
77 CPPFLAGS=-DHAVE_CONFIG_H @CPPFLAGS@
78 PICFLAG=@PICFLAG@
79
80 AR=@AR@
81 LDSHFLAGS=$(PICFLAG) @LDSHFLAGS@ @RELRO_LDFLAGS@ @LDFLAGS@ -lc @LDSHFLAGS_Z_DEFS@
82 LDSHFLAGS_MODULES=$(PICFLAG) @LDSHFLAGS@ @RELRO_LDFLAGS@ @LDFLAGS@ @LDSHFLAGS_Z_NODEFS@
83 LDFLAGS=@PIE_LDFLAGS@ @RELRO_LDFLAGS@ @LDFLAGS@
84
85 WINBIND_NSS_LDSHFLAGS=$(PICFLAG) @WINBIND_NSS_LDSHFLAGS@ @LDFLAGS@ -lc @LDSHFLAGS_Z_DEFS@
86 AWK=@AWK@
87 DYNEXP=@DYNEXP@
88 PERL=@PERL@
89 PYTHON=@PYTHON@
90 LIBDL=@LIBDL@
91
92 PIDL_ARGS=@PIDL_ARGS@
93
94 TERMLDFLAGS=@TERMLDFLAGS@
95 TERMLIBS=@TERMLIBS@
96 PRINT_LIBS=@PRINT_LIBS@
97 ZLIB_LIBS=@ZLIB_LIBS@
98 AUTH_LIBS=@AUTH_LIBS@
99 ACL_LIBS=@ACL_LIBS@
100 PASSDB_LIBS=@PASSDB_LIBS@
101 IDMAP_LIBS=@IDMAP_LIBS@
102 KRB5LIBS=@KRB5_LIBS@
103 LDAP_LIBS=@LDAP_LIBS@
104 NSCD_LIBS=@NSCD_LIBS@
105 UUID_LIBS=@UUID_LIBS@
106 LIBWBCLIENT=@LIBWBCLIENT_STATIC@ @LIBWBCLIENT_SHARED@
107 LIBWBCLIENT_LIBS=@LIBWBCLIENT_LIBS@
108 PTHREAD_LDFLAGS=@PTHREAD_LDFLAGS@
109 PTHREAD_CFLAGS=@PTHREAD_CFLAGS@
110 DNSSD_LIBS=@DNSSD_LIBS@
111 AVAHI_LIBS=@AVAHI_LIBS@
112 POPT_LIBS=@POPTLIBS@
113 LIBTALLOC=@LIBTALLOC_STATIC@ @LIBTALLOC_SHARED@
114 LIBTALLOC_LIBS=@LIBTALLOC_LIBS@
115 LIBREPLACE_LIBS=@LIBREPLACE_LIBS@
116 LIBTDB=@LIBTDB_STATIC@ @LIBTDB_SHARED@
117 LIBTDB_LIBS=@LIBTDB_LIBS@
118 TDB_DEPS=@TDB_DEPS@
119 LIBNETAPI=@LIBNETAPI_STATIC@ @LIBNETAPI_SHARED@
120 LIBNETAPI_LIBS=@LIBNETAPI_LIBS@
121 LIBSMBCLIENT_LIBS=@LIBSMBCLIENT_LIBS@
122 LIBSMBSHAREMODES_LIBS=@LIBSMBSHAREMODES_LIBS@
123
124 TALLOCTORT = @TALLOCTORT@
125
126 TDBBACKUP = @TDBBACKUP@
127 TDBTOOL = @TDBTOOL@
128 TDBDUMP = @TDBDUMP@
129 TDBRESTORE = @TDBRESTORE@
130 TDBTORTURE = @TDBTORTURE@
131 PTHREADPOOLTEST = @PTHREADPOOLTEST@
132
133 INSTALLCMD=@INSTALL@
134 INSTALLLIBCMD_SH=@INSTALLLIBCMD_SH@
135 INSTALLLIBCMD_A=@INSTALLLIBCMD_A@
136 UNINSTALLLIBCMD_SH=@UNINSTALLLIBCMD_SH@
137 UNINSTALLLIBCMD_A=@UNINSTALLLIBCMD_A@
138
139 VPATH=@srcdir@
140 srcdir=@abs_srcdir@
141 builddir=@abs_builddir@
142 # XXX: Perhaps this should be @SHELL@ instead -- apparently autoconf
143 # will search for a POSIX-compliant shell, and that might not be
144 # /bin/sh on some platforms.  I guess it's not a big problem -- mbp
145 SHELL=/bin/sh
146 DESTDIR=/
147
148 # See the autoconf manual "Installation Directory Variables" for a
149 # discussion of the subtle use of these variables.
150
151 VFSLIBDIR = $(MODULESDIR)/vfs
152 PERFCOUNTLIBDIR = $(MODULESDIR)/perfcount
153 PDBLIBDIR = $(MODULESDIR)/pdb
154 RPCLIBDIR = $(MODULESDIR)/rpc
155 IDMAPLIBDIR = $(MODULESDIR)/idmap
156 NSSINFOLIBDIR = $(MODULESDIR)/nss_info
157 CHARSETLIBDIR = $(MODULESDIR)/charset
158 AUTHLIBDIR = $(MODULESDIR)/auth
159 CONFIGLIBDIR = $(MODULESDIR)/config
160 GPEXTLIBDIR = $(MODULESDIR)/gpext
161 VARDIR = @localstatedir@
162
163 # The permissions to give the executables and other data
164 INSTALLPERMS_BIN = 0755
165 INSTALLPERMS_DATA = 0644
166
167 FLAGS = -I. \
168         -I$(srcdir) \
169         @FLAGS1@ \
170         @SAMBA_CPPFLAGS@ \
171         $(CPPFLAGS) \
172         $(ISA) \
173         -I$(srcdir)/lib \
174         -I.. \
175         -I./../lib/ldb/include \
176         -D_SAMBA_BUILD_=3
177
178 PATH_FLAGS = -DSMB_PASSWD_FILE=\"$(SMB_PASSWD_FILE)\" \
179         -DPRIVATE_DIR=\"$(PRIVATE_DIR)\" \
180         -DCONFIGFILE=\"$(CONFIGFILE)\" \
181         -DSBINDIR=\"$(SBINDIR)\" \
182         -DBINDIR=\"$(BINDIR)\" \
183         -DLMHOSTSFILE=\"$(LMHOSTSFILE)\" \
184         -DSWATDIR=\"$(SWATDIR)\" \
185         -DLOCKDIR=\"$(LOCKDIR)\" \
186         -DPIDDIR=\"$(PIDDIR)\" \
187         -DLIBDIR=\"$(LIBDIR)\" \
188         -DMODULESDIR=\"$(MODULESDIR)\" \
189         -DLOGFILEBASE=\"$(LOGFILEBASE)\" \
190         -DSHLIBEXT=\"@SHLIBEXT@\" \
191         -DNCALRPCDIR=\"$(NCALRPCDIR)\" \
192         -DCONFIGDIR=\"$(CONFIGDIR)\" \
193         -DCODEPAGEDIR=\"$(CODEPAGEDIR)\" \
194         -DCACHEDIR=\"$(CACHEDIR)\" \
195         -DSTATEDIR=\"$(STATEDIR)\" \
196         -DNMBDSOCKETDIR=\"$(NMBDSOCKETDIR)\" \
197         -DWINBINDD_SOCKET_DIR=\"$(WINBINDD_SOCKET_DIR)\" \
198         -DWINBINDD_PRIVILEGED_SOCKET_DIR=\"$(WINBINDD_PRIVILEGED_SOCKET_DIR)\" \
199         -DLOCALEDIR=\"$(LOCALEDIR)\" \
200         -DDATADIR=\"$(DATADIR)\" \
201         -DSETUPDIR=\"$(SETUPDIR)\"
202
203 # Note that all executable programs now provide for an optional executable suffix.
204
205 SBIN_PROGS = bin/smbd bin/nmbd @SWAT_SBIN_TARGETS@ @EXTRA_SBIN_PROGS@
206
207 BIN_PROGS1 = bin/smbclient bin/net bin/smbspool \
208         bin/testparm bin/smbstatus bin/smbget \
209         bin/smbta-util
210 BIN_PROGS2 = bin/smbcontrol bin/smbtree $(TDBBACKUP) \
211         bin/nmblookup bin/pdbedit $(TDBDUMP) \
212         $(TDBRESTORE) $(TDBTOOL) bin/dbwrap_tool
213 BIN_PROGS3 = bin/smbpasswd bin/rpcclient bin/smbcacls \
214         bin/profiles bin/ntlm_auth bin/sharesec \
215         bin/smbcquotas bin/eventlogadm 
216
217 TORTURE_PROGS = bin/smbtorture bin/msgtest \
218         bin/masktest bin/locktest \
219         bin/locktest2 bin/nsstest bin/vfstest \
220         bin/pdbtest $(TALLOCTORT) bin/replacetort \
221         $(TDBTORTURE) $(PTHREADPOOLTEST) \
222         bin/smbconftort bin/vlp
223
224 BIN_PROGS = @EXTRA_BIN_PROGS@ \
225         $(BIN_PROGS1) $(BIN_PROGS2) $(BIN_PROGS3)
226
227 EVERYTHING_PROGS = bin/debug2html bin/smbfilter \
228         $(TALLOCTORT) bin/replacetort \
229         bin/log2pcap \
230         bin/vlp \
231         bin/dbwrap_tool \
232         bin/dbwrap_torture
233
234 PAM_MODULES = @PAM_MODULES@
235
236 NSS_MODULES = @NSS_MODULES@
237
238 SCRIPTS = $(srcdir)/script/smbtar $(builddir)/script/findsmb
239
240 VFS_MODULES = @VFS_MODULES@
241 PERFCOUNT_MODULES = @PERFCOUNT_MODULES@
242 PDB_MODULES = @PDB_MODULES@
243 IDMAP_MODULES = @IDMAP_MODULES@
244 CHARSET_MODULES = @CHARSET_MODULES@
245 AUTH_MODULES = @AUTH_MODULES@
246 NSS_INFO_MODULES = @NSS_INFO_MODULES@
247 GPEXT_MODULES = @GPEXT_MODULES@
248 MODULES = $(VFS_MODULES) $(PDB_MODULES) $(IDMAP_MODULES) \
249           $(CHARSET_MODULES) $(AUTH_MODULES) $(NSS_INFO_MODULES) \
250           $(GPEXT_MODULES) $(PERFCOUNT_MODULES)
251
252 EXTRA_ALL_TARGETS = @EXTRA_ALL_TARGETS@
253
254 ######################################################################
255 # object file lists
256 ######################################################################
257
258 TDB_LIB_OBJ = lib/util_tdb.o ../lib/util/util_tdb.o \
259           ../lib/tdb_wrap/tdb_wrap.o \
260           ../lib/dbwrap/dbwrap.o \
261           lib/dbwrap/dbwrap_open.o \
262           ../lib/dbwrap/dbwrap_tdb.o \
263           lib/dbwrap/dbwrap_ctdb.o \
264           lib/g_lock.o \
265           ../lib/dbwrap/dbwrap_cache.o \
266           lib/dbwrap/dbwrap_watch.o \
267           ../lib/dbwrap/dbwrap_rbt.o \
268           ../lib/dbwrap/dbwrap_util.o
269
270 TDB_VALIDATE_OBJ = lib/tdb_validate.o
271
272 SMBLDAP_OBJ = @SMBLDAP@
273
274 VERSION_OBJ = lib/version.o
275
276 WBCOMMON_OBJ = ../nsswitch/wb_common.o
277
278 AFS_OBJ = lib/afs.o
279
280 AFS_SETTOKEN_OBJ = lib/afs_settoken.o
281
282 AVAHI_OBJ = @AVAHI_OBJ@
283
284 SERVER_MUTEX_OBJ = lib/server_mutex.o
285
286 PASSCHANGE_OBJ = libsmb/passchange.o
287
288 LIBNDR_DRSUAPI_OBJ = ../librpc/ndr/ndr_drsuapi.o \
289                      ../librpc/ndr/ndr_compression.o \
290                      librpc/gen_ndr/ndr_drsuapi.o \
291                      ../librpc/ndr/ndr_drsblobs.o \
292                      librpc/gen_ndr/ndr_drsblobs.o
293
294 ZLIB_OBJ = @ZLIB_OBJS@
295
296 COMPRESSION_OBJ = ../lib/compression/lzxpress.o \
297                   $(ZLIB_OBJ)
298
299 DRSUAPI_OBJ = $(LIBNDR_DRSUAPI_OBJ) \
300               $(COMPRESSION_OBJ)
301
302 LIBNDR_NTLMSSP_OBJ = librpc/gen_ndr/ndr_ntlmssp.o \
303                      ../librpc/ndr/ndr_ntlmssp.o
304
305 LIBNDR_OBJ = ../librpc/ndr/ndr_basic.o \
306              ../librpc/ndr/ndr.o \
307              ../librpc/ndr/ndr_misc.o \
308              librpc/gen_ndr/ndr_misc.o \
309              librpc/gen_ndr/ndr_security.o \
310              ../librpc/ndr/ndr_sec_helper.o \
311              ../librpc/ndr/ndr_string.o \
312              ../librpc/ndr/uuid.o \
313              ../librpc/ndr/util.o \
314              librpc/gen_ndr/ndr_server_id.o \
315              librpc/gen_ndr/ndr_file_id.o \
316              librpc/gen_ndr/ndr_dcerpc.o
317
318 LIBNDR_GEN_OBJ0 = librpc/gen_ndr/ndr_samr.o \
319                   librpc/gen_ndr/ndr_lsa.o
320
321 LIBNDR_NETLOGON_OBJ = librpc/gen_ndr/ndr_netlogon.o \
322                   ../librpc/ndr/ndr_netlogon.o
323
324 LIBNDR_SCHANNEL_OBJ = librpc/gen_ndr/ndr_schannel.o \
325                       ../librpc/ndr/ndr_schannel.o
326
327 LIBNDR_SPOOLSS_OBJ = librpc/gen_ndr/ndr_spoolss.o \
328                   ../librpc/ndr/ndr_spoolss_buf.o
329
330 LIBNDR_NTPRINTING_OBJ = librpc/gen_ndr/ndr_ntprinting.o \
331                         ../librpc/ndr/ndr_ntprinting.o \
332
333 LIBNDR_PREG_OBJ = librpc/gen_ndr/ndr_preg.o \
334                   ../librpc/ndr/ndr_preg.o
335
336 LIBNDR_XATTR_OBJ = librpc/gen_ndr/ndr_xattr.o \
337                    ../librpc/ndr/ndr_xattr.o
338
339 LIBCLI_SPOOLSS_OBJ = librpc/gen_ndr/ndr_spoolss_c.o \
340                      rpc_client/cli_spoolss.o \
341                      rpc_client/init_spoolss.o \
342                      rpc_client/cli_winreg_spoolss.o \
343                      printing/nt_printing_os2.o
344
345 LIBCLI_EVENTLOG_OBJ = librpc/gen_ndr/ndr_eventlog_c.o
346
347 LIBCLI_WINREG_OBJ = librpc/gen_ndr/ndr_winreg_c.o \
348                     rpc_client/cli_winreg.o
349
350 LIBCLI_WINREG_INT_OBJ = $(LIBCLI_WINREG_OBJ) \
351                         rpc_client/cli_winreg_int.o
352
353 LIBCLI_NTSVCS_OBJ = librpc/gen_ndr/ndr_ntsvcs_c.o
354
355 LIBCLI_DRSUAPI_OBJ = librpc/gen_ndr/ndr_drsuapi_c.o
356
357 LIBCLI_DFS_OBJ = librpc/gen_ndr/ndr_dfs_c.o
358
359 LIBCLI_ECHO_OBJ = librpc/gen_ndr/ndr_echo_c.o
360
361 LIBCLI_INITSHUTDOWN_OBJ = librpc/gen_ndr/ndr_initshutdown_c.o
362
363 LIBCLI_DSSETUP_OBJ = librpc/gen_ndr/ndr_dssetup_c.o
364
365 LIBCLI_SVCCTL_OBJ = librpc/gen_ndr/ndr_svcctl_c.o
366
367 LIBCLI_WKSSVC_OBJ = librpc/gen_ndr/ndr_wkssvc_c.o
368
369 LIBCLI_SRVSVC_OBJ = librpc/gen_ndr/ndr_srvsvc_c.o
370
371 LIBCLI_LSA_OBJ = librpc/gen_ndr/ndr_lsa_c.o \
372                  rpc_client/cli_lsarpc.o \
373                  rpc_client/init_lsa.o
374
375 LIBCLI_SAMR_OBJ = librpc/gen_ndr/ndr_samr_c.o \
376                   rpc_client/cli_samr.o
377
378 LIBCLI_NETLOGON_OBJ = librpc/gen_ndr/ndr_netlogon_c.o \
379                       rpc_client/cli_netlogon.o \
380                       rpc_client/util_netlogon.o
381
382 LIBCLI_EPMAPPER_OBJ = librpc/gen_ndr/ndr_epmapper_c.o
383
384 LIBNDR_GEN_OBJ = librpc/gen_ndr/ndr_wkssvc.o \
385                  $(LIBNDR_GEN_OBJ0) \
386                  librpc/gen_ndr/ndr_dfs.o \
387                  librpc/gen_ndr/ndr_dfsblobs.o \
388                  librpc/gen_ndr/ndr_echo.o \
389                  librpc/gen_ndr/ndr_winreg.o \
390                  librpc/gen_ndr/ndr_initshutdown.o \
391                  librpc/gen_ndr/ndr_srvsvc.o \
392                  librpc/gen_ndr/ndr_eventlog.o \
393                  $(LIBNDR_NETLOGON_OBJ) \
394                  librpc/gen_ndr/ndr_dssetup.o \
395                  librpc/gen_ndr/ndr_epmapper.o \
396                  librpc/gen_ndr/ndr_ntsvcs.o \
397                  $(LIBNDR_SPOOLSS_OBJ)
398
399 # this includes only the low level parse code, not stuff
400 # that requires knowledge of security contexts
401 REG_PARSE_PRS_OBJ = registry/reg_parse_prs.o
402
403 LIBREPLACE_OBJ = @LIBREPLACE_OBJS@
404
405 SOCKET_WRAPPER_OBJ = @SOCKET_WRAPPER_OBJS@
406 NSS_WRAPPER_OBJ = @NSS_WRAPPER_OBJS@
407 UID_WRAPPER_OBJ = @UID_WRAPPER_OBJS@
408
409 LIBSAMBAUTIL_OBJ = \
410                 $(LIBREPLACE_OBJ) \
411                 $(SOCKET_WRAPPER_OBJ) \
412                 $(UID_WRAPPER_OBJ) \
413                 $(NSS_WRAPPER_OBJ)
414
415 UTIL_OBJ = ../lib/util/rbtree.o ../lib/util/signal.o ../lib/util/time.o \
416                    ../lib/util/xfile.o ../lib/util/util_strlist.o  \
417                    ../lib/util/util_file.o ../lib/util/data_blob.o \
418                    ../lib/util/util.o ../lib/util/util_paths.o ../lib/util/fsusage.o \
419                    ../lib/util/params.o ../lib/util/talloc_stack.o \
420                    ../lib/util/genrand.o ../lib/util/util_net.o \
421                    ../lib/util/become_daemon.o ../lib/util/system.o \
422                    ../lib/util/tevent_unix.o ../lib/util/tevent_ntstatus.o \
423                    ../lib/util/tevent_werror.o \
424                    lib/tevent_barrier.o \
425                    ../lib/util/smb_threads.o ../lib/util/util_id.o \
426                    ../lib/util/blocking.o ../lib/util/rfc1738.o \
427                    ../lib/util/select.o ../lib/util/util_pw.o ../lib/util/server_id.o
428
429 CRYPTO_OBJ = ../lib/crypto/crc32.o @CRYPTO_MD5_OBJ@ \
430                          ../lib/crypto/hmacmd5.o ../lib/crypto/arcfour.o \
431                          ../lib/crypto/md4.o \
432                          ../lib/crypto/sha256.o ../lib/crypto/hmacsha256.o \
433                          ../lib/crypto/aes.o ../lib/crypto/rijndael-alg-fst.o \
434                          ../lib/crypto/aes_cmac_128.o
435
436 LIB_OBJ = $(LIBSAMBAUTIL_OBJ) $(UTIL_OBJ) $(CRYPTO_OBJ) $(LIBTSOCKET_OBJ) \
437           lib/messages.o librpc/gen_ndr/ndr_messaging.o lib/messages_local.o \
438           lib/messages_ctdbd.o lib/ctdb_packet.o lib/ctdbd_conn.o \
439           lib/ctdb_conn.o \
440           lib/msg_channel.o \
441           lib/id_cache.o \
442           ../lib/socket/interfaces.o lib/memcache.o \
443           lib/talloc_dict.o \
444           lib/serverid.o \
445           lib/util_transfer_file.o ../lib/async_req/async_sock.o \
446           lib/addrchange.o \
447           $(TDB_LIB_OBJ) \
448           $(VERSION_OBJ) lib/charcnv.o ../lib/util/charset/convert_string.o \
449           ../lib/util/charset/pull_push.o \
450           lib/fstring.o ../lib/util/debug.o ../lib/util/debug_s3.o ../lib/util/fault.o \
451           lib/interface.o lib/pidfile.o lib/dumpcore.o \
452           lib/system.o lib/sendfile.o lib/recvfile.o lib/time.o \
453           lib/username.o \
454           ../libds/common/flag_mapping.o \
455           lib/access.o lib/smbrun.o \
456           ../lib/util/bitmap.o ../lib/util/dprintf.o $(UTIL_REG_OBJ) \
457           lib/wins_srv.o lib/string_init.o \
458           lib/util_str.o ../lib/util/util_str_common.o \
459           ../lib/util/util_str.o \
460           ../lib/util/base64.o lib/util_sid.o \
461           ../lib/util/charset/util_unistr.o \
462           ../lib/util/charset/util_unistr_w.o ../lib/util/charset/codepoints.o ../lib/util/charset/util_str.o lib/util_file.o \
463           lib/util.o lib/util_malloc.o lib/namearray.o lib/util_cmdline.o lib/util_names.o \
464           lib/util_sock.o lib/sock_exec.o lib/util_sec.o \
465           lib/substitute.o lib/substitute_generic.o ../lib/util/substitute.o \
466           lib/ms_fnmatch.o ../lib/util/ms_fnmatch.o lib/errmap_unix.o ../libcli/util/errmap_unix.o \
467           lib/tallocmsg.o lib/dmallocmsg.o \
468           ../libcli/smb/smb_signing.o \
469           ../lib/util/charset/iconv.o ../lib/util/charset/weird.o \
470           ../lib/util/charset/charset_macosxfs.o intl/lang_tdb.o \
471           lib/conn_tdb.o lib/adt_tree.o lib/gencache.o \
472           lib/sessionid_tdb.o \
473           ../lib/util/modules.o lib/events.o @LIBTEVENT_OBJ0@ \
474           @CCAN_OBJ@ \
475           lib/server_contexts.o \
476           lib/server_prefork.o \
477           lib/server_prefork_util.o \
478           lib/ldap_escape.o @CHARSET_STATIC@ \
479           ../libcli/security/secdesc.o ../libcli/security/access_check.o \
480           ../libcli/security/secace.o ../libcli/security/object_tree.o \
481           ../libcli/security/sddl.o ../libcli/security/session.o \
482           ../libcli/security/secacl.o @PTHREADPOOL_OBJ@ \
483           lib/fncall.o \
484           libads/krb5_errs.o lib/system_smbd.o lib/audit.o $(LIBNDR_OBJ) \
485           lib/file_id.o lib/idmap_cache.o \
486           ../libcli/security/dom_sid.o ../libcli/security/security_descriptor.o \
487           ../libcli/security/security_token.o ../libcli/security/util_sid.o \
488           ../libcli/smb/util.o ../lib/util/idtree.o
489
490 LIB_DUMMY_OBJ = lib/smbd_shim.o lib/dummyparam.o
491 LIB_NONSMBD_OBJ = $(LIB_OBJ) $(LIB_DUMMY_OBJ)
492
493 READLINE_OBJ = ../libcli/smbreadline/smbreadline.o
494
495 # Also depends on  $(SECRETS_OBJ) $(LIBSAMBA_OBJ)
496 # Be sure to include them into your application
497 POPT_LIB_OBJ = lib/popt_common.o
498
499 PARAM_WITHOUT_REG_OBJ = ../dynconfig/dynconfig.o param/loadparm.o param/loadparm_ctx.o ../lib/param/loadparm_server_role.o param/util.o lib/sharesec.o lib/ldap_debug_handler.o ../lib/param/loadparm.o ../lib/param/util.o
500 PARAM_REG_ADD_OBJ = $(REG_SMBCONF_OBJ) $(LIBSMBCONF_OBJ) $(PRIVILEGES_BASIC_OBJ)
501 PARAM_OBJ = $(PARAM_WITHOUT_REG_OBJ) $(PARAM_REG_ADD_OBJ)
502
503 KRBCLIENT_OBJ = libads/kerberos.o libads/ads_status.o
504
505 LIBADDNS_OBJ0 = ../lib/addns/dnsrecord.o ../lib/addns/dnsutils.o  ../lib/addns/dnssock.o \
506                ../lib/addns/dnsgss.o ../lib/addns/dnsmarshall.o ../lib/addns/error.o
507 LIBADDNS_OBJ = $(LIBADDNS_OBJ0) $(SOCKET_WRAPPER_OBJ)
508
509 GPEXT_OBJ = ../libgpo/gpext/gpext.o @GPEXT_STATIC@
510
511 LIBGPO_OBJ0 = ../libgpo/gpo_ldap.o ../libgpo/gpo_ini.o ../libgpo/gpo_util.o \
512               ../libgpo/gpo_fetch.o libgpo/gpo_filesync.o ../libgpo/gpo_sec.o \
513               libgpo/gpo_reg.o \
514               $(GPEXT_OBJ)
515 LIBGPO_OBJ = $(LIBGPO_OBJ0)
516
517 LIBADS_OBJ = libads/ldap.o \
518              libads/sasl.o libads/sasl_wrapping.o \
519              libads/krb5_setpw.o \
520              libads/kerberos_util.o \
521              libads/ldap_user.o \
522              libads/ads_struct.o libads/kerberos_keytab.o \
523              libads/disp_sec.o libads/ldap_utils.o \
524              libads/ldap_schema.o libads/util.o libads/ndr.o
525
526 LIBADS_SERVER_OBJ = libads/authdata.o ../auth/kerberos/kerberos_pac.o \
527                     ../librpc/ndr/ndr_krb5pac.o \
528                     librpc/gen_ndr/ndr_krb5pac.o
529
530 LIBADS_PRINTER_OBJ = libads/ldap_printer.o
531
532 SECRETS_OBJ = passdb/secrets.o passdb/machine_account_secrets.o passdb/machine_sid.o \
533               librpc/gen_ndr/ndr_secrets.o \
534               passdb/secrets_lsa.o
535
536 LIBNBT_OBJ = ../libcli/nbt/nbtname.o \
537              ../libcli/netlogon/netlogon.o \
538              librpc/gen_ndr/ndr_nbt.o \
539              ../librpc/ndr/ndr_nbt.o \
540              librpc/gen_ndr/ndr_svcctl.o \
541              ../librpc/ndr/ndr_svcctl.o
542
543 LIBNMB_OBJ = libsmb/unexpected.o libsmb/namecache.o libsmb/nmblib.o \
544              libsmb/namequery.o ../libcli/nbt/lmhosts.o ../libcli/dns/dns_hosts_file.o libsmb/conncache.o \
545              libads/dns.o libads/sitename_cache.o
546
547 NTERR_OBJ = ../libcli/util/nterr.o libsmb/smberr.o
548 DOSERR_OBJ = ../libcli/util/doserr.o
549 ERRORMAP_OBJ = ../libcli/util/errormap.o libsmb/errormap.o
550 DCE_RPC_ERR_OBJ = ../librpc/rpc/dcerpc_error.o
551
552 LIBSMB_ERR_OBJ0 = $(NTERR_OBJ) $(DOSERR_OBJ) $(ERRORMAP_OBJ) $(DCE_RPC_ERR_OBJ)
553
554 LIBSMB_ERR_OBJ1 = ../libcli/auth/smbdes.o ../libcli/auth/smbencrypt.o ../libcli/auth/msrpc_parse.o ../libcli/auth/session.o
555
556 LIBSMB_ERR_OBJ = $(LIBSMB_ERR_OBJ0) $(LIBSMB_ERR_OBJ1) \
557                  $(SECRETS_OBJ)
558
559 LIBSMB_OBJ0 = \
560                ../lib/util/asn1.o \
561                ../libcli/auth/spnego_parse.o \
562                ../libcli/auth/ntlm_check.o \
563                libsmb/ntlmssp.o \
564                libsmb/ntlmssp_wrap.o \
565                libsmb/auth_generic.o \
566                ../lib/krb5_wrap/krb5_samba.o \
567                libsmb/clispnego.o \
568                ../auth/gensec/gensec.o \
569                ../auth/gensec/gensec_start.o \
570                ../auth/gensec/gensec_util.o \
571                ../auth/gensec/spnego.o \
572                ../auth/credentials/credentials.o \
573                ../auth/credentials/credentials_ntlm.o \
574                ../auth/credentials/credentials_samba3.o \
575                ../auth/ntlmssp/ntlmssp.o \
576                ../auth/ntlmssp/ntlmssp_util.o \
577                ../auth/ntlmssp/ntlmssp_sign.o \
578                ../auth/ntlmssp/ntlmssp_client.o \
579                ../auth/ntlmssp/gensec_ntlmssp.o \
580                ../auth/ntlmssp/gensec_ntlmssp_server.o \
581                $(LIBNDR_NTLMSSP_OBJ) \
582                ../auth/ntlmssp/ntlmssp_ndr.o \
583                ../auth/ntlmssp/ntlmssp_server.o
584
585 LIBSAMBA_OBJ = $(LIBSMB_OBJ0) \
586                $(LIBSMB_ERR_OBJ)
587
588 LIBCLI_LDAP_MESSAGE_OBJ = ../libcli/ldap/ldap_message.o
589 LIBCLI_LDAP_NDR_OBJ = ../libcli/ldap/ldap_ndr.o ../lib/ldb/common/ldb_parse.o
590
591 LIBTSOCKET_OBJ = ../lib/tsocket/tsocket.o \
592                 ../lib/tsocket/tsocket_helpers.o \
593                 ../lib/tsocket/tsocket_bsd.o
594
595 CLDAP_OBJ = libads/cldap.o \
596         ../libcli/cldap/cldap.o \
597         $(LIBCLI_LDAP_MESSAGE_OBJ) $(LIBCLI_LDAP_NDR_OBJ)
598
599 TLDAP_OBJ = lib/tldap.o lib/tldap_util.o lib/util_tsock.o
600
601 SCHANNEL_OBJ = ../libcli/auth/credentials.o \
602                ../libcli/auth/schannel_sign.o \
603                ../libcli/auth/schannel_state_tdb.o \
604                $(LIBNDR_SCHANNEL_OBJ)
605
606 LIBSMB_OBJ = libsmb/clientgen.o libsmb/cliconnect.o libsmb/clifile.o \
607              libsmb/reparse_symlink.o \
608              libsmb/clisymlink.o \
609              libsmb/clirap.o libsmb/clierror.o libsmb/climessage.o \
610              libsmb/clireadwrite.o libsmb/clilist.o libsmb/cliprint.o \
611              libsmb/clitrans.o libsmb/clisecdesc.o libsmb/clidgram.o \
612              libsmb/clistr.o libsmb/cliquota.o libsmb/clifsinfo.o libsmb/clidfs.o \
613              libsmb/clioplock.o libsmb/clirap2.o \
614              libsmb/async_smb.o \
615              libsmb/clisigning.o \
616              ../libcli/smb/smb_seal.o \
617              ../libcli/smb/read_smb.o \
618              ../libcli/smb/smbXcli_base.o \
619              ../libcli/smb/smb1cli_trans.o \
620              ../libcli/smb/smb2cli_session.o \
621              libsmb/smb2cli_tcon.o \
622              ../libcli/smb/smb2cli_create.o \
623              ../libcli/smb/smb2_create_blob.o \
624              ../libcli/smb/smb2_signing.o \
625              ../libcli/smb/smb2cli_close.o \
626              ../libcli/smb/smb2cli_flush.o \
627              ../libcli/smb/smb2cli_read.o \
628              ../libcli/smb/smb2cli_write.o \
629              ../libcli/smb/smb2cli_query_directory.o \
630              ../libcli/smb/smb2cli_ioctl.o \
631              ../libcli/smb/smb2cli_query_info.o \
632              ../libcli/smb/smb2cli_set_info.o \
633              libsmb/cli_np_tstream.o \
634              libsmb/smbsock_connect.o \
635              $(LIBSAMBA_OBJ) \
636              $(LIBNMB_OBJ) \
637              $(LIBNBT_OBJ) \
638              $(CLDAP_OBJ) \
639              $(DRSUAPI_OBJ)
640
641 LIBMSRPC_OBJ = $(SCHANNEL_OBJ) \
642                rpc_client/cli_pipe.o \
643                librpc/crypto/gse_krb5.o \
644                librpc/crypto/gse.o \
645                ../auth/kerberos/gssapi_pac.o \
646                librpc/rpc/rpc_common.o \
647                rpc_client/rpc_transport_np.o \
648                rpc_client/rpc_transport_sock.o \
649                rpc_client/rpc_transport_tstream.o \
650                ../librpc/rpc/binding.o \
651                ../librpc/rpc/dcerpc_util.o \
652                ../librpc/rpc/binding_handle.o \
653                librpc/rpc/dcerpc_helpers.o \
654                $(LIBCLI_EPMAPPER_OBJ)
655
656 LIBMSRPC_GEN_OBJ = $(LIBNDR_GEN_OBJ)
657
658 #
659 # registry-related objects
660 #
661 UTIL_REG_OBJ = ../libcli/registry/util_reg.o
662
663 REG_INIT_BASIC_OBJ = registry/reg_init_basic.o
664 REG_INIT_SMBCONF_OBJ = registry/reg_init_smbconf.o
665 REG_INIT_FULL_OBJ = registry/reg_init_full.o
666
667 REGFIO_OBJ = registry/regfio.o \
668              $(REG_PARSE_PRS_OBJ)
669
670 REG_API_REGF_OBJ = registry/reg_api_regf.o
671
672 REGOBJS_OBJ = registry/reg_objects.o
673
674 REG_BACKENDS_BASE_OBJ = registry/reg_backend_db.o
675
676 REG_BACKENDS_SMBCONF_OBJ = registry/reg_backend_smbconf.o
677
678 REG_BACKENDS_EXTRA_OBJ = registry/reg_backend_printing.o \
679                          registry/reg_backend_shares.o \
680                          registry/reg_backend_netlogon_params.o \
681                          registry/reg_backend_prod_options.o \
682                          registry/reg_backend_tcpip_params.o \
683                          registry/reg_backend_hkpt_params.o \
684                          registry/reg_backend_current_version.o \
685                          registry/reg_backend_perflib.o
686
687 REG_BASE_OBJ = registry/reg_api.o \
688                registry/reg_dispatcher.o \
689                registry/reg_cachehook.o \
690                $(REGOBJS_OBJ) \
691                registry/reg_util_internal.o \
692                lib/util_nttoken.o \
693                $(REG_BACKENDS_BASE_OBJ) \
694                registry/reg_parse_internal.o \
695                lib/cbuf.o lib/srprs.o \
696                $(REG_INIT_BASIC_OBJ)
697
698 REG_SMBCONF_OBJ = $(REG_BASE_OBJ) \
699                   registry/reg_util_token.o \
700                   registry/reg_api_util.o \
701                   $(REG_BACKENDS_SMBCONF_OBJ) \
702                   $(REG_INIT_SMBCONF_OBJ)
703
704 REG_FULL_OBJ = $(REG_SMBCONF_OBJ) \
705                $(REG_BACKENDS_EXTRA_OBJ) \
706                $(REG_INIT_FULL_OBJ) \
707                registry/reg_perfcount.o \
708                librpc/gen_ndr/ndr_perfcount.o
709
710 LIB_EVENTLOG_OBJ = lib/eventlog/eventlog.o
711
712 DCE_RPC_EP_OBJ = librpc/rpc/dcerpc_ep.o
713
714 RPC_LSARPC_OBJ = rpc_server/lsa/srv_lsa_nt.o \
715                  librpc/gen_ndr/srv_lsa.o \
716                  ../libcli/lsarpc/util_lsarpc.o
717
718 RPC_NETLOGON_OBJ = rpc_server/netlogon/srv_netlog_nt.o \
719                    librpc/gen_ndr/srv_netlogon.o
720
721 RPC_SAMR_OBJ = rpc_server/samr/srv_samr_nt.o \
722                rpc_server/samr/srv_samr_util.o \
723                rpc_server/samr/srv_samr_chgpasswd.o \
724                librpc/gen_ndr/srv_samr.o
725
726 RPC_INITSHUTDOWN_OBJ =  librpc/gen_ndr/srv_initshutdown.o rpc_server/initshutdown/srv_initshutdown_nt.o
727
728 RPC_WINREG_OBJ =  rpc_server/winreg/srv_winreg_nt.o \
729                   librpc/gen_ndr/srv_winreg.o
730
731 RPC_DSSETUP_OBJ =  rpc_server/dssetup/srv_dssetup_nt.o librpc/gen_ndr/srv_dssetup.o
732
733 RPC_SRVSVC_OBJ = rpc_server/srvsvc/srv_srvsvc_nt.o \
734                  librpc/gen_ndr/srv_srvsvc.o
735
736 RPC_WKSSVC_OBJ =  librpc/gen_ndr/srv_wkssvc.o \
737                   rpc_server/wkssvc/srv_wkssvc_nt.o
738
739 RPC_SVCCTL_OBJ =  rpc_server/svcctl/srv_svcctl_nt.o \
740                   rpc_server/svcctl/srv_svcctl_reg.o \
741                   librpc/gen_ndr/srv_svcctl.o \
742                   services/svc_winreg_glue.o \
743                   services/svc_spoolss.o services/svc_rcinit.o  \
744                   services/svc_netlogon.o services/svc_winreg.o \
745                   services/svc_wins.o
746
747 RPC_NTSVCS_OBJ = rpc_server/ntsvcs/srv_ntsvcs_nt.o \
748                  librpc/gen_ndr/srv_ntsvcs.o
749
750 RPC_NETDFS_OBJ =  librpc/gen_ndr/srv_dfs.o \
751                   rpc_server/dfs/srv_dfs_nt.o
752
753 RPC_SPOOLSS_OBJ = rpc_server/spoolss/srv_spoolss_nt.o \
754                   rpc_server/spoolss/srv_spoolss_util.o \
755                   librpc/gen_ndr/srv_spoolss.o
756
757 RPC_EVENTLOG_OBJ = rpc_server/eventlog/srv_eventlog_nt.o \
758                    rpc_server/eventlog/srv_eventlog_reg.o \
759                    $(LIB_EVENTLOG_OBJ) librpc/gen_ndr/srv_eventlog.o
760
761 NPA_TSTREAM_OBJ = ../libcli/named_pipe_auth/npa_tstream.o \
762                   librpc/gen_ndr/ndr_named_pipe_auth.o \
763                   ../auth/auth_sam_reply.o librpc/gen_ndr/ndr_auth.o ../librpc/ndr/ndr_auth.o
764
765 RPC_NCACN_NP = rpc_server/srv_pipe_register.o rpc_server/rpc_ncacn_np.o \
766                rpc_server/rpc_handles.o rpc_server/rpc_contexts.o \
767                rpc_server/srv_access_check.o
768
769 RPC_CONFIG = rpc_server/rpc_config.o
770
771 RPC_SERVICE = rpc_server/rpc_server.o
772
773 RPC_CRYPTO = rpc_server/dcesrv_auth_generic.o
774
775 RPC_PIPE_OBJ = rpc_server/srv_pipe.o rpc_server/srv_pipe_hnd.o \
776                $(RPC_CONFIG) $(RPC_NCACN_NP) $(RPC_SERVICE) $(RPC_CRYPTO)
777
778 RPC_RPCECHO_OBJ = rpc_server/echo/srv_echo_nt.o librpc/gen_ndr/srv_echo.o
779
780 RPC_EPMAPPER_OBJ = rpc_server/epmapper/srv_epmapper.o librpc/gen_ndr/srv_epmapper.o
781
782 RPC_SERVER_REGISTER_OBJ = rpc_server/rpc_ep_register.o $(DCE_RPC_EP_OBJ)
783
784 RPC_SERVER_OBJ = $(RPC_LSARPC_OBJ) $(RPC_WINREG_OBJ) $(RPC_INITSHUTDOWN_OBJ) \
785                  $(RPC_DSSETUP_OBJ) $(RPC_WKSSVC_OBJ) $(RPC_SVCCTL_OBJ) \
786                  $(RPC_NTSVCS_OBJ) $(RPC_NETLOGON_OBJ) $(RPC_NETDFS_OBJ) \
787                  $(RPC_SRVSVC_OBJ) $(RPC_SPOOLSS_OBJ) $(RPC_EVENTLOG_OBJ) \
788                  $(RPC_SAMR_OBJ) $(RPC_RPCECHO_OBJ) $(RPC_EPMAPPER_OBJ) \
789                  $(RPC_PIPE_OBJ) $(NPA_TSTREAM_OBJ) \
790                  $(LIBCLI_SPOOLSS_OBJ) \
791                  $(LIBCLI_WINREG_INT_OBJ) \
792                  $(LIBCLI_SRVSVC_OBJ) \
793                  $(LIBCLI_LSA_OBJ) \
794                  $(LIBCLI_SAMR_OBJ) \
795                  $(LIBCLI_NETLOGON_OBJ) \
796                  $(RPC_SERVER_REGISTER_OBJ) \
797                  $(RPC_CLIENT_SCHANNEL_OBJ) \
798                  rpc_server/rpc_sock_helper.o \
799                  rpc_server/rpc_service_setup.o \
800                  rpc_client/init_netlogon.o \
801                  rpc_client/init_samr.o
802
803 RPC_CLIENT_SCHANNEL_OBJ = rpc_client/cli_pipe_schannel.o
804
805 LOCKING_OBJ = locking/locking.o locking/brlock.o locking/posix.o \
806                 librpc/gen_ndr/ndr_open_files.o locking/share_mode_lock.o
807
808 PRIVILEGES_BASIC_OBJ = ../libcli/security/privileges.o
809
810 PRIVILEGES_OBJ = lib/privileges.o
811
812 PASSDB_GET_SET_OBJ = passdb/pdb_get_set.o
813
814 PASSDB_OBJ = $(PASSDB_GET_SET_OBJ) passdb/passdb.o passdb/pdb_interface.o \
815                 lib/util_wellknown.o lib/util_builtin.o passdb/pdb_compat.o \
816                 lib/util_unixsids.o passdb/lookup_sid.o \
817                 passdb/login_cache.o @PDB_STATIC@ \
818                 passdb/account_pol.o $(PRIVILEGES_OBJ) \
819                 lib/util_nscd.o lib/winbind_util.o $(SERVER_MUTEX_OBJ) \
820                 passdb/pdb_util.o passdb/pdb_ldap_schema.o \
821                 passdb/pdb_secrets.o
822
823 DEVEL_HELP_WEIRD_OBJ = ../lib/util/charset/weird.o
824 CHARSET_MACOSXFS_OBJ = ../lib/util/charset/charset_macosxfs.o
825
826 GROUPDB_OBJ = groupdb/mapping.o groupdb/mapping_tdb.o
827
828 PROFILE_OBJ = profile/profile.o
829 PROFILES_OBJ = utils/profiles.o \
830                $(LIBSMB_ERR_OBJ) \
831                $(PARAM_OBJ) \
832                $(LIB_OBJ) $(LIB_DUMMY_OBJ) \
833                $(POPT_LIB_OBJ) \
834                $(REGFIO_OBJ)
835
836 OPLOCK_OBJ = smbd/oplock.o smbd/oplock_irix.o smbd/oplock_linux.o
837
838 NOTIFY_OBJ = smbd/notify.o smbd/notify_inotify.o smbd/notify_internal.o \
839              librpc/gen_ndr/ndr_notify.o
840
841 FNAME_UTIL_OBJ = lib/filename_util.o
842
843 VFS_DEFAULT_OBJ = modules/vfs_default.o
844 VFS_AUDIT_OBJ = modules/vfs_audit.o
845 VFS_EXTD_AUDIT_OBJ = modules/vfs_extd_audit.o
846 VFS_FULL_AUDIT_OBJ = modules/vfs_full_audit.o
847 VFS_FAKE_PERMS_OBJ = modules/vfs_fake_perms.o
848 VFS_RECYCLE_OBJ = modules/vfs_recycle.o
849 VFS_NETATALK_OBJ = modules/vfs_netatalk.o
850 VFS_DEFAULT_QUOTA_OBJ = modules/vfs_default_quota.o
851 VFS_READONLY_OBJ = modules/vfs_readonly.o modules/getdate.o
852 VFS_CAP_OBJ = modules/vfs_cap.o
853 VFS_EXPAND_MSDFS_OBJ = modules/vfs_expand_msdfs.o
854 VFS_SHADOW_COPY_OBJ = modules/vfs_shadow_copy.o
855 VFS_SHADOW_COPY2_OBJ = modules/vfs_shadow_copy2.o
856 VFS_AFSACL_OBJ = modules/vfs_afsacl.o
857 VFS_XATTR_TDB_OBJ = modules/vfs_xattr_tdb.o lib/xattr_tdb.o
858 VFS_POSIXACL_OBJ = modules/vfs_posixacl.o
859 VFS_AIXACL_OBJ = modules/vfs_aixacl.o modules/vfs_aixacl_util.o
860 VFS_AIXACL2_OBJ = modules/vfs_aixacl2.o modules/vfs_aixacl_util.o modules/nfs4_acls.o
861 VFS_SOLARISACL_OBJ = modules/vfs_solarisacl.o
862 VFS_ZFSACL_OBJ = modules/vfs_zfsacl.o modules/nfs4_acls.o
863 VFS_HPUXACL_OBJ = modules/vfs_hpuxacl.o
864 VFS_IRIXACL_OBJ = modules/vfs_irixacl.o
865 VFS_TRU64ACL_OBJ = modules/vfs_tru64acl.o
866 VFS_CATIA_OBJ = modules/vfs_catia.o
867 VFS_STREAMS_XATTR_OBJ = modules/vfs_streams_xattr.o
868 VFS_STREAMS_DEPOT_OBJ = modules/vfs_streams_depot.o
869 VFS_CACHEPRIME_OBJ = modules/vfs_cacheprime.o
870 VFS_PREALLOC_OBJ = modules/vfs_prealloc.o
871 VFS_COMMIT_OBJ = modules/vfs_commit.o
872 VFS_GPFS_OBJ = modules/vfs_gpfs.o modules/gpfs.o modules/nfs4_acls.o
873 VFS_GPFS_HSM_NOTIFY_OBJ = modules/vfs_gpfs_hsm_notify.o
874 VFS_NOTIFY_FAM_OBJ = modules/vfs_notify_fam.o
875 VFS_READAHEAD_OBJ = modules/vfs_readahead.o
876 VFS_TSMSM_OBJ = modules/vfs_tsmsm.o
877 VFS_FILEID_OBJ = modules/vfs_fileid.o
878 VFS_AIO_FORK_OBJ = modules/vfs_aio_fork.o
879 VFS_AIO_PTHREAD_OBJ = modules/vfs_aio_pthread.o
880 VFS_AIO_LINUX_OBJ = modules/vfs_aio_linux.o
881 VFS_PREOPEN_OBJ = modules/vfs_preopen.o
882 VFS_SYNCOPS_OBJ = modules/vfs_syncops.o
883 VFS_ACL_XATTR_OBJ = modules/vfs_acl_xattr.o
884 VFS_ACL_TDB_OBJ = modules/vfs_acl_tdb.o
885 VFS_SMB_TRAFFIC_ANALYZER_OBJ = modules/vfs_smb_traffic_analyzer.o
886 PERFCOUNT_TEST_OBJ = modules/perfcount_test.o
887 VFS_DIRSORT_OBJ = modules/vfs_dirsort.o
888 VFS_SCANNEDONLY_OBJ = modules/vfs_scannedonly.o
889 VFS_CROSSRENAME_OBJ = modules/vfs_crossrename.o
890 VFS_LINUX_XFS_SGID_OBJ = modules/vfs_linux_xfs_sgid.o
891 VFS_TIME_AUDIT_OBJ = modules/vfs_time_audit.o
892
893 PAM_ERRORS_OBJ = ../libcli/auth/pam_errors.o
894 PLAINTEXT_AUTH_OBJ = auth/pampass.o auth/pass_check.o $(PAM_ERRORS_OBJ)
895
896 SLCACHE_OBJ = libsmb/samlogon_cache.o
897
898 DCUTIL_OBJ  = libsmb/namequery_dc.o libsmb/trustdom_cache.o libsmb/trusts_util.o libsmb/dsgetdcname.o
899
900 AUTH_BUILTIN_OBJ = auth/auth_builtin.o
901 AUTH_DOMAIN_OBJ = auth/auth_domain.o
902 AUTH_SAM_OBJ = auth/auth_sam.o auth/check_samsec.o
903 AUTH_UNIX_OBJ = auth/auth_unix.o
904 AUTH_WINBIND_OBJ = auth/auth_winbind.o
905 AUTH_WBC_OBJ = auth/auth_wbc.o
906 AUTH_SCRIPT_OBJ = auth/auth_script.o
907 AUTH_NETLOGOND_OBJ = auth/auth_netlogond.o
908
909 AUTH_OBJ = auth/auth.o @AUTH_STATIC@ auth/auth_util.o auth/token_util.o \
910            auth/server_info.o \
911            auth/server_info_sam.o \
912            auth/user_info.o \
913            auth/user_util.o \
914            auth/user_krb5.o \
915            auth/auth_ntlmssp.o auth/auth_generic.o \
916            $(PLAINTEXT_AUTH_OBJ) $(SLCACHE_OBJ) $(DCUTIL_OBJ)
917
918 MANGLE_OBJ = smbd/mangle.o smbd/mangle_hash.o smbd/mangle_hash2.o
919
920 SMBD_OBJ_MAIN = smbd/server.o smbd/server_exit.o
921
922 BUILDOPT_OBJ = smbd/build_options.o
923
924 SMBD_OBJ_SRV = smbd/server_reload.o \
925                smbd/files.o smbd/connection.o \
926                smbd/utmp.o smbd/session.o \
927                smbd/dfree.o smbd/dir.o smbd/password.o smbd/conn.o smbd/conn_idle.o smbd/conn_msg.o \
928                smbd/share_access.o smbd/fileio.o \
929                smbd/ipc.o smbd/lanman.o smbd/negprot.o \
930                smbd/message.o smbd/nttrans.o smbd/pipes.o \
931                smbd/reply.o smbd/sesssetup.o smbd/trans2.o smbd/uid.o \
932                smbd/dosmode.o smbd/filename.o smbd/open.o smbd/close.o \
933                smbd/blocking.o smbd/sec_ctx.o smbd/srvstr.o \
934                smbd/vfs.o smbd/perfcount.o smbd/statcache.o smbd/seal.o \
935                smbd/posix_acls.o lib/sysacls.o \
936                smbd/process.o smbd/service.o param/service.o smbd/error.o \
937                rpc_server/epmd.o \
938                rpc_server/lsasd.o \
939                printing/printspoolss.o printing/spoolssd.o \
940                lib/sysquotas.o lib/sysquotas_linux.o \
941                lib/sysquotas_xfs.o lib/sysquotas_4A.o \
942                lib/sysquotas_nfs.o \
943                lib/smbd_shim.o \
944                lib/background.o \
945                smbd/fake_file.o \
946                smbd/quotas.o smbd/ntquotas.o $(AFS_OBJ) smbd/msdfs.o \
947                $(AFS_SETTOKEN_OBJ) smbd/aio.o smbd/statvfs.o \
948                smbd/dmapi.o smbd/signing.o \
949                smbd/file_access.o \
950                smbd/dnsregister.o smbd/globals.o \
951                smbd/smb2_server.o \
952                smbd/smb2_glue.o \
953                smbd/smb2_negprot.o \
954                smbd/smb2_sesssetup.o \
955                smbd/smb2_tcon.o \
956                smbd/smb2_create.o \
957                smbd/smb2_close.o \
958                smbd/smb2_flush.o \
959                smbd/smb2_read.o \
960                smbd/smb2_write.o \
961                smbd/smb2_lock.o \
962                smbd/smb2_ioctl.o \
963                smbd/smb2_keepalive.o \
964                smbd/smb2_find.o \
965                smbd/smb2_notify.o \
966                smbd/smb2_getinfo.o \
967                smbd/smb2_setinfo.o \
968                smbd/smb2_break.o \
969                $(MANGLE_OBJ) @VFS_STATIC@
970
971 SMBD_OBJ_BASE = $(PARAM_WITHOUT_REG_OBJ) $(SMBD_OBJ_SRV) $(LIBSMB_OBJ) \
972                 $(RPC_SERVER_OBJ) \
973                 $(LOCKING_OBJ) $(PASSDB_OBJ) $(PRINTING_OBJ) $(PROFILE_OBJ) \
974                 $(LIB_OBJ) $(PRINTBACKEND_OBJ) $(OPLOCK_OBJ) \
975                 $(NOTIFY_OBJ) $(FNAME_UTIL_OBJ) $(GROUPDB_OBJ) $(AUTH_OBJ) \
976                 $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) $(AVAHI_OBJ) \
977                 $(LIBADS_OBJ) $(KRBCLIENT_OBJ) $(LIBADS_SERVER_OBJ) $(LIBADS_PRINTER_OBJ) \
978                 $(REG_FULL_OBJ) $(POPT_LIB_OBJ) $(BUILDOPT_OBJ) \
979                 $(SMBLDAP_OBJ) $(LIBNET_OBJ) \
980                 $(LIBSMBCONF_OBJ) \
981                 $(PRIVILEGES_BASIC_OBJ) \
982                 $(REGFIO_OBJ) \
983                 $(REG_API_REGF_OBJ) \
984                 $(LIBNDR_XATTR_OBJ)
985
986 PRINTING_OBJ = printing/pcap.o printing/print_svid.o printing/print_aix.o \
987                printing/print_cups.o printing/print_generic.o \
988                printing/lpq_parse.o printing/load.o \
989                printing/print_iprint.o printing/print_standard.o \
990                printing/printer_list.o librpc/gen_ndr/ndr_printcap.o
991
992 PRINTBASE_OBJ = printing/notify.o printing/printing_db.o
993 PRINTBACKEND_OBJ = printing/printing.o \
994                    printing/nt_printing.o \
995                    printing/nt_printing_tdb.o \
996                    printing/nt_printing_migrate.o \
997                    printing/nt_printing_migrate_internal.o \
998                    printing/nt_printing_ads.o \
999                    librpc/gen_ndr/ndr_ntprinting.o \
1000                     ../librpc/ndr/ndr_ntprinting.o \
1001                    printing/queue_process.o \
1002                    $(PRINTBASE_OBJ)
1003
1004 SMBD_OBJ = $(SMBD_OBJ_BASE) $(SMBD_OBJ_MAIN)
1005
1006 NMBD_OBJ1 = nmbd/asyncdns.o nmbd/nmbd.o nmbd/nmbd_become_dmb.o \
1007             nmbd/nmbd_become_lmb.o nmbd/nmbd_browserdb.o \
1008             nmbd/nmbd_browsesync.o nmbd/nmbd_elections.o \
1009             nmbd/nmbd_incomingdgrams.o nmbd/nmbd_incomingrequests.o \
1010             nmbd/nmbd_lmhosts.o nmbd/nmbd_logonnames.o nmbd/nmbd_mynames.o \
1011             nmbd/nmbd_namelistdb.o nmbd/nmbd_namequery.o \
1012             nmbd/nmbd_nameregister.o nmbd/nmbd_namerelease.o \
1013             nmbd/nmbd_nodestatus.o nmbd/nmbd_packets.o \
1014             nmbd/nmbd_processlogon.o nmbd/nmbd_responserecordsdb.o \
1015             nmbd/nmbd_sendannounce.o nmbd/nmbd_serverlistdb.o \
1016             nmbd/nmbd_subnetdb.o nmbd/nmbd_winsproxy.o nmbd/nmbd_winsserver.o \
1017             nmbd/nmbd_workgroupdb.o nmbd/nmbd_synclists.o
1018
1019 NMBD_OBJ = $(NMBD_OBJ1) $(PARAM_OBJ) $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
1020            $(PROFILE_OBJ) $(LIB_NONSMBD_OBJ) $(POPT_LIB_OBJ) \
1021            $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ)
1022
1023 SWAT_OBJ1 = web/cgi.o web/diagnose.o web/startstop.o web/statuspage.o \
1024            web/swat.o web/neg_lang.o
1025
1026 SWAT_OBJ = $(SWAT_OBJ1) $(PARAM_OBJ) $(PRINTING_OBJ) $(PRINTBASE_OBJ) $(LIBSMB_OBJ) \
1027            $(LOCKING_OBJ) $(PASSDB_OBJ) $(KRBCLIENT_OBJ) \
1028            $(LIB_NONSMBD_OBJ) $(GROUPDB_OBJ) $(PLAINTEXT_AUTH_OBJ) \
1029            $(POPT_LIB_OBJ) $(SMBLDAP_OBJ) $(LIBMSRPC_GEN_OBJ) $(LIBMSRPC_OBJ) \
1030            $(PASSCHANGE_OBJ) $(FNAME_UTIL_OBJ) \
1031            $(LIBCLI_SAMR_OBJ) \
1032            rpc_client/init_lsa.o
1033
1034 STATUS_OBJ = utils/status.o utils/status_profile.o \
1035              $(LOCKING_OBJ) $(PARAM_OBJ) \
1036              smbd/notify_internal.o librpc/gen_ndr/ndr_notify.o \
1037              $(PROFILE_OBJ) $(LIB_NONSMBD_OBJ) $(POPT_LIB_OBJ) \
1038              $(LIBSMB_ERR_OBJ) $(FNAME_UTIL_OBJ)
1039
1040 SMBCONTROL_OBJ = utils/smbcontrol.o $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
1041         $(LIBSMB_ERR_OBJ) $(POPT_LIB_OBJ) $(PRINTBASE_OBJ)
1042
1043 SMBTREE_OBJ = utils/smbtree.o $(PARAM_OBJ) \
1044              $(PROFILE_OBJ) $(LIB_NONSMBD_OBJ) $(LIBSMB_OBJ) \
1045              $(KRBCLIENT_OBJ) $(POPT_LIB_OBJ) \
1046              $(PASSDB_OBJ) $(SMBLDAP_OBJ) $(GROUPDB_OBJ) \
1047              $(LIBMSRPC_GEN_OBJ) \
1048              $(LIBMSRPC_OBJ) \
1049              $(LIBCLI_SRVSVC_OBJ)
1050
1051 TESTPARM_OBJ = utils/testparm.o \
1052                $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) $(POPT_LIB_OBJ) \
1053                $(LIBSMB_ERR_OBJ)
1054
1055 SMBTA_UTIL_OBJ = utils/smbta-util.o $(PARAM_OBJ) $(POPT_LIB_OBJ) \
1056         $(LIB_NONSMBD_OBJ) \
1057         $(LIBSMB_ERR_OBJ) $(FNAME_UTIL_OBJ)
1058
1059 TEST_LP_LOAD_OBJ = param/test_lp_load.o \
1060                    $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
1061                    $(POPT_LIB_OBJ) $(LIBSAMBA_OBJ)
1062
1063 PASSWD_UTIL_OBJ = utils/passwd_util.o
1064
1065 SMBPASSWD_OBJ = utils/smbpasswd.o $(PASSWD_UTIL_OBJ) $(PASSCHANGE_OBJ) \
1066                 $(PARAM_OBJ) $(LIBSMB_OBJ) $(PASSDB_OBJ) \
1067                 $(GROUPDB_OBJ) $(LIB_NONSMBD_OBJ) $(KRBCLIENT_OBJ) \
1068                 $(POPT_LIB_OBJ) $(SMBLDAP_OBJ) \
1069                 $(LIBMSRPC_GEN_OBJ) $(LIBMSRPC_OBJ) \
1070                 $(LIBCLI_SAMR_OBJ) \
1071                 rpc_client/init_lsa.o
1072
1073 PDBEDIT_OBJ = utils/pdbedit.o $(PASSWD_UTIL_OBJ) $(PARAM_OBJ) $(PASSDB_OBJ) \
1074                 $(AFS_SETTOKEN_OBJ) \
1075                 $(LIB_NONSMBD_OBJ) $(GROUPDB_OBJ) \
1076                 $(LIBSMB_ERR_OBJ0) $(LIBSMB_ERR_OBJ1) $(SECRETS_OBJ) \
1077                 $(POPT_LIB_OBJ) $(SMBLDAP_OBJ) \
1078                 ../lib/util/asn1.o $(LIBCLI_LDAP_NDR_OBJ) \
1079                 $(LIBNDR_DRSUAPI_OBJ) $(LIBNDR_GEN_OBJ0) $(COMPRESSION_OBJ)
1080
1081 SMBGET_OBJ = utils/smbget.o $(POPT_LIB_OBJ) $(LIBSMBCLIENT_OBJ1)
1082
1083 DISPLAY_SEC_OBJ= ../libcli/security/display_sec.o
1084
1085 RPCCLIENT_OBJ1 = rpcclient/rpcclient.o rpcclient/cmd_lsarpc.o \
1086                  rpcclient/cmd_samr.o rpcclient/cmd_spoolss.o \
1087                  rpcclient/cmd_netlogon.o rpcclient/cmd_srvsvc.o \
1088                  rpcclient/cmd_dfs.o rpcclient/cmd_epmapper.o \
1089                  rpcclient/cmd_dssetup.o rpcclient/cmd_echo.o \
1090                  rpcclient/cmd_shutdown.o rpcclient/cmd_test.o \
1091                  rpcclient/cmd_wkssvc.o rpcclient/cmd_ntsvcs.o \
1092                  rpcclient/cmd_drsuapi.o rpcclient/cmd_eventlog.o \
1093                  rpcclient/cmd_winreg.o \
1094                  $(DISPLAY_SEC_OBJ)
1095
1096 RPCCLIENT_OBJ = $(RPCCLIENT_OBJ1) \
1097              $(PARAM_OBJ) $(LIBSMB_OBJ) $(LIB_NONSMBD_OBJ) \
1098              $(PASSDB_OBJ) $(LIBMSRPC_GEN_OBJ) $(LIBMSRPC_OBJ) \
1099              $(READLINE_OBJ) $(GROUPDB_OBJ) $(KRBCLIENT_OBJ) \
1100              $(LIBADS_OBJ) $(POPT_LIB_OBJ) \
1101              $(SMBLDAP_OBJ) $(DCUTIL_OBJ) \
1102              $(LIBCLI_SPOOLSS_OBJ) \
1103              $(LIBCLI_EVENTLOG_OBJ) \
1104              $(LIBCLI_NTSVCS_OBJ) \
1105              $(LIBCLI_DRSUAPI_OBJ) \
1106              $(LIBCLI_DFS_OBJ) \
1107              $(LIBCLI_ECHO_OBJ) \
1108              $(LIBCLI_DSSETUP_OBJ) \
1109              $(LIBCLI_WKSSVC_OBJ) \
1110              $(LIBCLI_SRVSVC_OBJ) \
1111              $(LIBCLI_LSA_OBJ) \
1112              $(LIBCLI_SAMR_OBJ) \
1113              $(LIBCLI_WINREG_OBJ) \
1114              $(LIBCLI_NETLOGON_OBJ) \
1115              $(RPC_CLIENT_SCHANNEL_OBJ) \
1116              rpc_client/init_netlogon.o \
1117              rpc_client/init_samr.o
1118
1119 PAM_WINBIND_OBJ = ../nsswitch/pam_winbind.o $(WBCOMMON_OBJ) \
1120                   $(LIBREPLACE_OBJ) @BUILD_INIPARSER@
1121
1122 LIBSMBCLIENT_THREAD_OBJ = \
1123                         libsmb/libsmb_thread_impl.o \
1124                         libsmb/libsmb_thread_posix.o
1125
1126 LIBSMBCLIENT_OBJ0 = \
1127                     libsmb/libsmb_cache.o \
1128                     libsmb/libsmb_compat.o \
1129                     libsmb/libsmb_context.o \
1130                     libsmb/libsmb_dir.o \
1131                     libsmb/libsmb_file.o \
1132                     libsmb/libsmb_misc.o \
1133                     libsmb/libsmb_path.o \
1134                     libsmb/libsmb_printjob.o \
1135                     libsmb/libsmb_server.o \
1136                     libsmb/libsmb_stat.o \
1137                     libsmb/libsmb_xattr.o \
1138                     libsmb/libsmb_setget.o
1139
1140 LIBSMBCLIENT_OBJ1 = $(LIBSMBCLIENT_OBJ0) \
1141                     $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
1142                     $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
1143                     $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) \
1144                     $(PASSDB_OBJ) $(SMBLDAP_OBJ) $(GROUPDB_OBJ) \
1145                     $(LIBCLI_SRVSVC_OBJ) \
1146                     $(LIBCLI_LSA_OBJ)
1147
1148 LIBSMBCLIENT_OBJ = $(LIBSMBCLIENT_OBJ1)
1149
1150 CLIENT_OBJ1 = client/client.o client/clitar.o \
1151               client/dnsbrowse.o \
1152               $(LIBMSRPC_OBJ)
1153
1154 CLIENT_OBJ = $(CLIENT_OBJ1) $(PARAM_OBJ) $(LIBSMB_OBJ) \
1155              $(LIB_NONSMBD_OBJ) $(KRBCLIENT_OBJ) $(LIBMSRPC_GEN_OBJ) \
1156              $(READLINE_OBJ) $(POPT_LIB_OBJ) \
1157              $(PASSDB_OBJ) $(SMBLDAP_OBJ) $(GROUPDB_OBJ) \
1158              $(DISPLAY_SEC_OBJ) \
1159              $(LIBCLI_SRVSVC_OBJ)
1160
1161 LIBSMBCONF_OBJ = ../lib/smbconf/smbconf.o \
1162                  ../lib/smbconf/smbconf_util.o \
1163                  ../lib/smbconf/smbconf_txt.o \
1164                  lib/smbconf/smbconf_reg.o \
1165                  lib/smbconf/smbconf_init.o
1166
1167 SMBCONFTORT_OBJ0 = lib/smbconf/testsuite.o
1168
1169 SMBCONFTORT_OBJ = $(SMBCONFTORT_OBJ0) \
1170                   $(LIB_NONSMBD_OBJ) \
1171                   $(PARAM_OBJ) \
1172                   $(LIBSMB_ERR_OBJ) \
1173                   $(POPT_LIB_OBJ)
1174
1175 PTHREADPOOLTEST_OBJ = lib/pthreadpool/pthreadpool.o \
1176                 lib/pthreadpool/tests.o
1177
1178 LIBNET_OBJ = libnet/libnet_join.o \
1179              libnet/libnet_keytab.o \
1180              librpc/gen_ndr/ndr_libnet_join.o
1181
1182 LIBNET_DSSYNC_OBJ = libnet/libnet_dssync.o \
1183                     libnet/libnet_dssync_passdb.o \
1184                     libnet/libnet_dssync_keytab.o \
1185                     ../libcli/drsuapi/repl_decrypt.o
1186
1187 LIBNET_SAMSYNC_OBJ = libnet/libnet_samsync.o \
1188                      libnet/libnet_samsync_ldif.o \
1189                      libnet/libnet_samsync_passdb.o \
1190                      libnet/libnet_samsync_display.o \
1191                      libnet/libnet_samsync_keytab.o \
1192                      ../libcli/samsync/decrypt.o
1193
1194 NET_OBJ1 = utils/net.o utils/net_ads.o utils/net_help.o \
1195            utils/net_rap.o utils/net_rpc.o utils/net_rpc_samsync.o \
1196            utils/net_rpc_join.o utils/net_time.o utils/net_lookup.o \
1197            utils/net_cache.o utils/net_groupmap.o utils/net_idmap.o \
1198            utils/net_idmap_check.o utils/interact.o \
1199            utils/net_status.o utils/net_rpc_printer.o utils/net_rpc_rights.o \
1200            utils/net_rpc_service.o utils/net_rpc_registry.o utils/net_usershare.o \
1201            utils/netlookup.o utils/net_sam.o utils/net_rpc_shell.o \
1202            utils/net_util.o utils/net_rpc_sh_acct.o utils/net_rpc_audit.o \
1203            $(PASSWD_UTIL_OBJ) utils/net_dns.o utils/net_ads_gpo.o \
1204            utils/net_conf.o utils/net_join.o utils/net_user.o \
1205            utils/net_group.o utils/net_file.o utils/net_registry.o utils/net_registry_check.o\
1206            auth/token_util.o utils/net_dom.o utils/net_share.o \
1207            utils/net_g_lock.o \
1208            utils/net_serverid.o \
1209            utils/net_eventlog.o \
1210            utils/net_printing.o \
1211            utils/net_rpc_trust.o \
1212            utils/net_rpc_conf.o\
1213            $(LIBNDR_NTPRINTING_OBJ) \
1214            $(LIBNDR_PREG_OBJ) \
1215            $(LIBCLI_SPOOLSS_OBJ) \
1216            $(LIBCLI_WINREG_OBJ) \
1217            $(LIBCLI_DRSUAPI_OBJ) \
1218            $(LIBCLI_INITSHUTDOWN_OBJ) \
1219            $(LIBCLI_DSSETUP_OBJ) \
1220            $(LIBCLI_SVCCTL_OBJ) \
1221            $(LIBCLI_WKSSVC_OBJ) \
1222            $(LIBCLI_SRVSVC_OBJ) \
1223            $(LIBCLI_LSA_OBJ) \
1224            $(LIBCLI_SAMR_OBJ) \
1225            $(LIBCLI_NETLOGON_OBJ) \
1226            $(RPC_CLIENT_SCHANNEL_OBJ) \
1227            rpc_client/init_netlogon.o \
1228            rpc_client/init_samr.o \
1229            registry/reg_parse.o registry/reg_format.o \
1230            registry/reg_import.o \
1231            printing/nt_printing_migrate.o
1232
1233 # these are not processed by make proto
1234 NET_OBJ2 = utils/net_registry_util.o utils/net_help_common.o
1235
1236 NET_OBJ = $(NET_OBJ1) \
1237           $(NET_OBJ2) @FAKE_KASERVER_OBJ@\
1238           $(PARAM_WITHOUT_REG_OBJ) $(LIBSMB_OBJ) \
1239           $(PASSDB_OBJ) $(GROUPDB_OBJ) \
1240           $(KRBCLIENT_OBJ) $(LIB_NONSMBD_OBJ) $(LIBADDNS_OBJ0) \
1241           $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) \
1242           $(LIBADS_OBJ) $(LIBADS_SERVER_OBJ) $(LIBADS_PRINTER_OBJ) $(POPT_LIB_OBJ) \
1243           $(SMBLDAP_OBJ) $(DCUTIL_OBJ) \
1244           $(AFS_OBJ) $(AFS_SETTOKEN_OBJ) $(READLINE_OBJ) \
1245           $(LIBGPO_OBJ) @BUILD_INIPARSER@ $(DISPLAY_SEC_OBJ) \
1246           $(REG_SMBCONF_OBJ) \
1247           $(LIBNET_OBJ) $(LIBNET_DSSYNC_OBJ) $(LIBNET_SAMSYNC_OBJ) \
1248           $(LIBSMBCONF_OBJ) \
1249           $(REGFIO_OBJ) \
1250           $(PRIVILEGES_BASIC_OBJ) \
1251           $(LIB_EVENTLOG_OBJ)
1252
1253 CUPS_OBJ = client/smbspool.o $(PARAM_OBJ) $(LIBSMB_OBJ) \
1254                 $(LIB_NONSMBD_OBJ) $(KRBCLIENT_OBJ) $(POPT_LIB_OBJ) \
1255                 $(AFS_SETTOKEN_OBJ) $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ)
1256
1257 NMBLOOKUP_OBJ = utils/nmblookup.o $(PARAM_OBJ) $(LIBNMB_OBJ) \
1258                $(LIB_NONSMBD_OBJ) $(POPT_LIB_OBJ) $(LIBSMB_ERR_OBJ)
1259
1260 SMBTORTURE_OBJ1 = torture/torture.o torture/nbio.o torture/scanner.o torture/utable.o \
1261                 torture/denytest.o torture/mangle_test.o \
1262                 torture/nbench.o \
1263                 torture/test_async_echo.o \
1264                 torture/test_smbsock_any_connect.o \
1265                 torture/test_nttrans_create.o \
1266                 torture/test_nttrans_fsctl.o \
1267                 torture/test_notify_online.o \
1268                 torture/test_addrchange.o \
1269                 torture/test_case_insensitive.o \
1270                 torture/test_posix_append.o \
1271                 torture/test_smb2.o \
1272                 torture/test_chain3.o \
1273                 torture/test_authinfo_structs.o \
1274                 torture/test_cleanup.o \
1275                 torture/test_ctdbconn.o \
1276                 torture/test_msg.o \
1277                 torture/test_notify.o \
1278                 torture/test_dbwrap_watch.o \
1279                 torture/test_idmap_tdb_common.o \
1280                 torture/t_strappend.o
1281
1282 SMBTORTURE_OBJ = $(SMBTORTURE_OBJ1) $(PARAM_OBJ) $(TLDAP_OBJ) \
1283         $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) $(LIB_NONSMBD_OBJ) $(LOCKING_OBJ) \
1284         @LIBWBCLIENT_STATIC@ \
1285         torture/wbc_async.o \
1286         ../nsswitch/wb_reqtrans.o \
1287         ../libcli/lsarpc/util_lsarpc.o \
1288         lib/filename_util.o \
1289         $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) $(LIBCLI_ECHO_OBJ)
1290
1291 MASKTEST_OBJ = torture/masktest.o $(PARAM_OBJ) $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
1292                 $(LIB_NONSMBD_OBJ) \
1293                 $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ)
1294
1295 MSGTEST_OBJ = torture/msgtest.o $(PARAM_OBJ) $(LIBSMB_ERR_OBJ) \
1296                  $(LIB_NONSMBD_OBJ) \
1297                  $(LIBNDR_GEN_OBJ0)
1298
1299 LOCKTEST_OBJ = torture/locktest.o $(PARAM_OBJ) $(LOCKING_OBJ) $(KRBCLIENT_OBJ) \
1300                 $(LIBSMB_OBJ) $(LIB_NONSMBD_OBJ) \
1301                 $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) $(FNAME_UTIL_OBJ)
1302
1303 NSSTEST_OBJ = ../nsswitch/nsstest.o $(LIBSAMBAUTIL_OBJ)
1304
1305 PDBTEST_OBJ = torture/pdbtest.o $(PARAM_OBJ) $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
1306                 $(LIB_NONSMBD_OBJ) $(PASSDB_OBJ) $(GROUPDB_OBJ) \
1307                 $(SMBLDAP_OBJ) $(POPT_LIB_OBJ) \
1308                 $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ)
1309
1310 VFSTEST_OBJ = torture/cmd_vfs.o torture/vfstest.o $(SMBD_OBJ_BASE) $(READLINE_OBJ) \
1311                 torture/vfstest_chain.o
1312
1313 LOG2PCAP_OBJ = utils/log2pcaphex.o
1314
1315 LOCKTEST2_OBJ = torture/locktest2.o $(PARAM_OBJ) $(LOCKING_OBJ) $(LIBSMB_OBJ) \
1316                 $(KRBCLIENT_OBJ) $(LIB_NONSMBD_OBJ) \
1317                 $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) $(FNAME_UTIL_OBJ)
1318
1319 SMBCACLS_OBJ = utils/smbcacls.o $(PARAM_OBJ) $(LIBSMB_OBJ) \
1320                 $(KRBCLIENT_OBJ) $(LIB_NONSMBD_OBJ) \
1321                 $(PASSDB_OBJ) $(GROUPDB_OBJ) $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) \
1322                 $(POPT_LIB_OBJ) $(SMBLDAP_OBJ) \
1323                 $(LIBCLI_LSA_OBJ)
1324
1325 SMBCQUOTAS_OBJ = utils/smbcquotas.o $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
1326                 $(PARAM_OBJ) \
1327                 $(LIB_NONSMBD_OBJ) \
1328                 $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) $(POPT_LIB_OBJ) \
1329                 $(PASSDB_OBJ) $(SMBLDAP_OBJ) $(GROUPDB_OBJ) \
1330                 $(LIBCLI_LSA_OBJ)
1331
1332 EVTLOGADM_OBJ0  = utils/eventlogadm.o
1333
1334 EVTLOGADM_OBJ   = $(EVTLOGADM_OBJ0) $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
1335                 $(LIBSMB_ERR_OBJ) $(LIB_EVENTLOG_OBJ) \
1336                 librpc/gen_ndr/ndr_eventlog.o \
1337                 librpc/gen_ndr/ndr_lsa.o
1338
1339 SHARESEC_OBJ0 = utils/sharesec.o
1340 SHARESEC_OBJ  = $(SHARESEC_OBJ0) $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
1341                 $(LIBSMB_ERR_OBJ) \
1342                 $(POPT_LIB_OBJ)
1343
1344 TALLOCTORT_OBJ = @tallocdir@/testsuite.o @tallocdir@/testsuite_main.o \
1345                 $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) $(LIBSMB_ERR_OBJ)
1346
1347 REPLACETORT_OBJ = @libreplacedir@/test/testsuite.o \
1348                 @libreplacedir@/test/getifaddrs.o \
1349                 @libreplacedir@/test/os2_delete.o \
1350                 @libreplacedir@/test/strptime.o \
1351                 @libreplacedir@/test/main.o \
1352                 $(LIBREPLACE_OBJ) $(SOCKET_WRAPPER_OBJ)
1353
1354 DEBUG2HTML_OBJ = utils/debug2html.o utils/debugparse.o
1355
1356 SMBFILTER_OBJ = utils/smbfilter.o $(PARAM_OBJ) $(LIBSMB_OBJ) \
1357                 $(LIB_NONSMBD_OBJ) $(KRBCLIENT_OBJ) \
1358                 $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ)
1359
1360 WINBIND_WINS_NSS_OBJ = ../nsswitch/wins.o $(PARAM_OBJ) \
1361         $(LIB_NONSMBD_OBJ) $(LIBSMB_ERR_OBJ) $(LIBNMB_OBJ)
1362
1363 PAM_SMBPASS_OBJ_0 = pam_smbpass/pam_smb_auth.o pam_smbpass/pam_smb_passwd.o \
1364                 pam_smbpass/pam_smb_acct.o pam_smbpass/support.o
1365 PAM_SMBPASS_OBJ = $(PAM_SMBPASS_OBJ_0) $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) $(PASSDB_OBJ) $(GROUPDB_OBJ) \
1366                 $(SMBLDAP_OBJ) \
1367                 $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
1368                 $(AFS_SETTOKEN_OBJ) \
1369                 $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) \
1370                 $(PAM_ERRORS_OBJ)
1371
1372 IDMAP_RW_OBJ = winbindd/idmap_rw.o
1373
1374 IDMAP_TDB_COMMON_OBJ = winbindd/idmap_tdb_common.o
1375
1376 IDMAP_UTIL_OBJ = winbindd/idmap_util.o $(IDMAP_RW_OBJ) \
1377                  $(IDMAP_TDB_COMMON_OBJ)
1378
1379 IDMAP_OBJ     =  winbindd/idmap.o $(IDMAP_UTIL_OBJ) @IDMAP_STATIC@
1380
1381 NSS_INFO_OBJ = winbindd/nss_info.o @NSS_INFO_STATIC@
1382
1383 IDMAP_HASH_OBJ = \
1384                 winbindd/idmap_hash/idmap_hash.o \
1385                 winbindd/idmap_hash/mapfile.o
1386
1387 IDMAP_ADEX_OBJ = \
1388                 winbindd/idmap_adex/idmap_adex.o \
1389                 winbindd/idmap_adex/cell_util.o \
1390                 winbindd/idmap_adex/likewise_cell.o \
1391                 winbindd/idmap_adex/provider_unified.o \
1392                 winbindd/idmap_adex/gc_util.o \
1393                 winbindd/idmap_adex/domain_util.o
1394
1395 WINBINDD_OBJ1 = \
1396                 winbindd/winbindd.o       \
1397                 winbindd/winbindd_group.o \
1398                 winbindd/winbindd_util.o  \
1399                 winbindd/winbindd_cache.o \
1400                 winbindd/winbindd_pam.o   \
1401                 winbindd/winbindd_misc.o  \
1402                 winbindd/winbindd_cm.o    \
1403                 winbindd/winbindd_wins_byip.o  \
1404                 winbindd/winbindd_wins_byname.o  \
1405                 winbindd/winbindd_msrpc.o \
1406                 winbindd/winbindd_rpc.o   \
1407                 winbindd/winbindd_reconnect.o \
1408                 winbindd/winbindd_ads.o   \
1409                 winbindd/winbindd_samr.o \
1410                 winbindd/winbindd_dual.o  \
1411                 winbindd/winbindd_dual_ndr.o  \
1412                 winbindd/winbindd_dual_srv.o  \
1413                 librpc/gen_ndr/ndr_wbint_c.o \
1414                 librpc/gen_ndr/srv_wbint.o \
1415                 librpc/gen_ndr/ndr_wbint.o \
1416                 librpc/gen_ndr/ndr_idmap.o \
1417                 winbindd/winbindd_async.o \
1418                 winbindd/winbindd_creds.o \
1419                 winbindd/winbindd_cred_cache.o \
1420                 winbindd/winbindd_ccache_access.o \
1421                 winbindd/winbindd_domain.o \
1422                 winbindd/winbindd_idmap.o \
1423                 winbindd/winbindd_locator.o \
1424                 winbindd/winbindd_ndr.o \
1425                 winbindd/wb_ping.o \
1426                 winbindd/wb_lookupsid.o \
1427                 winbindd/wb_lookupsids.o \
1428                 winbindd/wb_lookupname.o \
1429                 winbindd/wb_sid2uid.o \
1430                 winbindd/wb_sid2gid.o \
1431                 winbindd/wb_uid2sid.o \
1432                 winbindd/wb_gid2sid.o \
1433                 winbindd/wb_queryuser.o \
1434                 winbindd/wb_lookupuseraliases.o \
1435                 winbindd/wb_lookupusergroups.o \
1436                 winbindd/wb_getpwsid.o \
1437                 winbindd/wb_gettoken.o \
1438                 winbindd/wb_seqnum.o \
1439                 winbindd/wb_seqnums.o \
1440                 winbindd/wb_group_members.o \
1441                 winbindd/wb_getgrsid.o \
1442                 winbindd/wb_query_user_list.o \
1443                 winbindd/wb_fill_pwent.o \
1444                 winbindd/wb_next_pwent.o \
1445                 winbindd/wb_next_grent.o \
1446                 winbindd/wb_dsgetdcname.o \
1447                 winbindd/winbindd_lookupsid.o \
1448                 winbindd/winbindd_lookupsids.o \
1449                 winbindd/winbindd_lookupname.o \
1450                 winbindd/winbindd_sid_to_uid.o \
1451                 winbindd/winbindd_sid_to_gid.o \
1452                 winbindd/winbindd_uid_to_sid.o \
1453                 winbindd/winbindd_gid_to_sid.o \
1454                 winbindd/winbindd_sids_to_xids.o \
1455                 winbindd/winbindd_allocate_uid.o \
1456                 winbindd/winbindd_allocate_gid.o \
1457                 winbindd/winbindd_getpwsid.o \
1458                 winbindd/winbindd_getpwnam.o \
1459                 winbindd/winbindd_getpwuid.o \
1460                 winbindd/winbindd_getsidaliases.o \
1461                 winbindd/winbindd_getuserdomgroups.o \
1462                 winbindd/winbindd_getgroups.o \
1463                 winbindd/winbindd_show_sequence.o \
1464                 winbindd/winbindd_getgrgid.o \
1465                 winbindd/winbindd_getgrnam.o \
1466                 winbindd/winbindd_getusersids.o \
1467                 winbindd/winbindd_lookuprids.o \
1468                 winbindd/winbindd_setpwent.o \
1469                 winbindd/winbindd_getpwent.o \
1470                 winbindd/winbindd_endpwent.o \
1471                 winbindd/winbindd_setgrent.o \
1472                 winbindd/winbindd_getgrent.o \
1473                 winbindd/winbindd_endgrent.o \
1474                 winbindd/winbindd_dsgetdcname.o \
1475                 winbindd/winbindd_getdcname.o \
1476                 winbindd/winbindd_list_users.o \
1477                 winbindd/winbindd_list_groups.o \
1478                 winbindd/winbindd_check_machine_acct.o \
1479                 winbindd/winbindd_change_machine_acct.o \
1480                 winbindd/winbindd_ping_dc.o \
1481                 winbindd/winbindd_pam_auth.o \
1482                 winbindd/winbindd_pam_auth_crap.o \
1483                 winbindd/winbindd_pam_chauthtok.o \
1484                 winbindd/winbindd_pam_chng_pswd_auth_crap.o \
1485                 winbindd/winbindd_pam_logoff.o \
1486                 auth/auth_util.o \
1487                 auth/token_util.o \
1488                 auth/user_util.o \
1489                 auth/check_samsec.o \
1490                 auth/server_info.o \
1491                 auth/server_info_sam.o \
1492                 auth/user_info.o \
1493                 auth/pampass.o \
1494                 ../nsswitch/wb_reqtrans.o
1495
1496 WINBINDD_OBJ = \
1497                 $(WINBINDD_OBJ1) $(PASSDB_OBJ) $(GROUPDB_OBJ) \
1498                 $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
1499                 $(LIBSMB_OBJ) $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) \
1500                 $(PROFILE_OBJ) $(SLCACHE_OBJ) $(SMBLDAP_OBJ) \
1501                 $(LIBADS_OBJ) $(KRBCLIENT_OBJ) $(POPT_LIB_OBJ) \
1502                 $(DCUTIL_OBJ) $(IDMAP_OBJ) $(NSS_INFO_OBJ) \
1503                 $(RPC_CONFIG) $(RPC_NCACN_NP) \
1504                 $(RPC_SAMR_OBJ) $(RPC_LSARPC_OBJ) \
1505                 $(NPA_TSTREAM_OBJ) \
1506                 $(AFS_OBJ) $(AFS_SETTOKEN_OBJ) \
1507                 $(LIBADS_SERVER_OBJ) \
1508                 $(TDB_VALIDATE_OBJ) \
1509                 $(LIBCLI_DSSETUP_OBJ) \
1510                 $(LIBCLI_LSA_OBJ) \
1511                 $(LIBCLI_SAMR_OBJ) \
1512                 $(LIBCLI_NETLOGON_OBJ) \
1513                 rpc_client/init_netlogon.o \
1514                 rpc_client/init_samr.o \
1515                 $(PAM_ERRORS_OBJ)
1516
1517 WBINFO_OBJ = ../nsswitch/wbinfo.o $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) \
1518                 $(POPT_LIB_OBJ) $(AFS_SETTOKEN_OBJ) \
1519                 lib/winbind_util.o $(WBCOMMON_OBJ) \
1520                 $(LIBSMB_ERR_OBJ0) $(LIBSMB_ERR_OBJ1) $(SECRETS_OBJ)
1521
1522 WINBIND_NSS_OBJ = $(WBCOMMON_OBJ) $(LIBREPLACE_OBJ) @WINBIND_NSS_EXTRA_OBJS@
1523
1524 WINBIND_KRB5_LOCATOR_OBJ1 = ../nsswitch/winbind_krb5_locator.o
1525 WINBIND_KRB5_LOCATOR_OBJ = $(WINBIND_KRB5_LOCATOR_OBJ1) $(LIBREPLACE_OBJ)
1526
1527 POPT_OBJ=../lib/popt/findme.o ../lib/popt/popt.o ../lib/popt/poptconfig.o \
1528           ../lib/popt/popthelp.o ../lib/popt/poptparse.o
1529
1530 INIPARSER_OBJ = ../lib/iniparser_build/iniparser.o ../lib/iniparser_build/dictionary.o \
1531                 ../lib/iniparser_build/strlib.o
1532
1533 TDBBACKUP_OBJ = @tdbdir@/tools/tdbbackup.o $(LIBREPLACE_OBJ) \
1534         $(SOCKET_WRAPPER_OBJ)
1535
1536 TDBTOOL_OBJ = @tdbdir@/tools/tdbtool.o $(LIBREPLACE_OBJ) \
1537         $(SOCKET_WRAPPER_OBJ)
1538
1539 TDBDUMP_OBJ = @tdbdir@/tools/tdbdump.o $(LIBREPLACE_OBJ) \
1540         $(SOCKET_WRAPPER_OBJ)
1541
1542 TDBRESTORE_OBJ = @tdbdir@/tools/tdbrestore.o $(LIBREPLACE_OBJ) \
1543         $(SOCKET_WRAPPER_OBJ)
1544
1545 TDBTORTURE_OBJ = @tdbdir@/tools/tdbtorture.o $(LIBREPLACE_OBJ) \
1546         $(SOCKET_WRAPPER_OBJ)
1547
1548
1549 NTLM_AUTH_OBJ1 = utils/ntlm_auth.o utils/ntlm_auth_diagnostics.o
1550
1551 NTLM_AUTH_OBJ = ${NTLM_AUTH_OBJ1} \
1552                 ${LIBADS_SERVER_OBJ} \
1553                 $(PASSDB_OBJ) $(GROUPDB_OBJ) \
1554                 $(WBCOMMON_OBJ) \
1555                 $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
1556                 $(AFS_SETTOKEN_OBJ) \
1557                 $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) \
1558                 $(POPT_LIB_OBJ) $(SMBLDAP_OBJ) @BUILD_INIPARSER@
1559
1560
1561 VLP_OBJ = printing/tests/vlp.o \
1562           ../lib/util/util_tdb.o \
1563           $(LIBSAMBAUTIL_OBJ) \
1564           param/util.o
1565
1566 RPC_OPEN_TCP_OBJ = torture/rpc_open_tcp.o \
1567                    $(LIBSMB_OBJ) \
1568                    $(PARAM_OBJ) \
1569                    $(PASSDB_OBJ) \
1570                    $(SMBLDAP_OBJ) $(GROUPDB_OBJ) \
1571                    $(LIB_NONSMBD_OBJ) \
1572                    $(KRBCLIENT_OBJ) \
1573                    $(LIBMSRPC_OBJ) \
1574                    $(LIBMSRPC_GEN_OBJ)
1575
1576 DBWRAP_TOOL_OBJ = utils/dbwrap_tool.o \
1577                   $(PARAM_OBJ) \
1578                   $(LIB_NONSMBD_OBJ) \
1579                   $(LIBSMB_ERR_OBJ) \
1580                   $(POPT_LIB_OBJ)
1581
1582 DBWRAP_TORTURE_OBJ = utils/dbwrap_torture.o \
1583                      $(PARAM_OBJ) \
1584                      $(LIB_NONSMBD_OBJ) \
1585                      $(LIBSMB_ERR_OBJ) \
1586                      $(POPT_LIB_OBJ)
1587
1588 SPLIT_TOKENS_OBJ = utils/split_tokens.o \
1589                    $(PARAM_OBJ) \
1590                    $(LIB_NONSMBD_OBJ) \
1591                    $(POPT_LIB_OBJ) \
1592                    $(LIBSAMBA_OBJ)
1593
1594 ######################################################################
1595 # now the rules...
1596 ######################################################################
1597 all:: SHOWFLAGS basics libs $(SBIN_PROGS) $(BIN_PROGS) \
1598         $(MODULES) $(NSS_MODULES) $(PAM_MODULES) \
1599         $(EXTRA_ALL_TARGETS)
1600
1601 basics:: samba3-idl mkparam
1602
1603 nss_modules:: $(NSS_MODULES)
1604
1605 pam_modules:: $(PAM_MODULES)
1606
1607 pam_smbpass: SHOWFLAGS bin/pam_smbpass.@SHLIBEXT@
1608
1609 pam_winbind: SHOWFLAGS bin/pam_winbind.@SHLIBEXT@
1610
1611 gpext_modules:: $(GPEXT_MODULES)
1612
1613 torture:: SHOWFLAGS basics $(TORTURE_PROGS) @SMBTORTURE4@
1614
1615 smbtorture : SHOWFLAGS bin/smbtorture
1616
1617 masktest : SHOWFLAGS bin/masktest
1618
1619 msgtest : SHOWFLAGS bin/msgtest
1620
1621 locktest : SHOWFLAGS bin/locktest
1622
1623 smbcacls : SHOWFLAGS bin/smbcacls
1624
1625 smbcquotas : SHOWFLAGS bin/smbcquotas
1626
1627 locktest2 : SHOWFLAGS bin/locktest2
1628
1629 debug2html : SHOWFLAGS bin/debug2html
1630
1631 smbfilter : SHOWFLAGS bin/smbfilter
1632
1633 eventlogadm: SHOWFLAGS bin/eventlogadm
1634
1635 sharesec: SHOWFLAGS bin/sharesec
1636
1637 talloctort : SHOWFLAGS $(TALLOCTORT)
1638
1639 replacetort : SHOWFLAGS bin/replacetort
1640
1641 smbconftort : SHOWFLAGS bin/smbconftort
1642
1643 pthreadpooltest : SHOWFLAGS bin/pthreadpooltest
1644
1645 timelimit : SHOWFLAGS bin/timelimit
1646
1647 nsswitch : SHOWFLAGS bin/winbindd bin/wbinfo @WINBIND_NSS@ \
1648         @WINBIND_WINS_NSS@ @WINBIND_KRB5_LOCATOR@ \
1649         bin/pam_winbind.@SHLIBEXT@ bin/smbcontrol
1650
1651 wins : SHOWFLAGS @WINBIND_WINS_NSS@
1652
1653 modules:: SHOWFLAGS $(MODULES)
1654
1655
1656 #####################################################################
1657 ## Perl IDL Compiler
1658
1659 IDL_FILES = librpc/idl/messaging.idl \
1660             librpc/idl/libnetapi.idl \
1661             librpc/idl/wbint.idl \
1662             librpc/idl/perfcount.idl \
1663             librpc/idl/secrets.idl \
1664             librpc/idl/open_files.idl \
1665             librpc/idl/libnet_join.idl
1666
1667 samba3-idl::
1668         @PIDL_OUTPUTDIR="librpc/gen_ndr" PIDL_ARGS="$(PIDL_ARGS)" CPP="$(CPP)" PIDL="../pidl/pidl" \
1669          srcdir="$(srcdir)" ../librpc/build_idl.sh ../librpc/idl/*.idl
1670         @PIDL_OUTPUTDIR="librpc/gen_ndr" PIDL_ARGS="$(PIDL_ARGS)" CPP="$(CPP)" PIDL="../pidl/pidl" \
1671          srcdir="$(srcdir)" $(srcdir)/script/build_idl.sh $(IDL_FILES)
1672
1673 idl_full::
1674         @PIDL_OUTPUTDIR="librpc/gen_ndr" PIDL_ARGS="$(PIDL_ARGS)" CPP="$(CPP)" PIDL="../pidl/pidl" \
1675          srcdir="$(srcdir)" ../librpc/build_idl.sh --full ../librpc/idl/*.idl
1676         @PIDL_OUTPUTDIR="librpc/gen_ndr" PIDL_ARGS="$(PIDL_ARGS)" CPP="$(CPP)" PIDL="../pidl/pidl" \
1677          srcdir="$(srcdir)" $(srcdir)/script/build_idl.sh --full $(IDL_FILES)
1678
1679 mkparam: ../lib/param/param_local.h ../lib/param/param_global.h param/param_global.h ../lib/param/param_proto.h ../lib/param/s3_param.h
1680
1681 ../lib/param/param_local.h:
1682          $(PERL) ../script/mkparamdefs.pl $(srcdir)/../lib/param/param_functions.c --file ../lib/param/param_local.h --generate-scope=LOCAL
1683 ../lib/param/param_global.h:
1684          $(PERL) ../script/mkparamdefs.pl $(srcdir)/../lib/param/loadparm.c --file ../lib/param/param_global.h --generate-scope=GLOBAL
1685 param/param_global.h:
1686          $(PERL) ../script/mkparamdefs.pl $(srcdir)/param/loadparm.c --file param/param_global.h --generate-scope=GLOBAL
1687 ../lib/param/param_proto.h:
1688          $(PERL) ../source4/script/mkproto.pl $(srcdir)/../lib/param/loadparm.c --public ../lib/param/param_proto.h  --private ../lib/param/param_proto.h
1689 ../lib/param/s3_param.h:
1690          $(PERL) ../script/mks3param.pl $(srcdir)/../lib/param/loadparm.c --file ../lib/param/s3_param.h
1691
1692
1693 #####################################################################
1694
1695
1696 everything:: all libtalloc libsmbclient libnetapi debug2html smbfilter talloctort replacetort smbconftort modules torture \
1697         $(EVERYTHING_PROGS) \
1698         vfs_examples
1699
1700 .SUFFIXES:
1701 .SUFFIXES: .c .o .lo
1702
1703 .PHONY: showflags SHOWFLAGS
1704
1705 showflags: SHOWFLAGS
1706
1707 SHOWFLAGS::
1708         @echo "Using CFLAGS     = $(CFLAGS)"
1709         @echo "      PICFLAG    = $(PICFLAG)"
1710         @echo "      LIBS       = $(LIBS)"
1711         @echo "      LDFLAGS    = $(LDFLAGS)"
1712         @echo "      DYNEXP     = $(DYNEXP)"
1713         @echo "      LDSHFLAGS  = $(LDSHFLAGS)"
1714         @echo "      SHLIBEXT   = @SHLIBEXT@"
1715         @echo "      SONAMEFLAG = @SONAMEFLAG@"
1716
1717 # "showcflags" target for debuggin how CFLAGS are composed:
1718
1719 .PHONY: showcflags SHOWCFLAGS
1720
1721 showcflags: SHOWCFLAGS
1722
1723 SHOWCFLAGS::
1724         @echo "CFLAGS         = $(CFLAGS)"
1725         @echo "FLAGS          = $(FLAGS)"
1726         @echo ""
1727         @echo "FLAGS1         = @FLAGS1@"
1728         @echo "SAMBA_CPPFLAGS = @SAMBA_CPPFLAGS@"
1729         @echo "CPPFLAGS       = $(CPPFLAGS)"
1730         @echo "ISA            = $(ISA)"
1731
1732 MAKEDIR = || exec false; \
1733           if test -d "$$dir"; then :; else \
1734           echo mkdir "$$dir"; \
1735           mkdir -p "$$dir" >/dev/null 2>&1 || \
1736           test -d "$$dir" || \
1737           mkdir "$$dir" || \
1738           exec false; fi || exec false
1739
1740 # Run a static checker.
1741 CHECK_CC = $(CC_CHECKER) $(CFLAGS) $(PICFLAG) -c $< -o $@
1742 # Compile a source file.
1743 COMPILE_CC = $(CC) $(CFLAGS) $(PICFLAG) -c $< -o $@
1744 # Compile a source file with the installation paths defined.
1745 COMPILE_CC_PATH = $(CC) $(PATH_FLAGS) $(CFLAGS) $(PICFLAG) -c $< -o $@
1746
1747 COMPILE = $(COMPILE_CC)
1748
1749 .c.o:
1750         @if (: >> $@ || : > $@) >/dev/null 2>&1; then rm -f $@; else \
1751          dir=`echo $@ | sed 's,/[^/]*$$,,;s,^$$,.,'` $(MAKEDIR); fi
1752         @if test -n "$(CC_CHECKER)"; then \
1753           echo "Checking  $*.c with '$(CC_CHECKER)'";\
1754           $(CHECK_CC); \
1755          fi
1756         @echo Compiling $*.c
1757         @$(COMPILE) && exit 0;\
1758                 echo "The following command failed:" 1>&2;\
1759                 echo "$(subst ",\",$(COMPILE_CC))" 1>&2;\
1760                 $(COMPILE_CC) >/dev/null 2>&1
1761 @BROKEN_CC@     -mv `echo $@ | sed 's%^.*/%%g'` $@
1762
1763 PRECOMPILED_HEADER = $(builddir)/include/includes.h.gch
1764
1765 # this adds support for precompiled headers. To use it, install a snapshot
1766 # of gcc-3.4 and run 'make pch' before you do the main build.
1767 pch::
1768         rm -f $(PRECOMPILED_HEADER)
1769         $(MAKE) $(PRECOMPILED_HEADER)
1770
1771 $(PRECOMPILED_HEADER): $(srcdir)/include/includes.h
1772         $(COMPILE)
1773
1774 BINARY_PREREQS = bin/.dummy
1775
1776 # These dependencies are only approximately correct: we want to make
1777 # sure Samba's paths are updated if ./configure is re-run.  Really it
1778 # would be nice if "make prefix=/opt/samba all" also rebuilt things,
1779 # but since we also require "make install prefix=/opt/samba" *not* to
1780 # rebuild it's a bit hard.
1781
1782 ../dynconfig/dynconfig.o: ../dynconfig/dynconfig.c Makefile
1783         @echo Compiling $*.c
1784         @$(COMPILE_CC_PATH) && exit 0;\
1785                 echo "The following command failed:" 1>&2;\
1786                 echo "$(COMPILE_CC_PATH)" 1>&2;\
1787                 $(COMPILE_CC_PATH) >/dev/null 2>&1
1788
1789 ../nsswitch/pam_winbind.o: ../nsswitch/pam_winbind.c Makefile
1790         @echo Compiling $*.c
1791         @$(COMPILE_CC_PATH) && exit 0;\
1792                 echo "The following command failed:" 1>&2;\
1793                 echo "$(COMPILE_CC_PATH)" 1>&2;\
1794                 $(COMPILE_CC_PATH) >/dev/null 2>&1
1795
1796 ../nsswitch/wb_common.o: ../nsswitch/wb_common.c Makefile
1797         @echo Compiling $*.c
1798         @$(COMPILE_CC_PATH) && exit 0;\
1799                 echo "The following command failed:" 1>&2;\
1800                 echo "$(COMPILE_CC_PATH)" 1>&2;\
1801                 $(COMPILE_CC_PATH) >/dev/null 2>&1
1802
1803 ### Start section of object files that require PTHREAD_CFLAGS
1804 ../nsswitch/wins.o: ../nsswitch/wins.c
1805         @echo Compiling $*.c
1806         @$(COMPILE) $(PTHREAD_CFLAGS) && exit 0;\
1807                 echo "The following command failed:" 1>&2;\
1808                 echo "$(COMPILE_CC) $(PTHREAD_CFLAGS)" 1>&2;\
1809                 $(COMPILE_CC) $(PTHREAD_CFLAGS) >/dev/null 2>&1
1810
1811 ../nsswitch/winbind_nss_linux.o: ../nsswitch/winbind_nss_linux.c
1812         @echo Compiling $*.c
1813         @$(COMPILE_CC) $(PTHREAD_CFLAGS) && exit 0;\
1814                 echo "The following command failed:" 1>&2;\
1815                 echo "$(COMPILE_CC) $(PTHREAD_CFLAGS)" 1>&2;\
1816                 $(COMPILE_CC) $(PTHREAD_CFLAGS) >/dev/null 2>&1
1817
1818 libsmb/libsmb_thread_impl.o: libsmb/libsmb_thread_impl.c
1819         @echo Compiling $*.c
1820         @$(COMPILE) $(PTHREAD_CFLAGS) && exit 0;\
1821                 echo "The following command failed:" 1>&2;\
1822                 echo "$(COMPILE_CC) $(PTHREAD_CFLAGS)" 1>&2;\
1823                 $(COMPILE_CC) $(PTHREAD_CFLAGS) >/dev/null 2>&1
1824
1825 libsmb/libsmb_thread_posix.o: libsmb/libsmb_thread_posix.c
1826         @echo Compiling $*.c
1827         @$(COMPILE) $(PTHREAD_CFLAGS) && exit 0;\
1828                 echo "The following command failed:" 1>&2;\
1829                 echo "$(COMPILE_CC) $(PTHREAD_CFLAGS)" 1>&2;\
1830                 $(COMPILE_CC) $(PTHREAD_CFLAGS) >/dev/null 2>&1
1831 ### End section of object files that require PTHREAD_CFLAGS
1832
1833 lib/pidfile.o: lib/pidfile.c
1834         @echo Compiling $*.c
1835         @$(COMPILE_CC_PATH) && exit 0;\
1836                 echo "The following command failed:" 1>&2;\
1837                 echo "$(COMPILE_CC_PATH)" 1>&2;\
1838                 $(COMPILE_CC_PATH) >/dev/null 2>&1
1839
1840 lib/version.o: lib/version.c include/autoconf/version.h
1841         @echo Compiling $*.c
1842         @$(COMPILE_CC_PATH) && exit 0;\
1843                 echo "The following command failed:" 1>&2;\
1844                 echo "$(COMPILE_CC_PATH)" 1>&2;\
1845                 $(COMPILE_CC_PATH) >/dev/null 2>&1
1846
1847 smbd/build_options.o: smbd/build_options.c Makefile include/autoconf/config.h include/build_env.h include/proto.h
1848         @echo Compiling $*.c
1849         @$(COMPILE_CC_PATH) && exit 0;\
1850                 echo "The following command failed:" 1>&2;\
1851                 echo "$(COMPILE_CC_PATH)" 1>&2;\
1852                 $(COMPILE_CC_PATH) >/dev/null 2>&1
1853
1854 smbd/build_options.c: include/autoconf/config.h.in script/mkbuildoptions.awk
1855         @echo Generating $@
1856         @dir=smbd $(MAKEDIR) && $(AWK) -f $(srcdir)/script/mkbuildoptions.awk > $(builddir)/smbd/build_options.c < $(srcdir)/include/autoconf/config.h.in
1857
1858 bin/.dummy:
1859         @if (: >> $@ || : > $@) >/dev/null 2>&1; then :; else \
1860           dir=bin $(MAKEDIR); fi
1861         @: >> $@ || : > $@ # what a fancy emoticon!
1862
1863 bin/smbd: $(BINARY_PREREQS) $(SMBD_OBJ) $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT) @BUILD_POPT@
1864         @echo Linking $@
1865         @$(CC) -o $@ $(SMBD_OBJ) $(LDFLAGS) $(LDAP_LIBS) @SMBD_FAM_LIBS@ \
1866                 $(KRB5LIBS) $(DYNEXP) $(PRINT_LIBS) $(AUTH_LIBS) \
1867                 $(ACL_LIBS) $(PASSDB_LIBS) $(LIBS) $(DNSSD_LIBS) $(AVAHI_LIBS) \
1868                 $(POPT_LIBS) @SMBD_LIBS@ $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) \
1869                 $(LIBWBCLIENT_LIBS) $(ZLIB_LIBS)
1870
1871 bin/nmbd: $(BINARY_PREREQS) $(NMBD_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
1872         @echo Linking $@
1873         @$(CC) -o $@ $(NMBD_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1874                 @LIBWBCLIENT_STATIC@ $(LIBWBCLIENT_LIBS) \
1875                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(POPT_LIBS) \
1876                 $(KRB5LIBS) $(LDAP_LIBS) $(ZLIB_LIBS)
1877
1878 bin/swat: $(BINARY_PREREQS) $(SWAT_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
1879         @echo Linking $@
1880         @$(CC) -o $@ $(SWAT_OBJ) $(LDFLAGS) $(DYNEXP) $(PRINT_LIBS) \
1881           $(AUTH_LIBS) $(LIBS) $(PASSDB_LIBS) $(POPT_LIBS) $(KRB5LIBS) \
1882           $(LDAP_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) $(ZLIB_LIBS)
1883
1884 bin/rpcclient: $(BINARY_PREREQS) $(RPCCLIENT_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
1885         @echo Linking $@
1886         @$(CC) -o $@ $(LDFLAGS) $(RPCCLIENT_OBJ) \
1887                 $(DYNEXP) $(TERMLDFLAGS) $(TERMLIBS) $(LIBS) $(POPT_LIBS) \
1888                 $(KRB5LIBS) $(LDAP_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) \
1889                 $(LIBWBCLIENT_LIBS) $(ZLIB_LIBS) $(PASSDB_LIBS)
1890
1891 bin/smbclient: $(BINARY_PREREQS) $(CLIENT_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
1892         @echo Linking $@
1893         @$(CC) -o $@ $(CLIENT_OBJ) $(LDFLAGS) $(DYNEXP) \
1894                 $(TERMLDFLAGS) $(TERMLIBS) $(LIBS) $(POPT_LIBS) \
1895                 $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) $(DNSSD_LIBS) \
1896                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) $(ZLIB_LIBS)
1897
1898 bin/net: $(BINARY_PREREQS) $(NET_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT) $(LIBNETAPI)
1899         @echo Linking $@
1900         @$(CC) -o $@ $(NET_OBJ) $(DYNEXP) $(LDFLAGS) $(LIBS) \
1901                 $(POPT_LIBS) $(KRB5LIBS) $(UUID_LIBS) $(LDAP_LIBS) \
1902                 $(PASSDB_LIBS) $(TERMLDFLAGS) $(TERMLIBS) $(NSCD_LIBS) \
1903                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) $(LIBNETAPI_LIBS) \
1904                 $(ZLIB_LIBS)
1905
1906 bin/profiles: $(BINARY_PREREQS) $(PROFILES_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB)
1907         @echo Linking $@
1908         @$(CC) -o $@ $(PROFILES_OBJ) $(DYNEXP) $(LDFLAGS) $(LIBS) \
1909                 $(LDAP_LIBS) $(POPT_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
1910
1911 bin/smbspool: $(BINARY_PREREQS) $(CUPS_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
1912         @echo Linking $@
1913         @$(CC) -o $@ $(CUPS_OBJ) $(DYNEXP) $(LDFLAGS) $(LIBS) \
1914                 @LIBWBCLIENT_STATIC@ $(LIBWBCLIENT_LIBS) \
1915                 $(KRB5LIBS) $(LDAP_LIBS) $(POPT_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(ZLIB_LIBS)
1916
1917 bin/testparm: $(BINARY_PREREQS) $(TESTPARM_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB)
1918         @echo Linking $@
1919         @$(CC) -o $@ $(TESTPARM_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1920                 $(LDAP_LIBS) $(POPT_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
1921
1922 bin/smbta-util: $(BINARY_PREREQS) $(SMBTA_UTIL_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB)
1923         @echo Linking $@
1924         @$(CC) -o $@ $(SMBTA_UTIL_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1925                 $(LDAP_LIBS) $(POPT_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
1926
1927 bin/smbstatus: $(BINARY_PREREQS) $(STATUS_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB)
1928         @echo Linking $@
1929         @$(CC) -o $@ $(STATUS_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1930                 $(LDAP_LIBS) $(POPT_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
1931
1932 bin/smbcontrol: $(BINARY_PREREQS) $(SMBCONTROL_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB)
1933         @echo Linking $@
1934         @$(CC) -DUSING_SMBCONTROL -o $@ \
1935                 $(SMBCONTROL_OBJ) $(DYNEXP) $(LDFLAGS) \
1936                 $(LIBS) $(LDAP_LIBS) @LIBUNWIND_PTRACE@ $(POPT_LIBS) \
1937                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
1938
1939 bin/smbtree: $(BINARY_PREREQS) $(SMBTREE_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
1940         @echo Linking $@
1941         @$(CC) -o $@ $(SMBTREE_OBJ) $(LDFLAGS) $(DYNEXP) \
1942                 $(LIBS) $(POPT_LIBS) $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) \
1943                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) $(ZLIB_LIBS)
1944
1945 bin/smbpasswd: $(BINARY_PREREQS) $(SMBPASSWD_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
1946         @echo Linking $@
1947         @$(CC) -o $@ $(SMBPASSWD_OBJ) $(LDFLAGS) $(PASSDB_LIBS) \
1948                 $(DYNEXP) $(LIBS) $(POPT_LIBS) $(KRB5LIBS) $(LDAP_LIBS) \
1949                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) $(ZLIB_LIBS)
1950
1951 bin/pdbedit: $(BINARY_PREREQS) $(PDBEDIT_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
1952         @echo Linking $@
1953         @$(CC) -o $@ $(PDBEDIT_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1954                 $(POPT_LIBS) $(PASSDB_LIBS) $(LDAP_LIBS) $(LIBTALLOC_LIBS) \
1955                 $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) $(ZLIB_LIBS)
1956
1957 bin/smbget: $(BINARY_PREREQS) $(SMBGET_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
1958         @echo Linking $@
1959         @$(CC) -o $@ $(SMBGET_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1960                 $(POPT_LIBS)  $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) \
1961                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) $(ZLIB_LIBS)
1962
1963 bin/nmblookup: $(BINARY_PREREQS) $(NMBLOOKUP_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB)
1964         @echo Linking $@
1965         @$(CC) -o $@ $(NMBLOOKUP_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
1966                 $(POPT_LIBS) $(LDAP_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
1967
1968 bin/smbtorture: $(BINARY_PREREQS) $(SMBTORTURE_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
1969         @echo Linking $@
1970         @$(CC) -o $@ $(SMBTORTURE_OBJ) $(IDMAP_UTIL_OBJ) $(LDFLAGS) $(DYNEXP) \
1971                 $(LIBS) $(KRB5LIBS) $(LDAP_LIBS) $(POPT_LIBS) $(LIBTALLOC_LIBS) \
1972                 $(LIBTDB_LIBS) $(ZLIB_LIBS) $(LIBWBCLIENT_LIBS)
1973
1974 bin/talloctort: $(BINARY_PREREQS) $(TALLOCTORT_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB)
1975         @echo Linking $@
1976         @$(CC) -o $@ $(TALLOCTORT_OBJ) $(LDFLAGS) \
1977                 $(DYNEXP) $(LIBS) $(LDAP_LIBS) $(POPT_LIBS) \
1978                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
1979
1980 bin/replacetort: $(REPLACETORT_OBJ) @BUILD_POPT@ $(LIBTALLOC)
1981         @echo Linking $@
1982         @$(CC) -o $@ $(REPLACETORT_OBJ) $(LDFLAGS) \
1983                 $(DYNEXP) $(LIBS) $(POPT_LIBS) $(LIBTALLOC_LIBS)
1984
1985 bin/smbconftort: $(SMBCONFTORT_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB)
1986         @echo Linking $@
1987         @$(CC) -o $@ $(SMBCONFTORT_OBJ) $(LDFLAGS) \
1988                 $(DYNEXP) $(LIBS) $(LDAP_LIBS) $(POPT_LIBS) \
1989                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
1990
1991 bin/pthreadpooltest: $(PTHREADPOOLTEST_OBJ)
1992         @echo Linking $@
1993         @$(CC) -o $@ $(PTHREADPOOLTEST_OBJ) $(LDFLAGS) $(LIBS) $(PTHREAD_LDFLAGS)
1994
1995 bin/masktest: $(BINARY_PREREQS) $(MASKTEST_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
1996         @echo Linking $@
1997         @$(CC) -o $@ $(MASKTEST_OBJ) $(LDFLAGS) $(DYNEXP) \
1998                 $(LIBS) $(KRB5LIBS) $(LDAP_LIBS) $(POPT_LIBS) \
1999                 @LIBWBCLIENT_STATIC@ $(LIBWBCLIENT_LIBS) \
2000                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(ZLIB_LIBS)
2001
2002 bin/msgtest: $(BINARY_PREREQS) $(MSGTEST_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB)
2003         @echo Linking $@
2004         @$(CC) -o $@ $(MSGTEST_OBJ) $(LDFLAGS) $(DYNEXP) \
2005                 $(LIBS) $(KRB5LIBS) $(LDAP_LIBS) $(POPT_LIBS) \
2006                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(ZLIB_LIBS)
2007
2008 bin/smbcacls: $(BINARY_PREREQS) $(SMBCACLS_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
2009         @echo Linking $@
2010         @$(CC) -o $@ $(SMBCACLS_OBJ) $(DYNEXP) $(LDFLAGS) \
2011                 $(LIBS) $(POPT_LIBS) $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) \
2012                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) $(ZLIB_LIBS)
2013
2014 bin/smbcquotas: $(BINARY_PREREQS) $(SMBCQUOTAS_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
2015         @echo Linking $@
2016         @$(CC) -o $@ $(SMBCQUOTAS_OBJ) $(DYNEXP) $(LDFLAGS) \
2017                 $(LIBS) $(POPT_LIBS) $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) \
2018                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) $(ZLIB_LIBS)
2019
2020 bin/eventlogadm: $(BINARY_PREREQS) $(EVTLOGADM_OBJ) $(LIBTALLOC) $(LIBTDB)
2021         @echo Linking $@
2022         @$(CC) -o $@ $(EVTLOGADM_OBJ) $(DYNEXP) $(LDFLAGS) \
2023                 $(LIBS) $(LDAP_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
2024
2025 bin/sharesec: $(BINARY_PREREQS) $(SHARESEC_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB)
2026         @echo Linking $@
2027         @$(CC) -o $@ $(SHARESEC_OBJ) $(DYNEXP) $(LDFLAGS) \
2028                 $(LIBS) $(LDAP_LIBS) $(POPT_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
2029
2030 bin/locktest: $(BINARY_PREREQS) $(LOCKTEST_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
2031         @echo Linking $@
2032         @$(CC) -o $@ $(LOCKTEST_OBJ) $(LDFLAGS) $(DYNEXP) \
2033                 $(LIBS) $(KRB5LIBS) $(LDAP_LIBS) $(POPT_LIBS) \
2034                 @LIBWBCLIENT_STATIC@ $(LIBWBCLIENT_LIBS) \
2035                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(ZLIB_LIBS)
2036
2037 bin/nsstest: $(BINARY_PREREQS) $(NSSTEST_OBJ) $(LIBTALLOC)
2038         @echo Linking $@
2039         @$(CC) -o $@ $(NSSTEST_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
2040                 $(LIBTALLOC_LIBS)
2041
2042 bin/pdbtest: $(BINARY_PREREQS) $(PDBTEST_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
2043         @echo Linking $@
2044         @$(CC) -o $@ $(PDBTEST_OBJ) $(LDFLAGS) $(DYNEXP) \
2045                 $(LIBS) $(KRB5LIBS) $(LDAP_LIBS) $(PASSDB_LIBS) \
2046                 $(POPT_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) $(ZLIB_LIBS)
2047
2048 bin/vfstest: $(BINARY_PREREQS) $(VFSTEST_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
2049         @echo Linking $@
2050         @$(CC) -o $@ $(VFSTEST_OBJ) $(LDFLAGS) $(TERMLDFLAGS) $(AVAHI_LIBS) \
2051                 $(TERMLIBS) $(DYNEXP) $(PRINT_LIBS) $(AUTH_LIBS) $(DNSSD_LIBS) \
2052                 $(ACL_LIBS) $(LIBS) $(POPT_LIBS) $(KRB5LIBS) $(LDAP_LIBS) \
2053                 @SMBD_LIBS@ $(NSCD_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) \
2054                 $(LIBWBCLIENT_LIBS) $(ZLIB_LIBS)
2055
2056 bin/log2pcap: $(BINARY_PREREQS) $(LOG2PCAP_OBJ) @BUILD_POPT@ $(LIBTALLOC)
2057         @echo Linking $@
2058         @$(CC) -o $@ $(LOG2PCAP_OBJ) $(LDFLAGS) $(DYNEXP) \
2059                 $(POPT_LIBS) $(LIBS) $(LIBTALLOC_LIBS)
2060
2061 bin/locktest2: $(BINARY_PREREQS) $(LOCKTEST2_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
2062         @echo Linking $@
2063         @$(CC) -o $@ $(LOCKTEST2_OBJ) $(LDFLAGS) $(DYNEXP) \
2064                 @LIBWBCLIENT_STATIC@ $(LIBWBCLIENT_LIBS) \
2065                 $(LIBS) $(KRB5LIBS) $(LDAP_LIBS) $(POPT_LIBS) \
2066                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(ZLIB_LIBS)
2067
2068 bin/debug2html: $(BINARY_PREREQS) $(DEBUG2HTML_OBJ) @BUILD_POPT@ $(LIBTALLOC)
2069         @echo Linking $@
2070         @$(CC) -o $@ $(DEBUG2HTML_OBJ) $(LDFLAGS) $(DYNEXP) \
2071                 $(LIBS) $(LIBTALLOC_LIBS)
2072
2073 bin/smbfilter: $(BINARY_PREREQS) $(SMBFILTER_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
2074         @echo Linking $@
2075         @$(CC) -o $@ $(SMBFILTER_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
2076                 $(KRB5LIBS) $(LDAP_LIBS) $(POPT_LIBS) \
2077                 @LIBWBCLIENT_STATIC@ $(LIBWBCLIENT_LIBS) \
2078                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(ZLIB_LIBS)
2079
2080 bin/versiontest: $(BINARY_PREREQS) lib/version_test.o $(VERSION_OBJ)
2081         @echo Linking $@
2082         @$(CC) $(FLAGS) -o $@ $(VERSION_OBJ) lib/version_test.o
2083
2084
2085 #####################################################################
2086 #
2087 # libraries
2088 #
2089 #####################################################################
2090
2091 MKSYMS_SH = $(srcdir)/script/mksyms.sh
2092
2093
2094 #-------------------------------------------------------------------
2095 #
2096 # libtalloc
2097 #
2098 #-------------------------------------------------------------------
2099
2100
2101 LIBTALLOC_OBJ0 = @LIBTALLOC_OBJ0@
2102 LIBTALLOC_OBJ = $(LIBTALLOC_OBJ0) $(LIBREPLACE_OBJ)
2103
2104 LIBTALLOC_SHARED_TARGET=@LIBTALLOC_SHARED_TARGET@
2105 LIBTALLOC_SOVER=@LIBTALLOC_SOVER@
2106 LIBTALLOC_FULLVER=@LIBTALLOC_FULLVER@
2107 LIBTALLOC_SHARED_TARGET_SONAME=@LIBTALLOC_SHARED_TARGET_SOVER@
2108 LIBTALLOC_SHARED_TARGET_FULLVER=@LIBTALLOC_SHARED_TARGET_FULLVER@
2109 LIBTALLOC_STATIC_TARGET=@LIBTALLOC_STATIC_TARGET@
2110 LIBTALLOC_SYMS=$(srcdir)/exports/libtalloc.@SYMSEXT@
2111 LIBTALLOC_HEADERS=$(srcdir)/@tallocdir@/talloc.h
2112
2113 $(LIBTALLOC_SYMS): $(LIBTALLOC_HEADERS)
2114         @$(MKSYMS_SH) $(AWK) $@ $(LIBTALLOC_HEADERS)
2115
2116 $(LIBTALLOC_SHARED_TARGET_SONAME): $(BINARY_PREREQS) $(LIBTALLOC_OBJ) $(LIBTALLOC_SYMS)
2117         @echo Linking shared library $@
2118         @$(SHLD_DSO) $(LIBTALLOC_OBJ) $(LIBREPLACE_LIBS) @SONAMEFLAG@`basename $@`
2119
2120 $(LIBTALLOC_SHARED_TARGET_FULLVER): $(LIBTALLOC_SHARED_TARGET_SONAME)
2121         @rm -f $@
2122         @mv -f $(LIBTALLOC_SHARED_TARGET_SONAME) $@
2123         @ln -f -s `basename $@` $(LIBTALLOC_SHARED_TARGET_SONAME)
2124
2125 $(LIBTALLOC_SHARED_TARGET): $(LIBTALLOC_SHARED_TARGET_FULLVER)
2126         @rm -f $@
2127         @ln -f -s `basename $(LIBTALLOC_SHARED_TARGET_SONAME)` $@
2128
2129 $(LIBTALLOC_STATIC_TARGET): $(BINARY_PREREQS) $(LIBTALLOC_OBJ0)
2130         @echo Linking non-shared library $@
2131         @-$(AR) -rc $@ $(LIBTALLOC_OBJ0)
2132 libtalloc: $(LIBTALLOC)
2133
2134 cleanlibtalloc::
2135         -rm -f \
2136                 $(LIBTALLOC_SYMS) \
2137                 $(LIBTALLOC_STATIC_TARGET) \
2138                 $(LIBTALLOC_SHARED_TARGET) \
2139                 $(LIBTALLOC_SHARED_TARGET_SONAME)
2140
2141 installlibtalloc:: installdirs libtalloc
2142         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2143         -$(INSTALLLIBCMD_SH) $(LIBTALLOC_SHARED_TARGET_FULLVER) $(DESTDIR)$(LIBDIR)
2144         @rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBTALLOC_SHARED_TARGET)`
2145         @rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBTALLOC_SHARED_TARGET_SONAME)`
2146         -if test -r $(LIBTALLOC_SHARED_TARGET_FULLVER) ; then \
2147                 ln -f -s `basename $(LIBTALLOC_SHARED_TARGET_FULLVER)` \
2148                         $(DESTDIR)$(LIBDIR)/`basename $(LIBTALLOC_SHARED_TARGET_SONAME)` ; \
2149         fi
2150         -if test -r $(LIBTALLOC_SHARED_TARGET_SONAME) ; then \
2151                 ln -f -s `basename $(LIBTALLOC_SHARED_TARGET_SONAME)` \
2152                         $(DESTDIR)$(LIBDIR)/`basename $(LIBTALLOC_SHARED_TARGET)` ; \
2153         fi
2154         -$(INSTALLLIBCMD_A) $(LIBTALLOC_STATIC_TARGET) $(DESTDIR)$(LIBDIR)
2155         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) ${prefix}/include
2156         -$(INSTALLCMD) -m $(INSTALLPERMS_DATA) $(LIBTALLOC_HEADERS) $(DESTDIR)${prefix}/include
2157
2158 uninstalllibtalloc::
2159         -rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBTALLOC_SHARED_TARGET)`
2160         -$(UNINSTALLLIBCMD_SH) $(DESTDIR)$(LIBDIR)/`basename $(LIBTALLOC_SHARED_TARGET_SONAME)`
2161         -$(UNINSTALLLIBCMD_A) $(DESTDIR)$(LIBDIR)/`basename $(LIBTALLOC_STATIC_TARGET)`
2162         -rm -f $(DESTDIR)${prefix}/include/talloc.h
2163
2164 libs:: libtalloc
2165 installlibs:: @INSTALL_LIBTALLOC@
2166 uninstalllibs:: @UNINSTALL_LIBTALLOC@
2167 cleanlibs:: cleanlibtalloc
2168 shlibs test_shlibs: @LIBTALLOC_SHARED@
2169
2170 showlibtalloc:
2171         @echo  ""
2172         @echo "LIBTALLOC_SHARED                = @LIBTALLOC_SHARED@"
2173         @echo "LIBTALLOC_STATIC                = @LIBTALLOC_STATIC@"
2174         @echo "LIBTALLOC_LIBS                  = $(LIBTALLOC_LIBS)"
2175         @echo ""
2176         @echo "LIBTALLOC_SHARED_TARGET         = $(LIBTALLOC_SHARED_TARGET)"
2177         @echo "LIBTALLOC_SOVER                 = $(LIBTALLOC_SOVER)"
2178         @echo "LIBTALLOC_FULLVER               = $(LIBTALLOC_FULLVER)"
2179         @echo "LIBTALLOC_SHARED TARGET_SONAME  = $(LIBTALLOC_SHARED_TARGET_SONAME)"
2180         @echo "LIBTALLOC_SHARED TARGET_FULLVER = $(LIBTALLOC_SHARED_TARGET_FULLVER)"
2181         @echo "LIBTALLOC_STATIC_TARGET         = $(LIBTALLOC_STATIC_TARGET)"
2182         @echo "LIBTALLOC                       = $(LIBTALLOC)"
2183
2184 showlibs:: showlibtalloc
2185
2186 #-------------------------------------------------------------------
2187 #
2188 # libtdb
2189 #
2190 #-------------------------------------------------------------------
2191
2192 LIBTDB_OBJ0 = @LIBTDB_OBJ0@
2193 LIBTDB_OBJ = $(LIBTDB_OBJ0) $(LIBREPLACE_OBJ)
2194
2195 LIBTDB_SHARED_TARGET=@LIBTDB_SHARED_TARGET@
2196 LIBTDB_SOVER=@LIBTDB_SOVER@
2197 LIBTDB_FULLVER=@LIBTDB_FULLVER@
2198 LIBTDB_SHARED_TARGET_SONAME=@LIBTDB_SHARED_TARGET_SOVER@
2199 LIBTDB_SHARED_TARGET_FULLVER=@LIBTDB_SHARED_TARGET_FULLVER@
2200 LIBTDB_STATIC_TARGET=@LIBTDB_STATIC_TARGET@
2201 LIBTDB_SYMS=$(srcdir)/exports/libtdb.@SYMSEXT@
2202 LIBTDB_HEADERS=$(srcdir)/@tdbdir@/include/tdb.h
2203
2204 $(LIBTDB_SYMS): $(LIBTDB_HEADERS)
2205         @$(MKSYMS_SH) $(AWK) $@ $(LIBTDB_HEADERS)
2206
2207
2208 $(LIBTDB_SHARED_TARGET_SONAME): $(BINARY_PREREQS) $(LIBTDB_OBJ) $(LIBTDB_SYMS)
2209         @echo Linking shared library $@
2210         @$(SHLD_DSO) $(LIBTDB_OBJ) $(LIBREPLACE_LIBS) $(TDB_DEPS) \
2211                 @SONAMEFLAG@`basename $@`
2212
2213 $(LIBTDB_SHARED_TARGET_FULLVER): $(LIBTDB_SHARED_TARGET_SONAME)
2214         @rm -f $@
2215         @mv -f $(LIBTDB_SHARED_TARGET_SONAME) $(LIBTDB_SHARED_TARGET_FULLVER)
2216         @ln -f -s `basename $(LIBTDB_SHARED_TARGET_FULLVER)` $(LIBTDB_SHARED_TARGET_SONAME)
2217
2218 $(LIBTDB_SHARED_TARGET): $(LIBTDB_SHARED_TARGET_FULLVER)
2219         @rm -f $@
2220         @ln -f -s `basename $(LIBTDB_SHARED_TARGET_SONAME)` $@
2221
2222 $(LIBTDB_STATIC_TARGET): $(BINARY_PREREQS) $(LIBTDB_OBJ0)
2223         @echo Linking non-shared library $@
2224         @-$(AR) -rc $@ $(LIBTDB_OBJ0)
2225
2226 libtdb: $(LIBTDB)
2227
2228 cleanlibtdb::
2229         -rm -f \
2230                 $(LIBTDB_SYMS) \
2231                 $(LIBTDB_STATIC_TARGET) \
2232                 $(LIBTDB_SHARED_TARGET) \
2233                 $(LIBTDB_SHARED_TARGET_SONAME)
2234
2235
2236 installlibtdb:: installdirs libtdb
2237         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2238         -$(INSTALLLIBCMD_SH) $(LIBTDB_SHARED_TARGET_FULLVER) $(DESTDIR)$(LIBDIR)
2239         @rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBTDB_SHARED_TARGET)`
2240         @rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBTDB_SHARED_TARGET_SONAME)`
2241         -if test -r $(LIBTDB_SHARED_TARGET_FULLVER) ; then \
2242                 ln -f -s `basename $(LIBTDB_SHARED_TARGET_FULLVER)` \
2243                         $(DESTDIR)$(LIBDIR)/`basename $(LIBTDB_SHARED_TARGET_SONAME)` ; \
2244         fi
2245         -if test -r $(LIBTDB_SHARED_TARGET_SONAME) ; then \
2246                 ln -f -s `basename $(LIBTDB_SHARED_TARGET_SONAME)` \
2247                         $(DESTDIR)$(LIBDIR)/`basename $(LIBTDB_SHARED_TARGET)` ; \
2248         fi
2249         -$(INSTALLLIBCMD_A) $(LIBTDB_STATIC_TARGET) $(DESTDIR)$(LIBDIR)
2250         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) ${prefix}/include
2251         -$(INSTALLCMD) -m $(INSTALLPERMS_DATA) $(LIBTDB_HEADERS) $(DESTDIR)${prefix}/include
2252
2253 uninstalllibtdb::
2254         -rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBTDB_SHARED_TARGET)`
2255         -$(UNINSTALLLIBCMD_SH) $(DESTDIR)$(LIBDIR)/`basename $(LIBTDB_SHARED_TARGET_SONAME)`
2256         -$(UNINSTALLLIBCMD_A) $(DESTDIR)$(LIBDIR)/`basename $(LIBTDB_STATIC_TARGET)`
2257         -rm -f $(DESTDIR)${prefix}/include/tdb.h
2258
2259 libs:: libtdb
2260 installlibs:: @INSTALL_LIBTDB@
2261 uninstalllibs:: @UNINSTALL_LIBTDB@
2262 cleanlibs:: cleanlibtdb
2263 shlibs test_shlibs: @LIBTDB_SHARED@
2264
2265 showlibtdb:
2266         @echo  ""
2267         @echo "LIBTDB_SHARED                = @LIBTDB_SHARED@"
2268         @echo "LIBTDB_STATIC                = @LIBTDB_STATIC@"
2269         @echo "LIBTDB_LIBS                  = $(LIBTDB_LIBS)"
2270         @echo ""
2271         @echo "LIBTDB_SHARED_TARGET         = $(LIBTDB_SHARED_TARGET)"
2272         @echo "LIBTDB_SOVER                 = $(LIBTDB_SOVER)"
2273         @echo "LIBTDB_FULLVER               = $(LIBTDB_FULLVER)"
2274         @echo "LIBTDB_SHARED TARGET_SONAME  = $(LIBTDB_SHARED_TARGET_SONAME)"
2275         @echo "LIBTDB_SHARED TARGET_FULLVER = $(LIBTDB_SHARED_TARGET_FULLVER)"
2276         @echo "LIBTDB_STATIC_TARGET         = $(LIBTDB_STATIC_TARGET)"
2277         @echo "LIBTDB                       = $(LIBTDB)"
2278
2279 showlibs:: showlibtdb
2280
2281 #-------------------------------------------------------------------
2282 #
2283 # libwbclient
2284 #
2285 #-------------------------------------------------------------------
2286
2287 LIBWBCLIENT_OBJ0 = ../nsswitch/libwbclient/wbclient.o \
2288                   ../nsswitch/libwbclient/wbc_util.o \
2289                   ../nsswitch/libwbclient/wbc_pwd.o \
2290                   ../nsswitch/libwbclient/wbc_idmap.o \
2291                   ../nsswitch/libwbclient/wbc_sid.o \
2292                   ../nsswitch/libwbclient/wbc_guid.o \
2293                   ../nsswitch/libwbclient/wbc_pam.o
2294
2295 LIBWBCLIENT_OBJ = $(LIBWBCLIENT_OBJ0) \
2296                   $(WBCOMMON_OBJ) \
2297                   $(LIBREPLACE_OBJ) \
2298                   ../lib/util/blocking.o \
2299                   $(SOCKET_WRAPPER_OBJ)
2300
2301 LIBWBCLIENT_SHARED_TARGET=@LIBWBCLIENT_SHARED_TARGET@
2302 LIBWBCLIENT_SOVER=@LIBWBCLIENT_SOVER@
2303 LIBWBCLIENT_FULLVER=@LIBWBCLIENT_FULLVER@
2304 LIBWBCLIENT_SHARED_TARGET_SONAME=@LIBWBCLIENT_SHARED_TARGET_SOVER@
2305 LIBWBCLIENT_STATIC_TARGET=@LIBWBCLIENT_STATIC_TARGET@
2306 LIBWBCLIENT_SYMS=$(srcdir)/exports/libwbclient.@SYMSEXT@
2307 LIBWBCLIENT_HEADERS=$(srcdir)/../nsswitch/libwbclient/wbclient.h
2308
2309 $(LIBWBCLIENT_SYMS): $(LIBWBCLIENT_HEADERS)
2310         @$(MKSYMS_SH) $(AWK) $@ $(LIBWBCLIENT_HEADERS)
2311
2312 $(LIBWBCLIENT_SHARED_TARGET_SONAME): $(BINARY_PREREQS) $(LIBWBCLIENT_OBJ) $(LIBWBCLIENT_SYMS)
2313         @echo Linking shared library $@
2314         @$(SHLD_DSO) $(LIBWBCLIENT_OBJ) $(LIBREPLACE_LIBS) \
2315                 @SONAMEFLAG@`basename $@`
2316
2317 $(LIBWBCLIENT_SHARED_TARGET): $(LIBWBCLIENT_SHARED_TARGET_SONAME)
2318         @rm -f $@
2319         @ln -f -s `basename $(LIBWBCLIENT_SHARED_TARGET_SONAME)` $@
2320
2321 $(LIBWBCLIENT_STATIC_TARGET): $(BINARY_PREREQS) $(LIBWBCLIENT_OBJ0) $(WBCOMMON_OBJ)
2322         @echo Linking non-shared library $@
2323         @-$(AR) -rc $@ $(LIBWBCLIENT_OBJ0) $(WBCOMMON_OBJ)
2324
2325 libwbclient: $(LIBWBCLIENT)
2326
2327 cleanlibwbclient::
2328         -rm -f \
2329                 $(LIBWBCLIENT_SYMS) \
2330                 $(LIBWBCLIENT_STATIC_TARGET) \
2331                 $(LIBWBCLIENT_SHARED_TARGET) \
2332                 $(LIBWBCLIENT_SHARED_TARGET_SONAME)
2333
2334 installlibwbclient:: installdirs libwbclient
2335         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2336         -$(INSTALLLIBCMD_SH) $(LIBWBCLIENT_SHARED_TARGET_SONAME) $(DESTDIR)$(LIBDIR)
2337         @rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBWBCLIENT_SHARED_TARGET)`
2338         -if test -r $(LIBWBCLIENT_SHARED_TARGET_SONAME) ; then \
2339                 ln -f -s `basename $(LIBWBCLIENT_SHARED_TARGET_SONAME)` \
2340                         $(DESTDIR)$(LIBDIR)/`basename $(LIBWBCLIENT_SHARED_TARGET)` ; \
2341         fi
2342         -$(INSTALLLIBCMD_A) bin/libwbclient.a $(DESTDIR)$(LIBDIR)
2343         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) ${prefix}/include
2344         -$(INSTALLCMD) -m $(INSTALLPERMS_DATA) $(LIBWBCLIENT_HEADERS) $(DESTDIR)${prefix}/include
2345
2346 uninstalllibwbclient::
2347         -rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBWBCLIENT_SHARED_TARGET)`
2348         -$(UNINSTALLLIBCMD_SH) $(DESTDIR)$(LIBDIR)/`basename $(LIBWBCLIENT_SHARED_TARGET_SONAME)`
2349         -$(UNINSTALLLIBCMD_A) $(DESTDIR)$(LIBDIR)/`basename $(LIBWBCLIENT_STATIC_TARGET)`
2350         -rm -f $(DESTDIR)${prefix}/include/wbclient.h
2351
2352 libs:: libwbclient
2353 installlibs:: @INSTALL_LIBWBCLIENT@
2354 uninstalllibs:: uninstalllibwbclient
2355 cleanlibs:: cleanlibwbclient
2356 shlibs test_shlibs: @LIBWBCLIENT_SHARED@
2357
2358 showlibwbclient:
2359         @echo  ""
2360         @echo "LIBWBCLIENT_SHARED               = @LIBWBCLIENT_SHARED@"
2361         @echo "LIBWBCLIENT_STATIC               = @LIBWBCLIENT_STATIC@"
2362         @echo "LIBWBCLIENT_LIBS                 = $(LIBWBCLIENT_LIBS)"
2363         @echo ""
2364         @echo "LIBWBCLIENT_SHARED_TARGET        = $(LIBWBCLIENT_SHARED_TARGET)"
2365         @echo "LIBWBCLIENT_SOVER                = $(LIBWBCLIENT_SOVER)"
2366         @echo "LIBWBCLIENT_FULLVER              = $(LIBWBCLIENT_FULLVER)"
2367         @echo "LIBWBCLIENT_SHARED TARGET_SONAME = $(LIBWBCLIENT_SHARED_TARGET_SONAME)"
2368         @echo "LIBWBCLIENT_STATIC_TARGET        = $(LIBWBCLIENT_STATIC_TARGET)"
2369         @echo "LIBWBCLIENT                      = $(LIBWBCLIENT)"
2370
2371 showlibs:: showlibwbclient
2372
2373
2374 #-------------------------------------------------------------------
2375 #
2376 # libaddns
2377 #
2378 #-------------------------------------------------------------------
2379
2380
2381 LIBADDNS_SHARED_TARGET=@LIBADDNS_SHARED_TARGET@
2382 LIBADDNS_SOVER=@LIBADDNS_SOVER@
2383 LIBADDNS_FULLVER=@LIBADDNS_FULLVER@
2384 LIBADDNS_SHARED_TARGET_SONAME=@LIBADDNS_SHARED_TARGET_SOVER@
2385 LIBADDNS_STATIC_TARGET=@LIBADDNS_STATIC_TARGET@
2386 LIBADDNS=@LIBADDNS_STATIC@ @LIBADDNS_SHARED@
2387 #LIBADDNS_SYMS=$(srcdir)/exports/libaddns.@SYMSEXT@
2388
2389 $(LIBADDNS_SHARED_TARGET_SONAME): $(BINARY_PREREQS) $(LIBADDNS_OBJ) $(LIBTALLOC)
2390         @echo Linking shared library $@
2391         @$(SHLD_DSO) $(LIBADDNS_OBJ) $(LIBS) \
2392                 $(KRB5LIBS) $(UUID_LIBS) $(LIBTALLOC_LIBS) \
2393                 @SONAMEFLAG@`basename $@`
2394
2395 $(LIBADDNS_SHARED_TARGET): $(LIBADDNS_SHARED_TARGET_SONAME)
2396         @rm -f $@
2397         @ln -f -s `basename $(LIBADDNS_SHARED_TARGET_SONAME)` $@
2398
2399 $(LIBADDNS_STATIC_TARGET): $(BINARY_PREREQS) $(LIBADDNS_OBJ0)
2400         @echo Linking non-shared library $@
2401         @-$(AR) -rc $@ $(LIBADDNS_OBJ0)
2402
2403 libaddns: $(LIBADDNS)
2404
2405 cleanlibaddns::
2406         -rm -f \
2407                 $(LIBADDNS_SHARED_TARGET) \
2408                 $(LIBADDNS_SHARED_TARGET_SONAME) \
2409                 $(LIBADDNS_STATIC_TARGET)
2410
2411 installlibaddns:: installdirs libaddns
2412         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2413         -$(INSTALLLIBCMD_SH) $(LIBADDNS_SHARED_TARGET_SONAME) $(DESTDIR)$(LIBDIR)
2414         @rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBADDNS_SHARED_TARGET)`
2415         -if test -r $(LIBADDNS_SHARED_TARGET_SONAME) ; then \
2416                 ln -f -s `basename $(LIBADDNS_SHARED_TARGET_SONAME)` \
2417                         $(DESTDIR)$(LIBDIR)/`basename $(LIBADDNS_SHARED_TARGET)` ; \
2418         fi
2419         -$(INSTALLLIBCMD_A) $(LIBADDNS_STATIC_TARGET) $(DESTDIR)$(LIBDIR)
2420
2421 uninstalllibaddns::
2422         -$(UNINSTALLLIBCMD_SH) $(DESTDIR)$(LIBDIR)/`basename $(LIBADDNS_SHARED_TARGET_SONAME)`
2423         -rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBADDNS_SHARED_TARGET)`
2424         -$(UNINSTALLLIBCMD_A) $(DESTDIR)$(LIBDIR)/`basename $(LIBADDNS_STATIC_TARGET)`
2425
2426 libs:: libaddns
2427 installlibs:: @INSTALL_LIBADDNS@
2428 uninstalllibs:: @UNINSTALL_LIBADDNS@
2429 cleanlibs:: cleanlibaddns
2430 shlibs test_shlibs: @LIBADDNS_SHARED@
2431
2432 showlibaddns:
2433         @echo  ""
2434         @echo "LIBADDNS_SHARED               = @LIBADDNS_SHARED@"
2435         @echo "LIBADDNS_STATIC               = @LIBADDNS_STATIC@"
2436         @echo "LIBADDNS_LIBS                 = $(LIBADDNS_LIBS)"
2437         @echo ""
2438         @echo "LIBADDNS_SHARED_TARGET        = $(LIBADDNS_SHARED_TARGET)"
2439         @echo "LIBADDNS_SOVER                = $(LIBADDNS_SOVER)"
2440         @echo "LIBADDNS_FULLVER              = $(LIBADDNS_FULLVER)"
2441         @echo "LIBADDNS_SHARED TARGET_SONAME = $(LIBADDNS_SHARED_TARGET_SONAME)"
2442         @echo "LIBADDNS_STATIC_TARGET        = $(LIBADDNS_STATIC_TARGET)"
2443         @echo "LIBADDNS                      = $(LIBADDNS)"
2444
2445 showlibs:: showlibaddns
2446
2447 #-------------------------------------------------------------------
2448 #
2449 # libnetapi
2450 #
2451 #-------------------------------------------------------------------
2452
2453 LIBNETAPI_OBJ0 = lib/netapi/netapi.o \
2454                  lib/netapi/cm.o \
2455                  librpc/gen_ndr/ndr_libnetapi.o \
2456                  lib/netapi/libnetapi.o \
2457                  lib/netapi/joindomain.o \
2458                  lib/netapi/serverinfo.o \
2459                  lib/netapi/getdc.o \
2460                  lib/netapi/user.o \
2461                  lib/netapi/group.o \
2462                  lib/netapi/localgroup.o \
2463                  lib/netapi/samr.o \
2464                  lib/netapi/sid.o \
2465                  lib/netapi/share.o \
2466                  lib/netapi/file.o \
2467                  lib/netapi/shutdown.o \
2468                  lib/netapi/netlogon.o
2469
2470 LIBNETAPI_OBJ  = $(LIBNETAPI_OBJ0) $(LIBNET_OBJ) \
2471                  $(LIBSMBCONF_OBJ) \
2472                  $(REG_SMBCONF_OBJ) \
2473                  $(PARAM_WITHOUT_REG_OBJ) $(LIB_NONSMBD_OBJ) \
2474                  $(LIBSMB_OBJ) $(KRBCLIENT_OBJ) \
2475                  $(LIBMSRPC_OBJ) $(LIBMSRPC_GEN_OBJ) \
2476                  $(PASSDB_OBJ) $(SMBLDAP_OBJ) $(GROUPDB_OBJ) \
2477                  $(DCUTIL_OBJ) $(LIBADS_OBJ) $(PRIVILEGES_BASIC_OBJ) \
2478                  auth/token_util.o \
2479                  $(LIBCLI_INITSHUTDOWN_OBJ) \
2480                  $(LIBCLI_WKSSVC_OBJ) \
2481                  $(LIBCLI_SRVSVC_OBJ) \
2482                  $(LIBCLI_LSA_OBJ) \
2483                  $(LIBCLI_SAMR_OBJ) \
2484                  $(LIBCLI_NETLOGON_OBJ) \
2485                  $(RPC_CLIENT_SCHANNEL_OBJ) \
2486                  rpc_client/init_netlogon.o \
2487                  rpc_client/init_samr.o
2488
2489 LIBNETAPI_SHARED_TARGET=@LIBNETAPI_SHARED_TARGET@
2490 LIBNETAPI_SOVER=@LIBNETAPI_SOVER@
2491 LIBNETAPI_FULLVER=@LIBNETAPI_FULLVER@
2492 LIBNETAPI_SHARED_TARGET_SONAME=@LIBNETAPI_SHARED_TARGET_SOVER@
2493 LIBNETAPI_STATIC_TARGET=@LIBNETAPI_STATIC_TARGET@
2494 LIBNETAPI_SYMS=$(srcdir)/exports/libnetapi.@SYMSEXT@
2495 LIBNETAPI_HEADERS=$(srcdir)/lib/netapi/netapi.h
2496
2497 $(LIBNETAPI_SYMS): $(LIBNETAPI_HEADERS)
2498         @$(MKSYMS_SH) $(AWK) $@ $(LIBNETAPI_HEADERS)
2499
2500 $(LIBNETAPI_SHARED_TARGET_SONAME): $(BINARY_PREREQS) $(LIBNETAPI_OBJ) $(LIBNETAPI_SYMS) $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
2501         @echo Linking shared library $@
2502         @$(SHLD_DSO) $(LIBNETAPI_OBJ) \
2503                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) $(LIBS) \
2504                 $(LDAP_LIBS) $(KRB5LIBS) $(NSCD_LIBS) $(ZLIB_LIBS) \
2505                 @SONAMEFLAG@`basename $@`
2506
2507 $(LIBNETAPI_SHARED_TARGET): $(LIBNETAPI_SHARED_TARGET_SONAME)
2508         @rm -f $@
2509         @ln -f -s `basename $(LIBNETAPI_SHARED_TARGET_SONAME)` $@
2510
2511 $(LIBNETAPI_STATIC_TARGET): $(BINARY_PREREQS) $(LIBNETAPI_OBJ0)
2512         @echo Linking non-shared library $@
2513         @-$(AR) -rc $@ $(LIBNETAPI_OBJ0)
2514
2515 libnetapi: $(LIBNETAPI)
2516
2517 cleanlibnetapi::
2518         -rm -f \
2519                 $(LIBNETAPI_SYMS) \
2520                 $(LIBNETAPI_STATIC_TARGET) \
2521                 $(LIBNETAPI_SHARED_TARGET) \
2522                 $(LIBNETAPI_SHARED_TARGET_SONAME)
2523
2524 installlibnetapi:: installdirs libnetapi
2525         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2526         -$(INSTALLLIBCMD_SH) $(LIBNETAPI_SHARED_TARGET_SONAME) $(DESTDIR)$(LIBDIR)
2527         @rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBNETAPI_SHARED_TARGET)`
2528         -if test -r $(LIBNETAPI_SHARED_TARGET_SONAME) ; then \
2529                 ln -f -s `basename $(LIBNETAPI_SHARED_TARGET_SONAME)` \
2530                         $(DESTDIR)$(LIBDIR)/`basename $(LIBNETAPI_SHARED_TARGET)` ; \
2531         fi
2532         -$(INSTALLLIBCMD_A) $(LIBNETAPI_STATIC_TARGET) $(DESTDIR)$(LIBDIR)
2533         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) ${prefix}/include
2534         -$(INSTALLCMD) -m $(INSTALLPERMS_DATA) $(srcdir)/lib/netapi/netapi.h $(DESTDIR)${prefix}/include
2535
2536 uninstalllibnetapi::
2537         -rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBNETAPI_SHARED_TARGET)`
2538         -$(UNINSTALLLIBCMD_SH) $(DESTDIR)$(LIBDIR)/`basename $(LIBNETAPI_SHARED_TARGET_SONAME)`
2539         -$(UNINSTALLLIBCMD_A) $(DESTDIR)$(LIBDIR)/`basename $(LIBNETAPI_STATIC_TARGET)`
2540         -rm -f $(DESTDIR)${prefix}/include/netapi.h
2541
2542 libs:: libnetapi
2543 installlibs:: @INSTALL_LIBNETAPI@
2544 uninstalllibs:: @UNINSTALL_LIBNETAPI@
2545 cleanlibs:: cleanlibnetapi
2546 shlibs test_shlibs: @LIBNETAPI_SHARED@
2547
2548 showlibnetapi:
2549         @echo  ""
2550         @echo "LIBNETAPI_SHARED               = @LIBNETAPI_SHARED@"
2551         @echo "LIBNETAPI_STATIC               = @LIBNETAPI_STATIC@"
2552         @echo "LIBNETAPI_LIBS                 = $(LIBNETAPI_LIBS)"
2553         @echo ""
2554         @echo "LIBNETAPI_SHARED_TARGET        = $(LIBNETAPI_SHARED_TARGET)"
2555         @echo "LIBNETAPI_SOVER                = $(LIBNETAPI_SOVER)"
2556         @echo "LIBNETAPI_FULLVER              = $(LIBNETAPI_FULLVER)"
2557         @echo "LIBNETAPI_SHARED TARGET_SONAME = $(LIBNETAPI_SHARED_TARGET_SONAME)"
2558         @echo "LIBNETAPI_STATIC_TARGET        = $(LIBNETAPI_STATIC_TARGET)"
2559         @echo "LIBNETAPI                      = $(LIBNETAPI)"
2560
2561 showlibs:: showlibnetapi
2562
2563 #-------------------------------------------------------------------
2564 #
2565 # libsmbclient
2566 #
2567 #-------------------------------------------------------------------
2568
2569 LIBSMBCLIENT_SHARED_TARGET=@LIBSMBCLIENT_SHARED_TARGET@
2570 LIBSMBCLIENT_SOVER=@LIBSMBCLIENT_SOVER@
2571 LIBSMBCLIENT_FULLVER=@LIBSMBCLIENT_FULLVER@
2572 LIBSMBCLIENT_SHARED_TARGET_SONAME=@LIBSMBCLIENT_SHARED_TARGET_SOVER@
2573 LIBSMBCLIENT_STATIC_TARGET=@LIBSMBCLIENT_STATIC_TARGET@
2574 LIBSMBCLIENT=@LIBSMBCLIENT_STATIC@ @LIBSMBCLIENT_SHARED@
2575 LIBSMBCLIENT_SYMS=$(srcdir)/exports/libsmbclient.@SYMSEXT@
2576 LIBSMBCLIENT_HEADERS=$(srcdir)/include/libsmbclient.h
2577
2578 $(LIBSMBCLIENT_SYMS): $(LIBSMBCLIENT_HEADERS)
2579         @$(MKSYMS_SH) $(AWK) $@ $(LIBSMBCLIENT_HEADERS)
2580
2581 $(LIBSMBCLIENT_SHARED_TARGET_SONAME): $(BINARY_PREREQS) $(LIBSMBCLIENT_OBJ) $(LIBSMBCLIENT_THREAD_OBJ) $(LIBSMBCLIENT_SYMS) $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
2582         @echo Linking shared library $@
2583         @$(SHLD_DSO) $(LIBSMBCLIENT_OBJ) $(LIBSMBCLIENT_THREAD_OBJ) \
2584                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) $(LIBS) \
2585                 $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) $(ZLIB_LIBS) $(PTHREAD_LDFLAGS) \
2586                 @SONAMEFLAG@`basename $@`
2587
2588 $(LIBSMBCLIENT_SHARED_TARGET): $(LIBSMBCLIENT_SHARED_TARGET_SONAME)
2589         @rm -f $@
2590         @ln -s `basename $(LIBSMBCLIENT_SHARED_TARGET_SONAME)` $@
2591
2592 $(LIBSMBCLIENT_STATIC_TARGET): $(BINARY_PREREQS) $(LIBSMBCLIENT_OBJ1)
2593         @echo Linking non-shared library $@
2594         @-$(AR) -rc $@ $(LIBSMBCLIENT_OBJ1)
2595
2596 libsmbclient: $(LIBSMBCLIENT)
2597
2598 cleanlibsmbclient::
2599         -rm -f \
2600                 $(LIBSMBCLIENT_SHARED_TARGET) \
2601                 $(LIBSMBCLIENT_SHARED_TARGET_SONAME) \
2602                 $(LIBSMBCLIENT_STATIC_TARGET)
2603
2604 installlibsmbclient:: installdirs libsmbclient
2605         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2606         -$(INSTALLLIBCMD_SH) $(LIBSMBCLIENT_SHARED_TARGET_SONAME) $(DESTDIR)$(LIBDIR)
2607         @rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBSMBCLIENT_SHARED_TARGET)`
2608         -if test -r $(LIBSMBCLIENT_SHARED_TARGET_SONAME) ; then \
2609                 ln -f -s `basename $(LIBSMBCLIENT_SHARED_TARGET_SONAME)` \
2610                         $(DESTDIR)$(LIBDIR)/`basename $(LIBSMBCLIENT_SHARED_TARGET)` ; \
2611         fi
2612         -$(INSTALLLIBCMD_A) $(LIBSMBCLIENT_STATIC_TARGET) $(DESTDIR)$(LIBDIR)
2613         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) ${prefix}/include
2614         -$(INSTALLCMD) -m $(INSTALLPERMS_DATA) $(LIBSMBCLIENT_HEADERS) $(DESTDIR)${prefix}/include
2615
2616 installclientlib:: installlibsmbclient
2617
2618 uninstalllibsmbclient::
2619         -rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBSMBCLIENT_SHARED_TARGET)`
2620         -$(UNINSTALLLIBCMD_SH) $(DESTDIR)$(LIBDIR)/`basename $(LIBSMBCLIENT_SHARED_TARGET_SONAME)`
2621         -$(UNINSTALLLIBCMD_A) $(DESTDIR)$(LIBDIR)/`basename $(LIBSMBCLIENT_STATIC_TARGET)`
2622         -rm -f $(DESTDIR)${prefix}/include/libsmbclient.h
2623
2624 uninstallclientlib:: uninstalllibsmbclient
2625
2626 libs:: libsmbclient
2627 installlibs:: @INSTALL_LIBSMBCLIENT@
2628 uninstalllibs:: @UNINSTALL_LIBSMBCLIENT@
2629 cleanlibs:: cleanlibsmbclient
2630 shlibs test_shlibs: @LIBSMBCLIENT_SHARED@
2631
2632 showlibsmbclient:
2633         @echo  ""
2634         @echo "LIBSMBCLIENT_SHARED               = @LIBSMBCLIENT_SHARED@"
2635         @echo "LIBSMBCLIENT_STATIC               = @LIBSMBCLIENT_STATIC@"
2636         @echo "LIBSMBCLIENT_LIBS                 = $(LIBSMBCLIENT_LIBS)"
2637         @echo ""
2638         @echo "LIBSMBCLIENT_SHARED_TARGET        = $(LIBSMBCLIENT_SHARED_TARGET)"
2639         @echo "LIBSMBCLIENT_SOVER                = $(LIBSMBCLIENT_SOVER)"
2640         @echo "LIBSMBCLIENT_FULLVER              = $(LIBSMBCLIENT_FULLVER)"
2641         @echo "LIBSMBCLIENT_SHARED TARGET_SONAME = $(LIBSMBCLIENT_SHARED_TARGET_SONAME)"
2642         @echo "LIBSMBCLIENT_STATIC_TARGET        = $(LIBSMBCLIENT_STATIC_TARGET)"
2643         @echo "LIBSMBCLIENT                      = $(LIBSMBCLIENT)"
2644
2645 showlibs:: showlibsmbclient
2646
2647 #-------------------------------------------------------------------
2648 #
2649 # libsmbsharemodes
2650 #
2651 #-------------------------------------------------------------------
2652
2653 LIBSMBSHAREMODES_OBJ0 = libsmb/smb_share_modes.o ../lib/ccan/hash/hash.o
2654
2655 LIBSMBSHAREMODES_OBJ = $(LIBSMBSHAREMODES_OBJ0)
2656
2657 LIBSMBSHAREMODES_SHARED_TARGET=@LIBSMBSHAREMODES_SHARED_TARGET@
2658 LIBSMBSHAREMODES_SOVER=@LIBSMBSHAREMODES_SOVER@
2659 LIBSMBSHAREMODES_FULLVER=@LIBSMBSHAREMODES_FULLVER@
2660 LIBSMBSHAREMODES_SHARED_TARGET_SONAME=@LIBSMBSHAREMODES_SHARED_TARGET_SOVER@
2661 LIBSMBSHAREMODES_STATIC_TARGET=@LIBSMBSHAREMODES_STATIC_TARGET@
2662 LIBSMBSHAREMODES=@LIBSMBSHAREMODES_STATIC@ @LIBSMBSHAREMODES_SHARED@
2663 LIBSMBSHAREMODES_SYMS=$(srcdir)/exports/libsmbsharemodes.@SYMSEXT@
2664 LIBSMBSHAREMODES_HEADERS=$(srcdir)/include/smb_share_modes.h
2665
2666 $(LIBSMBSHAREMODES_SYMS): $(LIBSMBSHAREMODES_HEADERS)
2667         @$(MKSYMS_SH) $(AWK) $@ $(LIBSMBSHAREMODES_HEADERS)
2668
2669 $(LIBSMBSHAREMODES_SHARED_TARGET_SONAME): $(BINARY_PREREQS) $(LIBSMBSHAREMODES_OBJ) $(LIBSMBSHAREMODES_SYMS) $(LIBTALLOC) $(LIBTDB)
2670         @echo Linking shared library $@
2671         @$(SHLD_DSO) $(LIBSMBSHAREMODES_OBJ) \
2672                 $(LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) \
2673                 @SONAMEFLAG@`basename $@`
2674
2675 $(LIBSMBSHAREMODES_SHARED_TARGET): $(LIBSMBSHAREMODES_SHARED_TARGET_SONAME)
2676         @rm -f $@
2677         @ln -f -s `basename $(LIBSMBSHAREMODES_SHARED_TARGET_SONAME)` $@
2678
2679 $(LIBSMBSHAREMODES_STATIC_TARGET): $(BINARY_PREREQS) $(LIBSMBSHAREMODES_OBJ0)
2680         @echo Linking non-shared library $@
2681         @-$(AR) -rc $@ $(LIBSMBSHAREMODES_OBJ0)
2682
2683 libsmbsharemodes: $(LIBSMBSHAREMODES)
2684
2685 cleanlibsmbsharemodes::
2686         -rm -f \
2687                 $(LIBSMBSHAREMODES_SHARED_TARGET) \
2688                 $(LIBSMBSHAREMODES_SHARED_TARGET_SONAME) \
2689                 $(LIBSMBSHAREMODES_STATIC_TARGET)
2690
2691 installlibsmbsharemodes:: installdirs libsmbsharemodes
2692         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(LIBDIR)
2693         -$(INSTALLLIBCMD_SH) $(LIBSMBSHAREMODES_SHARED_TARGET_SONAME) $(DESTDIR)$(LIBDIR)
2694         @rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBSMBSHAREMODES_SHARED_TARGET)`
2695         -if test -r $(LIBSMBSHAREMODES_SHARED_TARGET_SONAME) ; then \
2696                 ln -f -s `basename $(LIBSMBSHAREMODES_SHARED_TARGET_SONAME)` \
2697                         $(DESTDIR)$(LIBDIR)/`basename $(LIBSMBSHAREMODES_SHARED_TARGET)` ; \
2698         fi
2699         -$(INSTALLLIBCMD_A) $(LIBSMBSHAREMODES_STATIC_TARGET) $(DESTDIR)$(LIBDIR)
2700         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) ${prefix}/include
2701         -$(INSTALLCMD) -m $(INSTALLPERMS_DATA) $(LIBSMBSHAREMODES_HEADERS) $(DESTDIR)${prefix}/include
2702
2703 uninstalllibsmbsharemodes::
2704         -rm -f $(DESTDIR)$(LIBDIR)/`basename $(LIBSMBSHAREMODES_SHARED_TARGET)`
2705         -$(UNINSTALLLIBCMD_SH) $(DESTDIR)$(LIBDIR)/`basename $(LIBSMBSHAREMODES_SHARED_TARGET_SONAME)`
2706         -$(UNINSTALLLIBCMD_A) $(DESTDIR)$(LIBDIR)/`basename $(LIBSMBSHAREMODES_STATIC_TARGET)`
2707         -rm -f $(DESTDIR)${prefix}/include/smb_share_modes.h
2708
2709 libs:: libsmbsharemodes
2710 installlibs:: @INSTALL_LIBSMBSHAREMODES@
2711 uninstalllibs:: @UNINSTALL_LIBSMBSHAREMODES@
2712 cleanlibs:: cleanlibsmbsharemodes
2713 shlibs test_shlibs: @LIBSMBSHAREMODES_SHARED@
2714
2715 showlibsmbsharemodes:
2716         @echo  ""
2717         @echo "LIBSMBSHAREMODES_SHARED               = @LIBSMBSHAREMODES_SHARED@"
2718         @echo "LIBSMBSHAREMODES_STATIC               = @LIBSMBSHAREMODES_STATIC@"
2719         @echo "LIBSMBSHAREMODES_TARGET               = @LIBSMBSHAREMODES_TARGET@"
2720         @echo "LIBSMBSHAREMODES_LIBS                 = $(LIBSMBSHAREMODES_LIBS)"
2721         @echo ""
2722         @echo "LIBSMBSHAREMODES_SHARED_TARGET        = $(LIBSMBSHAREMODES_SHARED_TARGET)"
2723         @echo "LIBSMBSHAREMODES_SOVER                = $(LIBSMBSHAREMODES_SOVER)"
2724         @echo "LIBSMBSHAREMODES_FULLVER              = $(LIBSMBSHAREMODES_FULLVER)"
2725         @echo "LIBSMBSHAREMODES_SHARED TARGET_SONAME = $(LIBSMBSHAREMODES_SHARED_TARGET_SONAME)"
2726         @echo "LIBSMBSHAREMODES_STATIC_TARGET        = $(LIBSMBSHAREMODES_STATIC_TARGET)"
2727         @echo "LIBSMBSHAREMODES                      = $(LIBSMBSHAREMODES)"
2728
2729 showlibs:: showlibsmbsharemodes
2730
2731 #####################################################################
2732 #
2733 # shared modules
2734 #
2735 #####################################################################
2736
2737 # Linker command to link our shared libraries:
2738 SHLD_LIBRARY = $(SHLD) $(LDSHFLAGS) $(MODULE_EXPORTS) \
2739               -o $@ @SONAMEFLAG@`basename $@`
2740 # Linker command to link samba internal plugin modules:
2741 SHLD_MODULE = $(SHLD) $(LDSHFLAGS_MODULES) $(MODULE_EXPORTS) \
2742         -o $@ @SONAMEFLAG@`basename $@`
2743
2744 bin/librpc_lsarpc.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_LSARPC_OBJ)
2745         @echo "Linking $@"
2746         @$(SHLD_LIBRARY) $(RPC_LSARPC_OBJ)
2747
2748 bin/librpc_samr.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_SAMR_OBJ)
2749         @echo "Linking $@"
2750         @$(SHLD_LIBRARY) $(RPC_SAMR_OBJ)
2751
2752 bin/librpc_srvsvc.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_SRVSVC_OBJ)
2753         @echo "Linking $@"
2754         @$(SHLD_LIBRARY) $(RPC_SRVSVC_OBJ)
2755
2756 bin/librpc_svcctl.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_SVCCTL_OBJ)
2757         @echo "Linking $@"
2758         @$(SHLD_LIBRARY) $(RPC_SVCCTL_OBJ)
2759
2760 bin/librpc_ntsvcs.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_NTSVCS_OBJ)
2761         @echo "Linking $@"
2762         @$(SHLD_LIBRARY) $(RPC_NTSVCS_OBJ)
2763
2764 bin/librpc_wkssvc.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_WKSSVC_OBJ)
2765         @echo "Linking $@"
2766         @$(SHLD_LIBRARY) $(RPC_WKSSVC_OBJ)
2767
2768 bin/librpc_NETLOGON.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_NETLOGON_OBJ)
2769         @echo "Linking $@"
2770         @$(SHLD_LIBRARY) $(RPC_NETLOGON_OBJ)
2771
2772 bin/librpc_winreg.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_WINREG_OBJ)
2773         @echo "Linking $@"
2774         @$(SHLD_LIBRARY) $(RPC_WINREG_OBJ)
2775
2776 bin/librpc_initshutdown.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_INITSHUTDOWN_OBJ)
2777         @echo "Linking $@"
2778         @$(SHLD_LIBRARY) $(RPC_INITSHUTDOWN_OBJ)
2779
2780 bin/librpc_dssetup.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_DSSETUP_OBJ)
2781         @echo "Linking $@"
2782         @$(SHLD_LIBRARY) $(RPC_DSSETUP_OBJ)
2783
2784 bin/librpc_spoolss.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_SPOOLSS_OBJ)
2785         @echo "Linking $@"
2786         @$(SHLD_LIBRARY) $(RPC_SPOOLSS_OBJ)
2787
2788 bin/librpc_eventlog.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_EVENTLOG_OBJ)
2789         @echo "Linking $@"
2790         @$(SHLD_LIBRARY) $(RPC_EVENTLOG_OBJ)
2791
2792 bin/librpc_netdfs.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_NETDFS_OBJ)
2793         @echo "Linking $@"
2794         @$(SHLD_LIBRARY) $(RPC_NETDFS_OBJ)
2795
2796 bin/librpc_rpcecho.@SHLIBEXT@: $(BINARY_PREREQS) $(RPC_RPCECHO_OBJ)
2797         @echo "Linking $@"
2798         @$(SHLD_LIBRARY) $(RPC_RPCECHO_OBJ)
2799
2800 bin/winbindd: $(BINARY_PREREQS) $(WINBINDD_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
2801         @echo "Linking $@"
2802         @$(CC) -o $@ $(WINBINDD_OBJ) $(LDFLAGS) $(DYNEXP) $(LIBS) \
2803                 $(POPT_LIBS) $(KRB5LIBS) $(LDAP_LIBS) $(AUTH_LIBS) \
2804                 $(PASSDB_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) \
2805                 $(ZLIB_LIBS)
2806
2807 bin/vlp: $(BINARY_PREREQS) $(VLP_OBJ) $(LIBTDB) $(LIBTALLOC)
2808         @echo "Linking $@"
2809         @$(CC) -o $@ $(VLP_OBJ) $(LDFLAGS) $(DYNEXP) \
2810                 $(TERMLDFLAGS) $(TERMLIBS) $(LIBS) $(POPT_LIBS) \
2811                 $(LIBTALLOC_LIBS) \
2812                 $(LIBTDB_LIBS)
2813
2814 @WINBIND_NSS@: $(BINARY_PREREQS) $(WINBIND_NSS_OBJ)
2815         @echo "Linking $@"
2816         @$(SHLD) $(WINBIND_NSS_LDSHFLAGS) -o $@ $(WINBIND_NSS_OBJ) \
2817                 $(LIBREPLACE_LIBS) $(PTHREAD_LDFLAGS) \
2818                 @SONAMEFLAG@`basename $@`@NSSSONAMEVERSIONSUFFIX@
2819
2820 @WINBIND_WINS_NSS@: $(BINARY_PREREQS) $(WINBIND_WINS_NSS_OBJ) $(LIBTALLOC) $(LIBTDB)
2821         @echo "Linking $@"
2822         @$(SHLD) $(LDSHFLAGS) -o $@ $(WINBIND_WINS_NSS_OBJ) \
2823                 $(LDAP_LIBS) $(KRB5LIBS) $(LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(ZLIB_LIBS) \
2824                 @SONAMEFLAG@`basename $@`@NSSSONAMEVERSIONSUFFIX@
2825
2826 bin/winbind_krb5_locator.@SHLIBEXT@: $(BINARY_PREREQS) $(WINBIND_KRB5_LOCATOR_OBJ) $(LIBWBCLIENT)
2827         @echo "Linking $@"
2828         @$(SHLD) $(LDSHFLAGS) -o $@ $(WINBIND_KRB5_LOCATOR_OBJ) $(LIBWBCLIENT_LIBS) $(KRB5LIBS) \
2829                 @SONAMEFLAG@`basename $@`
2830
2831 bin/pam_winbind.@SHLIBEXT@: $(BINARY_PREREQS) $(PAM_WINBIND_OBJ) $(LIBTALLOC) $(LIBWBCLIENT)
2832         @echo "Linking shared library $@"
2833         @$(SHLD) $(LDSHFLAGS) -o $@ $(PAM_WINBIND_OBJ) -lpam @INIPARSERLIBS@ \
2834                 $(LIBREPLACE_LIBS) $(LIBTALLOC_LIBS) $(LIBWBCLIENT_LIBS) @SONAMEFLAG@`basename $@`
2835
2836 ##########
2837 # Plugins:
2838 ##########
2839
2840 bin/builtin.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_BUILTIN_OBJ)
2841         @echo "Building plugin $@"
2842         @$(SHLD_MODULE) $(AUTH_BUILTIN_OBJ)
2843
2844 bin/domain.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_DOMAIN_OBJ)
2845         @echo "Building plugin $@"
2846         @$(SHLD_MODULE) $(AUTH_DOMAIN_OBJ)
2847
2848 bin/script.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_SCRIPT_OBJ)
2849         @echo "Building plugin $@"
2850         @$(SHLD_MODULE) $(AUTH_SCRIPT_OBJ)
2851
2852 bin/netlogond.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_NETLOGOND_OBJ)
2853         @echo "Building plugin $@"
2854         @$(SHLD_MODULE) $(AUTH_NETLOGOND_OBJ)
2855
2856 bin/winbind.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_WINBIND_OBJ)
2857         @echo "Building plugin $@"
2858         @$(SHLD_MODULE) $(AUTH_WINBIND_OBJ)
2859
2860 bin/wbc.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_WBC_OBJ)
2861         @echo "Building plugin $@"
2862         @$(SHLD_MODULE) $(AUTH_WBC_OBJ)
2863
2864 bin/unix.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_UNIX_OBJ)
2865         @echo "Building plugin $@"
2866         @$(SHLD_MODULE) $(AUTH_UNIX_OBJ)
2867
2868 bin/sam.@SHLIBEXT@: $(BINARY_PREREQS) $(AUTH_SAM_OBJ)
2869         @echo "Building plugin $@"
2870         @$(SHLD_MODULE) $(AUTH_SAM_OBJ)
2871
2872 bin/ldapsam.@SHLIBEXT@: $(BINARY_PREREQS) passdb/pdb_ldap.o passdb/pdb_nds.o \
2873                         passdb/pdb_ipa.o passdb/pdb_ldap_util.o
2874         @echo "Building plugin $@"
2875         @$(SHLD_MODULE) passdb/pdb_ldap.o passdb/pdb_nds.o passdb/pdb_ipa.o \
2876                         passdb/pdb_ldap_util.o $(LDAP_LIBS)
2877
2878 bin/ads.@SHLIBEXT@: $(BINARY_PREREQS) passdb/pdb_ads.o
2879         @echo "Building plugin $@"
2880         @$(SHLD_MODULE) passdb/pdb_ads.o
2881
2882 bin/tdbsam.@SHLIBEXT@: $(BINARY_PREREQS) passdb/pdb_tdb.o
2883         @echo "Building plugin $@"
2884         @$(SHLD_MODULE) passdb/pdb_tdb.o
2885
2886 bin/wbc_sam.@SHLIBEXT@: $(BINARY_PREREQS) passdb/pdb_wbc_sam.o
2887         @echo "Building plugin $@"
2888         @$(SHLD_MODULE) passdb/pdb_wbc_sam.o
2889
2890 bin/smbpasswd.@SHLIBEXT@: $(BINARY_PREREQS) passdb/pdb_smbpasswd.o
2891         @echo "Building plugin $@"
2892         @$(SHLD_MODULE) passdb/pdb_smbpasswd.o
2893
2894 bin/rid.@SHLIBEXT@: $(BINARY_PREREQS) winbindd/idmap_rid.o
2895         @echo "Building plugin $@"
2896         @$(SHLD_MODULE) winbindd/idmap_rid.o
2897
2898 bin/passdb.@SHLIBEXT@: $(BINARY_PREREQS) winbindd/idmap_passdb.o
2899         @echo "Building plugin $@"
2900         @$(SHLD_MODULE) winbindd/idmap_passdb.o
2901
2902 bin/autorid.@SHLIBEXT@: $(BINARY_PREREQS) winbindd/idmap_autorid.o
2903         @echo "Building plugin $@"
2904         @$(SHLD_MODULE) winbindd/idmap_autorid.o
2905
2906 bin/ad.@SHLIBEXT@: $(BINARY_PREREQS) winbindd/idmap_ad.o
2907         @echo "Building plugin $@"
2908         @$(SHLD_MODULE) winbindd/idmap_ad.o
2909
2910 bin/hash.@SHLIBEXT@: $(BINARY_PREREQS) $(IDMAP_HASH_OBJ)
2911         @echo "Building plugin $@"
2912         @$(SHLD_MODULE) $(IDMAP_HASH_OBJ)
2913
2914 bin/adex.@SHLIBEXT@: $(BINARY_PREREQS) $(IDMAP_ADEX_OBJ)
2915         @echo "Building plugin $@"
2916         @$(SHLD_MODULE) $(IDMAP_ADEX_OBJ)
2917
2918 bin/tdb2.@SHLIBEXT@: $(BINARY_PREREQS) winbindd/idmap_tdb2.o $(IDMAP_RW_OBJ)
2919         @echo "Building plugin $@"
2920         @$(SHLD_MODULE) winbindd/idmap_tdb2.o $(IDMAP_RW_OBJ)
2921
2922 bin/ldap.@SHLIBEXT@: $(BINARY_PREREQS) winbindd/idmap_ldap.o $(IDMAP_RW_OBJ)
2923         @echo "Building plugin $@"
2924         @$(SHLD_MODULE) winbindd/idmap_ldap.o $(IDMAP_RW_OBJ)
2925
2926 # NOTE, there is no build rule for a dynamic default VFS module because
2927 # this one MUST MUST MUST be built statically.
2928
2929 bin/audit.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_AUDIT_OBJ)
2930         @echo "Building plugin $@"
2931         @$(SHLD_MODULE) $(VFS_AUDIT_OBJ)
2932
2933 bin/extd_audit.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_EXTD_AUDIT_OBJ)
2934         @echo "Building plugin $@"
2935         @$(SHLD_MODULE) $(VFS_EXTD_AUDIT_OBJ)
2936
2937 bin/full_audit.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_FULL_AUDIT_OBJ)
2938         @echo "Building plugin $@"
2939         @$(SHLD_MODULE) $(VFS_FULL_AUDIT_OBJ)
2940
2941 bin/recycle.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_RECYCLE_OBJ)
2942         @echo "Building plugin $@"
2943         @$(SHLD_MODULE) $(VFS_RECYCLE_OBJ)
2944
2945 bin/netatalk.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_NETATALK_OBJ)
2946         @echo "Building plugin $@"
2947         @$(SHLD_MODULE) $(VFS_NETATALK_OBJ)
2948
2949 bin/fake_perms.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_FAKE_PERMS_OBJ)
2950         @echo "Building plugin $@"
2951         @$(SHLD_MODULE) $(VFS_FAKE_PERMS_OBJ)
2952
2953 bin/default_quota.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_DEFAULT_QUOTA_OBJ)
2954         @echo "Building plugin $@"
2955         @$(SHLD_MODULE) $(VFS_DEFAULT_QUOTA_OBJ)
2956
2957 bin/readonly.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_READONLY_OBJ)
2958         @echo "Building plugin $@"
2959         @$(SHLD_MODULE) $(VFS_READONLY_OBJ)
2960
2961 bin/shadow_copy.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_SHADOW_COPY_OBJ)
2962         @echo "Building plugin $@"
2963         @$(SHLD_MODULE) $(VFS_SHADOW_COPY_OBJ)
2964
2965 bin/shadow_copy2.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_SHADOW_COPY2_OBJ)
2966         @echo "Building plugin $@"
2967         @$(SHLD_MODULE) $(VFS_SHADOW_COPY2_OBJ)
2968
2969 bin/syncops.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_SYNCOPS_OBJ)
2970         @echo "Building plugin $@"
2971         @$(SHLD_MODULE) $(VFS_SYNCOPS_OBJ)
2972
2973 bin/cap.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_CAP_OBJ)
2974         @echo "Building plugin $@"
2975         @$(SHLD_MODULE) $(VFS_CAP_OBJ)
2976
2977 bin/expand_msdfs.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_EXPAND_MSDFS_OBJ)
2978         @echo "Building plugin $@"
2979         @$(SHLD_MODULE) $(VFS_EXPAND_MSDFS_OBJ)
2980
2981 bin/afsacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_AFSACL_OBJ)
2982         @echo "Building plugin $@"
2983         @$(SHLD_MODULE) $(VFS_AFSACL_OBJ)
2984
2985 bin/xattr_tdb.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_XATTR_TDB_OBJ)
2986         @echo "Building plugin $@"
2987         @$(SHLD_MODULE) $(VFS_XATTR_TDB_OBJ)
2988
2989 bin/posixacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_POSIXACL_OBJ)
2990         @echo "Building plugin $@"
2991         @$(SHLD_MODULE) $(VFS_POSIXACL_OBJ)
2992
2993 bin/aixacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_AIXACL_OBJ)
2994         @echo "Building plugin $@"
2995         @$(SHLD_MODULE) $(VFS_AIXACL_OBJ)
2996
2997 bin/aixacl2.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_AIXACL2_OBJ)
2998         @echo "Building plugin $@"
2999         @$(SHLD_MODULE) $(VFS_AIXACL2_OBJ)
3000
3001 bin/solarisacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_SOLARISACL_OBJ)
3002         @echo "Building plugin $@"
3003         @$(SHLD_MODULE) $(VFS_SOLARISACL_OBJ)
3004
3005 bin/zfsacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_ZFSACL_OBJ)
3006         @echo "Building plugin $@"
3007         @$(SHLD_MODULE) $(VFS_ZFSACL_OBJ) @ZFSACL_LIBS@
3008
3009 bin/irixacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_IRIXACL_OBJ)
3010         @echo "Building plugin $@"
3011         @$(SHLD_MODULE) $(VFS_IRIXACL_OBJ)
3012
3013 bin/hpuxacl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_HPUXACL_OBJ)
3014         @echo "Building plugin $@"
3015         @$(SHLD_MODULE) $(VFS_HPUXACL_OBJ)
3016
3017 bin/tru64acl.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_TRU64ACL_OBJ)
3018         @echo "Building plugin $@"
3019         @$(SHLD_MODULE) $(VFS_TRU64ACL_OBJ)
3020
3021 bin/catia.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_CATIA_OBJ)
3022         @echo "Building plugin $@"
3023         @$(SHLD_MODULE) $(VFS_CATIA_OBJ)
3024
3025 bin/streams_xattr.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_STREAMS_XATTR_OBJ)
3026         @echo "Building plugin $@"
3027         @$(SHLD_MODULE) $(VFS_STREAMS_XATTR_OBJ)
3028
3029 bin/streams_depot.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_STREAMS_DEPOT_OBJ)
3030         @echo "Building plugin $@"
3031         @$(SHLD_MODULE) $(VFS_STREAMS_DEPOT_OBJ)
3032
3033 bin/cacheprime.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_CACHEPRIME_OBJ)
3034         @echo "Building plugin $@"
3035         @$(SHLD_MODULE) $(VFS_CACHEPRIME_OBJ)
3036
3037 bin/prealloc.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_PREALLOC_OBJ)
3038         @echo "Building plugin $@"
3039         @$(SHLD_MODULE) $(VFS_PREALLOC_OBJ)
3040
3041 bin/commit.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_COMMIT_OBJ)
3042         @echo "Building plugin $@"
3043         @$(SHLD_MODULE) $(VFS_COMMIT_OBJ)
3044
3045 bin/gpfs.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_GPFS_OBJ)
3046         @echo "Building plugin $@"
3047         @$(SHLD_MODULE) $(VFS_GPFS_OBJ)
3048
3049 bin/gpfs_hsm_notify.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_GPFS_HSM_NOTIFY_OBJ)
3050         @echo "Building plugin $@"
3051         @$(SHLD_MODULE) $(VFS_GPFS_HSM_NOTIFY_OBJ)
3052
3053 bin/notify_fam.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_NOTIFY_FAM_OBJ)
3054         @echo "Building plugin $@"
3055         @$(SHLD_MODULE) $(VFS_NOTIFY_FAM_OBJ) @SMB_FAM_LIBS@
3056
3057 bin/readahead.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_READAHEAD_OBJ)
3058         @echo "Building plugin $@"
3059         @$(SHLD_MODULE) $(VFS_READAHEAD_OBJ)
3060
3061 bin/tsmsm.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_TSMSM_OBJ)
3062         @echo "Building plugin $@"
3063         @$(SHLD_MODULE) $(VFS_TSMSM_OBJ)
3064
3065 bin/fileid.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_FILEID_OBJ)
3066         @echo "Building plugin $@"
3067         @$(SHLD_MODULE) $(VFS_FILEID_OBJ)
3068
3069 bin/aio_fork.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_AIO_FORK_OBJ)
3070         @echo "Building plugin $@"
3071         @$(SHLD_MODULE) $(VFS_AIO_FORK_OBJ)
3072
3073 bin/aio_pthread.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_AIO_PTHREAD_OBJ)
3074         @echo "Building plugin $@"
3075         @$(SHLD_MODULE) $(VFS_AIO_PTHREAD_OBJ)
3076
3077 bin/aio_linux.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_AIO_LINUX_OBJ)
3078         @echo "Building plugin $@"
3079         @$(SHLD_MODULE) $(VFS_AIO_LINUX_OBJ)
3080
3081 bin/preopen.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_PREOPEN_OBJ)
3082         @echo "Building plugin $@"
3083         @$(SHLD_MODULE) $(VFS_PREOPEN_OBJ)
3084
3085 bin/acl_xattr.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_ACL_XATTR_OBJ)
3086         @echo "Building plugin $@"
3087         @$(SHLD_MODULE) $(VFS_ACL_XATTR_OBJ)
3088
3089 bin/smb_traffic_analyzer.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_SMB_TRAFFIC_ANALYZER_OBJ)
3090         @echo "Building plugin $@"
3091         @$(SHLD_MODULE) $(VFS_SMB_TRAFFIC_ANALYZER_OBJ)
3092
3093 bin/acl_tdb.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_ACL_TDB_OBJ)
3094         @echo "Building plugin $@"
3095         @$(SHLD_MODULE) $(VFS_ACL_TDB_OBJ)
3096
3097 bin/pc_test.@SHLIBEXT@: $(BINARY_PREREQS) $(PERFCOUNT_TEST_OBJ)
3098         @echo "Building plugin $@"
3099         @$(SHLD_MODULE) $(PERFCOUNT_TEST_OBJ)
3100
3101 bin/registry.@SHLIBEXT@: $(BINARY_PREREQS) libgpo/gpext/registry.o
3102         @echo "Building plugin $@"
3103         @$(SHLD_MODULE) libgpo/gpext/registry.o
3104
3105 bin/scripts.@SHLIBEXT@: $(BINARY_PREREQS) libgpo/gpext/scripts.o
3106         @echo "Building plugin $@"
3107         @$(SHLD_MODULE) libgpo/gpext/scripts.o
3108
3109 bin/security.@SHLIBEXT@: $(BINARY_PREREQS) libgpo/gpext/security.o
3110         @echo "Building plugin $@"
3111         @$(SHLD_MODULE) libgpo/gpext/security.o
3112
3113 bin/dirsort.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_DIRSORT_OBJ)
3114         @echo "Building plugin $@"
3115         @$(SHLD_MODULE) $(VFS_DIRSORT_OBJ)
3116
3117 bin/scannedonly.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_SCANNEDONLY_OBJ)
3118         @echo "Building plugin $@"
3119         @$(SHLD_MODULE) $(VFS_SCANNEDONLY_OBJ)
3120
3121 bin/crossrename.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_CROSSRENAME_OBJ)
3122         @echo "Building plugin $@"
3123         @$(SHLD_MODULE) $(VFS_CROSSRENAME_OBJ)
3124
3125 bin/linux_xfs_sgid.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_LINUX_XFS_SGID_OBJ)
3126         @echo "Building plugin $@"
3127         @$(SHLD_MODULE) $(VFS_LINUX_XFS_SGID_OBJ)
3128
3129 bin/time_audit.@SHLIBEXT@: $(BINARY_PREREQS) $(VFS_TIME_AUDIT_OBJ)
3130         @echo "Building plugin $@"
3131         @$(SHLD_MODULE) $(VFS_TIME_AUDIT_OBJ)
3132
3133 #########################################################
3134 ## IdMap NSS plugins
3135
3136 ## None here right now
3137 #########################################################
3138
3139 bin/wbinfo: $(BINARY_PREREQS) $(WBINFO_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
3140         @echo Linking $@
3141         @$(CC) -o $@ $(LDFLAGS) $(WBINFO_OBJ) $(DYNEXP) $(LIBS) \
3142                 $(LDAP_LIBS) $(POPT_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) \
3143                 $(LIBWBCLIENT_LIBS)
3144
3145 bin/ntlm_auth: $(BINARY_PREREQS) $(NTLM_AUTH_OBJ) $(PARAM_OBJ) \
3146         $(LIB_NONSMBD_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
3147         @echo Linking $@
3148         @$(CC) -o $@ $(LDFLAGS) $(DYNEXP) $(NTLM_AUTH_OBJ) \
3149                 $(PARAM_OBJ) $(LIB_NONSMBD_OBJ) $(LIBS) $(ZLIB_LIBS) \
3150                 $(POPT_LIBS) $(KRB5LIBS) $(LDAP_LIBS) $(NSCD_LIBS) \
3151                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS) @INIPARSERLIBS@
3152
3153 bin/pam_smbpass.@SHLIBEXT@: $(BINARY_PREREQS) $(PAM_SMBPASS_OBJ) $(LIBTALLOC) $(LIBWBCLIENT) $(LIBTDB)
3154         @echo "Linking shared library $@"
3155         @$(SHLD) $(LDSHFLAGS) -o $@ $(PAM_SMBPASS_OBJ) -lpam $(DYNEXP) \
3156                 $(LIBS) $(LDAP_LIBS) $(NSCD_LIBS) $(KRB5LIBS) $(ZLIB_LIBS) \
3157                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(LIBWBCLIENT_LIBS)
3158
3159 bin/tdbbackup: $(BINARY_PREREQS) $(TDBBACKUP_OBJ) $(LIBTALLOC) $(LIBTDB)
3160         @echo Linking $@
3161         @$(CC) -o $@ $(LDFLAGS) $(TDBBACKUP_OBJ) $(DYNEXP) \
3162                 $(LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
3163
3164 bin/tdbtool: $(BINARY_PREREQS) $(TDBTOOL_OBJ) $(LIBTALLOC) $(LIBTDB)
3165         @echo Linking $@
3166         @$(CC) -o $@ $(LDFLAGS) $(TDBTOOL_OBJ) $(DYNEXP) \
3167                 $(LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
3168
3169 bin/tdbdump: $(BINARY_PREREQS) $(TDBDUMP_OBJ) $(LIBTDB)
3170         @echo Linking $@
3171         @$(CC) -o $@ $(LDFLAGS) $(TDBDUMP_OBJ) $(DYNEXP) $(LIBTDB_LIBS) $(LIBREPLACE_LIBS)
3172
3173 bin/tdbrestore: $(BINARY_PREREQS) $(TDBRESTORE_OBJ) $(LIBTDB)
3174         @echo Linking $@
3175         @$(CC) -o $@ $(LDFLAGS) $(TDBRESTORE_OBJ) $(DYNEXP) $(LIBTDB_LIBS) $(LIBREPLACE_LIBS)
3176
3177 bin/tdbtorture: $(BINARY_PREREQS) $(TDBTORTURE_OBJ) $(LIBTALLOC) $(LIBTDB)
3178         @echo Linking $@
3179         @$(CC) -o $@ $(LDFLAGS) $(TDBTORTURE_OBJ) $(DYNEXP) \
3180                 $(LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
3181
3182 bin/timelimit: script/tests/timelimit.o
3183         @echo Linking $@
3184         @$(CC) -o $@ $(DYNEXP) script/tests/timelimit.o $(LDFLAGS)
3185
3186 bin/rpc_open_tcp: $(BINARY_PREREQS) $(RPC_OPEN_TCP_OBJ) $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
3187         @echo "Linking $@"
3188         @$(CC) -o $@ $(RPC_OPEN_TCP_OBJ) $(LDFLAGS) $(DYNEXP) \
3189                 $(LIBS) $(LIBTALLOC_LIBS) $(LIBWBCLIENT_LIBS) \
3190                 $(LDAP_LIBS) $(KRB5LIBS) $(NSCD_LIBS)
3191
3192 bin/test_lp_load: $(BINARY_PREREQS) $(TEST_LP_LOAD_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
3193         @echo "Linking $@"
3194         @$(CC) -o $@ $(TEST_LP_LOAD_OBJ) \
3195                 $(LDFLAGS) $(DYNEXP) $(LIBS) \
3196                 $(LDAP_LIBS) $(LIBWBCLIENT_LIBS) \
3197                 $(POPT_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
3198
3199 bin/dbwrap_tool: $(DBWRAP_TOOL_OBJ) $(LIBTALLOC) $(LIBTDB)
3200         @echo "Linking $@"
3201         @$(CC) -o $@ $(DBWRAP_TOOL_OBJ)\
3202                 $(LDFLAGS) $(DYNEXP) $(LIBS) \
3203                 $(LDAP_LIBS) \
3204                 $(POPT_LIBS) \
3205                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
3206
3207 install-dbwrap_tool:: bin/dbwrap_tool
3208         @$(SHELL) script/installbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(BINDIR) $<
3209
3210 bin/dbwrap_torture: $(DBWRAP_TORTURE_OBJ) $(LIBTALLOC) $(LIBTDB)
3211         @echo "Linking $@"
3212         @$(CC) -o $@ $(DBWRAP_TORTURE_OBJ)\
3213                 $(LDFLAGS) $(DYNEXP) $(LIBS) \
3214                 $(LDAP_LIBS) \
3215                 $(POPT_LIBS) \
3216                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
3217
3218 install-dbwrap_torture:: bin/dbwrap_torture
3219         @$(SHELL) script/installbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(BINDIR) $<
3220
3221 bin/split_tokens: $(BINARY_PREREQS) $(SPLIT_TOKENS_OBJ) @BUILD_POPT@ $(LIBTALLOC) $(LIBTDB) $(LIBWBCLIENT)
3222         @echo "Linking $@"
3223         @$(CC) -o $@ $(SPLIT_TOKENS_OBJ) \
3224                 $(LDFLAGS) $(DYNEXP) \
3225                 $(LIBS) $(POPT_LIBS) \
3226                 $(LDAP_LIBS) $(LIBWBCLIENT_LIBS) \
3227                 $(LIBTALLOC_LIBS) $(LIBTDB_LIBS)
3228
3229 install:: installservers installbin installman \
3230                 installscripts installdat installmodules @SWAT_INSTALL_TARGETS@ \
3231                 @INSTALL_PAM_MODULES@ installlibs installmo
3232
3233 install-everything:: install installmodules
3234
3235 # DESTDIR is used here to prevent packagers wasting their time
3236 # duplicating the Makefile. Remove it and you will have the privelege
3237 # of package each samba release for muliple versions of multiple
3238 # distributions and operating systems, or at least supplying patches
3239 # to all the packaging files required for this, prior to committing
3240 # the removal of DESTDIR. Do not remove it even though you think it
3241 # is not used
3242
3243 installdirs::
3244         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) \
3245                 $(DESTDIR) $(prefix) $(BINDIR) $(SBINDIR) $(LIBDIR) \
3246                 $(VARDIR) $(PRIVATE_DIR) $(PIDDIR) $(LOCKDIR) $(STATEDIR) \
3247                 $(NMBDSOCKETDIR) $(WINBINDD_SOCKET_DIR) $(WINBINDD_PRIVILEGED_SOCKET_DIR) \
3248                 $(CACHEDIR) $(MANDIR) $(CODEPAGEDIR) $(MODULESDIR) $(LOCALEDIR)
3249
3250 installservers:: all installdirs
3251         @$(SHELL) script/installbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(SBINDIR) $(SBIN_PROGS)
3252
3253 installbin:: all installdirs
3254         @$(SHELL) script/installbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(BINDIR) $(BIN_PROGS)
3255
3256 # Some symlinks are required for the 'probing' of modules.
3257 # This mechanism should go at some point..
3258 installmodules:: modules installdirs
3259         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(VFSLIBDIR) $(VFS_MODULES)
3260         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(PDBLIBDIR) $(PDB_MODULES)
3261         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(IDMAPLIBDIR) $(IDMAP_MODULES)
3262         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(NSSINFOLIBDIR) $(NSS_INFO_MODULES)
3263         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(CHARSETLIBDIR) $(CHARSET_MODULES)
3264         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(AUTHLIBDIR) $(AUTH_MODULES)
3265         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(GPEXTLIBDIR) $(GPEXT_MODULES)
3266         @$(SHELL) $(srcdir)/script/installmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(PERFCOUNTLIBDIR) $(PERFCOUNT_MODULES)
3267         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(PDBLIBDIR) ldapsam.@SHLIBEXT@ NDS_ldapsam.@SHLIBEXT@
3268         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(PDBLIBDIR) ldapsam.@SHLIBEXT@ NDS_ldapsam_compat.@SHLIBEXT@
3269         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(PDBLIBDIR) ldapsam.@SHLIBEXT@ ldapsam_compat.@SHLIBEXT@
3270         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(AUTHLIBDIR) rhosts.@SHLIBEXT@ hostsequiv.@SHLIBEXT@
3271         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(AUTHLIBDIR) sam.@SHLIBEXT@ sam_ignoredomain.@SHLIBEXT@
3272         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(AUTHLIBDIR) domain.@SHLIBEXT@ trustdomain.@SHLIBEXT@ ntdomain.@SHLIBEXT@
3273         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(AUTHLIBDIR) builtin.@SHLIBEXT@ guest.@SHLIBEXT@ fixed_challenge.@SHLIBEXT@ name_to_ntstatus.@SHLIBEXT@
3274         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(NSSINFOLIBDIR) ../idmap/ad.@SHLIBEXT@ rfc2307.@SHLIBEXT@ sfu.@SHLIBEXT@ sfu20.@SHLIBEXT@
3275         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(NSSINFOLIBDIR) ../idmap/adex.@SHLIBEXT@ adex.@SHLIBEXT@
3276         @$(SHELL) $(srcdir)/script/linkmodules.sh $(DESTDIR)$(NSSINFOLIBDIR) ../idmap/hash.@SHLIBEXT@ hash.@SHLIBEXT@
3277
3278 installscripts:: installdirs
3279         @$(SHELL) $(srcdir)/script/installscripts.sh $(INSTALLPERMS_BIN) $(DESTDIR)$(BINDIR) $(SCRIPTS)
3280
3281 installdat:: installdirs
3282         @$(SHELL) $(srcdir)/script/installdat.sh $(DESTDIR) $(CODEPAGEDIR) $(srcdir)
3283
3284 installmsg:: installdirs
3285         @$(SHELL) $(srcdir)/script/installmsg.sh $(DESTDIR) $(CODEPAGEDIR) $(srcdir)
3286
3287 installswat:: installdirs installmsg
3288         @$(SHELL) $(srcdir)/script/installswat.sh $(DESTDIR) $(SWATDIR) $(srcdir)
3289
3290 installpammodules:: $(PAM_MODULES)
3291         @$(SHELL) $(srcdir)/script/installdirs.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(PAMMODULESDIR)
3292         @for module in $(PAM_MODULES); do \
3293                 echo "Installing module $${module} as $(DESTDIR)/$(PAMMODULESDIR)/$${module}.@SHLIBEXT@ "; \
3294                 $(INSTALLCMD) -m $(INSTALLPERMS_BIN) bin/$${module}.@SHLIBEXT@ \
3295                         "$(DESTDIR)/$(PAMMODULESDIR)"; \
3296         done
3297
3298 # revert to the previously installed version
3299 revert::
3300         @$(SHELL) $(srcdir)/script/revert.sh $(SBINDIR) $(SBIN_PROGS)
3301         @$(SHELL) $(srcdir)/script/revert.sh $(BINDIR) $(BIN_PROGS) $(SCRIPTS)
3302
3303 installman:: installdirs
3304         @$(SHELL) $(srcdir)/script/installman.sh $(DESTDIR)$(MANDIR) $(srcdir) C "@ROFF@"
3305
3306 installmo:: all installdirs
3307         @$(SHELL) $(srcdir)/script/installmo.sh $(DESTDIR) $(LOCALEDIR) $(srcdir)
3308
3309 .PHONY: showlayout
3310
3311 showlayout::
3312         @echo "Samba will be installed into:"
3313         @echo " prefix:                $(prefix)"
3314         @echo " exec_prefix:           $(exec_prefix)"
3315         @echo " sysconfdir:            $(sysconfdir)"
3316         @echo " localstatedir:         $(localstatedir)"
3317         @echo " datarootdir:           $(datarootdir)"
3318         @echo " BINDIR:                $(BINDIR)"
3319         @echo " SBINDIR:               $(SBINDIR)"
3320         @echo " LIBDIR:                $(LIBDIR)"
3321 #       @echo " LIBEXECDIR:            $(LIBEXECDIR)"
3322         @echo " MANDIR:                $(MANDIR)"
3323         @echo " DATADIR:               $(DATADIR)"
3324         @echo " LOCALEDIR:             $(LOCALEDIR)"
3325 #       @echo " SCRIPTSBINDIR:         $(SCRIPTSBINDIR)"
3326 #       @echo " PYTHONDIR:             $(PYTHONDIR)"
3327 #       @echo " PYTHONARCHDIR:         $(PYTHONARCHDIR)"
3328         @echo " MODULESDIR:            $(MODULESDIR)"
3329         @echo " INCLUDEDIR:            $(INCLUDEDIR)"
3330         @echo " SETUPDIR:              $(SETUPDIR)"
3331 #       @echo " PKGCONFIGDIR:          $(PKGCONFIGDIR)"
3332         @echo " SWATDIR:               $(SWATDIR)"
3333         @echo " CODEPAGEDIR:           $(CODEPAGEDIR)"
3334         @echo " PAMMODULESDIR:         $(PAMMODULESDIR)"
3335         @echo " CONFIGDIR:             $(CONFIGDIR)"
3336         @echo " PRIVATE_DIR:           $(PRIVATE_DIR)"
3337         @echo " LOCKDIR:               $(LOCKDIR)"
3338         @echo " PIDDIR:                $(PIDDIR)"
3339         @echo " STATEDIR:              $(STATEDIR)"
3340         @echo " CACHEDIR:              $(CACHEDIR)"
3341         @echo " LOGFILEBASE:           $(LOGFILEBASE)"
3342         @echo " SOCKET_DIR:            $(SOCKET_DIR)"
3343         @echo " PRIVILEGED_SOCKET_DIR: $(PRIVILEGED_SOCKET_DIR)"
3344         @echo " WINBINDD_SOCKET_DIR:   $(WINBINDD_SOCKET_DIR)"
3345         @echo " WINBINDD_PRIVILEGED_SOCKET_DIR: $(WINBINDD_PRIVILEGED_SOCKET_DIR)"
3346         @echo " NMBDSOCKETDIR:         $(NMBDSOCKETDIR)"
3347 #       @echo " NTP_SIGND_SOCKET_DIR:  $(NTP_SIGND_SOCKET_DIR)"
3348         @echo " NCALRPCDIR:            $(NCALRPCDIR)"
3349         @echo " CONFIGFILE:            $(CONFIGFILE)"
3350         @echo " LMHOSTSFILE:           $(LMHOSTSFILE)"
3351         @echo " SMB_PASSWD_FILE:       $(SMB_PASSWD_FILE)"
3352
3353
3354 uninstall:: uninstallmo uninstallman uninstallservers uninstallbin uninstallscripts uninstalldat uninstallswat uninstallmodules uninstalllibs @UNINSTALL_PAM_MODULES@
3355
3356 uninstallmo::
3357         @$(SHELL) $(srcdir)/script/uninstallmo.sh $(DESTDIR) $(LOCALEDIR) $(srcdir)
3358
3359 uninstallman::
3360         @$(SHELL) $(srcdir)/script/uninstallman.sh $(DESTDIR)$(MANDIR) $(srcdir) C
3361
3362 uninstallservers::
3363         @$(SHELL) script/uninstallbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(SBINDIR) $(SBIN_PROGS)
3364
3365 uninstallbin::
3366         @$(SHELL) script/uninstallbin.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(BINDIR) $(BIN_PROGS)
3367
3368 uninstallmodules::
3369         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(VFSLIBDIR) $(VFS_MODULES)
3370         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(PDBLIBDIR) $(PDB_MODULES)
3371         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(IDMAPLIBDIR) $(IDMAP_MODULES)
3372         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(CHARSETLIBDIR) $(CHARSET_MODULES)
3373         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(AUTHLIBDIR) $(AUTH_MODULES)
3374         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(GPEXTLIBDIR) $(GPEXT_MODULES)
3375         @$(SHELL) $(srcdir)/script/uninstallmodules.sh $(INSTALLPERMS_BIN) $(DESTDIR) $(prefix) $(PERFCOUNTLIBDIR) $(PERFCOUNT_MODULES)
3376
3377 uninstallscripts::
3378         @$(SHELL) $(srcdir)/script/uninstallscripts.sh $(INSTALLPERMS_BIN) $(DESTDIR)$(BINDIR) $(SCRIPTS)
3379
3380 uninstalldat::
3381         @$(SHELL) $(srcdir)/script/uninstalldat.sh $(DESTDIR) $(LIBDIR) $(srcdir)
3382
3383 uninstallmsg::
3384         @$(SHELL) $(srcdir)/script/uninstallmsg.sh $(DESTDIR) $(LIBDIR) $(srcdir)
3385
3386 uninstallswat:: uninstallmsg
3387         @$(SHELL) $(srcdir)/script/uninstallswat.sh $(DESTDIR) $(SWATDIR) $(srcdir)
3388
3389 uninstallpammodules::
3390         @for module in $(PAM_MODULES); do \
3391                 echo "Removing $(DESTDIR)/$(PAMMODULESDIR)/$${module}.@SHLIBEXT@ "; \
3392                 rm -f "$(DESTDIR)/$(PAMMODULESDIR)/$${module}.@SHLIBEXT@"; \
3393         done
3394
3395 cleanlibs::
3396         -rm -f ../lib/*/*.o ../lib/*/*/*.o \
3397                 ../lib/*/*.ho \
3398                 ../libcli/*.o ../libcli/*/*.o ../libcli/*/*/*.o \
3399                 ../librpc/*/*.o \
3400                 ../libgpo/*.o ../libgpo/*/*.o \
3401                 ../libds/*.o ../libds/*/*.o ../dynconfig/*.o ../auth/*.o ../auth/*/*.o
3402
3403 clean:: cleanlibs
3404         -rm -f include/build_env.h
3405         -rm -f smbd/build_options.c
3406         -rm -f param/param_local.h
3407         -rm -f param/param_global.h
3408         -rm -f ../lib/param/param_local.h
3409         -rm -f ../lib/param/param_global.h
3410         -rm -f ../lib/param/param_proto.h
3411         -rm -f ../lib/param/s3_param.h
3412         -rm -f $(PRECOMPILED_HEADER)
3413         -rm -f core */*~ *~ \
3414                 */*.o */*/*.o */*/*/*.o */*/*/*/*.o \
3415                 ../testsuite/*/*.o \
3416                 ../nsswitch/*.o ../nsswitch/*/*.o ../nsswitch/*/*/*.o ../nsswitch/*.@SHLIBEXT@ \
3417                 ../client/*.o \
3418                 */*.@SHLIBEXT@ */*/*.@SHLIBEXT@ */*/*/*.@SHLIBEXT@ \
3419                 $(TOPFILES) $(BIN_PROGS) $(SBIN_PROGS) \
3420                 $(MODULES) $(TORTURE_PROGS) \
3421                 $(EVERYTHING_PROGS) \
3422                 bin/timelimit \
3423                 .headers.stamp */src/*.o
3424         -rm -rf t_dir
3425
3426 include/build_env.h: script/build_env.sh
3427         @echo Building include/build_env.h
3428         @$(SHELL) $(srcdir)/script/build_env.sh $(srcdir) $(builddir) $(CC) \
3429           > $(builddir)/include/build_env.h
3430
3431 proto::
3432
3433 etags::
3434         rm -f TAGS
3435         find $(srcdir)/.. -name "*.[ch]" | xargs -n 100 etags --append $(ETAGS_OPTIONS)
3436
3437 ctags::
3438         ctags $(CTAGS_OPTIONS) `find $(srcdir)/.. -name "*.[ch]" | grep -v proto\.h`
3439
3440 realclean:: clean
3441         -rm -f config.log bin/.dummy script/findsmb script/gen-8bit-gap.sh
3442         -rm -f script/installbin.sh script/uninstallbin.sh
3443
3444 distclean:: realclean
3445         -rm -f smbadduser
3446         -rm -f include/autoconf/config.h Makefile
3447         -rm -f config.status config.cache so_locations
3448         -rm -rf .deps TAGS
3449
3450 realdistclean:: distclean
3451         -rm -f include/autoconf/config.h.in
3452         -rm -f include/version.h
3453         -rm -f configure
3454
3455 # this target is really just for my use. It only works on a limited
3456 # range of machines and is used to produce a list of potentially
3457 # dead (ie. unused) functions in the code. (tridge)
3458 finddead::
3459         nm */*.o |grep 'U ' | awk '{print $$2}' | sort -u > nmused.txt
3460         nm */*.o |grep 'T ' | awk '{print $$3}' | sort -u > nmfns.txt
3461         comm -13 nmused.txt nmfns.txt
3462
3463
3464 # when configure.in is updated, reconfigure
3465 $(srcdir)/configure: $(srcdir)/configure.in
3466         @echo "WARNING: you need to rerun ./autogen.sh"
3467
3468 config.status: $(srcdir)/configure
3469         @echo "WARNING: you need to run ./configure"
3470
3471 Makefile: $(srcdir)/Makefile.in config.status
3472         @echo "WARNING: you need to run ./config.status"
3473
3474 ######################################################################
3475 # Samba Testing Framework
3476
3477 # Check shared libs for unresolved symbols
3478 test_shlibs:
3479         @echo "Testing $? "
3480         @$(LIB_PATH_VAR)=./bin && \
3481         export $(LIB_PATH_VAR) && \
3482         for module in $?; do \
3483                 ./script/tests/dlopen.sh $(LIBDL) $${module} \
3484                         || exit 1; \
3485         done
3486
3487 # Check for NSS module problems.
3488 test_nss_modules:: nss_modules
3489         @echo "Testing $(NSS_MODULES) "
3490         @$(LIB_PATH_VAR)=./bin && \
3491         export $(LIB_PATH_VAR) && \
3492         for module in $(NSS_MODULES); do \
3493                 ./script/tests/dlopen.sh $(LIBDL) $${module} \
3494                         || exit 1; \
3495         done
3496
3497 # Check for PAM module problems.  Specifically, check that every module we
3498 # built can actually be loaded by a minimal PAM-aware application.
3499 test_pam_modules:: pam_modules
3500         @echo "Testing $(PAM_MODULES) "
3501         @$(LIB_PATH_VAR)=./bin && \
3502         export $(LIB_PATH_VAR) && \
3503         for module in $(PAM_MODULES); do \
3504                 ./script/tests/dlopen.sh -lpam $(LIBDL) bin/$${module}.@SHLIBEXT@ \
3505                         || exit 1; \
3506         done
3507
3508
3509 ##
3510 ## Targets for 'make test'
3511 ##
3512
3513 valgrindtest:: all torture timelimit
3514         @echo Running Test suite with valgrind
3515         @$(MAKE) test \
3516          NMBD_VALGRIND="xterm -n nmbd -e valgrind -q --db-attach=yes --num-callers=30" \
3517          WINBINDD_VALGRIND="xterm -n winbindd -e valgrind -q --db-attach=yes --num-callers=30" \
3518          SMBD_VALGRIND="xterm -n smbd -e valgrind -q --db-attach=yes --num-callers=30" \
3519          VALGRIND="valgrind -q --num-callers=30 --log-file=${selftest_prefix}/valgrind.log"
3520
3521 selftestdir = ../selftest
3522
3523 S3_LD_LIBPATH_OVERRIDE = $(LIB_PATH_VAR)="$(builddir)/bin:$$$(LIB_PATH_VAR)"
3524
3525 test:: all torture timelimit
3526         @LIB_PATH_VAR=$(LIB_PATH_VAR) $(S3_LD_LIBPATH_OVERRIDE) \
3527                 NSS_WRAPPER_WINBIND_SO_PATH="$(srcdir)/../nsswitch/libnss_winbind.so" \
3528                 SELFTESTDIR="$(selftestdir)" SELFTESTPREFIX="$(selftest_prefix)" \
3529                 SOURCEDIR="$(srcdir)" \
3530                 VFSLIBDIR="$(builddir)/bin" \
3531                 RUN_FROM_BUILD_FARM="$(RUN_FROM_BUILD_FARM)" \
3532                 SUBUNIT_FORMATTER="$(SUBUNIT_FORMATTER)" \
3533                 PERL="$(PERL)" PYTHON="$(PYTHON)" \
3534                 $(srcdir)/selftest/s3-selftest.sh
3535
3536 test-%:
3537         $(MAKE) test TESTS=$*
3538
3539 buildfarm-test:
3540         $(MAKE) test RUN_FROM_BUILD_FARM=yes
3541
3542 subunit-test:
3543         $(MAKE) test SUBUNIT_FORMATTER=cat
3544
3545 SELFTEST_TESTENV = s3dc
3546
3547 testenv:
3548         $(MAKE) test SELFTEST_TESTENV=$(SELFTEST_TESTENV) TESTS="--testenv"
3549
3550 gdbtestenv:
3551         $(MAKE) test SELFTEST_TESTENV=$(SELFTEST_TESTENV) \
3552                 NMBD_VALGRIND="xterm -n nmbd -title nmbd -e $(selftestdir)/gdb_run $(S3_LD_LIBPATH_OVERRIDE)" \
3553                 WINBINDD_VALGRIND="xterm -n winbindd -title winbindd -e $(selftestdir)/gdb_run $(S3_LD_LIBPATH_OVERRIDE)" \
3554                 SMBD_VALGRIND="xterm -n smbd -title smbd -e $(selftestdir)/gdb_run $(S3_LD_LIBPATH_OVERRIDE)" \
3555                 TESTS="--testenv"
3556
3557 valgrindtestenv:
3558         $(MAKE) test SELFTEST_TESTENV=$(SELFTEST_TESTENV) \
3559                 NMBD_VALGRIND="xterm -n nmbd -title nmbd -e valgrind -q --db-attach=yes --num-callers=30" \
3560                 WINBINDD_VALGRIND="xterm -n winbindd -title winbindd -e valgrind -q --db-attach=yes --num-callers=30" \
3561                 SMBD_VALGRIND="xterm -n smbd -title smbd -e valgrind -q --db-attach=yes --num-callers=30" \
3562                 TESTS="--testenv"
3563
3564
3565 # Check for Winbind struct 32/64bit padding
3566 test_wbpad:
3567         @echo "Testing winbind request/response structure for 32/64bit padding"
3568         @./script/tests/wb_pad.sh || exit 1;
3569
3570 ##
3571 ## Examples:
3572 ##
3573
3574 libsmbclient_examples: libsmbclient
3575         $(MAKE) -C ../examples/libsmbclient -f Makefile.internal
3576
3577 clean_libsmbclient_examples:
3578         $(MAKE) -C ../examples/libsmbclient -f Makefile.internal clean
3579
3580 libnetapi_examples: libnetapi
3581         $(MAKE) -C lib/netapi/examples
3582
3583 clean_libnetapi_examples:
3584         $(MAKE) -C lib/netapi/examples clean
3585
3586 .PHONY: bin/smbtorture4 bin/ndrdump4
3587
3588 bin/smbtorture4: $(BINARY_PREREQS)
3589         $(MAKE) -f Makefile-smbtorture4 bin/smbtorture4
3590
3591 bin/ndrdump4: $(BINARY_PREREQS)
3592         $(MAKE) -f Makefile-smbtorture4 bin/ndrdump4
3593
3594 .PHONY: vfs_examples
3595
3596 vfs_examples:
3597         ( \
3598         cd ../examples/VFS && \
3599         ./autogen.sh && \
3600         ./configure && \
3601         make clean && \
3602         make \
3603         )