Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 1 | # Beginning of file MCONFIG |
| 2 | |
Theodore Ts'o | ef8901b | 1999-07-03 04:55:36 +0000 | [diff] [blame] | 3 | all:: |
| 4 | |
Theodore Ts'o | 3e377db | 2000-12-09 02:37:33 +0000 | [diff] [blame] | 5 | check:: |
| 6 | |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 7 | SHELL = /bin/sh |
| 8 | |
| 9 | prefix = @prefix@ |
Theodore Ts'o | a4b2d3c | 1998-04-03 16:12:25 +0000 | [diff] [blame] | 10 | root_prefix = @root_prefix@ |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 11 | exec_prefix = @exec_prefix@ |
Theodore Ts'o | a4b2d3c | 1998-04-03 16:12:25 +0000 | [diff] [blame] | 12 | root_bindir = $(root_prefix)/bin |
| 13 | root_sbindir = $(root_prefix)/sbin |
| 14 | root_libdir = $(root_prefix)/lib |
| 15 | bindir = @bindir@ |
| 16 | sbindir = @sbindir@ |
| 17 | libdir = @libdir@ |
| 18 | includedir = @includedir@ |
| 19 | mandir = @mandir@ |
Theodore Ts'o | a4bf69d | 1999-05-29 21:53:30 +0000 | [diff] [blame] | 20 | man1dir = $(mandir)/man1 |
| 21 | man3dir = $(mandir)/man3 |
| 22 | man8dir = $(mandir)/man8 |
Theodore Ts'o | a4b2d3c | 1998-04-03 16:12:25 +0000 | [diff] [blame] | 23 | infodir = @infodir@ |
| 24 | datadir = @datadir@ |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 25 | |
| 26 | @SET_MAKE@ |
| 27 | |
| 28 | INSTALL_PROGRAM = @INSTALL_PROGRAM@ |
| 29 | INSTALL_DATA = @INSTALL_DATA@ |
| 30 | CC = @CC@ |
Theodore Ts'o | 6c13352 | 1999-07-03 20:37:03 +0000 | [diff] [blame] | 31 | BUILD_CC = @BUILD_CC@ |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 32 | DEFS = @DEFS@ |
Theodore Ts'o | 74becf3 | 1997-04-26 14:37:06 +0000 | [diff] [blame] | 33 | CFLAGS = @CFLAGS@ |
Theodore Ts'o | e8aed8c | 2000-04-03 03:18:59 +0000 | [diff] [blame] | 34 | CPPFLAGS = @CPPFLAGS@ |
Theodore Ts'o | 4d0f3e1 | 2001-01-11 15:48:50 +0000 | [diff] [blame] | 35 | ALL_CFLAGS = $(CPPFLAGS) $(DEFS) $(USE_WFLAGS) $(CFLAGS) $(XTRA_CFLAGS) \ |
Theodore Ts'o | 73ae2d4 | 2000-02-02 16:13:14 +0000 | [diff] [blame] | 36 | -I$(top_builddir)/lib -I$(top_srcdir)/lib \ |
| 37 | -I$(top_srcdir)/include $(LINUX_INCLUDE) |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 38 | LDFLAGS = @LDFLAGS@ |
Theodore Ts'o | 74becf3 | 1997-04-26 14:37:06 +0000 | [diff] [blame] | 39 | ALL_LDFLAGS = $(LDFLAGS) |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 40 | RM = @RM@ |
| 41 | LN = @LN@ |
Theodore Ts'o | fc6d9d5 | 1997-04-29 14:51:31 +0000 | [diff] [blame] | 42 | LN_S = @LN_S@ |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 43 | MV = @MV@ |
| 44 | CP = @CP@ |
| 45 | CHMOD = @CHMOD@ |
| 46 | AR = @AR@ |
| 47 | AWK = @AWK@ |
| 48 | SED = @SED@ |
Theodore Ts'o | 9d564f7 | 1999-07-03 20:25:58 +0000 | [diff] [blame] | 49 | PERL = @PERL@ |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 50 | RANLIB = @RANLIB@ |
| 51 | STRIP = @STRIP@ |
| 52 | LD = $(PURE) @CC@ |
| 53 | ARUPD = $(AR) r |
| 54 | |
| 55 | # |
Theodore Ts'o | a4d0961 | 1997-04-29 14:28:00 +0000 | [diff] [blame] | 56 | # Library definitions |
| 57 | # |
| 58 | LIB = $(top_builddir)/lib |
| 59 | LIBSS = $(LIB)/libss@LIB_EXT@ |
| 60 | LIBCOM_ERR = $(LIB)/libcom_err@LIB_EXT@ |
| 61 | LIBE2P = $(LIB)/libe2p@LIB_EXT@ |
| 62 | LIBEXT2FS = $(LIB)/libext2fs@LIB_EXT@ |
Theodore Ts'o | fc6d9d5 | 1997-04-29 14:51:31 +0000 | [diff] [blame] | 63 | LIBUUID = $(LIB)/libuuid@LIB_EXT@ @SOCKET_LIB@ |
Theodore Ts'o | 77200f4 | 2000-01-18 17:53:27 +0000 | [diff] [blame] | 64 | DEPLIBUUID = $(LIB)/libuuid@LIB_EXT@ |
Theodore Ts'o | a4d0961 | 1997-04-29 14:28:00 +0000 | [diff] [blame] | 65 | |
| 66 | STATIC_LIBSS = $(LIB)/libss@STATIC_LIB_EXT@ |
| 67 | STATIC_LIBCOM_ERR = $(LIB)/libcom_err@STATIC_LIB_EXT@ |
| 68 | STATIC_LIBE2P = $(LIB)/libe2p@STATIC_LIB_EXT@ |
| 69 | STATIC_LIBEXT2FS = $(LIB)/libext2fs@STATIC_LIB_EXT@ |
Theodore Ts'o | fc6d9d5 | 1997-04-29 14:51:31 +0000 | [diff] [blame] | 70 | STATIC_LIBUUID = $(LIB)/libuuid@STATIC_LIB_EXT@ @SOCKET_LIB@ |
Theodore Ts'o | 77200f4 | 2000-01-18 17:53:27 +0000 | [diff] [blame] | 71 | DEPSTATIC_LIBUUID = $(LIB)/libuuid@STATIC_LIB_EXT@ |
Theodore Ts'o | a4d0961 | 1997-04-29 14:28:00 +0000 | [diff] [blame] | 72 | |
| 73 | PROFILED_LIBSS = $(LIB)/libss@PROFILED_LIB_EXT@ |
| 74 | PROFILED_LIBCOM_ERR = $(LIB)/libcom_err@PROFILED_LIB_EXT@ |
| 75 | PROFILED_LIBE2P = $(LIB)/libe2p@PROFILED_LIB_EXT@ |
| 76 | PROFILED_LIBEXT2FS = $(LIB)/libext2fs@PROFILED_LIB_EXT@ |
Theodore Ts'o | fc6d9d5 | 1997-04-29 14:51:31 +0000 | [diff] [blame] | 77 | PROFILED_LIBUUID = $(LIB)/libuuid@PROFILED_LIB_EXT@ @SOCKET_LIB@ |
Theodore Ts'o | 77200f4 | 2000-01-18 17:53:27 +0000 | [diff] [blame] | 78 | DEPPROFILED_LIBUUID = $(LIB)/libuuid@PROFILED_LIB_EXT@ |
Theodore Ts'o | a4d0961 | 1997-04-29 14:28:00 +0000 | [diff] [blame] | 79 | |
| 80 | # |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 81 | # Use these definitions is you use tools 2.x, x < 16 |
| 82 | # |
| 83 | #DLL_BIN=/usr/dll/bin |
| 84 | #JUMP_PREFIX=/usr/dll/jump/ |
| 85 | |
| 86 | # |
| 87 | # Use these definitions if you use tools 2.16 or above |
| 88 | # |
| 89 | DLL_BIN=/usr/bin |
| 90 | JUMP_PREFIX=/usr/bin/jump |
| 91 | |
| 92 | # An include directive pointing to a directory holding enough linux-like |
| 93 | # include files to satisfy some programs here |
| 94 | LINUX_INCLUDE=@LINUX_INCLUDE@ |
| 95 | |
| 96 | # |
Theodore Ts'o | a4d0961 | 1997-04-29 14:28:00 +0000 | [diff] [blame] | 97 | # A fast substitution command for fixing up man pages, shell scripts, etc. |
| 98 | # |
Theodore Ts'o | 44339bd | 1997-10-15 02:47:20 +0000 | [diff] [blame] | 99 | SUBST_CONF=$(top_builddir)/util/subst.conf |
| 100 | SUBSTITUTE= $(top_builddir)/util/subst -f $(SUBST_CONF) |
| 101 | DEP_SUBSTITUTE= $(top_builddir)/util/subst $(SUBST_CONF) |
Theodore Ts'o | a4d0961 | 1997-04-29 14:28:00 +0000 | [diff] [blame] | 102 | |
Theodore Ts'o | ef8901b | 1999-07-03 04:55:36 +0000 | [diff] [blame] | 103 | $(top_builddir)/util/subst: |
Theodore Ts'o | e8aed8c | 2000-04-03 03:18:59 +0000 | [diff] [blame] | 104 | cd $(top_builddir)/util ; $(MAKE) subst |
Theodore Ts'o | ef8901b | 1999-07-03 04:55:36 +0000 | [diff] [blame] | 105 | |
Theodore Ts'o | a4d0961 | 1997-04-29 14:28:00 +0000 | [diff] [blame] | 106 | # |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 107 | # Warning flags |
| 108 | # |
Theodore Ts'o | 4d0f3e1 | 2001-01-11 15:48:50 +0000 | [diff] [blame] | 109 | # Run make gcc-wall to do a build with warning messages. |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 110 | # |
| 111 | # |
Theodore Ts'o | 4d0f3e1 | 2001-01-11 15:48:50 +0000 | [diff] [blame] | 112 | WFLAGS= -ansi -D_POSIX_SOURCE -pedantic \ |
| 113 | -Wall -Wwrite-strings -Wpointer-arith \ |
| 114 | -Wcast-qual -Wcast-align -Wtraditional \ |
| 115 | -Wstrict-prototypes -Wmissing-prototypes \ |
| 116 | -Wnested-externs -Winline -DNO_INLINE_FUNCS -Wshadow |
| 117 | |
Theodore Ts'o | c8c071a | 2001-01-11 16:08:23 +0000 | [diff] [blame] | 118 | gcc-wall-new: |
| 119 | (make USE_WFLAGS="$(WFLAGS)" > /dev/null) 2>&1 | sed -f $(top_srcdir)/util/gcc-wall-cleanup |
| 120 | |
Theodore Ts'o | 4d0f3e1 | 2001-01-11 15:48:50 +0000 | [diff] [blame] | 121 | gcc-wall: |
| 122 | make clean > /dev/null |
Theodore Ts'o | c8c071a | 2001-01-11 16:08:23 +0000 | [diff] [blame] | 123 | make gcc-wall-new |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 124 | |
| 125 | # |
| 126 | # Installation user and groups |
| 127 | # |
| 128 | BINGRP= bin |
| 129 | BINOWN= bin |
| 130 | BINMODE= 555 |
| 131 | INCGRP= bin |
| 132 | INCOWN= bin |
| 133 | INCMODE= 444 |
| 134 | LIBOWN= bin |
| 135 | LIBGRP= bin |
| 136 | LIBMODE= 444 |
| 137 | MANGRP= bin |
| 138 | MANOWN= bin |
| 139 | MANMODE= 444 |
| 140 | |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 141 | # |
Theodore Ts'o | fc6d9d5 | 1997-04-29 14:51:31 +0000 | [diff] [blame] | 142 | # Autoconf magic... |
| 143 | # |
| 144 | |
Theodore Ts'o | a4b2d3c | 1998-04-03 16:12:25 +0000 | [diff] [blame] | 145 | DEP_LIB_MAKEFILES = $(top_srcdir)/lib/Makefile.elf-lib \ |
| 146 | $(top_srcdir)/lib/Makefile.dll-lib $(top_srcdir)/lib/Makefile.bsd-lib \ |
| 147 | $(top_srcdir)/lib/Makefile.checker $(top_srcdir)/lib/Makefile.profile |
| 148 | |
Theodore Ts'o | fc6d9d5 | 1997-04-29 14:51:31 +0000 | [diff] [blame] | 149 | $(top_builddir)/config.status: $(top_srcdir)/configure |
Theodore Ts'o | e8aed8c | 2000-04-03 03:18:59 +0000 | [diff] [blame] | 150 | cd $(top_builddir); ./config.status --recheck |
Theodore Ts'o | fc6d9d5 | 1997-04-29 14:51:31 +0000 | [diff] [blame] | 151 | |
| 152 | $(top_builddir)/MCONFIG: $(top_srcdir)/MCONFIG.in $(top_builddir)/config.status |
Theodore Ts'o | e8aed8c | 2000-04-03 03:18:59 +0000 | [diff] [blame] | 153 | cd $(top_builddir); CONFIG_FILES=MCONFIG ./config.status |
Theodore Ts'o | fc6d9d5 | 1997-04-29 14:51:31 +0000 | [diff] [blame] | 154 | |
| 155 | $(top_builddir)/lib/substitute_sh: $(top_srcdir)/lib/substitute_sh.in \ |
| 156 | $(top_builddir)/config.status |
Theodore Ts'o | e8aed8c | 2000-04-03 03:18:59 +0000 | [diff] [blame] | 157 | cd $(top_builddir); CONFIG_FILES=lib/substitute_sh ./config.status |
Theodore Ts'o | fc6d9d5 | 1997-04-29 14:51:31 +0000 | [diff] [blame] | 158 | |
Theodore Ts'o | bf2602b | 1998-03-30 01:11:44 +0000 | [diff] [blame] | 159 | $(top_builddir)/util/subst.conf: $(top_srcdir)/util/subst.conf.in \ |
| 160 | $(top_builddir)/config.status |
Theodore Ts'o | e8aed8c | 2000-04-03 03:18:59 +0000 | [diff] [blame] | 161 | cd $(top_builddir); CONFIG_FILES=util/subst.conf ./config.status |
Theodore Ts'o | bf2602b | 1998-03-30 01:11:44 +0000 | [diff] [blame] | 162 | |
Theodore Ts'o | fc6d9d5 | 1997-04-29 14:51:31 +0000 | [diff] [blame] | 163 | Makefile: $(srcdir)/Makefile.in $(top_builddir)/MCONFIG \ |
Theodore Ts'o | a4b2d3c | 1998-04-03 16:12:25 +0000 | [diff] [blame] | 164 | $(DEP_MAKEFILE) $(top_builddir)/config.status |
Theodore Ts'o | e8aed8c | 2000-04-03 03:18:59 +0000 | [diff] [blame] | 165 | cd $(top_builddir); CONFIG_FILES=$(my_dir)/Makefile ./config.status |
Theodore Ts'o | fc6d9d5 | 1997-04-29 14:51:31 +0000 | [diff] [blame] | 166 | |
| 167 | $(top_srcdir)/configure: $(top_srcdir)/configure.in |
| 168 | cd $(top_srcdir) && autoconf |
| 169 | |
| 170 | # |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 171 | # Make depend magic... |
| 172 | # |
| 173 | |
Theodore Ts'o | 9d564f7 | 1999-07-03 20:25:58 +0000 | [diff] [blame] | 174 | .depend: Makefile $(SRCS) $(top_srcdir)/depfix.sed $(top_srcdir)/wordwrap.pl |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 175 | if test -n "$(SRCS)" ; then \ |
Theodore Ts'o | 74becf3 | 1997-04-26 14:37:06 +0000 | [diff] [blame] | 176 | $(CC) -M $(ALL_CFLAGS) $(SRCS) | \ |
Theodore Ts'o | 9d564f7 | 1999-07-03 20:25:58 +0000 | [diff] [blame] | 177 | $(SED) -f $(top_srcdir)/depfix.sed \ |
Theodore Ts'o | fc6d9d5 | 1997-04-29 14:51:31 +0000 | [diff] [blame] | 178 | -e 's; $(srcdir)/; $$(srcdir)/;g' \ |
| 179 | -e 's; $(top_srcdir)/; $$(top_srcdir)/;g' \ |
| 180 | -e 's; $(top_builddir)/; $$(top_builddir)/;g' \ |
| 181 | -e 's; \./; ;g' \ |
Theodore Ts'o | 9d564f7 | 1999-07-03 20:25:58 +0000 | [diff] [blame] | 182 | -e '/^ *\\$$/d' | \ |
| 183 | $(PERL) $(top_srcdir)/wordwrap.pl > .depend; \ |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 184 | else :; fi |
| 185 | |
| 186 | depend:: .depend |
| 187 | if test -n "$(SRCS)" ; then \ |
| 188 | sed -e '/^# +++ Dependency line eater +++/,$$d' \ |
| 189 | < $(srcdir)/Makefile.in | cat - .depend \ |
| 190 | > $(srcdir)/Makefile.in.new; \ |
Theodore Ts'o | 9d564f7 | 1999-07-03 20:25:58 +0000 | [diff] [blame] | 191 | if cmp -s $(srcdir)/Makefile.in $(srcdir)/Makefile.in.new ; then \ |
| 192 | $(RM) $(srcdir)/Makefile.in.new ; \ |
| 193 | else \ |
| 194 | $(MV) $(srcdir)/Makefile.in $(srcdir)/Makefile.in.old; \ |
| 195 | $(MV) $(srcdir)/Makefile.in.new $(srcdir)/Makefile.in; \ |
| 196 | fi ; else :; fi |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 197 | |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 198 | # End of file MCONFIG |