drsuapi.idl: readd type serialization headers to compressed DsGetNCChangesCtr*
[Samba.git] / source4 / Makefile
blobb0aa009edd2bede4671859f58987c925354e1003
1 #!gmake
2 # The Samba 4 Makefile.
3 # This file is *NOT* autogenerated.
5 .DEFAULT_GOAL := all
7 default: all
9 include mkconfig.mk
11 pidldir := $(srcdir)/pidl
13 BASEDIR = $(prefix)
14 TORTUREDIR = $(libdir)/torture
15 SWATDIR = $(datadir)/swat
16 JSDIR = $(datadir)/js
17 SETUPDIR = $(datadir)/setup
18 NCALRPCDIR = $(localstatedir)/ncalrpc
20 BNLD = $(LD)
21 BNLD_FLAGS = $(LDFLAGS) $(SYS_LDFLAGS)
23 HOSTCC_FLAGS = -D_SAMBA_HOSTCC_ $(CFLAGS)
24 HOSTLD_FLAGS = $(LDFLAGS) $(SYS_LDFLAGS)
26 $(srcdir)/version.h: $(srcdir)/VERSION
27 @$(SHELL) script/mkversion.sh VERSION $(srcdir)/version.h $(srcdir)/
29 ifneq ($(automatic_dependencies),yes)
30 ALL_PREDEP = basics
31 .NOTPARALLEL:
32 endif
34 regen_version::
35 @$(SHELL) script/mkversion.sh VERSION $(srcdir)/version.h $(srcdir)/
37 clean_pch::
38 @echo "Removing precompiled headers"
39 @-rm -f include/includes.h.gch
41 pch:: clean_pch include/includes.h.gch
43 .DEFAULT_GOAL := all
45 ifneq ($(automatic_dependencies),yes)
46 ALL_PREDEP = basics
47 .NOTPARALLEL:
48 endif
50 include $(srcdir)/build/make/rules.mk
51 include $(srcdir)/build/make/python.mk
52 dynconfigsrcdir := dynconfig
53 heimdalsrcdir := heimdal
54 dsdbsrcdir := dsdb
55 smbdsrcdir := smbd
56 clustersrcdir := cluster
57 libnetsrcdir := libnet
58 authsrcdir := auth
59 nsswitchsrcdir := nsswitch
60 libsrcdir := lib
61 libsocketsrcdir := lib/socket
62 libcharsetsrcdir := lib/charset
63 ldb_sambasrcdir := lib/ldb-samba
64 tdbsrcdir := lib/tdb
65 ldbsrcdir := lib/ldb
66 libtlssrcdir := lib/tls
67 libregistrysrcdir := lib/registry
68 smbreadlinesrcdir := lib/smbreadline
69 libmessagingsrcdir := lib/messaging
70 libeventssrcdir := lib/events
71 libcmdlinesrcdir := lib/cmdline
72 poptsrcdir := lib/popt
73 socketwrappersrcdir := lib/socket_wrapper
74 nsswrappersrcdir := lib/nss_wrapper
75 appwebsrcdir := lib/appweb
76 libstreamsrcdir := lib/stream
77 libutilsrcdir := lib/util
78 libtdrsrcdir := lib/tdr
79 libdbwrapsrcdir := lib/dbwrap
80 libcryptosrcdir := lib/crypto
81 libtorturesrcdir := lib/torture
82 smb_serversrcdir := smb_server
83 libcompressionsrcdir := lib/compression
84 libgencachesrcdir := lib
85 paramsrcdir := param
86 rpc_serversrcdir := rpc_server
87 ldap_serversrcdir := ldap_server
88 web_serversrcdir := web_server
89 winbindsrcdir := winbind
90 nbt_serversrcdir := nbt_server
91 wrepl_serversrcdir := wrepl_server
92 cldap_serversrcdir := cldap_server
93 utilssrcdir := utils
94 clientsrcdir := client
95 torturesrcdir := torture
96 ntvfssrcdir := ntvfs
97 ntptrsrcdir := ntptr
98 librpcsrcdir := librpc
99 libclisrcdir := libcli
100 ejsscriptsrcdir := scripting/ejs
101 pyscriptsrcdir := $(srcdir)/scripting/python
102 kdcsrcdir := kdc
103 ntp_signdsrcdir := ntp_signd
105 include data.mk
107 pythonmods:: $(PYTHON_PYS) $(PYTHON_SO)
109 DEP_FILES = $(patsubst %.ho,%.hd,$(patsubst %.o,%.d,$(ALL_OBJS))) \
110 include/includes.d
112 ifeq ($(automatic_dependencies),yes)
113 ifneq ($(MAKECMDGOALS),clean)
114 ifneq ($(MAKECMDGOALS),distclean)
115 ifneq ($(MAKECMDGOALS),realdistclean)
116 ifneq ($(SKIP_DEP_FILES),yes)
117 -include $(DEP_FILES)
118 endif
119 endif
120 endif
121 endif
123 ifneq ($(SKIP_DEP_FILES),yes)
124 clean::
125 @echo Removing dependency files
126 @find . -name '*.d' -o -name '*.hd' | xargs rm -f
127 endif
128 else
129 include $(srcdir)/static_deps.mk
130 endif
132 DEFAULT_HEADERS = $(srcdir)/lib/util/dlinklist.h \
133 $(srcdir)/version.h
135 libraries:: $(STATIC_LIBS) $(SHARED_LIBS)
136 modules:: $(PLUGINS)
137 headers:: $(PUBLIC_HEADERS) $(DEFAULT_HEADERS)
138 manpages:: $(MANPAGES)
139 all:: showflags $(ALL_PREDEP) binaries modules pythonmods libraries headers
140 everything:: all
142 LD_LIBPATH_OVERRIDE = $(LIB_PATH_VAR)=$(builddir)/bin/shared
144 # 'make testsuite' creates all binaries which are
145 # needed by samba3's 'make test' and the build-farm
146 # scripts use that it as fallback in case
147 # 'make everything' fails
148 testsuite:: bin/smbclient bin/cifsdd bin/smbtorture bin/nmblookup
150 showlayout::
151 @echo 'Samba will be installed into:'
152 @echo ' basedir: $(BASEDIR)'
153 @echo ' bindir: $(bindir)'
154 @echo ' sbindir: $(sbindir)'
155 @echo ' libdir: $(libdir)'
156 @echo ' modulesdir: $(modulesdir)'
157 @echo ' includedir: $(includedir)'
158 @echo ' vardir: $(localstatedir)'
159 @echo ' privatedir: $(privatedir)'
160 @echo ' piddir: $(piddir)'
161 @echo ' lockdir: $(lockdir)'
162 @echo ' logfilebase: $(logfilebase)'
163 @echo ' setupdir: $(SETUPDIR)'
164 @echo ' jsdir: $(JSDIR)'
165 @echo ' swatdir: $(SWATDIR)'
166 @echo ' mandir: $(mandir)'
167 @echo ' torturedir: $(TORTUREDIR)'
168 @echo ' datadir: $(datadir)'
169 @echo ' winbindd_socket_dir: $(winbindd_socket_dir)'
170 @echo ' ntp_signd_socket_dir: $(ntp_signd_socket_dir)'
172 showflags::
173 @echo ' srcdir = $(srcdir)'
174 @echo ' builddir = $(builddir)'
176 # The permissions to give the executables
177 INSTALLPERMS = 0755
179 install:: showlayout everything installbin installsbin installdat installswat installmisc \
180 installlib installheader installpc installplugins
182 # DESTDIR is used here to prevent packagers wasting their time
183 # duplicating the Makefile. Remove it and you will have the privilege
184 # of packaging each samba release for multiple versions of multiple
185 # distributions and operating systems, or at least supplying patches
186 # to all the packaging files required for this, prior to committing
187 # the removal of DESTDIR. Do not remove it even though you think it
188 # is not used.
190 installdirs::
191 @$(SHELL) $(srcdir)/script/installdirs.sh \
192 $(DESTDIR)$(BASEDIR) \
193 $(DESTDIR)$(bindir) \
194 $(DESTDIR)$(sbindir) \
195 $(DESTDIR)$(TORTUREDIR) \
196 $(DESTDIR)$(libdir) \
197 $(DESTDIR)$(modulesdir) \
198 $(DESTDIR)$(mandir) \
199 $(DESTDIR)$(localstatedir) \
200 $(DESTDIR)$(localstatedir)/lib \
201 $(DESTDIR)$(localstatedir)/run \
202 $(DESTDIR)$(privatedir) \
203 $(DESTDIR)$(datadir) \
204 $(DESTDIR)$(piddir) \
205 $(DESTDIR)$(lockdir) \
206 $(DESTDIR)$(logfilebase) \
207 $(DESTDIR)$(privatedir)/tls \
208 $(DESTDIR)$(includedir) \
209 $(DESTDIR)$(PKGCONFIGDIR) \
210 $(DESTDIR)$(sysconfdir)
212 installbin:: $(SBIN_PROGS) $(BIN_PROGS) $(TORTURE_PROGS) installdirs
213 @$(SHELL) $(srcdir)/script/installtorture.sh \
214 $(INSTALLPERMS) \
215 $(DESTDIR)$(TORTUREDIR) \
216 $(TORTURE_PROGS)
218 installplugins::
220 installlib:: $(SHARED_LIBS) $(STATIC_LIBS) installdirs
221 @$(SHELL) $(srcdir)/script/installlib.sh $(DESTDIR)$(libdir) "$(SHLIBEXT)" $(SHARED_LIBS)
222 #@$(SHELL) $(srcdir)/script/installlib.sh $(DESTDIR)$(libdir) "$(STLIBEXT)" $(STATIC_LIBS)
224 installheader:: headers installdirs
225 @srcdir=$(srcdir) builddir=$(builddir) $(PERL) $(srcdir)/script/installheader.pl $(DESTDIR)$(includedir) $(PUBLIC_HEADERS) $(DEFAULT_HEADERS)
227 installdat:: installdirs
228 @$(SHELL) $(srcdir)/script/installdat.sh $(DESTDIR)$(datadir) $(srcdir)
230 installswat:: installdirs
231 #SWAT has been disabled until further notice
232 # @$(SHELL) $(srcdir)/script/installswat.sh $(DESTDIR)$(SWATDIR) $(srcdir)
234 installman:: manpages installdirs
235 @$(SHELL) $(srcdir)/script/installman.sh $(DESTDIR)$(mandir) $(MANPAGES)
237 installmisc:: installdirs
238 @$(SHELL) $(srcdir)/script/installmisc.sh $(srcdir) $(DESTDIR)$(JSDIR) $(DESTDIR)$(SETUPDIR) $(DESTDIR)$(bindir)
240 installpc:: installdirs
241 @$(SHELL) $(srcdir)/script/installpc.sh $(builddir) $(DESTDIR)$(PKGCONFIGDIR) $(PC_FILES)
243 uninstall:: uninstallbin uninstallman uninstallmisc uninstalllib uninstallheader \
244 uninstallplugins
246 uninstallmisc::
247 #FIXME
249 $(DESTDIR)$(bindir)/%: bin/% installdirs
250 @mkdir -p $(@D)
251 @echo Installing $(@F) as $@
252 @if test -f $@; then echo -n ""; rm -f $@.old; mv $@ $@.old; fi
253 @cp $< $@
254 @chmod $(INSTALLPERMS) $@
256 $(DESTDIR)$(sbindir)/%: bin/% installdirs
257 @mkdir -p $(@D)
258 @echo Installing $(@F) as $@
259 @if test -f $@; then echo -n ""; rm -f $@.old; mv $@ $@.old; fi
260 @cp $< $@
261 @chmod $(INSTALLPERMS) $@
263 uninstallbin::
264 @$(SHELL) $(srcdir)/script/uninstallbin.sh $(INSTALLPERMS) $(DESTDIR)$(BASEDIR) $(DESTDIR)$(sbindir) $(DESTDIR)$(libdir) $(DESTDIR)$(localstatedir) $(DESTDIR)$(SBIN_PROGS)
265 @$(SHELL) $(srcdir)/script/uninstallbin.sh $(INSTALLPERMS) $(DESTDIR)$(BASEDIR) $(DESTDIR)$(bindir) $(DESTDIR)$(libdir) $(DESTDIR)$(localstatedir) $(DESTDIR)$(BIN_PROGS)
266 @$(SHELL) $(srcdir)/script/uninstalltorture.sh $(DESTDIR)$(TORTUREDIR) $(TORTURE_PROGS)
268 uninstalllib::
269 @$(SHELL) $(srcdir)/script/uninstalllib.sh $(DESTDIR)$(libdir) $(SHARED_LIBS)
270 #@$(SHELL) $(srcdir)/script/uninstalllib.sh $(DESTDIR)$(libdir) $(STATIC_LIBS)
272 uninstallheader::
273 @$(SHELL) $(srcdir)/script/uninstallheader.sh $(DESTDIR)$(includedir) $(PUBLIC_HEADERS)
275 uninstallman::
276 @$(SHELL) $(srcdir)/script/uninstallman.sh $(DESTDIR)$(mandir) $(MANPAGES)
278 uninstallplugins::
280 config.status:
281 @echo "config.status does not exist. Please run ./configure."
282 @/bin/false
284 data.mk: config.status $(MK_FILES)
285 ./config.status
287 testcov-html::
289 include $(pidldir)/config.mk
290 selftestdir := $(srcdir)/selftest
291 include $(selftestdir)/config.mk
293 showflags::
294 @echo ' pwd = '`/bin/pwd`