1 # Copyright (C) 1993, 1995, 1997, 1998 Free Software Foundation
3 # This file is part of the GNU IO Library. This library is free
4 # software; you can redistribute it and/or modify it under the
5 # terms of the GNU General Public License as published by the
6 # Free Software Foundation; either version 2, or (at your option)
9 # This library is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 # GNU General Public License for more details.
14 # You should have received a copy of the GNU General Public License
15 # along with GNU CC; see the file COPYING. If not, write to
16 # the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
18 # File descriptor usage:
19 # 1: All macros which need to be re-definable by any target fragments
20 # 2: All generic rules; especially those which use re-defined macros, e.g. _G_CONFIG_H!
22 # Significant variables:
24 # Note that TO_TOPDIR does *not* include multilib.
25 test -z "${TO_TOPDIR}" && TO_TOPDIR=${TOLIBGXX}../
26 # Native configurations build target libraries in directories at the same
27 # level as the rest of the tree. Cross configurations build target libraries
28 # one level deeper. TO_REAL_TOPDIR accounts for this.
29 # Obviously, TO_REAL_TOPDIR can only be used in the build tree.
30 if [ "${with_target_subdir}" != "." ] ; then
31 TO_REAL_TOPDIR="${TO_TOPDIR}../"
33 TO_REAL_TOPDIR="${TO_TOPDIR}"
35 DOING_LIBGXX=${DOING_LIBGXX-false}
36 THIS_FILE="${srcdir}/${TOLIBIO}config.shared"
38 echo "# Start of package fragment generated by ${THIS_FILE}."
40 echo >&2 "# Start of package rules fragment generated by ${THIS_FILE}."
45 echo 'MULTIBUILDTOP ='
49 echo 'MULTICLEAN = true'
57 # SUBDIRS [defaults to (configdirs)]
58 # INFO_FILES List of (basenames of) texinfo files
59 # INFO_SUBDIRS [default: empty] sub-directories containing documentation
61 # ??? This doesn't appear to be used by us or any of our callers.
62 # Note that all uses in this file are single-quoted.
63 rootme=${rootme-`pwd`}
65 # libg++ uses the convention that $rootme includes a trailing '/'.
66 # We use that in the definition of TOPDIR. $rootme is either empty
67 # or an absolute pathname to the current directory (with trailing '/').
68 TOPDIR=${TOPDIR-'$${rootme}$(MULTIBUILDTOP)'${TO_REAL_TOPDIR}}
69 echo '#' TOPDIR="${TOPDIR} invsubdir=${invsubdir} subdir=${subdir}"
70 SUBDIRS=${SUBDIRS-${configdirs}}
71 CHECK_SUBDIRS=${CHECK_SUBDIRS-${SUBDIRS}}
73 echo "srcdir = ${srcdir}"
74 echo "SUBDIRS = ${SUBDIRS}"
75 echo "CHECK_SUBDIRS = ${CHECK_SUBDIRS}"
77 echo "prefix = ${prefix-/usr/local}"
78 echo "exec_prefix = ${exec_prefix-'${prefix}'}"
80 echo 'bindir = $(exec_prefix)/bin'
81 echo 'libdir = $(exec_prefix)/lib'
82 echo 'libsubdir = $(libdir)/gcc-lib/$(target_alias)/$(gcc_version)'
84 echo 'datadir = $(prefix)/lib'
85 echo 'mandir = $(prefix)/man'
86 echo 'man1dir = $(mandir)/man1'
87 echo 'man2dir = $(mandir)/man2'
88 echo 'man3dir = $(mandir)/man3'
89 echo 'man4dir = $(mandir)/man4'
90 echo 'man5dir = $(mandir)/man5'
91 echo 'man6dir = $(mandir)/man6'
92 echo 'man7dir = $(mandir)/man7'
93 echo 'man8dir = $(mandir)/man8'
94 echo 'man9dir = $(mandir)/man9'
96 echo 'infodir = $(prefix)/info'
97 echo 'includedir = $(prefix)/include'
98 echo 'docdir = $(datadir)/doc'
100 echo 'SHELL = /bin/sh'
103 /*) echo 'INSTALL = $(srcdir)'/"${TO_TOPDIR}install-sh -c" ;;
104 .) echo 'INSTALL = $${rootme}'"${with_multisrctop}${TO_REAL_TOPDIR}install-sh -c" ;;
105 *) echo 'INSTALL = $${rootme}$(srcdir)'/"${TO_TOPDIR}install-sh -c" ;;
107 echo 'INSTALL_PROGRAM = $(INSTALL)'
108 echo 'INSTALL_DATA = $(INSTALL)'
110 echo 'AR = `if [ -f' ${TOPDIR}'binutils/ar ] ; \'
111 echo " then echo ${TOPDIR}binutils/ar ; "'\'
112 echo ' else echo ar ; fi`'
114 echo 'RANLIB = `if [ -f' ${TOPDIR}'binutils/ranlib ] ; \'
115 echo ' then echo '${TOPDIR}'binutils/ranlib ; \'
116 echo ' else echo ranlib ; fi`'
117 echo 'NM = `if [ -f' ${TOPDIR}'binutils/nm.new ] ; \'
118 echo ' then echo '${TOPDIR}'binutils/nm.new ; \'
119 echo ' else echo nm ; fi`'
120 echo 'NLMCONV = `if [ -f' ${TOPDIR}'binutils/nlmconv ] ; \'
121 echo ' then echo '${TOPDIR}'binutils/nlmconv ; \'
122 echo ' else echo nlmconv ; fi`'
123 echo 'LD = `if [ -f' ${TOPDIR}'ld/ld.new ] ; \'
124 echo ' then echo '${TOPDIR}'ld/ld.new ; \'
125 echo ' else echo ld ; fi`'
127 echo 'MAKEINFO = `if [ -f '${TOPDIR}'texinfo/C/makeinfo ] ; \'
128 echo ' then echo '${TOPDIR}'texinfo/C/makeinfo ; \'
129 echo ' else echo makeinfo ; fi`'
131 .) echo 'TEXIDIR = '"${with_multisrctop}${TO_REAL_TOPDIR}texinfo" ;;
132 *) echo 'TEXIDIR = $(srcdir)'/"${TO_TOPDIR}texinfo" ;;
134 echo 'TEXI2DVI = TEXINPUTS=${TEXIDIR}:$$TEXINPUTS texi2dvi'
141 echo 'WRAP_C_INCLUDES ='
143 echo 'WRAP_C_INCLUDES = -I$(srcdir)'/${TOLIBGXX}g++-include
146 echo 'CXXFLAGS = -g -O'
147 echo 'LIBCFLAGS = $(CFLAGS)'
148 echo 'LIBCXXFLAGS = $(CXXFLAGS) -fno-implicit-templates'
149 if [ "${LIBDIR}" = "yes" ]; then
150 echo 'PICDIR = stamp-picdir'
155 if test "${DOING_LIBGXX}" = "true" ; then
156 echo "TOLIBGXX = ${TOLIBGXX}"
157 echo 'PROTODIR = $(srcdir)'/${TOLIBGXX}src/gen
158 echo "LIBS = -L./${TOLIBGXX} -L./${TOLIBGXX}../libstdc++ -lg++ -lstdc++"
160 # You can override iostream (e.g. in a site- or host-Makefile fragment) to:
161 # iostream (Normal iostream library)
162 # old-stream (Old stream library; no longer supported)
163 # no-stream (If you don't want iostream to be part of libg++)
164 echo 'IO_DIR = ../libio'
165 echo '# IO_DIR = no-stream'
166 elif test "${DOING_GPERF}" = "true" ; then
167 echo "IO_DIR = libio"
168 echo "LIBS = -L${TO_TOPDIR}libstdc++ -lstdc++"
171 if [ -z "${ALL}" ] ; then
172 if [ -n "${TARGETLIB}" ] ; then
174 echo "TARGETLIB = ${TARGETLIB}"
175 elif [ -n "${TARGETPROG}" ] ; then
177 echo "TARGETPROG = ${TARGETPROG}"
179 echo "config error: neither ALL, TARGETLIB or TARGETPROG is defined" 1>&2
183 ALL='$(PICDIR)'" ${ALL}"
185 echo >&2 "all: ${ALL} multi-all"
186 if [ "${SUBDIRS}" != "" ] ; then
187 echo >&2 ' @rootme=`pwd`/; export rootme; \'
188 echo >&2 ' $(MAKE) "DODIRS=$(SUBDIRS)" DO=all $(FLAGS_TO_PASS) subdir_do'
190 echo >&2 '.PHONY: all'
193 echo >&2 '.PHONY: multi-all'
194 echo >&2 'multi-all:'
195 echo >&2 ' @$(MULTIDO) $(FLAGS_TO_PASS) multi-do DO=all'
199 if [ "${SUBDIRS}" != "" ] ; then
200 echo >&2 '.PHONY: subdir_do'
201 echo >&2 'subdir_do: force'
202 echo >&2 ' @rootme=`pwd`/; export rootme; \'
203 echo >&2 ' for i in $(DODIRS); do \'
204 echo >&2 ' if [ -f ./$$i/Makefile ] ; then \'
205 echo >&2 ' echo "cd $$i; make $(DO) ..." ; \'
206 echo >&2 ' (cd $$i ; $(MAKE) $(FLAGS_TO_PASS) $(DO)) || exit 1 ; \'
207 echo >&2 ' else true ; fi ; \'
210 echo >&2 '# List of variables to pass to sub-makes. This should not be needed'
211 echo >&2 '# by GNU make or Sun make (both of which pass command-line variable'
212 echo >&2 '# overrides thouh $(MAKE)) but may be needed by older versions.'
214 echo >&2 'FLAGS_TO_PASS= \'
215 echo >&2 ' "SHELL=$(SHELL)" \'
216 echo >&2 ' "INSTALL=$(INSTALL)" \'
217 echo >&2 ' "INSTALL_DATA=$(INSTALL_DATA)" \'
218 echo >&2 ' "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \'
219 echo >&2 ' "prefix=$(prefix)" \'
220 echo >&2 ' "exec_prefix=$(exec_prefix)" \'
221 echo >&2 ' "tooldir=$(tooldir)" \'
222 echo >&2 ' "gxx_include_dir=$(gxx_include_dir)" \'
223 echo >&2 ' "libsubdir=$(libsubdir)" \'
224 echo >&2 ' "gcc_version=$(gcc_version)" \'
225 echo >&2 ' "gcc_version_trigger=$(gcc_version_trigger)" \'
226 echo >&2 ' "AR=$(AR)" \'
227 echo >&2 ' "AR_FLAGS=$(AR_FLAGS)" \'
228 echo >&2 ' "CC=$(CC)" \'
229 echo >&2 ' "CXX=$(CXX)" \'
230 echo >&2 ' "CFLAGS=$(CFLAGS)" \'
231 echo >&2 ' "CXXFLAGS=$(CXXFLAGS)" \'
232 echo >&2 ' "NM=$(NM)" \'
233 echo >&2 ' "RANLIB=$(RANLIB)" \'
234 echo >&2 ' "LIBCFLAGS=$(LIBCFLAGS)" \'
235 echo >&2 ' "LIBCXXFLAGS=$(LIBCXXFLAGS)" \'
236 echo >&2 ' "LOADLIBES=$(LOADLIBES)" \'
237 echo >&2 ' "LDFLAGS=$(LDFLAGS)" \'
238 echo >&2 ' "MAKEINFO=$(MAKEINFO)" \'
239 echo >&2 ' "SHLIB=$(SHLIB)" \'
240 echo >&2 ' "SHCURSES=$(SHCURSES)" \'
241 echo >&2 ' "RUNTESTFLAGS=$(RUNTESTFLAGS)"'
244 echo >&2 'NOSTDINC = -nostdinc++'
245 if test -n "${XCXXINCLUDES}" ; then
246 echo >&2 "CXXINCLUDES = ${XCXXINCLUDES} "'$(NOSTDINC)'
247 elif test "${DOING_LIBGXX}" = "true" ; then
248 echo >&2 'CXXINCLUDES = $(NOSTDINC) -I. -I'"${TO_TOPDIR}libio"' -I$(srcdir) -I$(srcdir)/'"${TOLIBGXX}"'$(IO_DIR) -I$(srcdir)/'"${TOLIBGXX}"'../libstdc++ -I$(srcdir)/'"${TOLIBGXX}src"' '"${host_includes}"' $(WRAP_C_INCLUDES)'
250 if test -n "${XCINCLUDES}" ; then
251 echo >&2 "CINCLUDES = ${XCINCLUDES}"
252 elif test "${DOING_LIBGXX}" = "true" ; then
253 echo >&2 'CINCLUDES ='
256 if [ "${LIBDIR}" = "yes" ]; then
257 echo >&2 'XCFLAGS = $(LIBCFLAGS)'
258 echo >&2 'XCXXFLAGS = $(LIBCXXFLAGS)'
260 echo >&2 'XCFLAGS = $(CFLAGS)'
261 echo >&2 'XCXXFLAGS = $(CXXFLAGS)'
264 echo >&2 '.SUFFIXES: .o .C .cc .c'
265 echo >&2 'COMPILE.c = $(CC) -c $(XCFLAGS) $(CINCLUDES) $(MT_CFLAGS)'
267 if [ "${LIBDIR}" = "yes" ]; then
268 echo >&2 ' test x"$(enable_shared)" != xyes ||\'
269 echo >&2 ' $(COMPILE.c) $(PICFLAG) $< -o pic/$@'
271 echo >&2 ' $(COMPILE.c) $<'
272 [ "${TOUCH_ON_COMPILE}" = "yes" ] && echo >&2 ' @touch stamp'
273 echo >&2 'COMPILE.cc = $(CXX) -c $(XCXXFLAGS) $(CXXINCLUDES) $(MT_CFLAGS)'
275 if [ "${LIBDIR}" = "yes" ]; then
276 echo >&2 ' test x"$(enable_shared)" != xyes ||\'
277 echo >&2 ' $(COMPILE.cc) $(PICFLAG) $< -o pic/$@'
279 echo >&2 ' $(COMPILE.cc) $<'
280 [ "${TOUCH_ON_COMPILE}" = "yes" ] && echo >&2 ' @touch stamp'
282 if [ "${LIBDIR}" = "yes" ]; then
283 echo >&2 ' test x"$(enable_shared)" != xyes || \'
284 echo >&2 ' $(COMPILE.cc) $(PICFLAG) $< -o pic/$@'
286 echo >&2 ' $(COMPILE.cc) $<'
287 [ "${TOUCH_ON_COMPILE}" = "yes" ] && echo >&2 ' @touch stamp'
290 if [ -n "${TARGETLIB}" ] ; then
291 echo TARGETLIB = ${TARGETLIB}
293 if [ -n "${TARGETPROG}" ] ; then
294 echo TARGETPROG = ${TARGETPROG}
297 if [ "${LIBDIR}" = "yes" ]; then
299 echo >&2 'stamp-picdir:'
300 echo >&2 ' if [ x"$(enable_shared)" = xyes ] && [ ! -d pic ]; then \'
301 echo >&2 ' mkdir pic; \'
302 echo >&2 ' else true; fi'
303 echo >&2 ' touch stamp-picdir'
307 echo >&2 '.PHONY: install'
309 echo >&2 '.PHONY: check'
310 if [ "${CHECK}" != "check" ] ; then
311 echo >&2 "check: ${ALL} ${CHECK}"
312 if [ "${CHECK_SUBDIRS}" != "" ] ; then
313 echo >&2 ' rootme=`pwd`/; export rootme; \'
314 echo >&2 ' SAVE_LLPATH="$${SAVE_LLPATH-$$LD_LIBRARY_PATH}"; export SAVE_LLPATH; \'
315 echo >&2 ' LD_LIBRARY_PATH="$${rootme}${TOLIBGXX}../libstdc++:$${rootme}${TOLIBGXX}../libg++:$$SAVE_LLPATH"; \'
316 echo >&2 ' export LD_LIBRARY_PATH; \'
317 echo >&2 ' $(MAKE) "DODIRS=$(CHECK_SUBDIRS)" DO=check $(FLAGS_TO_PASS) subdir_do'
321 # Generate rules for documentation (depending on INFO_FILES and INFO_SUBDIRS).
323 echo >&2 '.PHONY: info dvi install-info clean-info'
325 # emit the rule for 'info'
326 # (Note that the top-level ../Makefile.in greps for '^info:' when making
327 # a release (in "make taz"), so don't break that!)
328 if [ -z "${INFO_FILES}" ] ; then
331 echo >&2 info: `for file in ${INFO_FILES} ; do echo $file.info ; done`
333 if [ "${INFO_SUBDIRS}" != "" ] ; then
334 echo >&2 ' @rootme=`pwd`/; export rootme; \
335 $(MAKE) "DODIRS='${INFO_SUBDIRS}'" DO=info $(FLAGS_TO_PASS) subdir_do'
338 # emit the rule for 'dvi'
339 if [ -z "${INFO_FILES}" ] ; then
342 echo >&2 dvi: `for file in ${INFO_FILES} ; do echo $file.dvi ; done`
344 if [ "${INFO_SUBDIRS}" != "" ] ; then
345 echo >&2 ' @rootme=`pwd`/; export rootme; \
346 $(MAKE) "DODIRS='${INFO_SUBDIRS}'" DO=dvi $(FLAGS_TO_PASS) subdir_do'
349 # Emit rules for each *.info and *.dvi file
350 for file in ${INFO_FILES} ; do
351 echo >&2 ${file}.info: '$(srcdir)'/${file}.texi
352 echo >&2 ' $(MAKEINFO) -I$(srcdir) -I$(TEXIDIR) $(srcdir)/'${file}.texi -o ${file}.info
353 echo >&2 ${file}.dvi: '$(srcdir)'/${file}.texi
354 echo >&2 ' $(TEXI2DVI) $(srcdir)'/${file}.texi
355 echo >&2 "${file}.ps: ${file}.dvi"
356 echo >&2 " dvips ${file} -o"
359 # emit the rule for install-info
360 echo >&2 'install-info:'
361 if [ -n "${INFO_FILES}" ] ; then
362 echo >&2 ' -parent=`echo $(infodir)|sed -e' "'"'s@/[^/]*$$@@'"'"'`; \'
363 echo >&2 ' if [ -d $$parent ] ; then true ; else mkdir $$parent ; fi'
364 echo >&2 ' -if [ -d $(infodir) ] ; then true ; else mkdir $(infodir) ; fi'
365 echo >&2 ' for i in *.info* ; do \'
366 echo >&2 ' $(INSTALL_DATA) $$i $(infodir)/$$i ; \'
369 if [ "${INFO_SUBDIRS}" != "" ] ; then
370 echo >&2 ' @rootme=`pwd`/; export rootme; \
371 $(MAKE) "DODIRS='${INFO_SUBDIRS}'" DO=install-info $(FLAGS_TO_PASS) subdir_do'
374 # emit clean-info and clean-dvi rules
375 echo >&2 '.PHONY: do-clean-info clean-info do-clean-dvi clean-dvi'
376 echo >&2 do-clean-info:
377 if [ -n "${INFO_FILES}" ] ; then
378 echo >&2 ' rm -f *.info*'
380 echo >&2 'do-clean-dvi:'
381 if [ -n "${INFO_FILES}" ] ; then
382 echo >&2 ' rm -f *.dvi *.aux *.cp *.cps *.fn* *.ky *.log *.pg *.toc *.tp *.vr'
384 for type in info dvi ; do
385 echo >&2 clean-${type}: do-clean-${type}
386 if [ "${INFO_SUBDIRS}" != "" ] ; then
387 echo >&2 ' @rootme=`pwd`/; export rootme; \
388 $(MAKE) "DODIRS='${NFO_SUBDIRS}'" DO=clean-'${type} '$(FLAGS_TO_PASS) subdir_do'
394 echo >&2 '.PHONY: boltcc'
396 echo >&2 ' rootme=`pwd`/ ; export rootme ; $(MAKE) $(FLAGS_TO_PASS)'
402 echo >&2 '# clean rules'
404 MOSTLYCLEAN="${MOSTLYCLEAN-*.o pic stamp-picdir core ${EXTRA_MOSTLYCLEAN}} `if test -n "${TOUCH_ON_COMPILE}"; then echo stamp; else true; fi`"
405 CLEAN="${CLEAN-${TARGETPROG} ${TARGETLIB}}"
406 DISTCLEAN="${DISTCLEAN-config.status Makefile *~ Make.pack target-mkfrag multilib.out ${EXTRA_DISTCLEAN-}}"
407 REALCLEAN="${REALCLEAN-depend *.info*}"
410 echo >&2 '.PHONY: mostlyclean clean distclean maintainer-clean realclean'
411 if test -z "${SUBDIRS}" ; then
412 echo >&2 "mostlyclean: clean-dvi"
413 echo >&2 " rm -rf ${MOSTLYCLEAN}"
414 echo >&2 ' @$(MULTICLEAN) multi-clean DO=mostlyclean'
415 echo >&2 "clean: clean-dvi"
416 echo >&2 " rm -rf ${MOSTLYCLEAN} ${CLEAN}"
417 echo >&2 ' @$(MULTICLEAN) multi-clean DO=clean'
418 echo >&2 "distclean: clean"
419 echo >&2 ' @$(MULTICLEAN) multi-clean DO=distclean'
420 echo >&2 " rm -rf ${DISTCLEAN}"
421 echo >&2 "maintainer-clean realclean: clean clean-info"
422 echo >&2 ' @$(MULTICLEAN) multi-clean DO=maintainer-clean'
423 echo >&2 " rm -rf ${DISTCLEAN} ${REALCLEAN}"
425 echo >&2 '.PHONY: do-clean subdir_distclean subdir_maintainer_clean'
426 echo >&2 "mostlyclean: do-clean-dvi"
427 echo >&2 " rm -rf ${MOSTLYCLEAN}"
428 echo >&2 ' @$(MAKE) $(FLAGS_TO_PASS) "DODIRS=$(SUBDIRS)" DO=mostlyclean subdir_do'
429 echo >&2 ' @$(MULTICLEAN) multi-clean DO=mostlyclean'
430 echo >&2 "do-clean: do-clean-dvi"
431 echo >&2 " rm -rf ${MOSTLYCLEAN} ${CLEAN}"
432 echo >&2 "clean: do-clean"
433 echo >&2 ' @$(MAKE) $(FLAGS_TO_PASS) "DODIRS=$(SUBDIRS)" DO=clean subdir_do'
434 echo >&2 ' @$(MULTICLEAN) multi-clean DO=clean'
435 # distclean and maintainer-clean are tricky because they remove the Makefile.
436 echo >&2 "subdir_distclean:"
437 echo >&2 ' @$(MAKE) $(FLAGS_TO_PASS) "DODIRS=$(SUBDIRS)" DO=distclean subdir_do'
438 echo >&2 "distclean: do-clean subdir_distclean"
439 echo >&2 ' @$(MULTICLEAN) multi-clean DO=distclean'
440 echo >&2 " rm -rf ${DISTCLEAN}"
441 echo >&2 "subdir_maintainer_clean:"
442 echo >&2 ' @$(MAKE) $(FLAGS_TO_PASS) "DODIRS=$(SUBDIRS)" DO=maintainer-clean subdir_do'
443 echo >&2 "maintainer-clean realclean: do-clean subdir_maintainer_clean do-clean-info"
444 echo >&2 ' @$(MULTICLEAN) multi-clean DO=maintainer-clean'
445 echo >&2 " rm -rf ${DISTCLEAN} ${REALCLEAN}"
449 echo >&2 '.PHONY: force'
452 echo >&2 '# with the gnu make, this is done automatically.'
454 echo >&2 'Makefile: $(srcdir)/Makefile.in $(host_makefile_frag) $(target_makefile_frag) $(gcc_version_trigger)'
455 echo >&2 ' $(SHELL) ./config.status'
457 echo >&2 '.NOEXPORT:'
458 echo >&2 'MAKEOVERRIDES='
461 DEPEND_SOURCES = ${srcdir}/*.cc ${srcdir}/*.c
463 # The sed script below attempts to make the depend output portable.
464 # It cleans up the depenency information generated by cpp.
465 # It replaces instances of $(srcdir)/ by the string '$(srcdir)/'.
466 # It removes remaining absolute files names (such as /usr/include/stdio.h).
467 # It removes lines containing only "\\".
468 # It inserts '$(MULTISRCTOP)' in '$(srcdir)/..'.
469 # In order to support SunOS VPATH, $(srcdir)/[a-z]*.{c,cc} is replaced with
470 # [a-z]*.{c,cc} (the directory part is removed).
471 # The awk script removes a continuation marker that is followed by
472 # a blank line, since that may confuse make.
473 echo "# AUTOMATICALLY GENERATED BY 'make depend' - DO NOT EDIT" \
475 $(CXX) -M $(CXXINCLUDES) $(DEPEND_SOURCES) \
476 | sed -e 's|$(srcdir)/|$$(srcdir)/|g' \
477 -e 's| [^ ]*_G_config.h| $$(_G_CONFIG_H)|g' \
478 -e 's| /[^ ]*||g' -e 's| libc-lock\.h||' \
479 -e '/^[ ]*\\$$/d' -e 's/^[ ]*$$//' \
480 | sed -e 's|$$(srcdir)/[.][.]|$$(srcdir)/$$(MULTISRCTOP)..|g' \
481 -e 's|$$(srcdir)/\([^/]*[.]c\)|\1|' \
482 | awk 'BEGIN { prev = "" } \
483 /^( )*$$/ { if (prev ~ /\\$$/) \
484 { prev = substr(prev,1,length(prev)-1); next } } \
485 { print prev; prev = $$0 } \
486 END { if (prev !~ /^( )*$$/) print prev }' \
488 $(srcdir)/depend: depend.new
489 mv depend.new $(srcdir)/depend
492 if [ -f ${srcdir}/${subdir}/depend ] ; then
493 cat ${srcdir}/${subdir}/depend >&2
496 echo "# End of package fragment generated by ${THIS_FILE}."
497 echo >&2 "# End of package rules fragment generated by ${THIS_FILE}."