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