blob: 0c74522041d86e41a7e901d31c888e3f7563f5a2 [file] [log] [blame]
Theodore Ts'o50e1e101997-04-26 13:58:21 +00001# Beginning of file MCONFIG
2
Theodore Ts'oef8901b1999-07-03 04:55:36 +00003all::
4
Theodore Ts'o3e377db2000-12-09 02:37:33 +00005check::
6
Theodore Ts'o50e1e101997-04-26 13:58:21 +00007SHELL = /bin/sh
8
Theodore Ts'o482afc42002-10-31 03:32:34 -05009COMPRESS_EXT = gz bz2 bz Z
10
Theodore Ts'o50e1e101997-04-26 13:58:21 +000011prefix = @prefix@
Theodore Ts'oa4b2d3c1998-04-03 16:12:25 +000012root_prefix = @root_prefix@
Theodore Ts'o50e1e101997-04-26 13:58:21 +000013exec_prefix = @exec_prefix@
Theodore Ts'ob5ffead2002-05-11 19:17:00 -040014root_bindir = @root_bindir@
15root_sbindir = @root_sbindir@
16root_libdir = @root_libdir@
Theodore Ts'ob6b65c32006-10-22 00:14:26 -040017datarootdir = @datarootdir@
Theodore Ts'oa4b2d3c1998-04-03 16:12:25 +000018bindir = @bindir@
19sbindir = @sbindir@
20libdir = @libdir@
Theodore Ts'ob5ffead2002-05-11 19:17:00 -040021datadir= @datadir@
Theodore Ts'oa04eba32003-05-03 16:35:17 -040022localedir = $(datadir)/locale
Theodore Ts'ob5ffead2002-05-11 19:17:00 -040023root_sysconfdir= @root_sysconfdir@
Theodore Ts'oa4b2d3c1998-04-03 16:12:25 +000024includedir = @includedir@
25mandir = @mandir@
Theodore Ts'oa4bf69d1999-05-29 21:53:30 +000026man1dir = $(mandir)/man1
27man3dir = $(mandir)/man3
Theodore Ts'o9dc6ad12006-03-23 22:00:01 -050028man5dir = $(mandir)/man5
Theodore Ts'oa4bf69d1999-05-29 21:53:30 +000029man8dir = $(mandir)/man8
Theodore Ts'oa4b2d3c1998-04-03 16:12:25 +000030infodir = @infodir@
31datadir = @datadir@
Theodore Ts'o50e1e101997-04-26 13:58:21 +000032
33@SET_MAKE@
34
Theodore Ts'obcb915b2009-07-02 18:19:10 -040035@ifGNUmake@ V =
36@ifGNUmake@ ifeq ($(strip $(V)),)
37@ifGNUmake@ # E = @echo
38@ifGNUmake@ # Q = @
39@ifGNUmake@ E = @E@
40@ifGNUmake@ Q = @Q@
41@ifGNUmake@ else
42@ifGNUmake@ E = @\#
43@ifGNUmake@ Q =
44@ifGNUmake@ endif
Theodore Ts'oc13351f2009-07-02 00:11:17 -040045
Theodore Ts'obcb915b2009-07-02 18:19:10 -040046@ifNotGNUmake@ E = @E@
47@ifNotGNUmake@ Q = @Q@
Theodore Ts'oc13351f2009-07-02 00:11:17 -040048
Theodore Ts'o50e1e101997-04-26 13:58:21 +000049CC = @CC@
Theodore Ts'o6c133521999-07-03 20:37:03 +000050BUILD_CC = @BUILD_CC@
Theodore Ts'o74becf31997-04-26 14:37:06 +000051CFLAGS = @CFLAGS@
Theodore Ts'od1154eb2011-09-18 17:34:37 -040052CPPFLAGS = @INCLUDES@
53ALL_CFLAGS = $(CPPFLAGS) $(CFLAGS)
Theodore Ts'o50e1e101997-04-26 13:58:21 +000054LDFLAGS = @LDFLAGS@
Theodore Ts'o55da9872008-09-02 23:12:38 -040055ALL_LDFLAGS = $(LDFLAGS) @LDFLAG_DYNAMIC@
56LDFLAGS_STATIC = $(LDFLAGS) @LDFLAG_STATIC@
Theodore Ts'odd947da2005-11-09 18:37:07 -040057BUILD_CFLAGS = @BUILD_CFLAGS@
58BUILD_LDFLAGS = @BUILD_LDFLAGS@
Theodore Ts'o9b3018a2011-08-11 14:56:49 -040059RDYNAMIC = @RDYNAMIC@
Theodore Ts'o5aa6c3f2010-05-17 19:21:42 -040060LINK_BUILD_FLAGS = @LINK_BUILD_FLAGS@
61LINK_INSTALL_FLAGS = @LINK_INSTALL_FLAGS@
Theodore Ts'o50e1e101997-04-26 13:58:21 +000062RM = @RM@
63LN = @LN@
Theodore Ts'ofc6d9d51997-04-29 14:51:31 +000064LN_S = @LN_S@
Theodore Ts'o50e1e101997-04-26 13:58:21 +000065MV = @MV@
66CP = @CP@
67CHMOD = @CHMOD@
68AR = @AR@
69AWK = @AWK@
70SED = @SED@
Theodore Ts'o9d564f71999-07-03 20:25:58 +000071PERL = @PERL@
Theodore Ts'o50e1e101997-04-26 13:58:21 +000072RANLIB = @RANLIB@
73STRIP = @STRIP@
74LD = $(PURE) @CC@
75ARUPD = $(AR) r
Theodore Ts'o47204ff2004-11-30 10:52:27 -050076ARGEN = $(AR) rc
Theodore Ts'o250f79f2001-05-19 22:02:22 +000077LDCONFIG = @LDCONFIG@
Theodore Ts'o6d402272004-12-14 21:46:26 -050078INSTALL_PROGRAM = @INSTALL_PROGRAM@
79INSTALL_DATA = @INSTALL_DATA@
80INSTALL_SCRIPT = @INSTALL_SCRIPT@
81MKINSTALLDIRS = @MKINSTALLDIRS@
Theodore Ts'o50e1e101997-04-26 13:58:21 +000082
83#
Theodore Ts'oa4d09611997-04-29 14:28:00 +000084# Library definitions
85#
86LIB = $(top_builddir)/lib
Theodore Ts'o55da9872008-09-02 23:12:38 -040087LIBSS = $(LIB)/libss@LIB_EXT@ @PRIVATE_LIBS_CMT@ @DLOPEN_LIB@
Theodore Ts'od7f45af2008-09-12 10:15:26 -040088LIBCOM_ERR = $(LIB)/libcom_err@LIB_EXT@ @PRIVATE_LIBS_CMT@ @SEM_INIT_LIB@
Theodore Ts'oa4d09611997-04-29 14:28:00 +000089LIBE2P = $(LIB)/libe2p@LIB_EXT@
90LIBEXT2FS = $(LIB)/libext2fs@LIB_EXT@
Scott James Remnant39fd3d42009-05-14 13:03:25 +010091LIBUUID = @LIBUUID@ @SOCKET_LIB@
Theodore Ts'o8f9d7082011-09-19 13:39:38 -040092LIBQUOTA = @STATIC_LIBQUOTA@
Theodore Ts'o14b596d2009-04-22 09:18:30 -040093LIBBLKID = @LIBBLKID@ @PRIVATE_LIBS_CMT@ $(LIBUUID)
Theodore Ts'oa04eba32003-05-03 16:35:17 -040094LIBINTL = @LIBINTL@
Theodore Ts'o9d994162008-06-07 21:53:35 -040095DEPLIBSS = $(LIB)/libss@LIB_EXT@
Theodore Ts'oa6a1c082009-07-01 22:06:51 -040096DEPLIBCOM_ERR = $(LIB)/libcom_err@LIB_EXT@
Scott James Remnant39fd3d42009-05-14 13:03:25 +010097DEPLIBUUID = @DEPLIBUUID@
Theodore Ts'o8f9d7082011-09-19 13:39:38 -040098DEPLIBQUOTA = @DEPSTATIC_LIBQUOTA@
Theodore Ts'o4a1e15a2009-07-01 17:20:24 -040099DEPLIBBLKID = @DEPLIBBLKID@ @PRIVATE_LIBS_CMT@ $(DEPLIBUUID)
Theodore Ts'oa4d09611997-04-29 14:28:00 +0000100
Theodore Ts'odaf7a6e2008-04-17 16:54:24 -0400101STATIC_LIBSS = $(LIB)/libss@STATIC_LIB_EXT@ @DLOPEN_LIB@
Theodore Ts'od7f45af2008-09-12 10:15:26 -0400102STATIC_LIBCOM_ERR = $(LIB)/libcom_err@STATIC_LIB_EXT@ @SEM_INIT_LIB@
Theodore Ts'oa4d09611997-04-29 14:28:00 +0000103STATIC_LIBE2P = $(LIB)/libe2p@STATIC_LIB_EXT@
104STATIC_LIBEXT2FS = $(LIB)/libext2fs@STATIC_LIB_EXT@
Scott James Remnant39fd3d42009-05-14 13:03:25 +0100105STATIC_LIBUUID = @STATIC_LIBUUID@ @SOCKET_LIB@
Aditya Kalif239fef2011-07-20 11:40:02 -0700106STATIC_LIBQUOTA = @STATIC_LIBQUOTA@
Theodore Ts'o14b596d2009-04-22 09:18:30 -0400107STATIC_LIBBLKID = @STATIC_LIBBLKID@ $(STATIC_LIBUUID)
Theodore Ts'o9d994162008-06-07 21:53:35 -0400108DEPSTATIC_LIBSS = $(LIB)/libss@STATIC_LIB_EXT@
Theodore Ts'oa6a1c082009-07-01 22:06:51 -0400109DEPSTATIC_LIBCOM_ERR = $(LIB)/libcom_err@STATIC_LIB_EXT@
Scott James Remnant39fd3d42009-05-14 13:03:25 +0100110DEPSTATIC_LIBUUID = @DEPSTATIC_LIBUUID@
Aditya Kalif239fef2011-07-20 11:40:02 -0700111DEPSTATIC_LIBQUOTA = @DEPSTATIC_LIBQUOTA@
Theodore Ts'o5f70f2e2010-11-26 19:25:26 -0500112DEPSTATIC_LIBBLKID = @DEPSTATIC_LIBBLKID@ $(DEPSTATIC_LIBUUID)
Theodore Ts'oa4d09611997-04-29 14:28:00 +0000113
Theodore Ts'odaf7a6e2008-04-17 16:54:24 -0400114PROFILED_LIBSS = $(LIB)/libss@PROFILED_LIB_EXT@ @DLOPEN_LIB@
Theodore Ts'o992a2f72008-11-15 12:12:57 -0500115PROFILED_LIBCOM_ERR = $(LIB)/libcom_err@PROFILED_LIB_EXT@ @SEM_INIT_LIB@
Theodore Ts'oa4d09611997-04-29 14:28:00 +0000116PROFILED_LIBE2P = $(LIB)/libe2p@PROFILED_LIB_EXT@
117PROFILED_LIBEXT2FS = $(LIB)/libext2fs@PROFILED_LIB_EXT@
Scott James Remnant39fd3d42009-05-14 13:03:25 +0100118PROFILED_LIBUUID = @PROFILED_LIBUUID@ @SOCKET_LIB@
Aditya Kalif239fef2011-07-20 11:40:02 -0700119PROFILED_LIBQUOTA = @PROFILED_LIBQUOTA@
Theodore Ts'o14b596d2009-04-22 09:18:30 -0400120PROFILED_LIBBLKID = @PROFILED_LIBBLKID@ $(PROFILED_LIBUUID)
Theodore Ts'oa6a1c082009-07-01 22:06:51 -0400121DEPPROFILED_LIBSS = $(LIB)/libss@PROFILED_LIB_EXT@
122DEPPROFILED_LIBCOM_ERR = $(LIB)/libcom_err@PROFILED_LIB_EXT@
Scott James Remnant39fd3d42009-05-14 13:03:25 +0100123DEPPROFILED_LIBUUID = @PROFILED_LIBUUID@
Aditya Kalif239fef2011-07-20 11:40:02 -0700124DEPPROFILED_LIBQUOTA = @PROFILED_LIBQUOTA@
Theodore Ts'o5f70f2e2010-11-26 19:25:26 -0500125DEPPROFILED_LIBBLKID = @PROFILED_LIBBLKID@ $(DEPPROFILED_LIBUUID)
Theodore Ts'oa4d09611997-04-29 14:28:00 +0000126
Theodore Ts'o50e1e101997-04-26 13:58:21 +0000127#
Theodore Ts'oa4d09611997-04-29 14:28:00 +0000128# A fast substitution command for fixing up man pages, shell scripts, etc.
129#
Theodore Ts'o44339bd1997-10-15 02:47:20 +0000130SUBST_CONF=$(top_builddir)/util/subst.conf
131SUBSTITUTE= $(top_builddir)/util/subst -f $(SUBST_CONF)
Theodore Ts'odd607052004-04-03 13:53:46 -0500132SUBSTITUTE_UPTIME= $(top_builddir)/util/subst -t -f $(SUBST_CONF)
Theodore Ts'o44339bd1997-10-15 02:47:20 +0000133DEP_SUBSTITUTE= $(top_builddir)/util/subst $(SUBST_CONF)
Theodore Ts'oa4d09611997-04-29 14:28:00 +0000134
Theodore Ts'oef8901b1999-07-03 04:55:36 +0000135$(top_builddir)/util/subst:
Theodore Ts'oe8aed8c2000-04-03 03:18:59 +0000136 cd $(top_builddir)/util ; $(MAKE) subst
Theodore Ts'oef8901b1999-07-03 04:55:36 +0000137
Theodore Ts'oa4d09611997-04-29 14:28:00 +0000138#
Theodore Ts'o183c73b2012-05-12 23:13:24 -0400139# Script for installing symlinks (for shared libraries)
140#
141$(top_builddir)/util/install-symlink: $(top_srcdir)/util/install-symlink.in \
142 $(top_builddir)/config.status
143 cd $(top_builddir); CONFIG_FILES=util/install-symlink ./config.status
144 chmod +x $(top_builddir)/util/install-symlink
145
146$(top_builddir)/util/symlinks:
147 cd $(top_builddir)/util ; $(MAKE) symlinks
148
149INSTALL_SYMLINK = /bin/sh $(top_builddir)/util/install-symlink \
150 @SYMLINK_RELATIVE@ \
151 --symlinks=$(top_builddir)/util/symlinks
152DEP_INSTALL_SYMLINK = $(top_builddir)/util/install-symlink \
153 $(top_builddir)/util/symlinks
154
155#
Theodore Ts'o50e1e101997-04-26 13:58:21 +0000156# Warning flags
157#
Theodore Ts'o4d0f3e12001-01-11 15:48:50 +0000158# Run make gcc-wall to do a build with warning messages.
Theodore Ts'o50e1e101997-04-26 13:58:21 +0000159#
160#
Theodore Ts'o19c000e2006-11-14 23:40:19 -0500161WFLAGS= -std=c99 -D_XOPEN_SOURCE=600 -D_GNU_SOURCE \
162 -pedantic $(WFLAGS_EXTRA) \
Theodore Ts'o032a7632003-11-26 23:18:56 -0500163 -Wall -W -Wwrite-strings -Wpointer-arith \
Theodore Ts'o19c000e2006-11-14 23:40:19 -0500164 -Wcast-qual -Wcast-align -Wno-variadic-macros \
Theodore Ts'o4d0f3e12001-01-11 15:48:50 +0000165 -Wstrict-prototypes -Wmissing-prototypes \
Theodore Ts'o48e6e812003-07-06 00:36:48 -0400166 -Wformat-security -Wformat-nonliteral \
Theodore Ts'o19c000e2006-11-14 23:40:19 -0500167 -Wmissing-format-attribute -O2 -Wstrict-aliasing \
Theodore Ts'o032a7632003-11-26 23:18:56 -0500168 -Wnested-externs -Winline -DNO_INLINE_FUNCS -Wshadow \
169 -UENABLE_NLS
Theodore Ts'o4d0f3e12001-01-11 15:48:50 +0000170
Theodore Ts'oc8c071a2001-01-11 16:08:23 +0000171gcc-wall-new:
Theodore Ts'od1154eb2011-09-18 17:34:37 -0400172 (make CFLAGS="@CFLAGS@ $(WFLAGS)" > /dev/null) 2>&1 | sed -f $(top_srcdir)/util/gcc-wall-cleanup
Theodore Ts'oc8c071a2001-01-11 16:08:23 +0000173
Theodore Ts'o4d0f3e12001-01-11 15:48:50 +0000174gcc-wall:
175 make clean > /dev/null
Theodore Ts'oc8c071a2001-01-11 16:08:23 +0000176 make gcc-wall-new
Theodore Ts'o50e1e101997-04-26 13:58:21 +0000177
178#
179# Installation user and groups
180#
181BINGRP= bin
182BINOWN= bin
183BINMODE= 555
184INCGRP= bin
185INCOWN= bin
186INCMODE= 444
187LIBOWN= bin
188LIBGRP= bin
189LIBMODE= 444
190MANGRP= bin
191MANOWN= bin
192MANMODE= 444
193
Theodore Ts'o50e1e101997-04-26 13:58:21 +0000194#
Theodore Ts'ofc6d9d51997-04-29 14:51:31 +0000195# Autoconf magic...
196#
197
Theodore Ts'o5aa6c3f2010-05-17 19:21:42 -0400198DEP_LIB_MAKEFILES = $(top_srcdir)/lib/Makefile.library \
199 $(top_srcdir)/lib/Makefile.elf-lib \
Theodore Ts'o2b5901d2004-11-19 17:06:47 -0500200 $(top_srcdir)/lib/Makefile.bsd-lib $(top_srcdir)/lib/Makefile.darwin-lib \
201 $(top_srcdir)/lib/Makefile.solaris-lib $(top_srcdir)/lib/Makefile.checker \
202 $(top_srcdir)/lib/Makefile.profile
Theodore Ts'oa4b2d3c1998-04-03 16:12:25 +0000203
Theodore Ts'ofc6d9d51997-04-29 14:51:31 +0000204$(top_builddir)/config.status: $(top_srcdir)/configure
Theodore Ts'oe8aed8c2000-04-03 03:18:59 +0000205 cd $(top_builddir); ./config.status --recheck
Theodore Ts'ofc6d9d51997-04-29 14:51:31 +0000206
207$(top_builddir)/MCONFIG: $(top_srcdir)/MCONFIG.in $(top_builddir)/config.status
Theodore Ts'oe8aed8c2000-04-03 03:18:59 +0000208 cd $(top_builddir); CONFIG_FILES=MCONFIG ./config.status
Theodore Ts'ofc6d9d51997-04-29 14:51:31 +0000209
Theodore Ts'od1154eb2011-09-18 17:34:37 -0400210$(top_builddir)/lib/config.h: $(top_srcdir)/lib/config.h.in \
211 $(top_builddir)/config.status
212 cd $(top_builddir); CONFIG_FILES=lib/config.h ./config.status
213
214$(top_builddir)/lib/dirpaths.h: $(DEP_SUBSTITUTE) $(top_srcdir)/lib/dirpaths.h.in
215 $(E) " SUBST $@"
216 $(Q) $(SUBSTITUTE) $(top_srcdir)/lib/dirpaths.h.in $@
217
Theodore Ts'ofc6d9d51997-04-29 14:51:31 +0000218$(top_builddir)/lib/substitute_sh: $(top_srcdir)/lib/substitute_sh.in \
219 $(top_builddir)/config.status
Theodore Ts'oe8aed8c2000-04-03 03:18:59 +0000220 cd $(top_builddir); CONFIG_FILES=lib/substitute_sh ./config.status
Theodore Ts'ofc6d9d51997-04-29 14:51:31 +0000221
Theodore Ts'obf2602b1998-03-30 01:11:44 +0000222$(top_builddir)/util/subst.conf: $(top_srcdir)/util/subst.conf.in \
223 $(top_builddir)/config.status
Theodore Ts'oe8aed8c2000-04-03 03:18:59 +0000224 cd $(top_builddir); CONFIG_FILES=util/subst.conf ./config.status
Theodore Ts'obf2602b1998-03-30 01:11:44 +0000225
Theodore Ts'ofc6d9d51997-04-29 14:51:31 +0000226Makefile: $(srcdir)/Makefile.in $(top_builddir)/MCONFIG \
Theodore Ts'oa4b2d3c1998-04-03 16:12:25 +0000227 $(DEP_MAKEFILE) $(top_builddir)/config.status
Theodore Ts'oe8aed8c2000-04-03 03:18:59 +0000228 cd $(top_builddir); CONFIG_FILES=$(my_dir)/Makefile ./config.status
Theodore Ts'ofc6d9d51997-04-29 14:51:31 +0000229
Theodore Ts'o98919bd2005-02-04 10:43:58 -0500230@MAINTAINER_CMT@$(top_srcdir)/configure: $(top_srcdir)/configure.in
Theodore Ts'od1154eb2011-09-18 17:34:37 -0400231@MAINTAINER_CMT@ cd $(top_srcdir) && autoheader && autoconf
Theodore Ts'ofc6d9d51997-04-29 14:51:31 +0000232
233#
Theodore Ts'o50e1e101997-04-26 13:58:21 +0000234# Make depend magic...
235#
236
Theodore Ts'o9d564f71999-07-03 20:25:58 +0000237.depend: Makefile $(SRCS) $(top_srcdir)/depfix.sed $(top_srcdir)/wordwrap.pl
Theodore Ts'o50e1e101997-04-26 13:58:21 +0000238 if test -n "$(SRCS)" ; then \
Theodore Ts'o74becf31997-04-26 14:37:06 +0000239 $(CC) -M $(ALL_CFLAGS) $(SRCS) | \
Theodore Ts'o9d564f71999-07-03 20:25:58 +0000240 $(SED) -f $(top_srcdir)/depfix.sed \
Theodore Ts'ofc6d9d51997-04-29 14:51:31 +0000241 -e 's; $(srcdir)/; $$(srcdir)/;g' \
242 -e 's; $(top_srcdir)/; $$(top_srcdir)/;g' \
243 -e 's; $(top_builddir)/; $$(top_builddir)/;g' \
244 -e 's; \./; ;g' \
Theodore Ts'o6d402272004-12-14 21:46:26 -0500245 -e '/^#/d' \
Theodore Ts'o9d564f71999-07-03 20:25:58 +0000246 -e '/^ *\\$$/d' | \
247 $(PERL) $(top_srcdir)/wordwrap.pl > .depend; \
Theodore Ts'o50e1e101997-04-26 13:58:21 +0000248 else :; fi
249
250depend:: .depend
251 if test -n "$(SRCS)" ; then \
252 sed -e '/^# +++ Dependency line eater +++/,$$d' \
253 < $(srcdir)/Makefile.in | cat - .depend \
254 > $(srcdir)/Makefile.in.new; \
Theodore Ts'o9d564f71999-07-03 20:25:58 +0000255 if cmp -s $(srcdir)/Makefile.in $(srcdir)/Makefile.in.new ; then \
256 $(RM) $(srcdir)/Makefile.in.new ; \
257 else \
258 $(MV) $(srcdir)/Makefile.in $(srcdir)/Makefile.in.old; \
259 $(MV) $(srcdir)/Makefile.in.new $(srcdir)/Makefile.in; \
260 fi ; else :; fi
Theodore Ts'o50e1e101997-04-26 13:58:21 +0000261
Theodore Ts'o50e1e101997-04-26 13:58:21 +0000262# End of file MCONFIG