From 33cf356ae139496836b379437a3ba627ab2497cd Mon Sep 17 00:00:00 2001 From: Stu Grossman Date: Tue, 16 Jun 1992 23:14:01 +0000 Subject: [PATCH] Unscrew this file... (Been up too long I think...) --- gdb/Makefile.in | 1706 ++++++++++++++++++----------------------------- 1 file changed, 641 insertions(+), 1065 deletions(-) diff --git a/gdb/Makefile.in b/gdb/Makefile.in index 3f3eaf8e6ed..e509ff4b733 100644 --- a/gdb/Makefile.in +++ b/gdb/Makefile.in @@ -1,8 +1,8 @@ -# -# Makefile for directory with subdirs to build. -# Copyright (C) 1990, 1991, 1992 Free Software Foundation -# -# This file is free software; you can redistribute it and/or modify +#Copyright (C) 1989, 1990, 1991, 1992 Free Software Foundation, Inc. + +# This file is part of GDB. + +# This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. @@ -14,17 +14,14 @@ # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software -# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -# - -srcdir = . +# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. prefix = /usr/local +program_prefix = exec_prefix = $(prefix) bindir = $(exec_prefix)/bin libdir = $(exec_prefix)/lib -tooldir = $(libdir) datadir = $(prefix)/lib mandir = $(prefix)/man @@ -48,1099 +45,678 @@ INSTALL_PROGRAM = $(INSTALL) INSTALL_DATA = $(INSTALL) AR = ar -AR_FLAGS = qc -CFLAGS = -g +AR_FLAGS = qv RANLIB = ranlib -BISON = `if [ -d $${rootme}/byacc ] ; \ - then echo $${rootme}/byacc/byacc ; \ - else echo byacc ; fi` - -LEX = `if [ -d $${rootme}/flex ] ; \ - then echo $${rootme}/flex/flex -S$${rootme}/flex/flex.skel ; \ - else echo flex ; fi` - -MAKEINFO = `if [ -d $${rootme}/texinfo/C ] ; \ - then echo $${rootme}/texinfo/C/makeinfo ; \ - else echo makeinfo ; fi` - -SUBDIRS = libiberty mmalloc glob readline bfd gdb binutils ld gas gcc libg++ libgcc clib newlib -OTHERS = - -ALL = all.normal -INSTALL_TARGET = install.all - -### for debugging -#GCCVERBOSE=-v - -GXX = `if [ -d $${rootme}/gcc ] ; \ - then echo $${rootme}/gcc/gcc -B$${rootme}/gcc/ ; \ - else echo gcc ; fi` - -XTRAFLAGS = `if [ -d $${rootme}/gcc ] ; \ - then echo -I$${rootme}/gcc/include ; \ - else echo ; fi` - -#### host and target specific makefile fragments come in here. -### - -FLAGS_TO_PASS = \ - "prefix=$(prefix)" \ - "exec_prefix=$(exec_prefix)" \ - "tooldir=$(tooldir)" \ - "AR=$(AR)" \ - "AR_FLAGS=$(AR_FLAGS)" \ - "CC=$(CC)" \ - "CFLAGS=$(CFLAGS)" \ - "RANLIB=$(RANLIB)" \ - "LOADLIBES=$(LOADLIBES)" \ - "LDFLAGS=$(LDFLAGS)" \ - "BISON=$(BISON)" \ - "LEX=$(LEX)" \ - "MAKEINFO=$(MAKEINFO)" \ - "INSTALL=$(INSTALL)" \ - "INSTALL_DATA=$(INSTALL_DATA)" \ - "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" - -.PHONY: all info install-info clean-info -.NOEXPORT: - -all: $(ALL) - -info: cfg-paper.info configure.info standards.info - @rootme=`pwd` ; export rootme ; $(MAKE) subdir_do DO=info "DODIRS=$(SUBDIRS)" $(FLAGS_TO_PASS) +# Flags that describe where you can find the termcap library. +# This can be overridden in the host Makefile fragment file. +TERMCAP = -ltermcap + +# System V: If you compile gdb with a compiler which uses the coff +# encapsulation feature (this is a function of the compiler used, NOT +# of the m-?.h file selected by config.gdb), you must make sure that +# the GNU nm is the one that is used by munch. + +# If you are compiling with GCC, make sure that either 1) You use the +# -traditional flag, or 2) You have the fixed include files where GCC +# can reach them. Otherwise the ioctl calls in inflow.c +# will be incorrectly compiled. The "fixincludes" script in the gcc +# distribution will fix your include files up. +#CC=cc +#CC=gcc -traditional +GCC=gcc + +# Directory containing source files. Don't clean up the spacing, +# this exact string is matched for by the "configure" script. +srcdir = . -# Note libg++ has to be handled specially (we can't compile it with CC=cc). +# It is also possible that you will need to add -I/usr/include/sys to the +# CFLAGS section if your system doesn't have fcntl.h in /usr/include (which +# is where it should be according to Posix). + +BISON=yacc +YACC=$(BISON) +MAKE=make + +# Documentation (gdb.dvi) needs either GNU m4 or SysV m4; +# Berkeley/Sun don't have quite enough. +#M4=/usr/5bin/m4 +M4=gm4 + +# where to find texinfo; GDB dist should include a recent one +TEXIDIR=${srcdir}/../texinfo/fsf + +# where to find makeinfo, preferably one designed for texinfo-2 +MAKEINFO=makeinfo + +# Set this up with gcc if you have gnu ld and the loader will print out +# line numbers for undefinded refs. +#CC-LD=gcc -static +CC-LD=${CC} + +# Where is the "include" directory? Traditionally ../include or ./include +INCLUDE_DIR = ${srcdir}/../include +INCLUDE_DEP = $$(INCLUDE_DIR) + +# Where is the source dir for the MMALLOC library? Traditionally ../mmalloc +# or ./mmalloc (When we want the binary library built from it, we use +# ${MMALLOC_DIR}${subdir}.) +# Note that mmalloc can still be used on systems without mmap(). +# To use your system malloc, comment out the following defines. +MMALLOC_DIR = ${srcdir}/../mmalloc +MMALLOC_DEP = $$(MMALLOC_DIR) +MMALLOC_LIB = ./../mmalloc${subdir}/libmmalloc.a +# To use your system malloc, uncomment MMALLOC_DISABLE. +#MMALLOC_DISABLE = -DNO_MMALLOC +# To use mmalloc but disable corruption checking, uncomment MMALLOC_CHECK +#MMALLOC_CHECK = -DNO_MMALLOC_CHECK +MMALLOC_CFLAGS = ${MMALLOC_CHECK} ${MMALLOC_DISABLE} + +# Where is the source dir for the BFD library? Traditionally ../bfd or ./bfd +# (When we want the binary library built from it, we use ${BFD_DIR}${subdir}.) +BFD_DIR = ${srcdir}/../bfd +BFD_DEP = $$(BFD_DIR) +BFD_LIB = ./../bfd${subdir}/libbfd.a + +# Where is the source dir for the READLINE library? Traditionally in .. or . +# (For the binary library built from it, we use ${READLINE_DIR}${subdir}.) +READLINE_DIR = ${srcdir}/../readline +READLINE_DEP = $$(READLINE_DIR) +RL_LIB = ./../readline${subdir}/libreadline.a + +# All the includes used for CFLAGS and for lint. +# -I. for config files. +# -I${srcdir} possibly for regex.h also. +INCLUDE_CFLAGS = -I. -I${srcdir} -I$(INCLUDE_DIR) -I$(READLINE_DIR) + +# M{H,T}_CFLAGS, if defined, has host- and target-dependent CFLAGS +# from the config/ directory. +GLOBAL_CFLAGS = ${MT_CFLAGS} ${MH_CFLAGS} +#PROFILE_CFLAGS = -pg + +# CFLAGS is specifically reserved for setting from the command line +# when running make. I.E. "make USER_CFLAGS=-Wmissing-prototypes". +CFLAGS = -g +# INTERNAL_CFLAGS is the aggregate of all other *CFLAGS macros. +INTERNAL_CFLAGS = ${CFLAGS} ${GLOBAL_CFLAGS} ${PROFILE_CFLAGS} ${MMALLOC_CFLAGS} ${INCLUDE_CFLAGS} ${USER_CFLAGS} +# None of the things in CFLAGS will do any harm, and on some systems +# (e.g. SunOS4) it is important to use the M_CFLAGS. +LDFLAGS = $(CFLAGS) + +# Where is the "-liberty" library, containing getopt and obstack? +LIBIBERTY_DIR = ${srcdir}/../libiberty +LIBIBERTY = ./../libiberty${subdir}/libiberty.a + +# The config/mh-* file must define REGEX and REGEX1 on USG machines. +# If your sysyem is missing alloca(), or, more likely, it's there but +# it doesn't work, define ALLOCA & ALLOCA1 too. +# If your system is missing putenv(), add putenv.c to XM_ADD_FILES. + +# Libraries and corresponding dependencies for compiling gdb. +# {X,T}M_CLIBS, defined in *config files, have host- and target-dependent libs. +# TERMCAP comes after readline, since readline depends on it. +CLIBS = ${BFD_LIB} ${RL_LIB} ${TERMCAP} ${MMALLOC_LIB} ${LIBIBERTY} \ + ${XM_CLIBS} ${TM_CLIBS} +CDEPS = ${XM_CDEPS} ${TM_CDEPS} ${BFD_LIB} ${MMALLOC_LIB} ${LIBIBERTY} \ + ${RL_LIB} ${MMALLOC_LIB} + +ADD_FILES = ${REGEX} ${ALLOCA} ${XM_ADD_FILES} ${TM_ADD_FILES} +ADD_DEPS = ${REGEX1} ${ALLOCA1} ${XM_ADD_FILES} ${TM_ADD_FILES} + +VERSION = 4.5.5 +DIST=gdb + +LINT=/usr/5bin/lint +LINTFLAGS= -I${BFD_DIR} + +# Select demangler to use. +DEMANGLER=cplus-dem + +# Select options to use when compiling ${DEMANGLER}.c. The default is no +# options, which is correct for most targets, and also defaults to g++ style +# demangling. For other demangling styles, such as the Annotated C++ +# Reference Manual (section 7.2.1c) style, set this define in the target- +# dependent makefile fragment. +DEMANGLE_OPTS= + +# Host and target-dependent makefile fragments come in here. +#### +# End of host and target-dependent makefile fragments + +# Source files in the main directory. +# Files which are included via a config/* Makefile fragment +# should *not* be specified here; they're in "ALLDEPFILES". +SFILES_MAINDIR = \ + blockframe.c breakpoint.c command.c core.c \ + environ.c eval.c expprint.c findvar.c infcmd.c inflow.c infrun.c \ + main.c printcmd.c gdbtypes.c \ + remote.c source.c stack.c symmisc.c symtab.c symfile.c \ + utils.c valarith.c valops.c valprint.c values.c c-exp.y m2-exp.y \ + ${DEMANGLER}.c mem-break.c target.c inftarg.c \ + dbxread.c coffread.c elfread.c dwarfread.c xcoffread.c \ + ieee-float.c language.c parse.c buildsym.c objfiles.c \ + minsyms.c mipsread.c + +# Source files in subdirectories (which will be handled separately by +# 'make gdb.tar.Z'). +# Files which are included via a config/* Makefile fragment +# should *not* be specified here; they're in "ALLDEPFILES". +SFILES_SUBDIR = \ + ${srcdir}/vx-share/dbgRpcLib.h \ + ${srcdir}/vx-share/ptrace.h \ + ${srcdir}/vx-share/reg.h \ + ${srcdir}/vx-share/vxTypes.h \ + ${srcdir}/vx-share/vxWorks.h \ + ${srcdir}/vx-share/wait.h \ + ${srcdir}/vx-share/xdr_ld.h \ + ${srcdir}/vx-share/xdr_ptrace.h \ + ${srcdir}/vx-share/xdr_rdb.h \ + ${srcdir}/vx-share/xdr_regs.h \ + ${srcdir}/nindy-share/b.out.h \ + ${srcdir}/nindy-share/block_io.h \ + ${srcdir}/nindy-share/coff.h \ + ${srcdir}/nindy-share/demux.h \ + ${srcdir}/nindy-share/env.h \ + ${srcdir}/nindy-share/stop.h \ + ${srcdir}/nindy-share/ttycntl.h + +# Non-source files in subdirs, that should go into gdb.tar.Z. +NONSRC_SUBDIR = \ + ${srcdir}/nindy-share/Makefile \ + ${srcdir}/nindy-share/VERSION + +# All source files that go into linking GDB, except config-specified files. +SFILES = $(SFILES_MAINDIR) $(SFILES_SUBDIR) + +# All source files that lint should look at +LINTFILES = $(SFILES) $(YYFILES) init.c + +# Any additional files specified on these lines should also be added to +# the OTHERS = definition below, so they go in the tar files. +SFILES_STAND = $(SFILES) standalone.c +SFILES_KGDB = $(SFILES) stuff.c kdb-start.c + +# Header files that are not named in config/* Makefile fragments go here. +HFILES= breakpoint.h buildsym.h call-cmds.h command.h defs.h environ.h \ + expression.h frame.h gdbcmd.h gdbcore.h gdbtypes.h \ + ieee-float.h inferior.h minimon.h objfiles.h partial-stab.h \ + signals.h symfile.h symtab.h solib.h xcoffsolib.h \ + target.h terminal.h tm-68k.h tm-i960.h tm-sunos.h tm-sysv4.h \ + xm-m68k.h xm-sysv4.h language.h parser-defs.h value.h xm-vax.h + +REMOTE_EXAMPLES = m68k-stub.c i386-stub.c rem-multi.shar + +POSSLIBS_MAINDIR = regex.c regex.h alloca.c +POSSLIBS = $(POSSLIBS_MAINDIR) + +TESTS = testbpt.c testfun.c testrec.c testreg.c testregs.c + +OTHERS = Makefile.in depend alldeps.mak createtags munch configure.in \ + ChangeLog ChangeLog-9091 ChangeLog-3.x gdb.1 refcard.ps \ + README TODO TAGS WHATS.NEW Projects \ + .gdbinit COPYING $(YYFILES) \ + copying.c Convex.notes copying.awk \ + saber.suppress standalone.c stuff.c kdb-start.c \ + putenv.c + +# Subdirectories of gdb, which should be included in their entirety in +# gdb-xxx.tar.Z: +TARDIRS = doc # tests + +# GDB "info" files, which should be included in their entirety +INFOFILES = gdb.info* + +DEPFILES= ${TDEPFILES} ${XDEPFILES} + +SOURCES=$(SFILES) $(ALLDEPFILES) $(YYFILES) +TAGFILES = $(SOURCES) ${HFILES} ${ALLPARAM} ${POSSLIBS} +TAGFILES_MAINDIR = $(SFILES_MAINDIR) $(ALLDEPFILES_MAINDIR) \ + ${HFILES} ${ALLPARAM} ${POSSLIBS_MAINDIR} +TARFILES = ${TAGFILES_MAINDIR} ${OTHERS} ${REMOTE_EXAMPLES} + +OBS = main.o blockframe.o breakpoint.o findvar.o stack.o source.o \ + values.o eval.o valops.o valarith.o valprint.o printcmd.o \ + symtab.o symfile.o symmisc.o infcmd.o infrun.o remote.o \ + command.o utils.o expprint.o environ.o version.o gdbtypes.o \ + copying.o $(DEPFILES) ${DEMANGLER}.o mem-break.o target.o \ + inftarg.o ieee-float.o putenv.o parse.o language.o $(YYOBJ) \ + buildsym.o objfiles.o minsyms.o \ + dbxread.o coffread.o elfread.o dwarfread.o xcoffread.o mipsread.o + +RAPP_OBS = rgdb.o rudp.o rserial.o serial.o udp.o $(XDEPFILES) + +TSOBS = core.o inflow.o + +NTSOBS = standalone.o + +TSSTART = /lib/crt0.o + +NTSSTART = kdb-start.o + +SUBDIRS = doc + +# For now, shortcut the "configure GDB for fewer languages" stuff. +YYFILES = c-exp.tab.c m2-exp.tab.c +YYOBJ = c-exp.tab.o m2-exp.tab.o + +# Prevent Sun make from putting in the machine type. Setting +# TARGET_ARCH to nothing works for SunOS 3, 4.0, but not for 4.1. +.c.o: + ${CC} -c ${INTERNAL_CFLAGS} $< + +all: gdb + $(MAKE) subdir_do DO=all "DODIRS=$(SUBDIRS)" check: - @rootme=`pwd` ; export rootme ; $(MAKE) subdir_do DO=check \ - "DODIRS=`echo $(SUBDIRS) | sed -e \"s/libg\+\+//\"" $(FLAGS_TO_PASS) - @rootme=`pwd` ; export rootme ; $(MAKE) subdir_do DO=check \ - "DODIRS=libg++" $(FLAGS_TO_PASS) "CC=${GXX}" "XTRAFLAGS=${XTRAFLAGS}" - -clean-info: - @$(MAKE) subdir_do DO=clean-info "DODIRS=$(SUBDIRS)" - rm -f *.info* - -cfg-paper.info: cfg-paper.texi - rootme=`pwd` ; export rootme ; $(MAKEINFO) -o cfg-paper.info $(srcdir)/cfg-paper.texi - -configure.info: configure.texi - rootme=`pwd` ; export rootme ; $(MAKEINFO) -o configure.info $(srcdir)/configure.texi - -standards.info: standards.texi - rootme=`pwd` ; export rootme ; $(MAKEINFO) -o standards.info $(srcdir)/standards.texi - -install-info: install-info-dirs force - [ -d $(infodir) ] || mkdir $(infodir) - @$(MAKE) subdir_do DO=install-info "DODIRS=$(SUBDIRS)" - $(INSTALL_DATA) cfg-paper.info $(infodir)/cfg-paper.info - $(INSTALL_DATA) configure.info $(infodir)/configure.info - $(INSTALL_DATA) standards.info $(infodir)/standards.info - @$(MAKE) dir.info install-dir.info - -install-dir.info: - $(INSTALL_DATA) dir.info $(infodir)/dir.info - -all.normal: all-autoconf all-libiberty all-mmalloc all-texinfo \ - all-bison all-byacc all-flex all-bfd all-ld all-gas all-gcc \ - all-binutils all-libg++ all-readline all-gdb \ - all-make all-rcs all-cvs all-diff all-grep \ - all-patch all-emacs all-ispell \ - all-newlib all-gprof all-send_pr - -all.cross: all-libiberty all-mmalloc all-gas all-byacc all-ld \ - all-bfd all-libgcc all-readline all-gdb -# $(MAKE) subdir_do DO=all "DODIRS=$(SUBDIRS) $(OTHERS)" - -clean: clean-autoconf clean-libiberty clean-mmalloc clean-texinfo \ - clean-bfd clean-newlib clean-binutils clean-flex \ - clean-bison clean-byacc clean-ld clean-gas \ - clean-gcc clean-libgcc clean-readline clean-glob clean-gdb \ - clean-make clean-diff clean-grep clean-rcs \ - clean-cvs clean-patch clean-emacs clean-ispell \ - clean-libg++ clean-gprof clean-send_pr - -rm -rf *.a TEMP errs core *.o *~ \#* TAGS *.E - -clean-stamps: - -rm -f all-* - -install: $(INSTALL_TARGET) $(srcdir)/configure.man - $(INSTALL_DATA) $(srcdir)/configure.man $(man1dir)/configure.1 - - -install.all: install-dirs install-autoconf install-texinfo \ - install-mmalloc install-libiberty install-bfd install-binutils \ - install-bison install-byacc install-flex install-ld \ - install-gas install-gcc install-gprof install-libgcc \ - install-readline install-glob install-gdb install-make \ - install-cvs install-patch install-emacs install-ispell \ - install-libg++ install-newlib \ - install-send_pr - -install.cross: install-dirs install-libiberty install-mmalloc \ - install-binutils install-bison install-byacc install-flex \ - install-ld install-gas install-libgcc install-readline \ - install-glob install-gdb install-mmalloc install-gprof - -### autoconf -all-autoconf: force - @if [ -d ./autoconf ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./autoconf; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-autoconf: force - @if [ -d ./autoconf ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./autoconf; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-autoconf: force - @if [ -d ./autoconf ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./autoconf; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### libiberty -all-libiberty: force - @if [ -d ./libiberty ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./libiberty; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-libiberty: force - @if [ -d ./libiberty ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./libiberty; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-libiberty: force - @if [ -d ./libiberty ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./libiberty; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### mmalloc -all-mmalloc: force - @if [ -d ./mmalloc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./mmalloc; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-mmalloc: force - @if [ -d ./mmalloc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./mmalloc; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-mmalloc: force - @if [ -d ./mmalloc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./mmalloc; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### texinfo -all-texinfo: all-libiberty - @if [ -d ./texinfo ] ; then \ - rootme=`pwd` ; export rootme ; \ - rootme=`pwd` ; export rootme ; \ - (cd ./texinfo; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-texinfo: force - @if [ -d ./texinfo ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./texinfo; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-texinfo: force - @if [ -d ./texinfo ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./texinfo; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### bfd -all-bfd: force - @if [ -d ./bfd ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./bfd; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-bfd: force - @if [ -d ./bfd ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./bfd; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-bfd: force - @if [ -d ./bfd ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./bfd; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### binutils -all-binutils: all-libiberty all-bfd all-flex - @if [ -d ./binutils ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./binutils; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-binutils: force - @if [ -d ./binutils ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./binutils; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-binutils: force - @if [ -d ./binutils ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./binutils; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### newlib -all-newlib: force - @if [ -d ./newlib ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./newlib; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-newlib: force - @if [ -d ./newlib ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./newlib; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-newlib: force - @if [ -d ./newlib ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./newlib; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### gprof -all-gprof: all-libiberty all-bfd - @if [ -d ./gprof ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./gprof; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-gprof: force - @if [ -d ./gprof ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./gprof; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-gprof: force - @if [ -d ./gprof ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./gprof; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### byacc -all-byacc: force - @if [ -d ./byacc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./byacc; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-byacc: force - @if [ -d ./byacc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./byacc; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-byacc: force - @if [ -d ./byacc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./byacc; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### bison -all-bison: all-libiberty - @if [ -d ./bison ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./bison; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-bison: force - @if [ -d ./bison ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./bison; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-bison: force - @if [ -d ./bison ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./bison; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### flex -all-flex: all-libiberty - @if [ -d ./flex ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./flex; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-flex: force - @if [ -d ./flex ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./flex; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-flex: force - @if [ -d ./flex ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./flex; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi -### gcc -all-gcc: all-libiberty all-byacc - @if [ -d ./gcc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./gcc; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-gcc: force - @if [ -d ./gcc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./gcc; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-gcc: force - @if [ -d ./gcc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./gcc; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### readline -all-readline: force - @if [ -d ./readline ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./readline; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-readline: force - @if [ -d ./readline ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./readline; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-readline: force - @if [ -d ./readline ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./readline; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### glob -all-glob: force - @if [ -d ./glob ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./glob; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-glob: force - @if [ -d ./glob ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./glob; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-glob: force - @if [ -d ./glob ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./glob; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### gas -all-gas: all-libiberty all-bfd - @if [ -d ./gas ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./gas; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-gas: force - @if [ -d ./gas ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./gas; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-gas: force - @if [ -d ./gas ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./gas; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### ld -all-ld: all-libiberty all-bfd all-byacc all-flex - @if [ -d ./ld ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./ld; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-ld: force - @if [ -d ./ld ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./ld; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-ld: force - @if [ -d ./ld ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./ld; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### libgcc (and libgcc1) -all-libgcc1: all-gas all-binutils - @if [ -d ./libgcc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./libgcc; \ - $(MAKE) $(FLAGS_TO_PASS) libgcc1.a) ; \ - else \ - true ; \ - fi - -clean-libgcc1: force - @if [ -d ./libgcc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./libgcc; \ - $(MAKE) $(FLAGS_TO_PASS) clean-libgcc1) ; \ - else \ - true ; \ - fi - -install-libgcc1: force - echo libgcc1 is a component, not an installable target - -all-libgcc: all-gas all-gcc all-binutils - true - @if [ -d ./libgcc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./libgcc; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-libgcc: force - @if [ -d ./libgcc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./libgcc; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-libgcc: force - @if [ -d ./libgcc ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./libgcc; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### gdb -all-gdb: all-bfd all-libiberty all-mmalloc all-readline all-glob all-byacc - @if [ -d ./gdb ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./gdb; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-gdb: force - @if [ -d ./gdb ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./gdb; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-gdb: force - @if [ -d ./gdb ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./gdb; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### make -all-make: all-libiberty - @if [ -d ./make ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./make; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-make: force - @if [ -d ./make ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./make; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi - -install-make: force - @if [ -d ./make ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./make; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi - -### diff -all-diff: force - @if [ -d ./diff ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./diff; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi - -clean-diff: force - @if [ -d ./diff ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./diff; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi +info: force + $(MAKE) subdir_do DO=info "DODIRS=$(SUBDIRS)" "MAKEINFO=$(MAKEINFO)" +install-info: force + $(MAKE) subdir_do DO=install-info "DODIRS=$(SUBDIRS)" +clean-info: force + $(MAKE) subdir_do DO=clean-info "DODIRS=$(SUBDIRS)" + +gdb.z:gdb.1 + nroff -man $(srcdir)/gdb.1 | col -b > gdb.t + pack gdb.t ; rm -f gdb.t + mv gdb.t.z gdb.z + +install: gdb + $(INSTALL_PROGRAM) gdb $(bindir)/$(program_prefix)gdb + $(INSTALL_DATA) $(srcdir)/gdb.1 $(man1dir)/$(program_prefix)gdb.1 + $(M_INSTALL) + $(MAKE) subdir_do DO=install "DODIRS=$(SUBDIRS)" + +init.c: $(srcdir)/munch $(OBS) $(TSOBS) + $(srcdir)/munch ${MUNCH_DEFINE} $(OBS) $(TSOBS) > init.c + +gdb: $(OBS) $(TSOBS) ${ADD_DEPS} ${CDEPS} init.o + ${CC-LD} $(GLOBAL_CFLAGS) $(LDFLAGS) -o gdb \ + init.o $(OBS) $(TSOBS) $(ADD_FILES) $(CLIBS) $(LOADLIBES) + +saber_gdb: $(SFILES) $(DEPFILES) copying.c version.c + #setopt load_flags $(CFLAGS) -I$(BFD_DIR) -DHOST_SYS=SUN4_SYS + #load ./init.c $(SFILES) + #unload ${srcdir}/c-exp.y ${srcdir}/m2-exp.y ${srcdir}/vx-share/*.h + #unload ${srcdir}/nindy-share/[A-Z]* + #load c-exp.tab.c m2-exp.tab.c + #load copying.c version.c + #load ../libiberty/libiberty.a + #load ../bfd/libbfd.a + #load ../readline/libreadline.a + #load ../mmalloc/libmmalloc.a + #load -ltermcap + #load `echo " "$(DEPFILES) | sed -e 's/\.o/.c/g' -e 's, , ../,g'` + echo "Load .c corresponding to:" $(DEPFILES) + + +# This is useful when debugging GDB, because some Unix's don't let you run GDB +# on itself without copying the executable. So "make gdb1" will make +# gdb and put a copy in gdb1, and you can run it with "gdb gdb1". +# Removing gdb1 before the copy is the right thing if gdb1 is open +# in another process. +gdb1: gdb + rm -f gdb1 + cp gdb gdb1 + +# This is a remote stub which runs under unix and starts up an +# inferior process. This is at least useful for debugging GDB's +# remote support. +rapp: $(RAPP_OBS) + rm -f rapp_init.c + ${srcdir}/munch ${MUNCH_DEFINE} ${RAPP_OBS} > rapp_init.c + ${CC-LD} $(LDFLAGS) -o $@ rapp_init.c $(RAPP_OBS) + +# Support for building Makefile out of configured pieces, automatically +# generated dependencies, etc. alldeps.mak is a file that contains +# "make" variable definitions for all ALLDEPFILES, ALLDEPFILES_MAINDIR, +# ALLDEPFILES_SUBDIR, ALLPARAM, and ALLCONFIG, all cadged from the current +# contents of the config subdirectory. + +alldeps.mak: ${srcdir}/config + rm -f alldeps.mak alldeps.tmp allparam.tmp allconfig.tmp + for i in `ls -d ${srcdir}/config/*.m[ht]` ; do \ + echo $$i >>allconfig.tmp; \ + awk <$$i ' \ + $$1 == "TDEPFILES=" || $$1 == "XDEPFILES=" { \ + for (i = 2; i <= NF; i++) \ + print $$i >> "alldeps.tmp" ; \ + } \ + $$1 == "TM_FILE=" || $$1 == "XM_FILE=" { \ + print $$2 >> "allparam.tmp" }' ; \ + done + sort alldeps2.tmp + echo '# Start of "alldeps.mak" definitions' \ + >>alldeps.mak; + echo 'ALLDEPFILES = $$(ALLDEPFILES_MAINDIR) $$(ALLDEPFILES_SUBDIR)' \ + >>alldeps.mak; + grep -v / alldeps2.tmp | \ + awk 'BEGIN {printf "ALLDEPFILES_MAINDIR="} \ + NR == 0 {printf $$0;} \ + NR != 0 {printf "\\\n" $$0} \ + END {printf "\n\n"}' >>alldeps.mak; + grep / alldeps2.tmp | \ + awk 'BEGIN {printf "ALLDEPFILES_SUBDIR="} \ + NR == 0 {printf $$0;} \ + NR != 0 {printf "\\\n" $$0} \ + END {printf "\n\n"}' >>alldeps.mak; + sort >alldeps.mak; + sort >alldeps.mak; + echo '# End of "alldeps.mak" definitions' \ + >>alldeps.mak; + rm -f alldeps.tmp alldeps2.tmp allparam.tmp allconfig.tmp + +# The sed script makes everything which depends on {x,t}m.h depend on +# config.status as well, in case someone reconfigures gdb out from +# under an already compiled gdb. +depend: $(SOURCES) Makefile.in + @echo Ignore errors about non-existent system-supplied include files + @echo for systems other than the one you are using. + @echo Also ignore parse errors in valops.c, and any errors in + @echo arm-convert.s. + touch xm.h tm.h + -$(GCC) -MM -nostdinc -I/usr/include $(CFLAGS) -I$(BFD_DIR) \ + $(INCLUDE_CFLAGS) `ls $(SOURCES) | grep -v '\.[hy]$$' | \ + sort -u` >depend.tmp +# If running in srcdir, translate "./foo.c" into "$srcdir/foo.c" except +# for xm.h and tm.h. This allows the same "depend" file to be used +# by the various subdirectories. + if [ "${srcdir}" = "." ] ; then \ + depend.tm2; \ + rm depend.tmp; \ + mv depend.tm2 depend.tmp; \ + fi + depend + rm depend.tmp + +config.status: + @echo "You must configure gdb. Look at the README file for details." + @false + +# These are not generated by "make depend" because they only are there +# for some machines. +# But these rules don't do what we want; we want to hack the foo.o: tm.h +# dependency to do the right thing. +tm-isi.h tm-sun3.h tm-news.h tm-hp300bsd.h tm-altos.h: tm-68k.h +tm-hp300hpux.h tm-sun2.h tm-3b1.h: tm-68k.h +xm-news1000.h: xm-news.h +xm-i386-sv32.h: xm-i386.h +tm-i386gas.h: tm-i386.h +xm-sun4os4.h: xm-sparc.h +tm-sun4os4.h: tm-sparc.h +xm-vaxult.h: xm-vax.h +xm-vaxbsd.h: xm-vax.h + +kdb: $(NTSSTART) $(OBS) $(NTSOBS) ${ADD_DEPS} ${CDEPS} + rm -f init.c + $(srcdir)/munch ${MUNCH_DEFINE} $(OBS) $(NTSOBS) > init.c + $(CC) $(LDFLAGS) -c init.c $(CLIBS) + ld -o kdb $(NTSSTART) $(OBS) $(NTSOBS) init.o $(ADD_FILES) \ + -lc $(CLIBS) + +# Put the proper machine-specific files first. +# createtags will edit the .o in DEPFILES into .c +TAGS: ${TAGFILES} + $(srcdir)/createtags $(TM_FILE) ${XM_FILE} $(DEPFILES) ${TAGFILES} +tags: TAGS + +# Making distributions of GDB and friends. + +# Make a directory `proto-gdb.dir' that contains an image of the GDB +# directory of the distribution, built up with symlinks. +make-proto-gdb.dir: force_update + $(MAKE) $(MFLAGS) -f Makefile.in setup-to-dist + $(MAKE) $(MFLAGS) -f Makefile make-proto-gdb-1 + +# Make a tar file containing the GDB directory of the distribution. +gdb.tar.Z: force_update + $(MAKE) $(MFLAGS) -f Makefile.in setup-to-dist + $(MAKE) $(MFLAGS) -f Makefile.in gdb-$(VERSION).tar.Z + +# Set up the GDB directory for distribution, by building all files that +# are products of other files. +setup-to-dist: force_update + ../configure none + rm -f alldeps.mak + $(MAKE) $(MFLAGS) alldeps.mak + ../configure none + rm -f depend + $(MAKE) $(MFLAGS) depend + ../configure none + (cd doc; $(MAKE) $(MFLAGS) gdbVN.m4) + $(MAKE) $(MFLAGS) gdb.info + $(MAKE) $(MFLAGS) refcard.ps + +# Build a tar file from a proto-gdb.dir. +gdb-$(VERSION).tar.Z: force_update + rm -f gdb.tar gdb-$(VERSION).tar.Z + $(MAKE) $(MFLAGS) -f Makefile make-proto-gdb-1 + ln -s proto-gdb.dir $(DIST) + tar chf - $(DIST) | compress >gdb-$(VERSION).tar.Z + rm -rf $(DIST) proto-gdb.dir + +# Build a proto-gdb.dir after GDB has been set up for distribution. +# This stuff must be run in `Makefile', not `Makefile.in`; we use the makefile +# built in the setup-to-dist process, since it defines things like ALLCONFIG +# and ALLDEPFILES, that we need. +make-proto-gdb-1: ${TARFILES} ${TARDIRS} gdb.info + rm -rf proto-gdb.dir + mkdir proto-gdb.dir + cd proto-gdb.dir ; for i in ${TARFILES} ; do ln -s ../$$i . ; done + cd proto-gdb.dir ; ln -s ../${INFOFILES} . + cd proto-gdb.dir ; for i in ${TARDIRS}; do \ + mkdir $$i; cd $$i; \ + ln -s ../../$$i/* .; \ + rm -rf SCCS CVS.adm RCS config.status; \ + if test -f Makefile.in; then rm Makefile; else true; fi; done + mkdir proto-gdb.dir/config + cd proto-gdb.dir/config ; \ + for i in $(ALLCONFIG) ; do ln -s ../../$$i ../$$i ; done + mkdir proto-gdb.dir/vx-share proto-gdb.dir/nindy-share + cd proto-gdb.dir/config ; \ + for i in $(SFILES_SUBDIR) $(NONSRC_SUBDIR) $(ALLDEPFILES_SUBDIR); \ + do ln -s ../../$$i ../$$i ; done + chmod og=u `find . -print` + +clean: + rm -f *.o ${ADD_FILES} *~ + rm -f init.c version.c + rm -f gdb core gdb.tar gdb.tar.Z make.log + rm -f gdb[0-9] + @$(MAKE) subdir_do DO=clean "DODIRS=$(SUBDIRS)" + +distclean: clean c-exp.tab.c m2-exp.tab.c TAGS + rm -f tm.h xm.h config.status + rm -f y.output yacc.acts yacc.tmp + rm -f ${TESTS} Makefile depend + @$(MAKE) subdir_do DO=distclean "DODIRS=$(SUBDIRS)" + +realclean: clean + rm -f c-exp.tab.c m2-exp.tab.c TAGS + rm -f tm.h xm.h config.status + rm -f Makefile depend + @$(MAKE) subdir_do DO=realclean "DODIRS=$(SUBDIRS)" + +STAGESTUFF=${OBS} ${TSOBS} ${NTSOBS} ${ADD_FILES} init.c init.o version.c gdb + +subdir_do: force + @for i in $(DODIRS); do \ + if [ -d ./$$i ] ; then \ + if (cd ./$$i; \ + $(MAKE) \ + "against=$(against)" \ + "AR=$(AR)" \ + "AR_FLAGS=$(AR_FLAGS)" \ + "CC=$(CC)" \ + "CFLAGS=$(CFLAGS)" \ + "RANLIB=$(RANLIB)" \ + "MAKEINFO=$(MAKEINFO)" \ + "INSTALL=$(INSTALL)" \ + "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \ + "INSTALL_DATA=$(INSTALL_DATA)" \ + "BISON=$(BISON)" $(DO)) ; then true ; \ + else exit 1 ; fi ; \ + else true ; fi ; \ + done -install-diff: force - @if [ -d ./diff ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./diff/; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi +Makefile: $(srcdir)/Makefile.in $(host_makefile_frag) $(target_makefile_frag) + $(SHELL) ./config.status -### grep -all-grep: force - @if [ -d ./grep ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./grep; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi +force: -clean-grep: force - @if [ -d ./grep ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./grep; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi +# Documentation! +# GDB QUICK REFERENCE (TeX dvi file, CM fonts) +refcard.dvi: $(srcdir)/doc/refcard.tex + ( cd ./doc; $(MAKE) refcard.dvi ) + mv ./doc/refcard.dvi . -install-grep: force - @if [ -d ./grep ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./grep; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi +# GDB QUICK REFERENCE (PostScript output, common PS fonts) +refcard.ps: $(srcdir)/doc/refcard.tex + ( cd ./doc; $(MAKE) refcard.ps ) + mv ./doc/refcard.ps . -### rcs -all-rcs: force - @if [ -d ./rcs ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./rcs; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi +# GDB MANUAL: TeX dvi file +gdb.dvi: ./doc/gdb-all.texi + ( cd ./doc; $(MAKE) M4=$(M4) gdb.dvi ) + mv ./doc/gdb.dvi . -clean-rcs: force - @if [ -d ./rcs ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./rcs; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi +# GDB MANUAL: info file +gdb.info: ./doc/gdb-all.texi + ( cd ./doc; $(MAKE) M4=$(M4) gdb.info ) + mv ./doc/gdb.info* . -install-rcs: force - @if [ -d ./rcs ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./rcs; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi +./doc/gdb-all.texi: + (cd $(srcdir)/doc; $(MAKE) M4=$(M4) gdb-all.texi) -### cvs -all-cvs: force - @if [ -d ./cvs ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./cvs; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi +# Make copying.c from COPYING +copying.c: ${srcdir}/COPYING ${srcdir}/copying.awk + awk -f ${srcdir}/copying.awk < ${srcdir}/COPYING > copying.c -clean-cvs: force - @if [ -d ./cvs ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./cvs; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi +version.c: Makefile + echo 'char *version = "$(VERSION)";' >version.c -install-cvs: force - @if [ -d ./cvs ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./cvs; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi +# c-exp.tab.c is generated in target dir from c-exp.y if it doesn't exist +# in srcdir, then compiled in target dir to c-exp.tab.o. +c-exp.tab.o: c-exp.tab.c +c-exp.tab.c: $(srcdir)/c-exp.y + @echo 'Expect 4 shift/reduce conflicts.' + ${YACC} $(srcdir)/c-exp.y + -mv y.tab.c c-exp.tab.c -### patch -all-patch: force - @if [ -d ./patch ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./patch; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi +# m2-exp.tab.c is generated in target dir from m2-exp.y if it doesn't exist +# in srcdir, then compiled in target dir to m2-exp.tab.o. +m2-exp.tab.o: m2-exp.tab.c +m2-exp.tab.c: $(srcdir)/m2-exp.y + ${YACC} $(srcdir)/m2-exp.y + -mv y.tab.c m2-exp.tab.c -clean-patch: force - @if [ -d ./patch ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./patch; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi +# The symbol-file readers have dependencies on BFD header files. +dbxread.o: ${srcdir}/dbxread.c + ${CC} -c ${INTERNAL_CFLAGS} -I$(BFD_DIR) ${srcdir}/dbxread.c -install-patch: force - @if [ -d ./patch ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./patch; \ - $(MAKE) $(FLAGS_TO_PASS) \ - bindir=$(bindir) \ - man1dir=$(man1dir) install) ; \ - else \ - true ; \ - fi +coffread.o: ${srcdir}/coffread.c + ${CC} -c ${INTERNAL_CFLAGS} -I$(BFD_DIR) ${srcdir}/coffread.c -### emacs -all-emacs: force - @if [ -d ./emacs ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./emacs; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi +mipsread.o: ${srcdir}/mipsread.c + ${CC} -c ${INTERNAL_CFLAGS} -I$(BFD_DIR) ${srcdir}/mipsread.c -clean-emacs: force - @if [ -d ./emacs ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./emacs; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi +elfread.o: ${srcdir}/elfread.c + ${CC} -c ${INTERNAL_CFLAGS} -I$(BFD_DIR) ${srcdir}/elfread.c -install-emacs: force - @if [ -d ./emacs ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./emacs; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi +dwarfread.o: ${srcdir}/dwarfread.c + ${CC} -c ${INTERNAL_CFLAGS} -I$(BFD_DIR) ${srcdir}/dwarfread.c -### ispell -all-ispell: all-emacs - @if [ -d ./ispell ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./ispell; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi +xcoffread.o: ${srcdir}/xcoffread.c + ${CC} -c ${INTERNAL_CFLAGS} -I$(BFD_DIR) ${srcdir}/xcoffread.c -clean-ispell: force - @if [ -d ./ispell ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./ispell; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi +xcoffexec.o: ${srcdir}/xcoffexec.c + ${CC} -c ${INTERNAL_CFLAGS} -I$(BFD_DIR) ${srcdir}/xcoffexec.c -install-ispell: force - @if [ -d ./ispell ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./ispell; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi +# Drag in the files that are in another directory. -### send_pr -all-send_pr: force - @if [ -d ./send_pr ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./send_pr; \ - $(MAKE) $(FLAGS_TO_PASS) all) ; \ - else \ - true ; \ - fi +xdr_ld.o: ${srcdir}/vx-share/xdr_ld.c + ${CC} -c ${INTERNAL_CFLAGS} ${srcdir}/vx-share/xdr_ld.c -clean-send_pr: force - @if [ -d ./send_pr ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./send_pr; \ - $(MAKE) $(FLAGS_TO_PASS) clean) ; \ - else \ - true ; \ - fi +xdr_ptrace.o: ${srcdir}/vx-share/xdr_ptrace.c + ${CC} -c ${INTERNAL_CFLAGS} ${srcdir}/vx-share/xdr_ptrace.c -install-send_pr: force - @if [ -d ./send_pr ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./send_pr; \ - $(MAKE) $(FLAGS_TO_PASS) install) ; \ - else \ - true ; \ - fi +xdr_rdb.o: ${srcdir}/vx-share/xdr_rdb.c + ${CC} -c ${INTERNAL_CFLAGS} ${srcdir}/vx-share/xdr_rdb.c -### libg++ +xdr_regs.o: ${srcdir}/vx-share/xdr_regs.c + ${CC} -c ${INTERNAL_CFLAGS} ${srcdir}/vx-share/xdr_regs.c -all-libg++: all-gas all-ld all-gcc - @if [ -d ./libg++ ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./libg++; \ - $(MAKE) $(FLAGS_TO_PASS) "CC=${GXX}" all) ; \ - else \ - true ; \ - fi +nindy.o: ${srcdir}/nindy-share/nindy.c + ${CC} -c ${INTERNAL_CFLAGS} ${srcdir}/nindy-share/nindy.c -clean-libg++: force - @if [ -d ./libg++ ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./libg++; \ - $(MAKE) $(FLAGS_TO_PASS) "CC=${GXX}" clean) ; \ - else \ - true ; \ - fi +Onindy.o: ${srcdir}/nindy-share/Onindy.c + ${CC} -c ${INTERNAL_CFLAGS} ${srcdir}/nindy-share/Onindy.c -install-libg++: force - @if [ -d ./libg++ ] ; then \ - rootme=`pwd` ; export rootme ; \ - (cd ./libg++; \ - $(MAKE) $(FLAGS_TO_PASS) "CC=${GXX}" install) ; \ - else \ - true ; \ - fi +ttybreak.o: ${srcdir}/nindy-share/ttybreak.c + ${CC} -c ${INTERNAL_CFLAGS} ${srcdir}/nindy-share/ttybreak.c -### other supporting targets -# this is a bad hack. -all.xclib: all.normal - if [ -d clib ] ; then \ - (cd clib ; $(MAKE) $(FLAGS_TO_PASS)) ; \ - fi +ttyflush.o: ${srcdir}/nindy-share/ttyflush.c + ${CC} -c ${INTERNAL_CFLAGS} ${srcdir}/nindy-share/ttyflush.c -subdir_do: - @for i in $(DODIRS); do \ - if [ -f ./$$i/localenv ] ; then \ - if (rootme=`pwd` ; export rootme ; cd ./$$i; \ - $(MAKE) $(FLAGS_TO_PASS) $(DO)) ; then true ; \ - else exit 1 ; fi ; \ - else if [ -d ./$$i ] ; then \ - if (rootme=`pwd` ; export rootme ; cd ./$$i; \ - $(MAKE) $(FLAGS_TO_PASS) $(DO)) ; then true ; \ - else exit 1 ; fi ; \ - else true ; fi ; \ - fi ; \ - done +lint: $(LINTFILES) + $(LINT) $(INCLUDE_CFLAGS) $(LINTFLAGS) $(LINTFILES) \ + `echo ${DEPFILES} | sed 's/\.o /\.c /g' -# The "else true" stuff is for Ultrix; the shell returns the exit code -# of the "if" command, if no commands are run in the "then" or "else" part, -# causing Make to quit. - -MAKEDIRS= \ - $(prefix) \ - $(exec_prefix) \ - $(bindir) \ - $(libdir) \ - $(tooldir) \ - $(includedir) \ - $(datadir) \ - $(docdir) \ - $(mandir) \ - $(man1dir) \ - $(man5dir) - -# $(man2dir) \ -# $(man3dir) \ -# $(man4dir) \ -# $(man6dir) \ -# $(man7dir) \ -# $(man8dir) - -install-dirs: - for i in $(MAKEDIRS) ; do \ - echo Making $$i... ; \ - [ -d $$i ] || mkdir $$i || exit 1 ; \ - done +gdb.cxref: $(SFILES) + cxref -I. $(SFILES) >gdb.cxref -MAKEINFODIRS= \ - $(prefix) \ - $(infodir) - -install-info-dirs: - if [ -d $(prefix) ] ; then true ; else mkdir $(prefix) ; fi - if [ -d $(datadir) ] ; then true ; else mkdir $(datadir) ; fi - if [ -d $(infodir) ] ; then true ; else mkdir $(infodir) ; fi - -dir.info: - $(srcdir)/texinfo/gen-info-dir $(infodir) > dir.info.new - mv -f dir.info.new dir.info - -etags tags: TAGS - -TAGS: - etags `$(MAKE) ls` - -ls: - @echo Makefile - @for i in $(SUBDIRS); \ - do \ - (cd $$i; \ - pwd=`pwd`; \ - wd=`basename $$pwd`; \ - for j in `$(MAKE) ls`; \ - do \ - echo $$wd/$$j; \ - done) \ - done +force_update: -force: +# Generate the demangler linked in with gdb. Also create a standalone +# demangler if so desired ("make demangle"). -# with the gnu make, this is done automatically. +${DEMANGLER}.o: ${DEMANGLER}.c + ${CC} -c ${INTERNAL_CFLAGS} ${DEMANGLE_OPTS} \ + `echo ${srcdir}/${DEMANGLER}.c | sed 's,^\./,,'` -Makefile: $(srcdir)/Makefile.in $(host_makefile_frag) $(target_makefile_frag) - $(SHELL) ./config.status +demangle: ${DEMANGLER}.c + ${CC} -o $@ -DMAIN ${INTERNAL_CFLAGS} ${DEMANGLE_OPTS} \ + `echo ${srcdir}/${DEMANGLER}.c | sed 's,^\./,,'` -# -# Build GDB distributions that contain BFD, Include, Libiberty, Readline, etc - -DEVO_SUPPORT= README cfg-paper.texi Makefile.in configure configure.in \ - config.sub config configure.man -GDB_SUPPORT_DIRS= bfd include libiberty mmalloc readline glob -GDB_SUPPORT_FILES= $(GDB_SUPPORT_DIRS) texinfo/fsf/texinfo.tex - -setup-dirs: force_update - ./configure sun4 - make clean - ./configure -rm sun4 - chmod og=u `find $(DEVO_SUPPORT) $(GDB_SUPPORT_FILES) -print` - -bfd.ilrt.tar.Z: setup-dirs - rm -f bfd.ilrt.tar.Z - tar cf - $(DEVO_SUPPORT) $(GDB_SUPPORT_FILES) \ - | compress -v >bfd.ilrt.tar.Z - -gdb.tar.Z: setup-dirs - (cd gdb; $(MAKE) -f Makefile.in make-proto-gdb.dir) - $(MAKE) $(MFLAGS) -f Makefile.in make-gdb.tar.Z - -make-gdb.tar.Z: $(DEVO_SUPPORT) $(GDB_SUPPORT_DIRS) gdb texinfo/fsf/texinfo.tex - rm -rf proto-toplev; mkdir proto-toplev - ln -s ../gdb/proto-gdb.dir proto-toplev/gdb - (cd proto-toplev; for i in $(DEVO_SUPPORT) $(GDB_SUPPORT_DIRS); do \ - ln -s ../$$i . ; \ - done) - # Put only one copy (four hard links) of COPYING in the tar file. - rm proto-toplev/bfd/COPYING - ln proto-toplev/gdb/COPYING proto-toplev/bfd/COPYING - rm proto-toplev/include/COPYING - ln proto-toplev/gdb/COPYING proto-toplev/include/COPYING - rm proto-toplev/readline/COPYING - ln proto-toplev/gdb/COPYING proto-toplev/readline/COPYING - # Take out texinfo from configurable dirs - rm proto-toplev/configure.in - sed '/^configdirs=/s/texinfo //' proto-toplev/configure.in - # Take out glob from buildable dirs - rm proto-toplev/Makefile.in - - sed -e '/^SUBDIRS =/s/glob //' \ - -e '/^all\.normal: /s/\all-texinfo //' \ - -e '/^clean: /s/clean-texinfo //' \ - -e '/^install\.all: /s/install-texinfo //' \ - proto-toplev/Makefile.in - - rm temp.$$ temp1.$$ - mkdir proto-toplev/texinfo - mkdir proto-toplev/texinfo/fsf - ln -s ../../../texinfo/fsf/texinfo.tex proto-toplev/texinfo/fsf/ - chmod og=u `find proto-toplev -print` - (VER=`sed Making gdb-$$VER.tar.Z"; \ - ln -s proto-toplev gdb-$$VER; \ - tar cfh - gdb-$$VER \ - | compress -v >gdb-$$VER.tar.Z) +# GNU Make has an annoying habit of putting *all* the Makefile variables +# into the environment, unless you include this target as a circumvention. +# Rumor is that this will be fixed (and this target can be removed) +# in GNU Make 4.0. +.NOEXPORT: -force_update: +# This is the end of "Makefile.in". When built into "Makefile" +# by the configure script, two things are added below this point: +# alldeps.mak -- defintions of all files that are used in +# host- or target-dependent configurations +# depend -- what .o files depend on what .c and .h files, +# for all configurations. -nothing: -# end of Makefile.in -- 2.30.2