]>
Commit | Line | Data |
---|---|---|
50e1e10f TT |
1 | # Beginning of file MCONFIG |
2 | ||
ef8901be TT |
3 | all:: |
4 | ||
3e377db2 TT |
5 | check:: |
6 | ||
50e1e10f TT |
7 | SHELL = /bin/sh |
8 | ||
482afc44 TT |
9 | COMPRESS_EXT = gz bz2 bz Z |
10 | ||
50e1e10f | 11 | prefix = @prefix@ |
a4b2d3ce | 12 | root_prefix = @root_prefix@ |
50e1e10f | 13 | exec_prefix = @exec_prefix@ |
b5ffeade TT |
14 | root_bindir = @root_bindir@ |
15 | root_sbindir = @root_sbindir@ | |
16 | root_libdir = @root_libdir@ | |
b6b65c3d | 17 | datarootdir = @datarootdir@ |
a4b2d3ce TT |
18 | bindir = @bindir@ |
19 | sbindir = @sbindir@ | |
20 | libdir = @libdir@ | |
b5ffeade | 21 | datadir= @datadir@ |
a04eba3f | 22 | localedir = $(datadir)/locale |
b5ffeade | 23 | root_sysconfdir= @root_sysconfdir@ |
a4b2d3ce TT |
24 | includedir = @includedir@ |
25 | mandir = @mandir@ | |
a4bf69d9 TT |
26 | man1dir = $(mandir)/man1 |
27 | man3dir = $(mandir)/man3 | |
9dc6ad1e | 28 | man5dir = $(mandir)/man5 |
a4bf69d9 | 29 | man8dir = $(mandir)/man8 |
a4b2d3ce TT |
30 | infodir = @infodir@ |
31 | datadir = @datadir@ | |
50e1e10f TT |
32 | |
33 | @SET_MAKE@ | |
34 | ||
bcb915b0 TT |
35 | @ifGNUmake@ V = |
36 | @ifGNUmake@ ifeq ($(strip $(V)),) | |
37 | @ifGNUmake@ # E = @echo | |
c1986ecb | 38 | @ifGNUmake@ # ES = echo |
bcb915b0 TT |
39 | @ifGNUmake@ # Q = @ |
40 | @ifGNUmake@ E = @E@ | |
c1986ecb | 41 | @ifGNUmake@ ES = @ES@ |
bcb915b0 TT |
42 | @ifGNUmake@ Q = @Q@ |
43 | @ifGNUmake@ else | |
44 | @ifGNUmake@ E = @\# | |
c1986ecb | 45 | @ifGNUmake@ ES = \# |
bcb915b0 TT |
46 | @ifGNUmake@ Q = |
47 | @ifGNUmake@ endif | |
c13351f6 | 48 | |
bcb915b0 | 49 | @ifNotGNUmake@ E = @E@ |
c1986ecb | 50 | @ifNotGNUmake@ ES = @ES@ |
bcb915b0 | 51 | @ifNotGNUmake@ Q = @Q@ |
c13351f6 | 52 | |
50e1e10f | 53 | CC = @CC@ |
6c133523 | 54 | BUILD_CC = @BUILD_CC@ |
74becf3c | 55 | CFLAGS = @CFLAGS@ |
d1154eb4 TT |
56 | CPPFLAGS = @INCLUDES@ |
57 | ALL_CFLAGS = $(CPPFLAGS) $(CFLAGS) | |
50e1e10f | 58 | LDFLAGS = @LDFLAGS@ |
55da9876 TT |
59 | ALL_LDFLAGS = $(LDFLAGS) @LDFLAG_DYNAMIC@ |
60 | LDFLAGS_STATIC = $(LDFLAGS) @LDFLAG_STATIC@ | |
dd947da2 TT |
61 | BUILD_CFLAGS = @BUILD_CFLAGS@ |
62 | BUILD_LDFLAGS = @BUILD_LDFLAGS@ | |
9b3018a8 | 63 | RDYNAMIC = @RDYNAMIC@ |
5aa6c3f6 TT |
64 | LINK_BUILD_FLAGS = @LINK_BUILD_FLAGS@ |
65 | LINK_INSTALL_FLAGS = @LINK_INSTALL_FLAGS@ | |
50e1e10f TT |
66 | RM = @RM@ |
67 | LN = @LN@ | |
fc6d9d51 | 68 | LN_S = @LN_S@ |
50e1e10f TT |
69 | MV = @MV@ |
70 | CP = @CP@ | |
71 | CHMOD = @CHMOD@ | |
72 | AR = @AR@ | |
73 | AWK = @AWK@ | |
74 | SED = @SED@ | |
9d564f73 | 75 | PERL = @PERL@ |
50e1e10f TT |
76 | RANLIB = @RANLIB@ |
77 | STRIP = @STRIP@ | |
78 | LD = $(PURE) @CC@ | |
79 | ARUPD = $(AR) r | |
47204ff9 | 80 | ARGEN = $(AR) rc |
250f79f0 | 81 | LDCONFIG = @LDCONFIG@ |
6d402278 TT |
82 | INSTALL_PROGRAM = @INSTALL_PROGRAM@ |
83 | INSTALL_DATA = @INSTALL_DATA@ | |
84 | INSTALL_SCRIPT = @INSTALL_SCRIPT@ | |
85 | MKINSTALLDIRS = @MKINSTALLDIRS@ | |
50e1e10f | 86 | |
a4d09610 TT |
87 | # |
88 | # Library definitions | |
89 | # | |
90 | LIB = $(top_builddir)/lib | |
55da9876 | 91 | LIBSS = $(LIB)/libss@LIB_EXT@ @PRIVATE_LIBS_CMT@ @DLOPEN_LIB@ |
d7f45af8 | 92 | LIBCOM_ERR = $(LIB)/libcom_err@LIB_EXT@ @PRIVATE_LIBS_CMT@ @SEM_INIT_LIB@ |
a4d09610 TT |
93 | LIBE2P = $(LIB)/libe2p@LIB_EXT@ |
94 | LIBEXT2FS = $(LIB)/libext2fs@LIB_EXT@ | |
39fd3d4f | 95 | LIBUUID = @LIBUUID@ @SOCKET_LIB@ |
8f9d708f | 96 | LIBQUOTA = @STATIC_LIBQUOTA@ |
14b596d4 | 97 | LIBBLKID = @LIBBLKID@ @PRIVATE_LIBS_CMT@ $(LIBUUID) |
a04eba3f | 98 | LIBINTL = @LIBINTL@ |
9d99416e | 99 | DEPLIBSS = $(LIB)/libss@LIB_EXT@ |
a6a1c081 | 100 | DEPLIBCOM_ERR = $(LIB)/libcom_err@LIB_EXT@ |
39fd3d4f | 101 | DEPLIBUUID = @DEPLIBUUID@ |
8f9d708f | 102 | DEPLIBQUOTA = @DEPSTATIC_LIBQUOTA@ |
4a1e15a8 | 103 | DEPLIBBLKID = @DEPLIBBLKID@ @PRIVATE_LIBS_CMT@ $(DEPLIBUUID) |
a4d09610 | 104 | |
daf7a6e5 | 105 | STATIC_LIBSS = $(LIB)/libss@STATIC_LIB_EXT@ @DLOPEN_LIB@ |
d7f45af8 | 106 | STATIC_LIBCOM_ERR = $(LIB)/libcom_err@STATIC_LIB_EXT@ @SEM_INIT_LIB@ |
a4d09610 TT |
107 | STATIC_LIBE2P = $(LIB)/libe2p@STATIC_LIB_EXT@ |
108 | STATIC_LIBEXT2FS = $(LIB)/libext2fs@STATIC_LIB_EXT@ | |
39fd3d4f | 109 | STATIC_LIBUUID = @STATIC_LIBUUID@ @SOCKET_LIB@ |
f239fefc | 110 | STATIC_LIBQUOTA = @STATIC_LIBQUOTA@ |
14b596d4 | 111 | STATIC_LIBBLKID = @STATIC_LIBBLKID@ $(STATIC_LIBUUID) |
9d99416e | 112 | DEPSTATIC_LIBSS = $(LIB)/libss@STATIC_LIB_EXT@ |
a6a1c081 | 113 | DEPSTATIC_LIBCOM_ERR = $(LIB)/libcom_err@STATIC_LIB_EXT@ |
39fd3d4f | 114 | DEPSTATIC_LIBUUID = @DEPSTATIC_LIBUUID@ |
f239fefc | 115 | DEPSTATIC_LIBQUOTA = @DEPSTATIC_LIBQUOTA@ |
5f70f2e6 | 116 | DEPSTATIC_LIBBLKID = @DEPSTATIC_LIBBLKID@ $(DEPSTATIC_LIBUUID) |
a4d09610 | 117 | |
daf7a6e5 | 118 | PROFILED_LIBSS = $(LIB)/libss@PROFILED_LIB_EXT@ @DLOPEN_LIB@ |
992a2f7f | 119 | PROFILED_LIBCOM_ERR = $(LIB)/libcom_err@PROFILED_LIB_EXT@ @SEM_INIT_LIB@ |
a4d09610 TT |
120 | PROFILED_LIBE2P = $(LIB)/libe2p@PROFILED_LIB_EXT@ |
121 | PROFILED_LIBEXT2FS = $(LIB)/libext2fs@PROFILED_LIB_EXT@ | |
39fd3d4f | 122 | PROFILED_LIBUUID = @PROFILED_LIBUUID@ @SOCKET_LIB@ |
f239fefc | 123 | PROFILED_LIBQUOTA = @PROFILED_LIBQUOTA@ |
14b596d4 | 124 | PROFILED_LIBBLKID = @PROFILED_LIBBLKID@ $(PROFILED_LIBUUID) |
a6a1c081 TT |
125 | DEPPROFILED_LIBSS = $(LIB)/libss@PROFILED_LIB_EXT@ |
126 | DEPPROFILED_LIBCOM_ERR = $(LIB)/libcom_err@PROFILED_LIB_EXT@ | |
39fd3d4f | 127 | DEPPROFILED_LIBUUID = @PROFILED_LIBUUID@ |
f239fefc | 128 | DEPPROFILED_LIBQUOTA = @PROFILED_LIBQUOTA@ |
5f70f2e6 | 129 | DEPPROFILED_LIBBLKID = @PROFILED_LIBBLKID@ $(DEPPROFILED_LIBUUID) |
a4d09610 | 130 | |
a4d09610 TT |
131 | # |
132 | # A fast substitution command for fixing up man pages, shell scripts, etc. | |
133 | # | |
44339bdf TT |
134 | SUBST_CONF=$(top_builddir)/util/subst.conf |
135 | SUBSTITUTE= $(top_builddir)/util/subst -f $(SUBST_CONF) | |
dd607056 | 136 | SUBSTITUTE_UPTIME= $(top_builddir)/util/subst -t -f $(SUBST_CONF) |
44339bdf | 137 | DEP_SUBSTITUTE= $(top_builddir)/util/subst $(SUBST_CONF) |
a4d09610 | 138 | |
ef8901be | 139 | $(top_builddir)/util/subst: |
e8aed8c8 | 140 | cd $(top_builddir)/util ; $(MAKE) subst |
ef8901be | 141 | |
183c73b0 TT |
142 | # |
143 | # Script for installing symlinks (for shared libraries) | |
144 | # | |
145 | $(top_builddir)/util/install-symlink: $(top_srcdir)/util/install-symlink.in \ | |
146 | $(top_builddir)/config.status | |
147 | cd $(top_builddir); CONFIG_FILES=util/install-symlink ./config.status | |
148 | chmod +x $(top_builddir)/util/install-symlink | |
149 | ||
150 | $(top_builddir)/util/symlinks: | |
151 | cd $(top_builddir)/util ; $(MAKE) symlinks | |
152 | ||
153 | INSTALL_SYMLINK = /bin/sh $(top_builddir)/util/install-symlink \ | |
154 | @SYMLINK_RELATIVE@ \ | |
155 | --symlinks=$(top_builddir)/util/symlinks | |
156 | DEP_INSTALL_SYMLINK = $(top_builddir)/util/install-symlink \ | |
157 | $(top_builddir)/util/symlinks | |
158 | ||
50e1e10f TT |
159 | # |
160 | # Warning flags | |
161 | # | |
4d0f3e17 | 162 | # Run make gcc-wall to do a build with warning messages. |
50e1e10f TT |
163 | # |
164 | # | |
19c000e8 TT |
165 | WFLAGS= -std=c99 -D_XOPEN_SOURCE=600 -D_GNU_SOURCE \ |
166 | -pedantic $(WFLAGS_EXTRA) \ | |
032a763f | 167 | -Wall -W -Wwrite-strings -Wpointer-arith \ |
19c000e8 | 168 | -Wcast-qual -Wcast-align -Wno-variadic-macros \ |
4d0f3e17 | 169 | -Wstrict-prototypes -Wmissing-prototypes \ |
48e6e813 | 170 | -Wformat-security -Wformat-nonliteral \ |
19c000e8 | 171 | -Wmissing-format-attribute -O2 -Wstrict-aliasing \ |
032a763f TT |
172 | -Wnested-externs -Winline -DNO_INLINE_FUNCS -Wshadow \ |
173 | -UENABLE_NLS | |
4d0f3e17 | 174 | |
c8c071a0 | 175 | gcc-wall-new: |
d1154eb4 | 176 | (make CFLAGS="@CFLAGS@ $(WFLAGS)" > /dev/null) 2>&1 | sed -f $(top_srcdir)/util/gcc-wall-cleanup |
c8c071a0 | 177 | |
4d0f3e17 TT |
178 | gcc-wall: |
179 | make clean > /dev/null | |
c8c071a0 | 180 | make gcc-wall-new |
50e1e10f TT |
181 | |
182 | # | |
183 | # Installation user and groups | |
184 | # | |
185 | BINGRP= bin | |
186 | BINOWN= bin | |
187 | BINMODE= 555 | |
188 | INCGRP= bin | |
189 | INCOWN= bin | |
190 | INCMODE= 444 | |
191 | LIBOWN= bin | |
192 | LIBGRP= bin | |
193 | LIBMODE= 444 | |
194 | MANGRP= bin | |
195 | MANOWN= bin | |
196 | MANMODE= 444 | |
197 | ||
fc6d9d51 TT |
198 | # |
199 | # Autoconf magic... | |
200 | # | |
201 | ||
5aa6c3f6 TT |
202 | DEP_LIB_MAKEFILES = $(top_srcdir)/lib/Makefile.library \ |
203 | $(top_srcdir)/lib/Makefile.elf-lib \ | |
2b5901d9 TT |
204 | $(top_srcdir)/lib/Makefile.bsd-lib $(top_srcdir)/lib/Makefile.darwin-lib \ |
205 | $(top_srcdir)/lib/Makefile.solaris-lib $(top_srcdir)/lib/Makefile.checker \ | |
206 | $(top_srcdir)/lib/Makefile.profile | |
a4b2d3ce | 207 | |
fc6d9d51 | 208 | $(top_builddir)/config.status: $(top_srcdir)/configure |
e8aed8c8 | 209 | cd $(top_builddir); ./config.status --recheck |
fc6d9d51 TT |
210 | |
211 | $(top_builddir)/MCONFIG: $(top_srcdir)/MCONFIG.in $(top_builddir)/config.status | |
e8aed8c8 | 212 | cd $(top_builddir); CONFIG_FILES=MCONFIG ./config.status |
fc6d9d51 | 213 | |
d1154eb4 TT |
214 | $(top_builddir)/lib/config.h: $(top_srcdir)/lib/config.h.in \ |
215 | $(top_builddir)/config.status | |
216 | cd $(top_builddir); CONFIG_FILES=lib/config.h ./config.status | |
217 | ||
218 | $(top_builddir)/lib/dirpaths.h: $(DEP_SUBSTITUTE) $(top_srcdir)/lib/dirpaths.h.in | |
219 | $(E) " SUBST $@" | |
220 | $(Q) $(SUBSTITUTE) $(top_srcdir)/lib/dirpaths.h.in $@ | |
221 | ||
fc6d9d51 TT |
222 | $(top_builddir)/lib/substitute_sh: $(top_srcdir)/lib/substitute_sh.in \ |
223 | $(top_builddir)/config.status | |
e8aed8c8 | 224 | cd $(top_builddir); CONFIG_FILES=lib/substitute_sh ./config.status |
fc6d9d51 | 225 | |
bf2602be TT |
226 | $(top_builddir)/util/subst.conf: $(top_srcdir)/util/subst.conf.in \ |
227 | $(top_builddir)/config.status | |
e8aed8c8 | 228 | cd $(top_builddir); CONFIG_FILES=util/subst.conf ./config.status |
bf2602be | 229 | |
fc6d9d51 | 230 | Makefile: $(srcdir)/Makefile.in $(top_builddir)/MCONFIG \ |
a4b2d3ce | 231 | $(DEP_MAKEFILE) $(top_builddir)/config.status |
e8aed8c8 | 232 | cd $(top_builddir); CONFIG_FILES=$(my_dir)/Makefile ./config.status |
fc6d9d51 | 233 | |
98919bdb | 234 | @MAINTAINER_CMT@$(top_srcdir)/configure: $(top_srcdir)/configure.in |
d1154eb4 | 235 | @MAINTAINER_CMT@ cd $(top_srcdir) && autoheader && autoconf |
fc6d9d51 | 236 | |
50e1e10f TT |
237 | # |
238 | # Make depend magic... | |
239 | # | |
240 | ||
9d564f73 | 241 | .depend: Makefile $(SRCS) $(top_srcdir)/depfix.sed $(top_srcdir)/wordwrap.pl |
50e1e10f | 242 | if test -n "$(SRCS)" ; then \ |
74becf3c | 243 | $(CC) -M $(ALL_CFLAGS) $(SRCS) | \ |
9d564f73 | 244 | $(SED) -f $(top_srcdir)/depfix.sed \ |
fc6d9d51 TT |
245 | -e 's; $(srcdir)/; $$(srcdir)/;g' \ |
246 | -e 's; $(top_srcdir)/; $$(top_srcdir)/;g' \ | |
247 | -e 's; $(top_builddir)/; $$(top_builddir)/;g' \ | |
248 | -e 's; \./; ;g' \ | |
6d402278 | 249 | -e '/^#/d' \ |
9d564f73 TT |
250 | -e '/^ *\\$$/d' | \ |
251 | $(PERL) $(top_srcdir)/wordwrap.pl > .depend; \ | |
50e1e10f TT |
252 | else :; fi |
253 | ||
254 | depend:: .depend | |
255 | if test -n "$(SRCS)" ; then \ | |
256 | sed -e '/^# +++ Dependency line eater +++/,$$d' \ | |
257 | < $(srcdir)/Makefile.in | cat - .depend \ | |
258 | > $(srcdir)/Makefile.in.new; \ | |
9d564f73 TT |
259 | if cmp -s $(srcdir)/Makefile.in $(srcdir)/Makefile.in.new ; then \ |
260 | $(RM) $(srcdir)/Makefile.in.new ; \ | |
261 | else \ | |
262 | $(MV) $(srcdir)/Makefile.in $(srcdir)/Makefile.in.old; \ | |
263 | $(MV) $(srcdir)/Makefile.in.new $(srcdir)/Makefile.in; \ | |
264 | fi ; else :; fi | |
50e1e10f | 265 | |
50e1e10f | 266 | # End of file MCONFIG |