Annotation of gcc/Makefile.in, revision 1.1.1.7

1.1       root        1: # Makefile for GNU C compiler.
1.1.1.7 ! root        2: #   Copyright (C) 1987, 88, 90, 91, 92, 93, 1994 Free Software Foundation, Inc.
1.1       root        3: 
                      4: #This file is part of GNU CC.
                      5: 
                      6: #GNU CC is free software; you can redistribute it and/or modify
                      7: #it under the terms of the GNU General Public License as published by
                      8: #the Free Software Foundation; either version 2, or (at your option)
                      9: #any later version.
                     10: 
                     11: #GNU CC is distributed in the hope that it will be useful,
                     12: #but WITHOUT ANY WARRANTY; without even the implied warranty of
                     13: #MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
                     14: #GNU General Public License for more details.
                     15: 
                     16: #You should have received a copy of the GNU General Public License
                     17: #along with GNU CC; see the file COPYING.  If not, write to
                     18: #the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
                     19: 
                     20: # The targets for external use include:
                     21: # all, doc, proto, install, install-cross, install-cross-rest,
1.1.1.2   root       22: # uninstall, TAGS, mostlyclean, clean, distclean, realclean,
1.1       root       23: # stage1, stage2, stage3, stage4.
                     24: 
1.1.1.2   root       25: # Suppress smart makes who think they know how to automake Yacc files
                     26: .y.c:
                     27: 
1.1       root       28: # Variables that exist for you to override.
                     29: # See below for how to change them for certain systems.
                     30: 
1.1.1.7 ! root       31: # List of language subdirectories.
        !            32: # This is overridden by configure.
        !            33: SUBDIRS =
        !            34: 
1.1       root       35: # Selection of languages to be made.
1.1.1.7 ! root       36: # This is overridden by configure.
        !            37: LANGUAGES = c objective-c proto
1.1       root       38: 
                     39: ALLOCA =
1.1.1.4   root       40: ALLOCA_FLAGS =
                     41: ALLOCA_FINISH = true
1.1       root       42: 
                     43: # Various ways of specifying flags for compilations:  
                     44: # CFLAGS is for the user to override to, e.g., do a bootstrap with -O2.
                     45: # BOOT_CFLAGS is the value of CFLAGS to pass
                     46: # to the stage2 and stage3 compilations
                     47: # XCFLAGS is used for most compilations but not when using the GCC just built.
                     48: XCFLAGS =
                     49: CFLAGS = -g
                     50: BOOT_CFLAGS = -O $(CFLAGS)
                     51: # These exists to be overridden by the x-* and t-* files, respectively.
                     52: X_CFLAGS =
                     53: T_CFLAGS =
                     54: 
                     55: X_CPPFLAGS =
                     56: T_CPPFLAGS =
                     57: 
                     58: CC = cc
                     59: BISON = bison
                     60: BISONFLAGS =
1.1.1.7 ! root       61: LEX = flex
        !            62: LEXFLAGS =
1.1       root       63: AR = ar
                     64: OLDAR_FLAGS = qc
                     65: AR_FLAGS = rc
                     66: SHELL = /bin/sh
                     67: # on sysV, define this as cp.
                     68: INSTALL = install -c
                     69: # These permit overriding just for certain files.
                     70: INSTALL_PROGRAM = $(INSTALL)
                     71: INSTALL_DATA = $(INSTALL)
                     72: SYMLINK = ln -s
1.1.1.5   root       73: MAKEINFO = makeinfo
                     74: TEXI2DVI = texi2dvi
1.1.1.7 ! root       75: # For GNUmake: let us decide what gets passed to recursive makes.
        !            76: MAKEOVERRIDES =
1.1       root       77: 
                     78: # Define this as & to perform parallel make on a Sequent.
                     79: # Note that this has some bugs, and it seems currently necessary 
                     80: # to compile all the gen* files first by hand to avoid erroneous results.
                     81: P =
                     82: 
                     83: # How to invoke ranlib.
                     84: RANLIB = ranlib
                     85: # Test to use to see whether ranlib exists on the system.
                     86: RANLIB_TEST = [ -f /usr/bin/ranlib -o -f /bin/ranlib ]
                     87: 
                     88: # Compiler to use for compiling libgcc1.a.
                     89: # OLDCC should not be the GNU C compiler,
                     90: # since that would compile typical libgcc1.a functions such as mulsi3
                     91: # into infinite recursions.
                     92: OLDCC = cc
                     93: 
                     94: # CFLAGS for use with OLDCC, for compiling libgcc1.a.
                     95: # NOTE: -O does not work on some Unix systems!
                     96: CCLIBFLAGS = -O
                     97: 
1.1.1.2   root       98: # Version of ar to use when compiling libgcc1.a.
1.1       root       99: OLDAR = ar
                    100: 
1.1.1.5   root      101: # Target to use when installing include directory.  Either
                    102: # install-headers-tar or install-headers-cpio.
                    103: INSTALL_HEADERS_DIR = install-headers-tar
                    104: 
1.1.1.4   root      105: # The GCC to use for compiling libgcc2.a, enquire, and cross-test.
                    106: # Usually the one we just built.
1.1       root      107: # Don't use this as a dependency--use $(GCC_PASSES) or $(GCC_PARTS).
1.1.1.4   root      108: GCC_FOR_TARGET = ./xgcc -B./
1.1       root      109: 
                    110: # This is used instead of ALL_CFLAGS when compiling with GCC_FOR_TARGET.
                    111: # It omits XCFLAGS, and specifies -B./.
1.1.1.7 ! root      112: # It also specifies -I./include to find, e.g., stddef.h.
        !           113: GCC_CFLAGS=$(INTERNAL_CFLAGS) $(X_CFLAGS) $(T_CFLAGS) $(CFLAGS) -I./include
1.1       root      114: 
                    115: # Special flags for compiling enquire.
                    116: # We disable optimization to make floating point more reliable.
1.1.1.7 ! root      117: ENQUIRE_CFLAGS = -DNO_MEM -DNO_LONG_DOUBLE_IO -O0
1.1       root      118: ENQUIRE_LDFLAGS = $(LDFLAGS)
                    119: 
                    120: # Tools to use when building a cross-compiler.
                    121: # These are used because `configure' appends `cross-make'
                    122: # to the makefile when making a cross-compiler.
                    123: 
                    124: TARGET_TOOLPREFIX = $(tooldir)/bin/
                    125: AR_FOR_TARGET = $(TARGET_TOOLPREFIX)ar
                    126: AR_FOR_TARGET_FLAGS = rc
                    127: RANLIB_FOR_TARGET = $(TARGET_TOOLPREFIX)ranlib
                    128: RANLIB_TEST_FOR_TARGET = [ -f $(TARGET_TOOLPREFIX)ranlib ]
                    129: 
1.1.1.4   root      130: # Dir to search for system headers.  Overridden by cross-make.
                    131: SYSTEM_HEADER_DIR = /usr/include
                    132: 
1.1.1.6   root      133: # Control whether to run fixproto.
                    134: STMP_FIXPROTO = stmp-fixproto
                    135: 
1.1.1.3   root      136: # There may be a premade insn-attrtab.c for this machine.
                    137: # (You could rebuild it with genattrtab as usual, but it takes a long time.)
                    138: # PREMADE_ATTRTAB is the file name of the file to use.
                    139: # PREMADE_ATTRTAB_MD is the md file it corresponds to.
                    140: PREMADE_ATTRTAB_MD = Makefile  # Guaranteed not to cmp equal to md.
                    141: PREMADE_ATTRTAB = 
                    142: 
1.1       root      143: target= ... `configure' substitutes actual target name here.
                    144: xmake_file= ... `configure' substitutes actual x- file name here.
                    145: tmake_file= ... `configure' substitutes actual t- file name here.
1.1.1.4   root      146: version=`sed -e 's/.*\"\([^ \"]*\)[ \"].*/\1/' < $(srcdir)/version.c`
1.1.1.6   root      147: mainversion=`sed -e 's/.*\"\([0-9]*\.[0-9]*\).*/\1/' < $(srcdir)/version.c`
1.1       root      148: 
                    149: # Directory where sources are, from where we are.
                    150: srcdir = .
                    151: # Common prefix for installation directories.
                    152: # NOTE: This directory must exist when you start installation.
                    153: prefix = /usr/local
1.1.1.5   root      154: # Directory in which to put localized header files. On the systems with
                    155: # gcc as the native cc, `local_prefix' may not be `prefix' which is
                    156: # `/usr'.
                    157: # NOTE: local_prefix *should not* default from prefix.
                    158: local_prefix = /usr/local
1.1.1.2   root      159: # Directory in which to put host dependent programs and libraries
                    160: exec_prefix = $(prefix)
1.1       root      161: # Directory in which to put the executable for the command `gcc'
1.1.1.2   root      162: bindir = $(exec_prefix)/bin
1.1       root      163: # Directory in which to put the directories used by the compiler.
1.1.1.2   root      164: libdir = $(exec_prefix)/lib
1.1       root      165: # Directory in which the compiler finds executables, libraries, etc.
1.1.1.2   root      166: libsubdir = $(libdir)/gcc-lib/$(target)/$(version)
1.1.1.7 ! root      167: # Directory in which the compiler finds g++ includes.
        !           168: gxx_include_dir= $(libdir)/g++-include
1.1.1.5   root      169: # Directory to search for site-specific includes.
                    170: includedir = $(local_prefix)/include
1.1.1.4   root      171: # assertdir is overridden in cross-make.
1.1.1.5   root      172: # (But this currently agrees with what is in cross-make.)
                    173: assertdir = $(tooldir)/include
                    174: # where the info files go
                    175: infodir = $(prefix)/info
1.1       root      176: # Extension (if any) to put in installed man-page filename.
                    177: manext = .1
                    178: # Directory in which to put man pages.
                    179: mandir = $(prefix)/man/man1
                    180: # Directory in which to find other cross-compilation tools and headers.
                    181: # Used in install-cross.
1.1.1.5   root      182: tooldir = $(exec_prefix)/$(target)
1.1.1.4   root      183: # Dir for temp files.
                    184: tmpdir = /tmp
1.1       root      185: 
                    186: # Additional system libraries to link with.
                    187: CLIB=
                    188: 
                    189: # Change this to a null string if obstacks are installed in the
                    190: # system library.
                    191: OBSTACK=obstack.o
                    192: 
1.1.1.6   root      193: # Specify the rule for actually making libgcc.a,
                    194: LIBGCC = libgcc.a
                    195: # and the rule for installing it.
                    196: INSTALL_LIBGCC = install-libgcc
                    197: 
1.1       root      198: # Specify the rule for actually making libgcc1.a.
1.1.1.2   root      199: # The value may be empty; that means to do absolutely nothing
                    200: # with or for libgcc1.a.
1.1       root      201: LIBGCC1 = libgcc1.a
                    202: 
1.1.1.6   root      203: # Specify the rule for making libgcc1.a for a cross-compiler.
                    204: # The default rule assumes that libgcc1.a is supplied by the user.
                    205: CROSS_LIBGCC1 = libgcc1.cross
                    206: 
1.1       root      207: # Specify the rule for actually making libgcc2.a.
                    208: LIBGCC2 = libgcc2.a
                    209: 
                    210: # Options to use when compiling libgcc2.a.
                    211: # -g1 causes output of debug info only for file-scope entities.
                    212: # we use this here because that should be enough, and also
                    213: # so that -g1 will be tested.
1.1.1.5   root      214: LIBGCC2_CFLAGS = -O2 $(LIBGCC2_INCLUDES) $(GCC_CFLAGS) -g1
                    215: 
                    216: # Additional options to use when compiling libgcc2.a.
                    217: # Some targets override this to -Iinclude
                    218: LIBGCC2_INCLUDES =
                    219: 
                    220: # Things which must be built before building libgcc2.a.
                    221: # Some targets override this to stmp-int-hdrs
                    222: LIBGCC2_DEPS =
1.1       root      223: 
1.1.1.6   root      224: # Enquire target (This is a variable so that a target can choose not to
                    225: # build it.)
                    226: ENQUIRE = enquire
                    227: 
                    228: # Cross-test target (must also be overridable for a target)
                    229: CROSS_TEST = cross-test
                    230: 
1.1       root      231: # List of extra executables that should be compiled for this target machine
                    232: # that are used for compiling from source code to object code.
                    233: # The rules for compiling them should be in the t-* file for the machine.
                    234: EXTRA_PASSES =
                    235: 
1.1.1.2   root      236: # Like EXTRA_PASSES, but these are used when linking.
                    237: EXTRA_PROGRAMS = 
                    238: 
                    239: # List of extra object files that should be compiled for this target machine.
1.1       root      240: # The rules for compiling them should be in the t-* file for the machine.
                    241: EXTRA_PARTS =
                    242: 
                    243: # List of extra object files that should be compiled and linked with
                    244: # compiler proper (cc1, cc1obj, cc1plus).
                    245: EXTRA_OBJS =
                    246: 
1.1.1.3   root      247: # List of additional header files to install.
                    248: # Often this is edited directly by `configure'.
                    249: EXTRA_HEADERS =
                    250: 
                    251: # Set this to `ld' to enable use of collect2.
                    252: # USE_COLLECT2 =
                    253: # It is convenient for configure to add the assignment at the beginning,
                    254: # so don't override it here.
                    255: 
1.1       root      256: # List of extra C and assembler files to add to libgcc1.a.
                    257: # Assembler files should have names ending in `.asm'.
                    258: LIB1FUNCS_EXTRA = 
                    259: 
                    260: # List of extra C and assembler files to add to libgcc2.a.
                    261: # Assembler files should have names ending in `.asm'.
                    262: LIB2FUNCS_EXTRA = 
                    263: 
1.1.1.5   root      264: # Default float.h source to use for cross-compiler.
                    265: CROSS_FLOAT_H=float.h-cross
                    266: 
1.1       root      267: # Program to convert libraries.
                    268: LIBCONVERT = 
                    269: 
                    270: # Control whether header files are installed.
                    271: INSTALL_HEADERS=install-headers
                    272: 
1.1.1.5   root      273: # Options for tar when copying trees.  So HPUX can override it.
                    274: TAROUTOPTS = xpBf
                    275: 
1.1       root      276: # Select which version of fixincludes to use (I.E. regular versus SVR4)
1.1.1.5   root      277: # This value is overridden directly by configure.
1.1       root      278: FIXINCLUDES=fixincludes
                    279: 
1.1.1.4   root      280: # Additional directories of header files to run fixincludes on.
1.1.1.5   root      281: # These should be directories searched automatically by default
                    282: # just as /usr/include is.
                    283: # *Do not* use this for directories that happen to contain 
                    284: # header files, but are not searched automatically by default.
1.1.1.4   root      285: # On most systems, this is empty.
                    286: OTHER_FIXINCLUDES_DIRS=
                    287: 
                    288: # List of things which should already be built whenever we try to use xgcc
1.1       root      289: # to compile anything (without linking).
1.1.1.4   root      290: GCC_PASSES=xgcc cc1 cpp $(EXTRA_PASSES)
1.1       root      291: 
1.1.1.4   root      292: # List of things which should already be built whenever we try to use xgcc
1.1       root      293: # to link anything.
1.1.1.6   root      294: GCC_PARTS=$(GCC_PASSES) $(LIBGCC) $(EXTRA_PROGRAMS) $(USE_COLLECT2) $(EXTRA_PARTS)
1.1       root      295: 
                    296: # Directory to link to, when using the target `maketest'.
                    297: DIR = ../gcc
                    298: 
1.1.1.6   root      299: # Guaranteed to not exist when not passing md through cpp.
1.1.1.7 ! root      300: # This value is overridden directly by configure.
1.1.1.6   root      301: MD_FILE = md-cpp-not-used
                    302: 
1.1       root      303: # Flags to use when cross-building GCC.
                    304: # Prefix to apply to names of object files when using them
                    305: # to run on the machine we are compiling on.
                    306: HOST_PREFIX=
                    307: # Prefix to apply to names of object files when compiling them
                    308: # to run on the machine we are compiling on.
                    309: # The default for this variable is chosen to keep these rules 
                    310: # out of the way of the other rules for compiling the same source files.
                    311: HOST_PREFIX_1=loser-
                    312: HOST_CC=$(CC)
                    313: HOST_CFLAGS=$(ALL_CFLAGS)
                    314: HOST_CLIB=$(CLIB)
                    315: HOST_LDFLAGS=$(LDFLAGS)
                    316: HOST_CPPFLAGS=$(ALL_CPPFLAGS)
                    317: HOST_ALLOCA=$(ALLOCA)
                    318: HOST_MALLOC=$(MALLOC)
                    319: HOST_OBSTACK=$(OBSTACK)
                    320: 
                    321: # Choose the real default target.
                    322: ALL=all.internal
                    323: 
                    324: # Choose the real install target.
1.1.1.5   root      325: INSTALL_TARGET=install-normal
                    326: 
                    327: # Source for float.h.  Overridden by cross-make.
                    328: FLOAT_H=float.h-nat
1.1       root      329: 
1.1.1.7 ! root      330: # Extra symbols for fixproto to define when parsing headers.
        !           331: FIXPROTO_DEFINES = 
        !           332: 
1.1       root      333: # End of variables for you to override.
                    334: 
                    335: # Definition of `all' is here so that new rules inserted by sed
                    336: # do not specify the default target.
                    337: # The real definition is under `all.internal' (for native compilers)
                    338: # or `all.cross' (for cross compilers).
1.1.1.2   root      339: all: all.indirect
1.1       root      340: 
1.1.1.3   root      341: # This tells GNU Make version 3 not to put all variables in the environment.
                    342: .NOEXPORT:
                    343: 
1.1       root      344: # sed inserts variable overrides after the following line.
1.1.1.4   root      345: ####target overrides
                    346: ####host overrides
                    347: ####cross overrides
                    348: ####build overrides
1.1       root      349: 
                    350: # Now figure out from those variables how to compile and link.
                    351: 
1.1.1.2   root      352: all.indirect: $(ALL)
                    353: 
1.1.1.7 ! root      354: # IN_GCC tells obstack.h that we are using gcc's <stddef.h> file.
        !           355: # ??? IN_GCC should be obsolete now.
1.1.1.4   root      356: INTERNAL_CFLAGS = $(CROSS) -DIN_GCC
1.1       root      357: 
                    358: # This is the variable actually used when we compile.
                    359: ALL_CFLAGS = $(INTERNAL_CFLAGS) $(X_CFLAGS) $(T_CFLAGS) $(CFLAGS) $(XCFLAGS)
                    360: 
                    361: # Likewise.
                    362: ALL_CPPFLAGS = $(CPPFLAGS) $(X_CPPFLAGS) $(T_CPPFLAGS)
                    363: 
                    364: # Even if ALLOCA is set, don't use it if compiling with GCC.
1.1.1.7 ! root      365: USE_ALLOCA= ` case "${CC}" in "${OLDCC}") echo "${ALLOCA}" ;; esac `
1.1.1.2   root      366: USE_HOST_ALLOCA= ` case "${HOST_CC}"@"${HOST_ALLOCA}" in "${OLDCC}"@?*) echo ${HOST_PREFIX}${HOST_ALLOCA} ;; esac `
                    367: USE_HOST_MALLOC= ` case "${HOST_MALLOC}" in ?*) echo ${HOST_PREFIX}${HOST_MALLOC} ;; esac `
                    368: USE_HOST_OBSTACK= ` case "${HOST_OBSTACK}" in ?*) echo ${HOST_PREFIX}${HOST_OBSTACK} ;; esac `
1.1       root      369: 
                    370: # Dependency on obstack, alloca, malloc or whatever library facilities
                    371: # are not installed in the system libraries.
                    372: # We don't use USE_ALLOCA because backquote expansion doesn't work in deps.
                    373: LIBDEPS= $(OBSTACK) $(ALLOCA) $(MALLOC)
                    374: 
                    375: # Likewise, for use in the tools that must run on this machine
                    376: # even if we are cross-building GCC.
                    377: # We don't use USE_ALLOCA because backquote expansion doesn't work in deps.
                    378: HOST_LIBDEPS= $(HOST_PREFIX)$(HOST_OBSTACK) $(HOST_PREFIX)$(HOST_ALLOCA) $(HOST_PREFIX)$(HOST_MALLOC)
                    379: 
                    380: # How to link with both our special library facilities
                    381: # and the system's installed libraries.
                    382: LIBS = $(OBSTACK) $(USE_ALLOCA) $(MALLOC) $(CLIB)
                    383: 
                    384: # Likewise, for use in the tools that must run on this machine
                    385: # even if we are cross-building GCC.
                    386: HOST_LIBS = $(USE_HOST_OBSTACK) $(USE_HOST_ALLOCA) $(USE_HOST_MALLOC)  \
                    387:            $(HOST_CLIB)
                    388: 
                    389: HOST_RTL = $(HOST_PREFIX)rtl.o
                    390: HOST_RTLANAL = $(HOST_PREFIX)rtlanal.o
1.1.1.3   root      391: HOST_PRINT = $(HOST_PREFIX)print-rtl.o
1.1       root      392: 
                    393: # Specify the directories to be searched for header files.
                    394: # Both . and srcdir are used, in that order,
                    395: # so that tm.h and config.h will be found in the compilation
                    396: # subdirectory rather than in the source directory.
                    397: INCLUDES = -I. -I$(srcdir) -I$(srcdir)/config
                    398: 
                    399: # Always use -I$(srcdir)/config when compiling.
                    400: .c.o:
                    401:        $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) $<
                    402: 
                    403: # This tells GNU make version 3 not to export all the variables
                    404: # defined in this file into the environment.
                    405: .NOEXPORT:
                    406: 
1.1.1.7 ! root      407: # Support for additional languages (other than c and objc).
        !           408: # ??? objc can be supported this way too (leave for later).
        !           409: 
        !           410: # These next lines are overridden by configure.
        !           411: LANG_MAKEFILES =
        !           412: LANG_STAGESTUFF =
        !           413: LANG_DIFF_EXCLUDES =
        !           414: 
        !           415: # Flags to pass to recursive makes.
        !           416: # CC is set by configure.  Hosts without symlinks need special handling
        !           417: # because we need CC="stage1/xgcc -Bstage1/" to work in the language
        !           418: # subdirectories.
        !           419: # ??? The choices here will need some experimenting with.
        !           420: FLAGS_TO_PASS = \
        !           421:        "AR_FLAGS=$(AR_FLAGS)" \
        !           422:        "AR_FOR_TARGET=$(AR_FOR_TARGET)" \
        !           423:        "BISON=$(BISON)" \
        !           424:        "BISONFLAGS=$(BISONFLAGS)" \
        !           425:        "CC=set-by-configure" \
        !           426:        "CFLAGS=$(CFLAGS)" \
        !           427:        "GCC_FOR_TARGET=$(GCC_FOR_TARGET)" \
        !           428:        "LDFLAGS=$(LDFLAGS)" \
        !           429:        "LEX=$(LEX)" \
        !           430:        "LEXFLAGS=$(LEXFLAGS)" \
        !           431:        "MAKEINFO=$(MAKEINFO)" \
        !           432:        "MAKEINFOFLAGS=$(MAKEINFOFLAGS)" \
        !           433:        "RANLIB_FOR_TARGET=$(RANLIB_FOR_TARGET)" \
        !           434:        "RANLIB_TEST_FOR_TARGET=$(RANLIB_TEST_FOR_TARGET)" \
        !           435:        "SHELL=$(SHELL)" \
        !           436:        "exec_prefix=$(exec_prefix)" \
        !           437:        "prefix=$(prefix)" \
        !           438:        "tooldir=$(tooldir)" \
        !           439:        "bindir=$(bindir)" \
        !           440:        "libsubdir=$(libsubdir)"
        !           441: 
1.1       root      442: # Lists of files for various purposes.
                    443: 
                    444: # A list of all the language-specific executables.
1.1.1.7 ! root      445: # This is overridden by configure.
        !           446: COMPILERS = cc1 cc1obj
1.1       root      447: 
                    448: # Language-specific object files for C.
1.1.1.5   root      449: C_OBJS = c-parse.o c-lang.o c-lex.o c-pragma.o \
                    450:    c-decl.o c-typeck.o c-convert.o c-aux-info.o c-common.o c-iterate.o
1.1       root      451: 
1.1.1.5   root      452: # Language-specific object files for Objective C.
                    453: OBJC_OBJS = objc-parse.o objc-act.o c-lex.o c-pragma.o \
                    454:    c-decl.o c-typeck.o c-convert.o c-aux-info.o c-common.o c-iterate.o
1.1       root      455: 
1.1.1.6   root      456: # Files specific to the C interpreter bytecode compiler(s).
                    457: BC_OBJS = bc-emit.o bc-optab.o
1.1       root      458: 
                    459: # Language-independent object files.
                    460: OBJS = toplev.o version.o tree.o print-tree.o stor-layout.o fold-const.o \
                    461:  function.o stmt.o expr.o calls.o expmed.o explow.o optabs.o varasm.o \
1.1.1.5   root      462:  rtl.o print-rtl.o rtlanal.o emit-rtl.o real.o \
1.1.1.2   root      463:  dbxout.o sdbout.o dwarfout.o xcoffout.o \
1.1       root      464:  integrate.o jump.o cse.o loop.o unroll.o flow.o stupid.o combine.o \
1.1.1.4   root      465:  regclass.o local-alloc.o global.o reload.o reload1.o caller-save.o \
1.1       root      466:  insn-peep.o reorg.o sched.o final.o recog.o reg-stack.o \
1.1.1.5   root      467:  insn-opinit.o insn-recog.o insn-extract.o insn-output.o insn-emit.o \
                    468:  insn-attrtab.o aux-output.o getpwd.o convert.o $(EXTRA_OBJS)
1.1       root      469: 
                    470: # GEN files are listed separately, so they can be built before doing parallel
                    471: #  makes for cc1 or cc1plus.  Otherwise sequent parallel make attempts to load
                    472: #  them before rtl.o is compiled.
                    473: GEN= genemit genoutput genrecog genextract genflags gencodes genconfig genpeep
                    474: 
                    475: # Files to be copied away after each stage in building.
                    476: STAGESTUFF = *.o insn-flags.h insn-config.h insn-codes.h \
                    477:  insn-output.c insn-recog.c insn-emit.c insn-extract.c insn-peep.c \
1.1.1.5   root      478:  insn-attr.h insn-attrtab.c insn-opinit.c \
1.1       root      479:  stamp-flags stamp-config stamp-codes \
                    480:  stamp-output stamp-recog stamp-emit stamp-extract stamp-peep \
1.1.1.5   root      481:  stamp-attr stamp-attrtab stamp-opinit stamp-proto \
1.1       root      482:  genemit genoutput genrecog genextract genflags gencodes genconfig genpeep \
1.1.1.5   root      483:  genattrtab genattr genopinit \
1.1.1.6   root      484:  bc-arity.h bc-opcode.h bc-opname.h \
                    485:  stamp-bcarity stamp-bcopcode stamp-bcopname \
                    486:  bi-arity bi-opcode bi-opname \
1.1.1.7 ! root      487:  $(GCC_PASSES) $(EXTRA_PARTS) $(EXTRA_PROGRAMS) gcc-cross cccp \
        !           488:  cc1obj enquire protoize unprotoize specs collect2 $(USE_COLLECT2) \
        !           489:  $(LANG_STAGESTUFF)
1.1       root      490: 
                    491: # Members of libgcc1.a.
                    492: LIB1FUNCS = _mulsi3 _udivsi3 _divsi3 _umodsi3 _modsi3 \
                    493:    _lshrsi3 _lshlsi3 _ashrsi3 _ashlsi3 \
                    494:    _divdf3 _muldf3 _negdf2 _adddf3 _subdf3 \
                    495:    _fixdfsi _fixsfsi _floatsidf _floatsisf _truncdfsf2 _extendsfdf2 \
                    496:    _addsf3 _negsf2 _subsf3 _mulsf3 _divsf3 \
                    497:    _eqdf2 _nedf2 _gtdf2 _gedf2 _ltdf2 _ledf2 \
                    498:    _eqsf2 _nesf2 _gtsf2 _gesf2 _ltsf2 _lesf2
                    499: 
                    500: # Library members defined in libgcc2.c.
                    501: LIB2FUNCS = _muldi3 _divdi3 _moddi3 _udivdi3 _umoddi3 _negdi2 \
1.1.1.5   root      502:      _lshrdi3 _lshldi3 _ashldi3 _ashrdi3 _ffsdi2 \
1.1.1.4   root      503:     _udiv_w_sdiv _udivmoddi4 _cmpdi2 _ucmpdi2 _floatdidf _floatdisf \
1.1       root      504:     _fixunsdfsi _fixunssfsi _fixunsdfdi _fixdfdi _fixunssfdi _fixsfdi \
1.1.1.5   root      505:     _fixxfdi _fixunsxfdi _floatdixf _fixunsxfsi \
1.1.1.6   root      506:     _fixtfdi _fixunstfdi _floatditf \
1.1.1.7 ! root      507:     __gcc_bcmp _varargs _eprintf _op_new _op_vnew _new_handler _op_delete \
        !           508:     _op_vdel _bb _shtab _clear_cache _trampoline __main _exit _ctors _eh \
        !           509:     _pure
1.1       root      510: 
                    511: # Header files that are made available under the same name
1.1.1.4   root      512: # to programs compiled with GCC.
1.1.1.7 ! root      513: USER_H = $(srcdir)/ginclude/stdarg.h $(srcdir)/ginclude/stddef.h \
        !           514:     $(srcdir)/ginclude/varargs.h $(srcdir)/ginclude/va-alpha.h \
        !           515:     $(srcdir)/ginclude/va-h8300.h $(srcdir)/ginclude/va-i860.h \
        !           516:     $(srcdir)/ginclude/va-i960.h $(srcdir)/ginclude/va-mips.h \
        !           517:     $(srcdir)/ginclude/va-m88k.h $(srcdir)/ginclude/va-pa.h \
        !           518:     $(srcdir)/ginclude/va-pyr.h $(srcdir)/ginclude/va-sparc.h \
        !           519:     $(srcdir)/ginclude/va-clipper.h $(srcdir)/ginclude/va-spur.h \
        !           520:     $(srcdir)/ginclude/proto.h $(EXTRA_HEADERS)
1.1       root      521: 
                    522: # The files that "belong" in CONFIG_H are deliberately omitted
                    523: # because having them there would not be useful in actual practice.
                    524: # All they would do is cause complete recompilation every time
                    525: # one of the machine description files is edited.
                    526: # That may or may not be what one wants to do.
                    527: # If it is, rm *.o is an easy way to do it.
                    528: # CONFIG_H = config.h tm.h
                    529: CONFIG_H =
                    530: RTL_H = rtl.h rtl.def machmode.h machmode.def
                    531: TREE_H = tree.h real.h tree.def machmode.h machmode.def
1.1.1.6   root      532: BYTECODE_H = bytecode.h bc-emit.h bc-optab.h
1.1       root      533: 
1.1.1.7 ! root      534: # Language makefile fragments.
        !           535: 
        !           536: # The following targets define the interface between us and the languages.
        !           537: #
        !           538: # all.build, all.cross, start.encap, rest.encap,
        !           539: # info, dvi,
        !           540: # install-normal, install-common, install-info, install-man,
        !           541: # uninstall, distdir,
        !           542: # mostlyclean, clean, distclean, extraclean, realclean,
        !           543: # stage1, stage2, stage3, stage4
        !           544: #
        !           545: # Each language is linked in with a series of hooks (since we can't use `::'
        !           546: # targets).  The name of each hooked is "lang.${target_name}" (eg: lang.info).
        !           547: # Configure computes and adds these here.
        !           548: 
        !           549: ####language hooks
        !           550: 
        !           551: # sed inserts language fragments after the following line.
        !           552: ####language fragments
        !           553: 
        !           554: # End of language makefile fragments.
        !           555: 
1.1       root      556: # Avoid a lot of time thinking about remaking Makefile.in and *.def.
                    557: .SUFFIXES: .in .def
                    558: 
1.1.1.3   root      559: Makefile: $(srcdir)/Makefile.in $(srcdir)/configure $(srcdir)/version.c \
1.1.1.7 ! root      560:    $(srcdir)/config/$(xmake_file) $(srcdir)/config/$(tmake_file) \
        !           561:    $(LANG_MAKEFILES)
        !           562:        $(SHELL) config.status
1.1       root      563: 
                    564: all.internal: start.encap rest.encap
                    565: # This is what to compile if making a cross-compiler.
1.1.1.7 ! root      566: # Note that we can compile enquire using the cross-compiler just built,
1.1.1.5   root      567: # although we can't run it on this machine.
1.1.1.7 ! root      568: all.cross: native gcc-cross specs stmp-headers $(LIBGCC) $(STMP_FIXPROTO) \
        !           569:        $(CROSS_TEST) $(ENQUIRE) $(EXTRA_PARTS) lang.all.cross
1.1.1.4   root      570: # This is what to compile if making gcc with a cross-compiler.
1.1.1.7 ! root      571: all.build: native xgcc $(EXTRA_PARTS) lang.all.build
1.1       root      572: # This is what must be made before installing GCC and converting libraries.
1.1.1.7 ! root      573: start.encap: native xgcc specs $(LIBGCC1) xlimits.h lang.start.encap
        !           574: # These can't be made until after GCC can run.
        !           575: rest.encap: stmp-headers $(LIBGCC) $(STMP_FIXPROTO) $(EXTRA_PARTS) lang.rest.encap
1.1       root      576: # This is what is made with the host's compiler
                    577: # whether making a cross compiler or not.
1.1.1.3   root      578: native: config.status cpp $(LANGUAGES) $(EXTRA_PASSES) $(EXTRA_PROGRAMS) $(USE_COLLECT2)
1.1       root      579: 
                    580: # Define the names for selecting languages in LANGUAGES.
                    581: C c: cc1
1.1.1.7 ! root      582: OBJC objc: cc1obj objc-runtime
        !           583: OBJECTIVE-C objective-c: cc1obj objc-runtime
1.1       root      584: PROTO: proto
                    585: 
1.1.1.2   root      586: # Really, really stupid make features, such as SUN's KEEP_STATE, may force
                    587: # a target to build even if it is up-to-date.  So we must verify that
                    588: # config.status does not exist before failing.
1.1       root      589: config.status:
1.1.1.2   root      590:        @if [ ! -f config.status ] ; then \
                    591:          echo You must configure gcc.  Look at the INSTALL file for details.; \
                    592:          false; \
                    593:        else \
                    594:          true; \
                    595:        fi
1.1       root      596: 
1.1.1.3   root      597: # On the target machine, finish building a cross compiler.
                    598: # This does the things that can't be done on the host machine.
1.1.1.6   root      599: rest.cross: $(LIBGCC) gfloat.h specs
1.1.1.3   root      600: 
                    601: # Verify that it works to compile and link cross-test.
                    602: # If it does, then there are sufficient replacements for libgcc1.a.
1.1.1.6   root      603: cross-test: cross-test.o native gcc-cross $(LIBGCC) $(GCC_PARTS)
1.1.1.7 ! root      604:        $(GCC_FOR_TARGET) $(GCC_CFLAGS) cross-test.o -o cross-test
1.1.1.3   root      605: cross-test.o: cross-test.c native gcc-cross
                    606:        $(GCC_FOR_TARGET) $(GCC_CFLAGS) $(ALL_CPPFLAGS) -c $(srcdir)/cross-test.c
                    607: 
                    608: # Recompile all the language-independent object files.
                    609: # This is used only if the user explicitly asks for it.
1.1       root      610: compilations: ${OBJS}
                    611: 
1.1.1.7 ! root      612: # Create a list of the language-independent object files so the language
        !           613: # subdirectories needn't mention their names explicitly.
        !           614: stamp-objlist: Makefile $(OBJS) $(BC_OBJS)
        !           615:        echo " $(OBJS) $(BC_OBJS)" | sed -e 's, \([a-z]\), ../\1,g' >stamp-objlist
        !           616: 
1.1.1.4   root      617: # We call this executable `xgcc' rather than `gcc'
                    618: # to avoid confusion if the current directory is in the path
                    619: # and CC is `gcc'.  It is renamed to `gcc' when it is installed.
                    620: xgcc: gcc.o version.o $(LIBDEPS)
                    621:        $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o xgcc gcc.o version.o $(LIBS)
1.1.1.3   root      622: 
                    623: # Dump a specs file to make -B./ read these specs over installed ones.
1.1.1.4   root      624: specs: xgcc
1.1.1.5   root      625:        $(GCC_FOR_TARGET) -dumpspecs > specs
1.1       root      626: 
1.1.1.4   root      627: # We do want to create an executable named `xgcc', so we can use it to
1.1       root      628: # compile libgcc2.a.
                    629: # Also create gcc-cross, so that install-common will install properly.
1.1.1.4   root      630: gcc-cross: xgcc
                    631:        cp xgcc gcc-cross
1.1       root      632: 
1.1.1.6   root      633: cc1: $(P) $(C_OBJS) $(OBJS) $(BC_OBJS) $(LIBDEPS)
                    634:        $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o cc1 $(C_OBJS) $(OBJS) $(BC_OBJS) $(LIBS)
1.1       root      635: 
1.1.1.6   root      636: cc1obj: $(P) $(OBJC_OBJS) $(OBJS) $(BC_OBJS) $(LIBDEPS)
                    637:        $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o cc1obj $(OBJC_OBJS) $(OBJS) $(BC_OBJS) $(LIBS)
1.1       root      638: 
1.1.1.5   root      639: # Copy float.h from its source.
                    640: gfloat.h: $(FLOAT_H)
                    641:        cp $(FLOAT_H) gfloat.h
                    642: 
                    643: # Create float.h source for the native machine.
                    644: float.h-nat: enquire
1.1       root      645:        -./enquire -f > tmp-float.h
1.1.1.5   root      646:        mv tmp-float.h float.h-nat
                    647: 
                    648: # Create a dummy float.h source for a cross-compiler.
                    649: float.h-cross:
                    650:        echo "#error float.h values not known for cross-compiler" > float.h-cross
1.1       root      651: 
                    652: # Used to compile enquire with standard cc, but have forgotten why.
                    653: # Let's try with GCC.
                    654: enquire: enquire.o $(GCC_PARTS)
1.1.1.7 ! root      655:        $(GCC_FOR_TARGET) $(GCC_CFLAGS) $(ENQUIRE_LDFLAGS) enquire.o -o enquire
        !           656: enquire.o: $(srcdir)/enquire.c $(GCC_PASSES) stmp-int-hdrs
1.1.1.4   root      657: #      -if [ "$(srcdir)" != "." ]; then rm -f ./enquire.c; else true; fi
                    658: #      -cp $(srcdir)/enquire.c . > /dev/null 2>&1
1.1       root      659: # Breaking this line caused a problem with one version of GNU make.
1.1.1.4   root      660:        $(GCC_FOR_TARGET) $(GCC_CFLAGS) $(ALL_CPPFLAGS) $(ENQUIRE_CFLAGS) -I. -c $(srcdir)/enquire.c
                    661: 
                    662: # Build the version of limits.h that we will install.
                    663: xlimits.h: glimits.h limitx.h limity.h
                    664:        if [ -f $(SYSTEM_HEADER_DIR)/limits.h ] ; then \
                    665:          cat $(srcdir)/limitx.h $(srcdir)/glimits.h $(srcdir)/limity.h > xlimits.h; \
                    666:        else \
                    667:          cat $(srcdir)/glimits.h > xlimits.h; \
                    668:        fi
1.1       root      669: 
                    670: # Build libgcc.a.
                    671: # This is done in two parts because some functions, in libgcc1.c,
1.1.1.4   root      672: # must be compiled with something other than GCC,
                    673: # while the rest, in libgcc2.c, must be compiled with xgcc.
                    674: # That means we can't do libgcc2.c until after xgcc, cc1, etc.
1.1       root      675: 
                    676: # Use this as value of LIBGCC1 to cause conversion to GNU library format.
                    677: # LIBCONVERT should put its output in libgcc1.conv.
                    678: libgcc1.conv: libgcc1.a
                    679:        $(LIBCONVERT) libgcc1.a libgcc1.conv
                    680: 
                    681: # Use this as value of LIBGCC1 to inhibit use of libgcc1.c entirely.
                    682: # Make an empty file instead.
1.1.1.5   root      683: libgcc1.null: $(GCC_PASSES)
1.1       root      684:        echo "__foo () {}" > dummy.c
                    685:        $(GCC_FOR_TARGET) $(GCC_CFLAGS) -c dummy.c
                    686:        $(OLDAR) $(OLDAR_FLAGS) libgcc1.null dummy.o
                    687:        rm -f dummy.o dummy.c
                    688: 
1.1.1.4   root      689: # This is $(LIBGCC1) for a cross-compiler.
                    690: # We have no automatic way of building libgcc1.a, 
                    691: # so it's up to the installer to find a way to do that.
                    692: # This rule deliberately does not depend on libgcc1.a
                    693: # so that it will fail if the installer hasn't provided it.
                    694: libgcc1.cross:
                    695:        mv libgcc1.a libgcc1.cross || (echo You must find a way to make libgcc1.a; false)
                    696: 
1.1       root      697: # Compile the library of arithmetic subroutines with the native compiler.
1.1.1.4   root      698: # Don't compile it with GCC!
1.1       root      699: # (That would cause most arithmetic functions to call themselves.)
                    700: libgcc1.a: libgcc1.c $(CONFIG_H) $(LIB1FUNCS_EXTRA) config.status
                    701:        -rm -f tmplibgcc1.a
                    702: # Actually build it in tmplibgcc1.a, then rename at end,
                    703: # so that libgcc1.a itself remains nonexistent if compilation is aborted.
                    704: # -e causes any failing command to make this rule fail.
                    705: # -e doesn't work in certain shells, so we test $$? as well.
1.1.1.6   root      706: # lynx has a broken ar, it always complains when the initial library is
                    707: # empty, thus this command works only if we don't do -e
                    708: # There is a trailing backslash (\) deleted from the following line.
                    709: #      set -e;
1.1       root      710:        for name in $(LIB1FUNCS); \
                    711:        do \
                    712:          echo $${name}; \
                    713:          rm -f $${name}.o; \
                    714:          $(OLDCC) $(CCLIBFLAGS) $(INCLUDES) -c -DL$${name} $(srcdir)/libgcc1.c; \
                    715:          if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
                    716:          mv libgcc1.o $${name}.o; \
                    717:          $(OLDAR) $(OLDAR_FLAGS) tmplibgcc1.a $${name}.o; \
                    718:          rm -f $${name}.o; \
                    719:        done
                    720: # Some shells crash when a loop has no items.
                    721: # So make sure there is always at least one--`..'.
                    722: # Then ignore it.
                    723: # We don't use -e here because there are if statements
                    724: # that should not make the command give up when the if condition is false.
                    725: # Instead, we test for failure after each command where it matters.
1.1.1.7 ! root      726:        for file in .. $(LIB1FUNCS_EXTRA); \
1.1       root      727:        do \
                    728:          if [ x$${file} != x.. ]; then \
                    729:            name=`echo $${file} | sed -e 's/[.]c$$//' -e 's/[.]asm$$//'`; \
                    730:            echo $${name}; \
                    731:            if [ $${name}.asm = $${file} ]; then \
1.1.1.4   root      732:              cp $${file} $${name}.s || exit 1; file=$${name}.s; \
1.1       root      733:            else true; fi; \
                    734:            $(OLDCC) $(CCLIBFLAGS) $(INCLUDES) -c $${file}; \
                    735:            if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
                    736:            $(OLDAR) $(OLDAR_FLAGS) tmplibgcc1.a $${name}.o; \
                    737:            if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
                    738:            rm -f $${name}.[so]; \
                    739:          else true; \
                    740:          fi; \
                    741:        done
                    742:        mv tmplibgcc1.a libgcc1.a
                    743: 
1.1.1.7 ! root      744: # Build libgcc1.a from assembler source.  LIB1ASMFUNCS is the list of
        !           745: # functions.  LIB1ASMSRC is the name of the source file in the config
        !           746: # subdirectory.
        !           747: libgcc1-asm.a: libgcc2.ready config.status $(srcdir)/config/$(LIB1ASMSRC)
        !           748:        -rm -f tmplibgcc1.a libgcc1.S
        !           749:        cp $(srcdir)/config/$(LIB1ASMSRC) libgcc1.S
        !           750: # Actually build it in tmplibgcc1.a, then rename at end,
        !           751: # so that libgcc1-asm.a itself remains nonexistent if compilation is aborted.
        !           752: # -e causes any failing command to make this rule fail.
        !           753: # -e doesn't work in certain shells, so we test $$? as well.
        !           754: # lynx has a broken ar, it always complains when the initial library is
        !           755: # empty, thus this command works only if we don't do -e
        !           756: # There is a trailing backslash (\) deleted from the following line.
        !           757: #      set -e;
        !           758:        for name in $(LIB1ASMFUNCS); \
        !           759:        do \
        !           760:          echo $${name}; \
        !           761:          $(GCC_FOR_TARGET) $(LIBGCC2_CFLAGS) $(INCLUDES) -c -DL$${name} libgcc1.S; \
        !           762:          if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
        !           763:          mv libgcc1.o $${name}.o; \
        !           764:          $(AR) $(AR_FLAGS) tmplibgcc1.a $${name}.o; \
        !           765:          rm -f $${name}.o; \
        !           766:        done
        !           767:        -rm -f libgcc1.S
        !           768:        mv tmplibgcc1.a libgcc1-asm.a
        !           769: 
1.1       root      770: # Compiling libgcc2.a requires making sure that cc1, etc. have been compiled.
                    771: # But recompiling cc1 should not force recompilation of libgcc2.a.
                    772: # If you want to force recompilation, delete libgcc2.a.
1.1.1.7 ! root      773: libgcc2.ready: $(GCC_PASSES) $(LIBGCC2_DEPS) stmp-int-hdrs
1.1       root      774:        -if [ -f libgcc2.ready ] ; then \
                    775:                true; \
                    776:        else \
                    777:                touch libgcc2.ready; \
                    778:        fi
                    779: 
                    780: libgcc2.a: libgcc2.c libgcc2.ready $(CONFIG_H) $(LIB2FUNCS_EXTRA) \
1.1.1.4   root      781:    machmode.h longlong.h gbl-ctors.h config.status
1.1       root      782: # Actually build it in tmplibgcc2.a, then rename at end,
                    783: # so that libgcc2.a itself remains nonexistent if compilation is aborted.
                    784:        -rm -f tmplibgcc2.a
                    785: # -e causes any failing command to make this rule fail.
                    786: # -e doesn't work in certain shells, so we test $$? as well.
1.1.1.6   root      787: # lynx has a broken ar, it always complains when the initial library is
                    788: # empty, thus this command works only if we don't do -e
                    789: # There is a trailing backslash (\) deleted from the following line.
                    790: #      set -e;
1.1       root      791:        for name in $(LIB2FUNCS); \
                    792:        do \
                    793:          echo $${name}; \
1.1.1.2   root      794:          $(GCC_FOR_TARGET) $(LIBGCC2_CFLAGS) $(INCLUDES) -c -DL$${name} \
1.1       root      795:              $(srcdir)/libgcc2.c -o $${name}.o; \
                    796:          if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
                    797:          $(AR) $(AR_FLAGS) tmplibgcc2.a $${name}.o; \
                    798:          rm -f $${name}.o; \
                    799:        done
                    800: # Some shells crash when a loop has no items.
                    801: # So make sure there is always at least one--`..'.
                    802: # Then ignore it.
                    803: # We don't use -e here because there are if statements
                    804: # that should not make the command give up when the if condition is false.
                    805: # Instead, we test for failure after each command where it matters.
1.1.1.7 ! root      806:        for file in .. $(LIB2FUNCS_EXTRA); \
1.1       root      807:        do \
                    808:          if [ x$${file} != x.. ]; then \
                    809:            name=`echo $${file} | sed -e 's/[.]c$$//' -e 's/[.]asm$$//'`; \
                    810:            echo $${name}; \
                    811:            if [ $${name}.asm = $${file} ]; then \
1.1.1.4   root      812:              cp $${file} $${name}.s || exit 1; file=$${name}.s; \
1.1       root      813:            else true; fi; \
1.1.1.2   root      814:            $(GCC_FOR_TARGET) $(LIBGCC2_CFLAGS) $(INCLUDES) -c $${file}; \
1.1       root      815:            if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
                    816:            $(AR) $(AR_FLAGS) tmplibgcc2.a $${name}.o; \
                    817:            rm -f $${name}.[so]; \
                    818:          else true; \
                    819:          fi; \
                    820:        done
                    821:        mv tmplibgcc2.a libgcc2.a
                    822: # These lines were deleted from above the mv command
                    823: # because ranlibing libgcc.a itself should suffice.
                    824: #      -if [ x${HPUX_GAS} = x ] ; then \
                    825: #        if $(RANLIB_TEST) ; then $(RANLIB) tmplibgcc2.a; else true; fi \
                    826: #      else true; fi
                    827: 
                    828: # Combine the various libraries into a single library, libgcc.a.
                    829: libgcc.a: $(LIBGCC1) $(LIBGCC2)
                    830:        -rm -rf tmplibgcc.a libgcc.a tmpcopy
                    831:        mkdir tmpcopy
1.1.1.2   root      832:        -if [ x$(LIBGCC1) != x ];                       \
                    833:        then (cd tmpcopy; $(AR) x ../$(LIBGCC1));       \
                    834:        else true;                                      \
                    835:        fi
1.1.1.6   root      836: # Some versions of ar (specifically the one in RISC/os 5.x), create an
                    837: # unwritable table of contents file, and then print an error message when
                    838: # the second ar command tries to overwrite this file.  To avoid the error
                    839: # message from ar, we make sure all files are writable.
                    840:        -(cd tmpcopy; chmod +w * > /dev/null 2>&1)
1.1       root      841:        (cd tmpcopy; $(AR) x ../$(LIBGCC2))
                    842:        (cd tmpcopy; $(AR) $(AR_FLAGS) ../tmplibgcc.a *.o)
                    843:        rm -rf tmpcopy
                    844:        -if $(RANLIB_TEST) ; then $(RANLIB) tmplibgcc.a; else true; fi
                    845: # Actually build it in tmplibgcc.a, then rename at end,
                    846: # so that libgcc.a itself remains nonexistent if compilation is aborted.
                    847:        mv tmplibgcc.a libgcc.a
                    848: 
1.1.1.7 ! root      849: # Use the genmultilib shell script to generate the information the gcc
        !           850: # driver program needs to select the library directory based on the
        !           851: # switches.
        !           852: multilib.h: $(srcdir)/genmultilib config.status
        !           853:        $(SHELL) $(srcdir)/genmultilib "$(MULTILIB_OPTIONS)" \
        !           854:          "$(MULTILIB_DIRNAMES)" "$(MULTILIB_MATCHES)" > multilib.h
        !           855: 
        !           856: # Build multiple copies of libgcc.a, one for each target switch.
        !           857: stmp-multilib: $(LIBGCC1) libgcc2.c libgcc2.ready $(CONFIG_H) \
        !           858:    $(LIB2FUNCS_EXTRA) machmode.h longlong.h gbl-ctors.h config.status
        !           859:        for i in `$(GCC_FOR_TARGET) --print-multi-lib`; do \
        !           860:          dir=`echo $$i | sed -e 's/;.*$$//'`; \
        !           861:          flags=`echo $$i | sed -e 's/^[^;]*;//' -e 's/@/ -/g'`; \
        !           862:          $(MAKE) GCC_FOR_TARGET="$(GCC_FOR_TARGET)" \
        !           863:            AR="$(AR)" AR_FLAGS="$(AR_FLAGS)" \
        !           864:            RANLIB="$(RANLIB)" RANLIB_TEST="$(RANLIB_TEST)" \
        !           865:            HOST_PREFIX="$(HOST_PREFIX)" HOST_PREFIX_1="$(HOST_PREFIX_1)" \
        !           866:            LIBGCC2_CFLAGS="$(LIBGCC2_CFLAGS) $${flags}" \
        !           867:            LIBGCC1="$(LIBGCC1)" LIBGCC2="$(LIBGCC2)" \
        !           868:            dir="$${dir}" stmp-multilib-sub; \
        !           869:        done
        !           870:        touch stmp-multilib
        !           871: 
        !           872: # Subroutine of stmp-multilib so make -n works.
        !           873: stmp-multilib-sub:
        !           874:        rm -f $(dir)/libgcc.a $(LIBGCC2)
        !           875:        $(MAKE) GCC_FOR_TARGET="$(GCC_FOR_TARGET)" \
        !           876:          AR="$(AR)" AR_FLAGS="$(AR_FLAGS)" \
        !           877:          HOST_PREFIX="$(HOST_PREFIX)" HOST_PREFIX_1="$(HOST_PREFIX_1)" \
        !           878:          LIBGCC2_CFLAGS="$(LIBGCC2_CFLAGS)" $(LIBGCC2)
        !           879:        if [ x$(LIBGCC1) != xlibgcc1-asm.a ]; \
        !           880:        then true; \
        !           881:        else rm -f $(LIBGCC1); \
        !           882:        fi
        !           883:        if [ x$(LIBGCC1) != xlibgcc1-asm.a ]; \
        !           884:        then true; \
        !           885:        else \
        !           886:          $(MAKE) GCC_FOR_TARGET="$(GCC_FOR_TARGET)" \
        !           887:            AR="$(AR)" AR_FLAGS="$(AR_FLAGS)" \
        !           888:            HOST_PREFIX="$(HOST_PREFIX)" HOST_PREFIX_1="$(HOST_PREFIX_1)" \
        !           889:            LIBGCC2_CFLAGS="$(LIBGCC2_CFLAGS)" $(LIBGCC1); \
        !           890:        fi
        !           891:        rm -rf tmplibgcc.a tmpcopy
        !           892:        mkdir tmpcopy
        !           893:        if [ x$(LIBGCC1) != x ]; \
        !           894:        then (cd tmpcopy; $(AR) x ../$(LIBGCC1)); \
        !           895:        else true; \
        !           896:        fi
        !           897:        (cd tmpcopy; $(AR) x ../$(LIBGCC2))
        !           898:        (cd tmpcopy; $(AR) $(AR_FLAGS) ../tmplibgcc.a *.o)
        !           899:        rm -rf libgcc2.a tmpcopy
        !           900:        if $(RANLIB_TEST) ; then $(RANLIB) tmplibgcc.a; else true; fi
        !           901:        if [ -d $(dir) ]; then true; else mkdir $(dir); fi
        !           902:        mv tmplibgcc.a $(dir)/libgcc.a
        !           903: 
1.1.1.4   root      904: objc-runtime: libobjc.a
                    905: 
                    906: # Build the Objective C runtime library.
1.1.1.7 ! root      907: libobjc.a: cc1obj stmp-int-hdrs libgcc2.ready $(USE_COLLECT2) $(EXTRA_PARTS)
1.1.1.4   root      908:        if [ -d objc ]; then true; else mkdir objc; fi
                    909:        thisdir1=`pwd`; \
                    910:        srcdir1=`cd $(srcdir); pwd`; \
                    911:        cd objc; \
                    912:        $(MAKE) -f $${srcdir1}/objc/Makefile libobjc.a \
                    913:          srcdir=$${srcdir1} tooldir=$(tooldir) AR="$(AR)" AR_FLAGS="$(AR_FLAGS)" \
                    914:          GCC_FOR_TARGET="$${thisdir1}/xgcc -B$${thisdir1}/" \
                    915:          GCC_CFLAGS="$(GCC_CFLAGS)"
                    916:        -rm -f libobjc.a
                    917:        ln objc/libobjc.a . >/dev/null 2>&1 || cp objc/libobjc.a .
                    918:        -if $(RANLIB_TEST) ; then $(RANLIB) libobjc.a; else true; fi
                    919: 
                    920: # This is used by objc/Makefile if the user runs that directly.
1.1.1.7 ! root      921: sublibobjc.a: cc1obj stmp-int-hdrs libgcc2.ready
1.1.1.4   root      922:        thisdir1=`pwd`; \
                    923:        srcdir1=`cd $(srcdir); pwd`; \
                    924:        cd objc; \
                    925:        $(MAKE) -f $$srcdir1/objc/Makefile libobjc.a \
                    926:          srcdir=$$srcdir1 tooldir=$(tooldir) AR="$(AR)" AR_FLAGS="$(AR_FLAGS)" \
                    927:          GCC_FOR_TARGET="$$thisdir1/xgcc -B$$thisdir1/" \
                    928:          GCC_CFLAGS="$(GCC_CFLAGS)"
1.1       root      929: 
                    930: # Compile two additional files that are linked with every program
                    931: # linked using GCC on system V, for the sake of C++ constructors.
                    932: crtbegin.o:    crtstuff.c $(GCC_PASSES) $(CONFIG_H) gbl-ctors.h
                    933:        $(GCC_FOR_TARGET) $(GCC_CFLAGS) $(INCLUDES) -DCRT_BEGIN \
1.1.1.6   root      934:          -finhibit-size-directive -fno-inline-functions \
                    935:          -g0 -c $(srcdir)/crtstuff.c -o crtbegin.o
1.1       root      936: 
                    937: crtend.o:      crtstuff.c $(GCC_PASSES) $(CONFIG_H) gbl-ctors.h
                    938:        $(GCC_FOR_TARGET) $(GCC_CFLAGS) $(INCLUDES) -DCRT_END \
1.1.1.6   root      939:          -finhibit-size-directive -fno-inline-functions \
                    940:          -g0 -c $(srcdir)/crtstuff.c -o crtend.o
1.1       root      941: 
                    942: # Compiling object files from source files.
                    943: 
                    944: # Note that dependencies on obstack.h are not written
                    945: # because that file is not part of GCC.
                    946: 
                    947: # C language specific files.
                    948: 
1.1.1.7 ! root      949: c-parse.o : $(srcdir)/c-parse.c $(CONFIG_H) $(TREE_H) c-lex.h \
        !           950:     $(srcdir)/c-parse.h c-tree.h input.h flags.h
1.1       root      951:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c $(srcdir)/c-parse.c
                    952: $(srcdir)/c-parse.c $(srcdir)/c-parse.h: $(srcdir)/c-parse.y
                    953:        cd $(srcdir); $(BISON) $(BISONFLAGS) -d c-parse.y -o c-parse.c
1.1.1.5   root      954: $(srcdir)/c-parse.y: $(srcdir)/c-parse.in
                    955:        sed -e "/^ifobjc$$/,/^end ifobjc$$/d" \
                    956:          -e "/^ifc$$/d" -e "/^end ifc$$/d" \
1.1.1.7 ! root      957:          $(srcdir)/c-parse.in >tmp-c-parse.y
        !           958:        $(srcdir)/move-if-change tmp-c-parse.y $(srcdir)/c-parse.y
        !           959: 
        !           960: $(srcdir)/c-gperf.h: $(srcdir)/c-parse.gperf
        !           961:        gperf -p -j1 -i 1 -g -o -t -G -N is_reserved_word -k1,3,$$ \
        !           962:           $(srcdir)/c-parse.gperf >tmp-gperf.h
        !           963:         $(srcdir)/move-if-change tmp-gperf.h $(srcdir)/c-gperf.h
1.1       root      964: 
                    965: c-decl.o : c-decl.c $(CONFIG_H) $(TREE_H) c-tree.h c-lex.h flags.h
                    966: c-typeck.o : c-typeck.c $(CONFIG_H) $(TREE_H) c-tree.h flags.h
                    967: c-lang.o : c-lang.c $(CONFIG_H) $(TREE_H)
1.1.1.7 ! root      968: c-lex.o : c-lex.c $(CONFIG_H) $(TREE_H) c-lex.h c-tree.h $(srcdir)/c-parse.h \
        !           969:     input.h flags.h $(srcdir)/c-gperf.h
1.1       root      970: c-aux-info.o : c-aux-info.c  $(CONFIG_H) $(TREE_H) c-tree.h flags.h
                    971: c-convert.o : c-convert.c $(CONFIG_H) $(TREE_H) flags.h
1.1.1.4   root      972: c-pragma.o: c-pragma.c $(CONFIG_H) $(TREE_H)
1.1.1.5   root      973: c-iterate.o: c-iterate.c $(CONFIG_H) $(TREE_H) $(RTL_H) c-tree.h flags.h
1.1       root      974: 
1.1.1.3   root      975: # To make a configuration always use collect2, set USE_COLLECT2 to ld.
                    976: ld: collect2
                    977:        rm -f ld
                    978:        ln collect2 ld
                    979: 
1.1       root      980: collect2 : collect2.o version.o $(LIBDEPS)
1.1.1.4   root      981: # Don't try modifying collect2 (aka ld) in place--it might be linking this.
                    982:        -rm -f collect2
1.1       root      983:        $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o collect2 collect2.o version.o $(LIBS)
                    984: 
                    985: collect2.o : collect2.c $(CONFIG_H) gstab.h
1.1.1.5   root      986:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES)  \
                    987:        -DTARGET_MACHINE=\"$(target)\" \
                    988:        -c `echo $(srcdir)/collect2.c | sed 's,^\./,,'`
1.1       root      989: 
1.1.1.5   root      990: # Objective C language specific files.
1.1       root      991: 
                    992: objc-parse.o : $(srcdir)/objc-parse.c $(CONFIG_H) $(TREE_H) c-lex.h \
1.1.1.5   root      993:    c-tree.h input.h flags.h objc-act.h
1.1       root      994:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c $(srcdir)/objc-parse.c
                    995: $(srcdir)/objc-parse.c : $(srcdir)/objc-parse.y
                    996:        cd $(srcdir); $(BISON) $(BISONFLAGS) objc-parse.y -o objc-parse.c
1.1.1.5   root      997: $(srcdir)/objc-parse.y: $(srcdir)/c-parse.in
                    998:        sed -e "/^ifc$$/,/^end ifc$$/d" \
                    999:          -e "/^ifobjc$$/d" -e "/^end ifobjc$$/d" \
1.1.1.7 ! root     1000:          $(srcdir)/c-parse.in >tmp-objc-prs.y
        !          1001:        $(srcdir)/move-if-change tmp-objc-prs.y $(srcdir)/objc-parse.y
1.1       root     1002: 
1.1.1.5   root     1003: objc-act.o : objc-act.c $(CONFIG_H) $(TREE_H) $(RTL_H) c-tree.h c-lex.h \
                   1004:    flags.h objc-act.h input.h function.h $(srcdir)/c-parse.h
1.1       root     1005: 
                   1006: # A file used by all variants of C.
                   1007: 
                   1008: c-common.o : c-common.c $(CONFIG_H) $(TREE_H) c-tree.h c-lex.h flags.h
                   1009: 
                   1010: # Language-independent files.
                   1011: 
1.1.1.7 ! root     1012: gcc.o: gcc.c $(CONFIG_H) multilib.h config.status
1.1       root     1013:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
                   1014:   -DSTANDARD_STARTFILE_PREFIX=\"$(libdir)/\" \
1.1.1.2   root     1015:   -DSTANDARD_EXEC_PREFIX=\"$(libdir)/gcc-lib/\" \
1.1.1.7 ! root     1016:   -DDEFAULT_TARGET_VERSION=\"$(version)\" \
1.1       root     1017:   -DDEFAULT_TARGET_MACHINE=\"$(target)\" \
1.1.1.5   root     1018:   -DTOOLDIR_BASE_PREFIX=\"$(exec_prefix)/\" \
                   1019:   $(MAYBE_TARGET_DEFAULT) \
1.1       root     1020:   -c `echo $(srcdir)/gcc.c | sed 's,^\./,,'`
                   1021: 
                   1022: dumpvers: dumpvers.c
                   1023: 
                   1024: version.o: version.c
                   1025: obstack.o: obstack.c
                   1026: 
1.1.1.5   root     1027: convert.o: convert.c $(CONFIG_H) $(TREE_H) flags.h convert.h
                   1028: 
1.1.1.7 ! root     1029: tree.o : tree.c $(CONFIG_H) $(TREE_H) flags.h function.h
1.1       root     1030: print-tree.o : print-tree.c $(CONFIG_H) $(TREE_H)
                   1031: stor-layout.o : stor-layout.c $(CONFIG_H) $(TREE_H) function.h
                   1032: fold-const.o : fold-const.c $(CONFIG_H) $(TREE_H) flags.h 
1.1.1.2   root     1033: toplev.o : toplev.c $(CONFIG_H) $(TREE_H) $(RTL_H) flags.h input.h \
1.1.1.5   root     1034:    insn-attr.h xcoffout.h defaults.h
1.1.1.3   root     1035:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
1.1.1.4   root     1036:          $(MAYBE_TARGET_DEFAULT) $(MAYBE_USE_COLLECT2) \
                   1037:          -c `echo $(srcdir)/toplev.c | sed 's,^\./,,'`
1.1       root     1038: 
                   1039: rtl.o : rtl.c $(CONFIG_H) $(RTL_H)
                   1040: 
                   1041: print-rtl.o : print-rtl.c $(CONFIG_H) $(RTL_H)
                   1042: rtlanal.o : rtlanal.c $(CONFIG_H) $(RTL_H)
                   1043: 
1.1.1.6   root     1044: toplev.o: bytecode.h bc-emit.h
1.1.1.4   root     1045: varasm.o : varasm.c $(CONFIG_H) $(TREE_H) $(RTL_H) flags.h function.h \
1.1.1.6   root     1046:    defaults.h insn-codes.h expr.h hard-reg-set.h regs.h xcoffout.h bytecode.h
1.1       root     1047: function.o : function.c $(CONFIG_H) $(RTL_H) $(TREE_H) flags.h function.h  \
                   1048:    insn-flags.h insn-codes.h expr.h regs.h hard-reg-set.h insn-config.h \
1.1.1.6   root     1049:    recog.h output.h bytecode.h
1.1       root     1050: stmt.o : stmt.c $(CONFIG_H) $(RTL_H) $(TREE_H) flags.h function.h  \
1.1.1.6   root     1051:    insn-flags.h insn-config.h insn-codes.h hard-reg-set.h expr.h loop.h \
                   1052:    recog.h bytecode.h bc-typecd.h bc-typecd.def bc-opcode.h bc-optab.h \
                   1053:    bc-emit.h
1.1.1.7 ! root     1054: expr.o : expr.c $(CONFIG_H) $(RTL_H) $(TREE_H) flags.h function.h regs.h \
1.1.1.6   root     1055:    insn-flags.h insn-codes.h expr.h insn-config.h recog.h output.h \
                   1056:    typeclass.h bytecode.h bc-opcode.h bc-typecd.h bc-typecd.def bc-optab.h \
                   1057:    bc-emit.h modemap.def
1.1       root     1058: calls.o : calls.c $(CONFIG_H) $(RTL_H) $(TREE_H) flags.h expr.h insn-codes.h \
1.1.1.7 ! root     1059:    insn-flags.h
1.1       root     1060: expmed.o : expmed.c $(CONFIG_H) $(RTL_H) $(TREE_H) flags.h  \
                   1061:    insn-flags.h insn-config.h insn-codes.h expr.h recog.h real.h
                   1062: explow.o : explow.c $(CONFIG_H) $(RTL_H) $(TREE_H) flags.h hard-reg-set.h \
                   1063:    insn-config.h expr.h recog.h insn-flags.h insn-codes.h
                   1064: optabs.o : optabs.c $(CONFIG_H) $(RTL_H) $(TREE_H) flags.h  \
1.1.1.5   root     1065:    insn-flags.h insn-config.h insn-codes.h expr.h recog.h reload.h
1.1       root     1066: dbxout.o : dbxout.c $(CONFIG_H) $(TREE_H) $(RTL_H) flags.h regs.h \
1.1.1.4   root     1067:    insn-config.h reload.h gstab.h xcoffout.h defaults.h output.h
1.1       root     1068: sdbout.o : sdbout.c $(CONFIG_H) $(TREE_H) $(RTL_H) gsyms.h flags.h \
                   1069:    insn-config.h reload.h
                   1070: dwarfout.o : dwarfout.c $(CONFIG_H) $(TREE_H) $(RTL_H) dwarf.h flags.h \
1.1.1.4   root     1071:    insn-config.h reload.h output.h defaults.h
1.1.1.2   root     1072: xcoffout.o : xcoffout.c $(CONFIG_H) $(TREE_H) $(RTL_H) xcoffout.h flags.h
1.1.1.7 ! root     1073: emit-rtl.o : emit-rtl.c $(CONFIG_H) $(RTL_H) $(TREE_H) flags.h \
1.1.1.6   root     1074:    function.h regs.h insn-config.h insn-codes.h real.h expr.h bytecode.h \
                   1075:    bc-opcode.h bc-typecd.h bc-typecd.def bc-optab.h bc-emit.h bc-opname.h
1.1.1.5   root     1076: real.o : real.c $(CONFIG_H) $(TREE_H)
1.1.1.2   root     1077: getpwd.o : getpwd.c $(CONFIG_H)
1.1       root     1078: 
                   1079: integrate.o : integrate.c $(CONFIG_H) $(RTL_H) $(TREE_H) flags.h integrate.h \
1.1.1.6   root     1080:    insn-flags.h insn-config.h insn-codes.h expr.h real.h function.h \
                   1081:    bytecode.h
1.1       root     1082: 
                   1083: jump.o : jump.c $(CONFIG_H) $(RTL_H) flags.h hard-reg-set.h regs.h \
                   1084:    insn-config.h insn-flags.h insn-codes.h expr.h real.h
                   1085: stupid.o : stupid.c $(CONFIG_H) $(RTL_H) regs.h hard-reg-set.h flags.h
                   1086: 
                   1087: cse.o : cse.c $(CONFIG_H) $(RTL_H) regs.h hard-reg-set.h flags.h real.h \
                   1088:    insn-config.h recog.h
                   1089: loop.o : loop.c $(CONFIG_H) $(RTL_H) flags.h loop.h insn-config.h \
                   1090:    insn-flags.h insn-codes.h regs.h hard-reg-set.h recog.h expr.h real.h
                   1091: unroll.o : unroll.c $(CONFIG_H) $(RTL_H) insn-config.h insn-codes.h \
                   1092:    integrate.h regs.h flags.h expr.h loop.h
                   1093: flow.o : flow.c $(CONFIG_H) $(RTL_H) flags.h insn-config.h \
                   1094:    basic-block.h regs.h hard-reg-set.h output.h
1.1.1.7 ! root     1095: combine.o : combine.c $(CONFIG_H) $(RTL_H) flags.h  \
1.1       root     1096:    insn-config.h insn-flags.h insn-codes.h insn-attr.h regs.h expr.h \
1.1.1.5   root     1097:    basic-block.h recog.h real.h hard-reg-set.h
1.1       root     1098: regclass.o : regclass.c $(CONFIG_H) $(RTL_H) hard-reg-set.h flags.h \
1.1.1.6   root     1099:    basic-block.h regs.h insn-config.h recog.h reload.h real.h bytecode.h
1.1       root     1100: local-alloc.o : local-alloc.c $(CONFIG_H) $(RTL_H) flags.h basic-block.h \
                   1101:    regs.h hard-reg-set.h insn-config.h recog.h output.h
1.1.1.4   root     1102: global.o : global.c $(CONFIG_H) $(RTL_H) flags.h  \
1.1       root     1103:    basic-block.h regs.h hard-reg-set.h insn-config.h output.h
                   1104: 
                   1105: reload.o : reload.c $(CONFIG_H) $(RTL_H) flags.h \
                   1106:    reload.h recog.h hard-reg-set.h insn-config.h insn-codes.h regs.h real.h
                   1107: reload1.o : reload1.c $(CONFIG_H) $(RTL_H) flags.h expr.h \
                   1108:    reload.h regs.h hard-reg-set.h insn-config.h insn-flags.h insn-codes.h \
                   1109:    basic-block.h recog.h output.h
                   1110: caller-save.o : caller-save.c $(CONFIG_H) $(RTL_H) flags.h \
                   1111:    regs.h hard-reg-set.h insn-config.h basic-block.h recog.h reload.h expr.h
                   1112: reorg.o : reorg.c $(CONFIG_H) $(RTL_H) conditions.h hard-reg-set.h \
                   1113:    basic-block.h regs.h insn-config.h insn-attr.h insn-flags.h recog.h \
                   1114:    flags.h output.h
                   1115: sched.o : sched.c $(CONFIG_H) $(RTL_H) basic-block.h regs.h hard-reg-set.h \
                   1116:    flags.h insn-config.h insn-attr.h
1.1.1.7 ! root     1117: final.o : final.c $(CONFIG_H) $(RTL_H) $(TREE_H) flags.h regs.h \
1.1       root     1118:    recog.h conditions.h insn-config.h insn-attr.h real.h output.h \
1.1.1.4   root     1119:    hard-reg-set.h insn-flags.h insn-codes.h gstab.h xcoffout.h defaults.h
1.1       root     1120: recog.o : recog.c $(CONFIG_H) $(RTL_H)  \
                   1121:    regs.h recog.h hard-reg-set.h flags.h insn-config.h insn-attr.h \
                   1122:    insn-flags.h insn-codes.h real.h
                   1123: reg-stack.o : reg-stack.c $(CONFIG_H) $(RTL_H) $(TREE_H) \
                   1124:    regs.h hard-reg-set.h flags.h insn-config.h
1.1.1.3   root     1125: 
1.1       root     1126: aux-output.o : aux-output.c $(CONFIG_H) \
                   1127:    $(RTL_H) regs.h hard-reg-set.h real.h insn-config.h conditions.h \
                   1128:    insn-flags.h output.h insn-attr.h insn-codes.h
1.1.1.7 ! root     1129:        $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
        !          1130:         $(MAYBE_TARGET_DEFAULT) aux-output.c
1.1       root     1131: 
1.1.1.6   root     1132: # Build auxiliary files that support ecoff format.
                   1133: mips-tfile: mips-tfile.o version.o $(LIBDEPS)
                   1134:        $(CC) $(CFLAGS) $(LDFLAGS) -o mips-tfile mips-tfile.o version.o $(LIBS)
                   1135: 
                   1136: mips-tfile.o : mips-tfile.c $(CONFIG_H) $(RTL_H)
                   1137: 
                   1138: mips-tdump: mips-tdump.o version.o $(LIBDEPS)
                   1139:        $(CC) $(CFLAGS) $(LDFLAGS) -o mips-tdump mips-tdump.o version.o $(LIBS)
                   1140: 
                   1141: mips-tdump.o : mips-tdump.c $(CONFIG_H) $(RTL_H)
                   1142: 
1.1.1.7 ! root     1143: # Build file to support OSF/rose half-pic format.
        !          1144: halfpic.o: halfpic.c $(CONFIG_H) $(RTL_H) $(TREE_H)
        !          1145: 
1.1       root     1146: # Normally this target is not used; but it is used if you
                   1147: # define ALLOCA=alloca.o.  In that case, you must get a suitable alloca.c
                   1148: # from the GNU Emacs distribution.
                   1149: alloca.o:      alloca.c
                   1150:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) $(ALLOCA_FLAGS) \
1.1.1.5   root     1151:          -c `echo $(srcdir)/alloca.c | sed 's,^\./,,'`
1.1       root     1152:        $(ALLOCA_FINISH)
                   1153: 
                   1154: # Generate header and source files from the machine description, 
                   1155: # and compile them.
                   1156: 
                   1157: .PRECIOUS: insn-config.h insn-flags.h insn-codes.h \
                   1158:   insn-emit.c insn-recog.c insn-extract.c insn-output.c insn-peep.c \
                   1159:   insn-attr.h insn-attrtab.c
                   1160: 
                   1161: # The following pair of rules has this effect:
                   1162: # genconfig is run only if the md has changed since genconfig was last run;
                   1163: # but the file insn-config.h is touched only when its contents actually change.
                   1164: 
                   1165: # Each of the other insn-* files is handled by a similar pair of rules.
                   1166: 
1.1.1.4   root     1167: # This causes an anomaly in the results of make -n
                   1168: # because insn-* is older than stamp-*
                   1169: # and thus make -n thinks that insn-* will be updated
                   1170: # and force recompilation of things that depend on it.
1.1.1.5   root     1171: # We use move-if-change precisely to avoid such recompilation.
1.1.1.4   root     1172: # But there is no way to teach make -n that it will be avoided.
                   1173: 
1.1       root     1174: # Each of the insn-*.[ch] rules has a semicolon at the end,
                   1175: # for otherwise the system Make on SunOS 4.1 never tries
1.1.1.5   root     1176: # to recompile insn-*.o.  To avoid problems and extra noise from
                   1177: # versions of make which don't like empty commands (nothing after the
                   1178: # trailing `;'), we call true for each.
1.1       root     1179: 
1.1.1.5   root     1180: insn-config.h: stamp-config ; @true
1.1       root     1181: stamp-config : md genconfig $(srcdir)/move-if-change
                   1182:        ./genconfig md > tmp-config.h
                   1183:        $(srcdir)/move-if-change tmp-config.h insn-config.h
                   1184:        touch stamp-config
                   1185: 
1.1.1.5   root     1186: insn-flags.h: stamp-flags ; @true
1.1       root     1187: stamp-flags : md genflags $(srcdir)/move-if-change
                   1188:        ./genflags md > tmp-flags.h
                   1189:        $(srcdir)/move-if-change tmp-flags.h insn-flags.h
                   1190:        touch stamp-flags
                   1191: 
1.1.1.5   root     1192: insn-codes.h: stamp-codes ; @true
1.1       root     1193: stamp-codes : md gencodes $(srcdir)/move-if-change
                   1194:        ./gencodes md > tmp-codes.h
                   1195:        $(srcdir)/move-if-change tmp-codes.h insn-codes.h
                   1196:        touch stamp-codes
                   1197: 
                   1198: insn-emit.o : insn-emit.c $(CONFIG_H) $(RTL_H) expr.h real.h output.h \
                   1199:   insn-config.h insn-flags.h insn-codes.h
                   1200:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-emit.c
                   1201: 
1.1.1.5   root     1202: insn-emit.c: stamp-emit ; @true
1.1       root     1203: stamp-emit : md genemit $(srcdir)/move-if-change
                   1204:        ./genemit md > tmp-emit.c
                   1205:        $(srcdir)/move-if-change tmp-emit.c insn-emit.c
                   1206:        touch stamp-emit
                   1207: 
                   1208: insn-recog.o : insn-recog.c $(CONFIG_H) $(RTL_H) insn-config.h recog.h \
                   1209:   real.h output.h flags.h
                   1210:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-recog.c
                   1211: 
1.1.1.5   root     1212: insn-recog.c: stamp-recog ; @true
1.1       root     1213: stamp-recog : md genrecog $(srcdir)/move-if-change
                   1214:        ./genrecog md > tmp-recog.c
                   1215:        $(srcdir)/move-if-change tmp-recog.c insn-recog.c
                   1216:        touch stamp-recog
                   1217: 
1.1.1.5   root     1218: insn-opinit.o : insn-opinit.c $(CONFIG_H) $(RTL_H) insn-codes.h insn-flags.h \
                   1219:   insn-config.h flags.h rtl.h recog.h expr.h reload.h
                   1220:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-opinit.c
                   1221: 
                   1222: insn-opinit.c: stamp-opinit ; @true
                   1223: stamp-opinit : md genopinit $(srcdir)/move-if-change
                   1224:        ./genopinit md > tmp-opinit.c
                   1225:        $(srcdir)/move-if-change tmp-opinit.c insn-opinit.c
                   1226:        touch stamp-opinit
                   1227: 
1.1       root     1228: insn-extract.o : insn-extract.c $(CONFIG_H) $(RTL_H)
                   1229:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-extract.c
                   1230: 
1.1.1.5   root     1231: insn-extract.c: stamp-extract ; @true
1.1       root     1232: stamp-extract : md genextract $(srcdir)/move-if-change
                   1233:        ./genextract md > tmp-extract.c
                   1234:        $(srcdir)/move-if-change tmp-extract.c insn-extract.c
                   1235:        touch stamp-extract
                   1236: 
                   1237: insn-peep.o : insn-peep.c $(CONFIG_H) $(RTL_H) regs.h output.h real.h
                   1238:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-peep.c
                   1239: 
1.1.1.5   root     1240: insn-peep.c: stamp-peep ; @true
1.1       root     1241: stamp-peep : md genpeep $(srcdir)/move-if-change
                   1242:        ./genpeep md > tmp-peep.c
                   1243:        $(srcdir)/move-if-change tmp-peep.c insn-peep.c
                   1244:        touch stamp-peep
                   1245: 
                   1246: insn-attrtab.o : insn-attrtab.c $(CONFIG_H) $(RTL_H) regs.h real.h output.h \
                   1247:      insn-attr.h insn-config.h
                   1248:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-attrtab.c
                   1249: 
1.1.1.5   root     1250: insn-attr.h: stamp-attr ; @true
1.1       root     1251: stamp-attr : md genattr $(srcdir)/move-if-change
                   1252:        ./genattr md > tmp-attr.h
                   1253:        $(srcdir)/move-if-change tmp-attr.h insn-attr.h
                   1254:        touch stamp-attr
                   1255: 
1.1.1.5   root     1256: insn-attrtab.c: stamp-attrtab ; @true
1.1       root     1257: stamp-attrtab : md genattrtab $(srcdir)/move-if-change
1.1.1.3   root     1258:        if cmp -s $(PREMADE_ATTRTAB_MD) md;     \
                   1259:        then                                    \
                   1260:          echo Using $(PREMADE_ATTRTAB);        \
                   1261:          cp $(PREMADE_ATTRTAB) tmp-attrtab.c;  \
                   1262:        else                                    \
                   1263:          ./genattrtab md > tmp-attrtab.c;      \
                   1264:        fi
1.1       root     1265:        $(srcdir)/move-if-change tmp-attrtab.c insn-attrtab.c
                   1266:        touch stamp-attrtab
                   1267: 
                   1268: insn-output.o : insn-output.c $(CONFIG_H) $(RTL_H) regs.h real.h conditions.h \
                   1269:     hard-reg-set.h insn-config.h insn-flags.h insn-attr.h output.h recog.h \
                   1270:     insn-codes.h
                   1271:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-output.c
                   1272: 
1.1.1.5   root     1273: insn-output.c: stamp-output ; @true
1.1       root     1274: stamp-output : md genoutput $(srcdir)/move-if-change
                   1275:        ./genoutput md > tmp-output.c
                   1276:        $(srcdir)/move-if-change tmp-output.c insn-output.c
                   1277:        touch stamp-output
                   1278: 
                   1279: # Compile the programs that generate insn-* from the machine description.
                   1280: # They are compiled with $(HOST_CC), and associated libraries,
                   1281: # since they need to run on this machine
                   1282: # even if GCC is being compiled to run on some other machine.
                   1283: 
                   1284: # $(CONFIG_H) is omitted from the deps of the gen*.o
                   1285: # because these programs don't really depend on anything 
                   1286: # about the target machine.  They do depend on config.h itself,
                   1287: # since that describes the host machine.
                   1288: 
1.1.1.6   root     1289: # Pass the md file through cpp if the target requests it.
1.1.1.7 ! root     1290: $(MD_FILE): $(MD_DEPS)
        !          1291:        rm -f $@
        !          1292:        $(MD_CPP) $(MD_CPPFLAGS) md.pre-cpp | sed 's/^# /; /g' > $@
1.1.1.6   root     1293: 
1.1       root     1294: genconfig : genconfig.o $(HOST_RTL) $(HOST_LIBDEPS)
                   1295:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o genconfig \
                   1296:          genconfig.o $(HOST_RTL) $(HOST_LIBS)
                   1297: 
1.1.1.4   root     1298: genconfig.o : genconfig.c $(RTL_H) hconfig.h
1.1       root     1299:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genconfig.c
                   1300: 
                   1301: genflags : genflags.o $(HOST_RTL) $(HOST_LIBDEPS)
                   1302:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o genflags \
                   1303:         genflags.o $(HOST_RTL) $(HOST_LIBS)
                   1304: 
1.1.1.4   root     1305: genflags.o : genflags.c $(RTL_H) hconfig.h
1.1       root     1306:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genflags.c
                   1307: 
                   1308: gencodes : gencodes.o $(HOST_RTL) $(HOST_LIBDEPS)
                   1309:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o gencodes \
                   1310:         gencodes.o $(HOST_RTL) $(HOST_LIBS)
                   1311: 
1.1.1.4   root     1312: gencodes.o : gencodes.c $(RTL_H) hconfig.h
1.1       root     1313:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/gencodes.c
                   1314: 
                   1315: genemit : genemit.o $(HOST_RTL) $(HOST_LIBDEPS)
                   1316:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o genemit \
                   1317:         genemit.o $(HOST_RTL) $(HOST_LIBS)
                   1318: 
1.1.1.4   root     1319: genemit.o : genemit.c $(RTL_H) hconfig.h
1.1       root     1320:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genemit.c
                   1321: 
1.1.1.5   root     1322: genopinit : genopinit.o $(HOST_RTL) $(HOST_LIBDEPS)
                   1323:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o genopinit \
                   1324:         genopinit.o $(HOST_RTL) $(HOST_LIBS)
                   1325: 
                   1326: genopinit.o : genopinit.c $(RTL_H) hconfig.h
                   1327:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genopinit.c
                   1328: 
1.1       root     1329: genrecog : genrecog.o $(HOST_RTL) $(HOST_LIBDEPS)
                   1330:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o genrecog \
                   1331:         genrecog.o $(HOST_RTL) $(HOST_LIBS)
                   1332: 
1.1.1.4   root     1333: genrecog.o : genrecog.c $(RTL_H) hconfig.h
1.1       root     1334:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genrecog.c
                   1335: 
                   1336: genextract : genextract.o $(HOST_RTL) $(HOST_LIBDEPS)
                   1337:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o genextract \
                   1338:         genextract.o $(HOST_RTL) $(HOST_LIBS)
                   1339: 
1.1.1.4   root     1340: genextract.o : genextract.c $(RTL_H) hconfig.h insn-config.h
1.1       root     1341:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genextract.c
                   1342: 
                   1343: genpeep : genpeep.o $(HOST_RTL) $(HOST_LIBDEPS)
                   1344:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o genpeep \
                   1345:         genpeep.o $(HOST_RTL) $(HOST_LIBS)
                   1346: 
1.1.1.4   root     1347: genpeep.o : genpeep.c $(RTL_H) hconfig.h
1.1       root     1348:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genpeep.c
                   1349: 
                   1350: genattr : genattr.o $(HOST_RTL) $(HOST_LIBDEPS)
                   1351:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o genattr \
                   1352:         genattr.o $(HOST_RTL) $(HOST_LIBS)
                   1353: 
1.1.1.4   root     1354: genattr.o : genattr.c $(RTL_H) hconfig.h
1.1       root     1355:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genattr.c
                   1356: 
1.1.1.3   root     1357: genattrtab : genattrtab.o $(HOST_RTL) $(HOST_PRINT) $(HOST_RTLANAL) $(HOST_LIBDEPS)
1.1       root     1358:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o genattrtab \
1.1.1.3   root     1359:         genattrtab.o $(HOST_RTL) $(HOST_PRINT) $(HOST_RTLANAL) $(HOST_LIBS)
1.1       root     1360: 
1.1.1.4   root     1361: genattrtab.o : genattrtab.c $(RTL_H) hconfig.h insn-config.h
1.1       root     1362:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genattrtab.c
                   1363: 
                   1364: genoutput : genoutput.o $(HOST_RTL) $(HOST_LIBDEPS)
                   1365:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o genoutput \
                   1366:         genoutput.o $(HOST_RTL) $(HOST_LIBS)
                   1367: 
1.1.1.4   root     1368: genoutput.o : genoutput.c $(RTL_H) hconfig.h
1.1       root     1369:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genoutput.c
                   1370: 
                   1371: # Compile the libraries to be used by gen*.
                   1372: # If we are not cross-building, gen* use the same .o's that cc1 will use,
                   1373: # and HOST_PREFIX_1 is `foobar', just to ensure these rules don't conflict
                   1374: # with the rules for rtl.o, alloca.o, etc.
                   1375: $(HOST_PREFIX_1)rtl.o: $(srcdir)/rtl.c $(CONFIG_H) $(RTL_H)
                   1376:        rm -f $(HOST_PREFIX)rtl.c
1.1.1.4   root     1377:        sed -e 's/config[.]h/hconfig.h/' $(srcdir)/rtl.c > $(HOST_PREFIX)rtl.c
1.1       root     1378:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(HOST_PREFIX)rtl.c
                   1379: 
1.1.1.3   root     1380: $(HOST_PREFIX_1)print-rtl.o: $(srcdir)/print-rtl.c $(CONFIG_H) $(RTL_H)
                   1381:        rm -f $(HOST_PREFIX)print-rtl.c
1.1.1.4   root     1382:        sed -e 's/config[.]h/hconfig.h/' $(srcdir)/print-rtl.c > $(HOST_PREFIX)print-rtl.c
1.1.1.3   root     1383:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(HOST_PREFIX)print-rtl.c
                   1384: 
1.1       root     1385: $(HOST_PREFIX_1)rtlanal.o: $(srcdir)/rtlanal.c $(CONFIG_H) $(RTL_H)
                   1386:        rm -f $(HOST_PREFIX)rtlanal.c
1.1.1.4   root     1387:        sed -e 's/config[.]h/hconfig.h/' $(srcdir)/rtlanal.c > $(HOST_PREFIX)rtlanal.c
1.1       root     1388:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(HOST_PREFIX)rtlanal.c
                   1389: 
                   1390: $(HOST_PREFIX_1)alloca.o: alloca.c
                   1391:        rm -f $(HOST_PREFIX)alloca.c
                   1392:        cp $(srcdir)/alloca.c $(HOST_PREFIX)alloca.c
                   1393:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(HOST_PREFIX)alloca.c
                   1394: 
                   1395: $(HOST_PREFIX_1)obstack.o: obstack.c
                   1396:        rm -f $(HOST_PREFIX)obstack.c
1.1.1.4   root     1397:        sed -e 's/config[.]h/hconfig.h/' $(srcdir)/obstack.c > $(HOST_PREFIX)obstack.c
1.1       root     1398:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(HOST_PREFIX)obstack.c
                   1399: 
                   1400: $(HOST_PREFIX_1)malloc.o: malloc.c
                   1401:        rm -f $(HOST_PREFIX)malloc.c
1.1.1.4   root     1402:        sed -e 's/config[.]h/hconfig.h/' $(srcdir)/malloc.c > $(HOST_PREFIX)malloc.c
1.1       root     1403:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(HOST_PREFIX)malloc.c
                   1404: 
                   1405: # This satisfies the dependency that we get if you cross-compile a compiler
                   1406: # that does not need to compile alloca, malloc or whatever.
                   1407: $(HOST_PREFIX_1): 
                   1408:        touch $(HOST_PREFIX_1)
                   1409: 
1.1.1.6   root     1410: # Remake bytecode files.
                   1411: # BI_ALL=bi-run.o
                   1412: BI_ALL=
                   1413: BC_ALL=bc-opname.h bc-opcode.h bc-arity.h
                   1414: BI_OBJ=bi-parser.o bi-lexer.o bi-reverse.o
                   1415: 
                   1416: 
                   1417: bc-emit.o : bc-emit.c $(CONFIG_H) $(RTL_H) real.h $(BYTECODE_H) \
                   1418:         bc-arity.h bc-opcode.h bc-typecd.h bc-typecd.def bi-run.h bytetypes.h
                   1419: bc-optab.o : bc-optab.c $(CONFIG_H) $(REAL_H) $(BYTECODE_H) \
                   1420:                bc-opcode.h bc-typecd.h bc-typecd.def
                   1421: 
                   1422: 
                   1423: bytecode: $(BI_ALL) $(BC_ALL)
                   1424: 
                   1425: bi-arity: bi-arity.o $(BI_OBJ) $(HOST_LIBDEPS)
                   1426:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o bi-arity \
                   1427:         bi-arity.o $(BI_OBJ) $(HOST_LIBS)
                   1428: bi-opcode: bi-opcode.o $(BI_OBJ) $(HOST_LIBDEPS)
                   1429:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o bi-opcode \
                   1430:         bi-opcode.o $(BI_OBJ) $(HOST_LIBS)
                   1431: bi-opname: bi-opname.o $(BI_OBJ) $(HOST_LIBDEPS)
                   1432:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o bi-opname \
                   1433:         bi-opname.o $(BI_OBJ) $(HOST_LIBS)
                   1434: 
                   1435: bi-run.o:      $(srcdir)/bi-run.c $(srcdir)/bi-run.h $(srcdir)/bc-typecd.h \
                   1436:   bc-opname.h bc-arity.h bc-opcode.h
                   1437:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c $(srcdir)/bi-run.c
                   1438: $(srcdir)/bi-parser.c $(srcdir)/bi-parser.h: $(srcdir)/bi-parser.y
                   1439:        cd $(srcdir); $(BISON) $(BISONFLAGS) -d bi-parser.y -o bi-parser.c
                   1440: bi-parser.o:   $(srcdir)/bi-parser.c $(srcdir)/bi-defs.h hconfig.h
                   1441:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) \
                   1442:           $(srcdir)/bi-parser.c
                   1443: bi-lexer.o:    $(srcdir)/bi-lexer.c $(srcdir)/bi-parser.h hconfig.h
                   1444:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) \
                   1445:           $(srcdir)/bi-lexer.c
                   1446: bi-arity.o: bi-arity.c $(srcdir)/bi-defs.h hconfig.h
                   1447:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) \
                   1448:           $(srcdir)/bi-arity.c
                   1449: bi-opcode.o: bi-opcode.c $(srcdir)/bi-defs.h hconfig.h
                   1450:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) \
                   1451:           $(srcdir)/bi-opcode.c
                   1452: bi-opname.o: bi-opname.c $(srcdir)/bi-defs.h hconfig.h
                   1453:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) \
                   1454:           $(srcdir)/bi-opname.c
                   1455: bi-reverse.o: bi-reverse.c $(srcdir)/bi-defs.h
                   1456:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) \
                   1457:           $(srcdir)/bi-reverse.c
                   1458: 
                   1459: 
                   1460: bc-arity.h: stamp-bcarity ; @true
                   1461: stamp-bcarity : $(srcdir)/bytecode.def bi-arity $(srcdir)/move-if-change
                   1462:        ./bi-arity < $(srcdir)/bytecode.def >tmp-bc-arity.h
                   1463:        $(srcdir)/move-if-change tmp-bc-arity.h bc-arity.h
                   1464:        touch stamp-bcarity
                   1465: 
                   1466: bc-opcode.h: stamp-bcopcode ; @true
                   1467: stamp-bcopcode : $(srcdir)/bytecode.def bi-opcode $(srcdir)/move-if-change
                   1468:        ./bi-opcode < $(srcdir)/bytecode.def >tmp-bcopcd.h
                   1469:        $(srcdir)/move-if-change tmp-bcopcd.h bc-opcode.h
                   1470:        touch stamp-bcopcode
                   1471: 
                   1472: bc-opname.h: stamp-bcopname ; @true
                   1473: stamp-bcopname : $(srcdir)/bytecode.def bi-opname $(srcdir)/move-if-change
                   1474:        ./bi-opname < $(srcdir)/bytecode.def >tmp-bcopnm.h
                   1475:        $(srcdir)/move-if-change tmp-bcopnm.h bc-opname.h
                   1476:        touch stamp-bcopname
                   1477: 
                   1478: bytecode.mostlyclean:
                   1479:        -rm -f bc-arity.h bc-opcode.h bc-opname.h
                   1480: 
                   1481: bytecode.distclean bytecode.clean:     bytecode.mostlyclean
                   1482:        -rm -f bi-arity bi-opcode bi-opname bi-lexer
                   1483: 
                   1484: bytecode.realclean: bytecode.clean
                   1485:        -rm -f bi-parser.c bi-parser.h
                   1486: 
                   1487: 
1.1       root     1488: # Remake cpp and protoize.
                   1489: 
                   1490: # Making the preprocessor
                   1491: cpp: cccp
                   1492:        -rm -f cpp
                   1493:        ln cccp cpp
                   1494: cccp: cccp.o cexp.o version.o $(LIBDEPS)
                   1495:        $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o cccp cccp.o cexp.o version.o $(LIBS)
                   1496: cexp.o: $(srcdir)/cexp.c $(CONFIG_H)
                   1497:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c $(srcdir)/cexp.c
                   1498: $(srcdir)/cexp.c: $(srcdir)/cexp.y
                   1499:        cd $(srcdir); $(BISON) -o cexp.c cexp.y
1.1.1.5   root     1500: cccp.o: cccp.c $(CONFIG_H) pcp.h version.c config.status
1.1       root     1501: # The reason we use $(libdir)/g++-include rather than using libsubdir
                   1502: # is for compatibility with the current version of libg++.
                   1503:        $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
1.1.1.2   root     1504:          -DGCC_INCLUDE_DIR=\"$(libsubdir)/include\" \
1.1.1.7 ! root     1505:          -DGPLUSPLUS_INCLUDE_DIR=\"$(gxx_include_dir)\" \
        !          1506:          -DLOCAL_INCLUDE_DIR=\"$(includedir)\" \
1.1.1.2   root     1507:          -DCROSS_INCLUDE_DIR=\"$(libsubdir)/sys-include\" \
1.1.1.5   root     1508:          -DTOOL_INCLUDE_DIR=\"$(tooldir)/include\" \
1.1       root     1509:          -c `echo $(srcdir)/cccp.c | sed 's,^\./,,'`
                   1510: 
1.1.1.5   root     1511: # Note for the stamp targets, we run the program `true' instead of
                   1512: # having an empty command (nothing following the semicolon).
                   1513: 
1.1.1.4   root     1514: proto: config.status protoize unprotoize SYSCALLS.c.X
1.1       root     1515: 
1.1.1.2   root     1516: protoize: protoize.o getopt.o getopt1.o getpwd.o version.o $(LIBDEPS)
1.1       root     1517:        $(CC) $(ALL_CFLAGS) $(LDFLAGS) \
1.1.1.7 ! root     1518:          protoize.o getopt.o getopt1.o getpwd.o version.o $(LIBS) -o protoize
1.1.1.5   root     1519: protoize.o: stamp-proto ; @true
1.1.1.3   root     1520: 
                   1521: unprotoize: unprotoize.o getopt.o getopt1.o getpwd.o version.o $(LIBDEPS)
                   1522:        $(CC) $(ALL_CFLAGS) $(LDFLAGS) \
1.1.1.7 ! root     1523:          unprotoize.o getopt.o getopt1.o getpwd.o version.o $(LIBS) \
        !          1524:           -o unprotoize
1.1.1.5   root     1525: unprotoize.o:  stamp-proto ; @true
1.1.1.3   root     1526: 
                   1527: stamp-proto:   $(srcdir)/protoize.c getopt.h $(CONFIG_H)
1.1       root     1528:        $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
                   1529:           -DGCC_INCLUDE_DIR=\"$(libsubdir)/include\" \
1.1.1.7 ! root     1530:          -DGPLUSPLUS_INCLUDE_DIR=\"$(gxx_include_dir)\" \
1.1       root     1531:           -DCROSS_INCLUDE_DIR=\"$(libsubdir)/sys-include\" \
1.1.1.5   root     1532:          -DTOOL_INCLUDE_DIR=\"$(tooldir)/include\" \
1.1.1.7 ! root     1533:          -DLOCAL_INCLUDE_DIR=\"$(includedir)\" \
1.1       root     1534:          -DSTD_PROTO_DIR=\"$(libsubdir)\" \
1.1.1.3   root     1535:          -DUNPROTOIZE $(srcdir)/protoize.c
                   1536:        mv protoize.o unprotoize.o
1.1       root     1537:        $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
                   1538:           -DGCC_INCLUDE_DIR=\"$(libsubdir)/include\" \
1.1.1.7 ! root     1539:          -DGPLUSPLUS_INCLUDE_DIR=\"$(gxx_include_dir)\" \
1.1       root     1540:           -DCROSS_INCLUDE_DIR=\"$(libsubdir)/sys-include\" \
1.1.1.5   root     1541:          -DTOOL_INCLUDE_DIR=\"$(tooldir)/include\" \
1.1.1.7 ! root     1542:          -DLOCAL_INCLUDE_DIR=\"$(includedir)\" \
1.1       root     1543:          -DSTD_PROTO_DIR=\"$(libsubdir)\" \
1.1.1.3   root     1544:          $(srcdir)/protoize.c
1.1.1.4   root     1545:        touch stamp-proto
1.1       root     1546: 
                   1547: getopt.o: $(srcdir)/getopt.c getopt.h
                   1548:        $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) $(srcdir)/getopt.c
                   1549: getopt1.o: $(srcdir)/getopt1.c getopt.h
                   1550:        $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) $(srcdir)/getopt1.c
                   1551: 
                   1552: # This info describes the target machine, so compile with GCC just built.
1.1.1.7 ! root     1553: SYSCALLS.c.X: $(srcdir)/sys-types.h $(srcdir)/sys-protos.h $(GCC_PASSES) stmp-int-hdrs
1.1.1.3   root     1554:        -rm -f SYSCALLS.c tmp-SYSCALLS.s
                   1555:        cat $(srcdir)/sys-types.h $(srcdir)/sys-protos.h > SYSCALLS.c
1.1       root     1556:        $(GCC_FOR_TARGET) $(GCC_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
1.1.1.3   root     1557:          -aux-info $@ -S -o tmp-SYSCALLS.s SYSCALLS.c
                   1558:        -rm -f SYSCALLS.c tmp-SYSCALLS.s
                   1559: 
1.1.1.6   root     1560: 
1.1.1.3   root     1561: test-protoize-simple: ./protoize ./unprotoize $(GCC_PASSES)
                   1562:        -rm -f tmp-proto.[cso]
                   1563:        cp $(srcdir)/protoize.c tmp-proto.c
                   1564:        chmod u+w tmp-proto.c
                   1565:        ./protoize -N -B ./ -x getopt.h -c "-B./ -Wall -Wwrite-strings \
                   1566:          $(CFLAGS) $(INCLUDES) \
                   1567:          -DGCC_INCLUDE_DIR=0 \
                   1568:          -DGPLUSPLUS_INCLUDE_DIR=0 \
                   1569:          -DCROSS_INCLUDE_DIR=0 \
1.1.1.5   root     1570:          -DTOOL_INCLUDE_DIR=0 \
1.1.1.3   root     1571:          -DSTD_PROTO_DIR=0" tmp-proto.c
1.1.1.4   root     1572:        @echo '**********' Expect 400 lines of differences.
1.1.1.3   root     1573:        -diff $(srcdir)/protoize.c tmp-proto.c > tmp-proto.diff
                   1574:        -wc -l tmp-proto.diff
                   1575:        ./unprotoize -N -x getopt.h -c "-B./ -Wall -Wwrite-strings \
                   1576:          $(CFLAGS) $(INCLUDES) \
                   1577:          -DGCC_INCLUDE_DIR=0 \
                   1578:          -DGPLUSPLUS_INCLUDE_DIR=0 \
                   1579:          -DCROSS_INCLUDE_DIR=0 \
1.1.1.5   root     1580:          -DTOOL_INCLUDE_DIR=0 \
1.1.1.3   root     1581:          -DSTD_PROTO_DIR=0" tmp-proto.c
                   1582:        @echo Expect zero differences.
                   1583:        diff $(srcdir)/protoize.c tmp-proto.c | cat
                   1584:        -rm -f tmp-proto.[cso]
1.1       root     1585: 
1.1.1.5   root     1586: # Build the include directory.  The stamp files are stmp-* rather than
                   1587: # stamp-* so that mostlyclean does not force the include directory to
                   1588: # be rebuilt.
                   1589: 
                   1590: # Build the include directory except for float.h (which depends upon
                   1591: # enquire).
1.1.1.7 ! root     1592: stmp-int-hdrs: stmp-fixinc $(USER_H) xlimits.h objc-headers
1.1.1.5   root     1593: # Copy in the headers provided with gcc.
                   1594: # The sed command gets just the last file name component;
                   1595: # this is necessary because VPATH could add a dirname.
                   1596: # Using basename would be simpler, but some systems don't have it.
                   1597:        objdir=`pwd`; \
                   1598:        cd $(srcdir); \
                   1599:        for file in $(USER_H); do \
                   1600:          realfile=`echo $$file | sed -e 's|.*/\([^/]*\)$$|\1|'`; \
                   1601:          rm -f $$objdir/include/$$realfile; \
1.1.1.7 ! root     1602:          cp ginclude/$$realfile $$objdir/include; \
1.1.1.5   root     1603:          chmod a+r $$objdir/include/$$realfile; \
                   1604:        done
                   1605:        rm -f include/limits.h
                   1606:        cp xlimits.h include/limits.h
                   1607:        chmod a+r include/limits.h
                   1608: # Install the README
                   1609:        rm -f include/README
                   1610:        cp $(srcdir)/README-fixinc include/README
                   1611:        chmod a+r include/README
                   1612:        touch stmp-int-hdrs
                   1613: 
                   1614: # Build the complete include directory.
                   1615: stmp-headers: stmp-int-hdrs gfloat.h
                   1616:        rm -f include/float.h
                   1617:        cp gfloat.h include/float.h
                   1618:        chmod a+r include/float.h
                   1619:        touch stmp-headers
                   1620: 
                   1621: # Build fixed copies of system files.
1.1.1.7 ! root     1622: stmp-fixinc: $(srcdir)/$(FIXINCLUDES) gsyslimits.h
1.1.1.5   root     1623:        rm -rf include
                   1624:        mkdir include
                   1625:        if [ x$(FIXINCLUDES) != xMakefile.in ]; \
                   1626:        then \
                   1627:          for dir in $(SYSTEM_HEADER_DIR) $(OTHER_FIXINCLUDES_DIRS); do \
                   1628:            if [ -d $$dir ]; \
                   1629:            then \
1.1.1.7 ! root     1630:              $(SHELL) $(srcdir)/$(FIXINCLUDES) include $$dir; \
1.1.1.5   root     1631:            else true; fi; \
                   1632:          done; \
                   1633:        else true; \
                   1634:        fi
                   1635:        rm -f include/syslimits.h
                   1636:        if [ -f include/limits.h ]; then \
                   1637:          mv include/limits.h include/syslimits.h; \
                   1638:        else \
                   1639:          cp $(srcdir)/gsyslimits.h include/syslimits.h; \
                   1640:        fi
                   1641:        chmod a+r include/syslimits.h
                   1642:        touch stmp-fixinc
                   1643: 
                   1644: # copy objc header files into build directory
1.1.1.6   root     1645: objc-headers: stmp-fixinc
1.1.1.7 ! root     1646:        if [ -d include ]; then true; else mkdir include; fi
1.1.1.5   root     1647:        if [ -d objc ]; then true; else mkdir objc; fi
                   1648:        thisdir1=`pwd`; \
                   1649:        srcdir1=`cd $(srcdir); pwd`; \
                   1650:        cd objc; \
                   1651:        $(MAKE) -f $${srcdir1}/objc/Makefile copy-headers \
                   1652:        srcdir=$${srcdir1} tooldir=$(tooldir) AR="$(AR)" AR_FLAGS="$(AR_FLAGS)" \
                   1653:        GCC_FOR_TARGET="$${thisdir1}/xgcc -B$${thisdir1}/" \
                   1654:        GCC_CFLAGS="$(GCC_CFLAGS)" incinstalldir=$${thisdir1}/include
                   1655:        touch objc-headers
1.1.1.6   root     1656: 
                   1657: # Files related to the fixproto script.
                   1658: 
                   1659: deduced.h: $(GCC_PASSES) $(srcdir)/scan-types.sh stmp-int-hdrs
                   1660:        CC="$(GCC_FOR_TARGET) $(GCC_CFLAGS) $(ALL_CPPFLAGS) -I. -I$(srcdir) -Iinclude -I${SYSTEM_HEADER_DIR}"; \
                   1661:          export CC; \
1.1.1.7 ! root     1662:          $(SHELL) $(srcdir)/scan-types.sh "$(srcdir)" >tmp-deduced.h
1.1.1.6   root     1663:        mv tmp-deduced.h deduced.h
                   1664: 
                   1665: gen-protos: gen-protos.o scan.o $(HOST_LIBDEPS)
                   1666:        ${HOST_CC} $(HOST_CFLAGS) $(HOST_LDFLAGS) -o gen-protos \
                   1667:          gen-protos.o scan.o $(HOST_LIBS)
                   1668: 
                   1669: gen-protos.o: gen-protos.c scan.h hconfig.h
                   1670:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/gen-protos.c
                   1671: 
                   1672: scan.o: scan.c scan.h hconfig.h
                   1673:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/scan.c
                   1674: 
                   1675: xsys-protos.h: $(GCC_PASSES) $(srcdir)/sys-protos.h deduced.h gen-protos Makefile
                   1676:        cat deduced.h $(srcdir)/sys-protos.h > fixtmp.c
1.1.1.7 ! root     1677:        $(GCC_FOR_TARGET) fixtmp.c -w -U__SIZE_TYPE__ -U__PTRDIFF_TYPE_ -U__WCHAR_TYPE__ -E \
1.1.1.6   root     1678:          | sed -e 's/  / /g' -e 's/ *(/ (/g' -e 's/ [ ]*/ /g' -e 's/( )/()/' \
                   1679:          | ./gen-protos >xsys-protos.h
                   1680:        rm -rf fixtmp.c
                   1681: 
                   1682: fix-header: fix-header.o scan-decls.o scan.o xsys-protos.h $(HOST_LIBDEPS)
                   1683:        $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o fix-header \
                   1684:          fix-header.o scan-decls.o scan.o $(HOST_LIBS)
                   1685: 
                   1686: fix-header.o: fix-header.c obstack.h scan.h xsys-protos.h hconfig.h
                   1687:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/fix-header.c
                   1688: 
                   1689: scan-decls.o: scan-decls.c scan.h hconfig.h
                   1690:        $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/scan-decls.c
                   1691: 
                   1692: # stmp-fixproto depends on this, not on fix-header directly.
                   1693: # The idea is to make sure fix-header gets built,
                   1694: # but not rerun fixproto after each stage
                   1695: # just because fix-header's mtime has changed.
                   1696: fixhdr.ready: fix-header
                   1697:        -if [ -f fixhdr.ready ] ; then \
                   1698:                true; \
                   1699:        else \
                   1700:                touch fixhdr.ready; \
                   1701:        fi
                   1702: 
                   1703: # stmp-headers is to make sure fixincludes has already finished.
                   1704: # The if statement is so that we don't run fixproto a second time
                   1705: # if it has already been run on the files in `include'.
                   1706: stmp-fixproto: fixhdr.ready fixproto stmp-headers
                   1707:        @echo "Various warnings and error messages from fixproto are normal"
                   1708:        -if [ -d include ] ; then true; else mkdir include; fi
1.1.1.7 ! root     1709:        -if [ -f include/fixed ] ; then true; \
1.1.1.6   root     1710:        else \
1.1.1.7 ! root     1711:          : This line works around a 'make' bug in BSDI 1.1.; \
1.1.1.6   root     1712:          CPP="$(GCC_FOR_TARGET) -E"; export CPP; \
1.1.1.7 ! root     1713:            FIXPROTO_DEFINES="$(FIXPROTO_DEFINES)"; export FIXPROTO_DEFINES; \
        !          1714:            $(SHELL) ${srcdir}/fixproto include include $(SYSTEM_HEADER_DIR); \
1.1.1.6   root     1715:          touch include/fixed; \
                   1716:        fi
                   1717:        touch stmp-fixproto
1.1.1.5   root     1718: 
1.1       root     1719: # Remake the info files.
                   1720: 
1.1.1.5   root     1721: doc: info
1.1.1.7 ! root     1722: info: $(srcdir)/cpp.info $(srcdir)/gcc.info lang.info
1.1       root     1723: 
1.1.1.3   root     1724: $(srcdir)/cpp.info: cpp.texi
1.1.1.5   root     1725:        cd $(srcdir); $(MAKEINFO) cpp.texi
1.1       root     1726: 
1.1.1.3   root     1727: $(srcdir)/gcc.info: gcc.texi extend.texi install.texi invoke.texi \
                   1728:                md.texi rtl.texi tm.texi 
1.1.1.5   root     1729:        cd $(srcdir); $(MAKEINFO) gcc.texi
                   1730: 
1.1.1.7 ! root     1731: dvi: $(srcdir)/gcc.dvi $(srcdir)/cpp.dvi lang.dvi
1.1.1.3   root     1732: 
1.1.1.4   root     1733: # This works with GNU Make's default rule.
                   1734: $(srcdir)/gcc.dvi: gcc.texi extend.texi install.texi invoke.texi \
                   1735:                md.texi rtl.texi tm.texi 
1.1.1.5   root     1736:        $(TEXI2DVI) $<
1.1.1.4   root     1737: 
                   1738: # This works with GNU Make's default rule.
                   1739: $(srcdir)/cpp.dvi: cpp.texi
1.1.1.5   root     1740:        $(TEXI2DVI) $<
1.1.1.4   root     1741: 
1.1.1.3   root     1742: $(srcdir)/INSTALL: install1.texi install.texi
1.1.1.6   root     1743:        $(MAKEINFO) -D INSTALLONLY --no-header --no-split \
                   1744:          `echo $(srcdir)/install1.texi | sed 's,^\./,,'`
1.1       root     1745: 
                   1746: # Deletion of files made during compilation.
                   1747: # There are four levels of this:
1.1.1.3   root     1748: #   `mostlyclean', `clean', `distclean' and `realclean'.
1.1       root     1749: # `mostlyclean' is useful while working on a particular type of machine.
1.1.1.2   root     1750: # It deletes most, but not all, of the files made by compilation.
1.1       root     1751: # It does not delete libgcc.a or its parts, so it won't have to be recompiled.
1.1.1.2   root     1752: # `clean' deletes everything made by running `make all'.
1.1.1.3   root     1753: # `distclean' also deletes the files made by config.
1.1       root     1754: # `realclean' also deletes everything that could be regenerated automatically.
1.1.1.7 ! root     1755: # We remove as much from the language subdirectories as we can
        !          1756: # (less duplicated code).
1.1       root     1757: 
1.1.1.3   root     1758: 
1.1.1.7 ! root     1759: mostlyclean: bytecode.mostlyclean lang.mostlyclean
1.1       root     1760:        -rm -f $(STAGESTUFF)
1.1.1.4   root     1761: # Clean the objc subdir if we created one.
                   1762:        if [ -d objc ]; then \
                   1763:          srcdir1=`cd $(srcdir); pwd`; \
                   1764:          cd objc; $(MAKE) -f $$srcdir1/objc/Makefile mostlyclean; \
                   1765:        else true; fi
                   1766:        -rm -f libobjc.a
1.1       root     1767: # Delete the temporary source copies for cross compilation.
                   1768:        -rm -f $(HOST_PREFIX_1)rtl.c $(HOST_PREFIX_1)rtlanal.c
                   1769:        -rm -f $(HOST_PREFIX_1)alloca.c $(HOST_PREFIX_1)malloc.c
                   1770:        -rm -f $(HOST_PREFIX_1)obstack.c 
                   1771: # Delete the temp files made in the course of building libgcc.a.
1.1.1.4   root     1772:        -rm -f tmplibgcc* tmpcopy xlimits.h
1.1       root     1773:        for name in $(LIB1FUNCS); do rm -f $${name}.c; done
                   1774: # Delete other temporary files.
1.1.1.5   root     1775:        -rm -f tmp-float.h tmp-gcc.xtar.gz
1.1.1.3   root     1776:        -rm -f tmp-foo1 tmp-foo2 tmp-proto.* tmp-unproto.1 tmp-SYSCALLS.s
1.1.1.7 ! root     1777:        -rm -f tmp-c-parse.y tmp-objc-prs.y tmp-gperf.h
1.1       root     1778: # Delete the stamp files.
                   1779:        -rm -f stamp-* tmp-*
1.1.1.7 ! root     1780:        -rm -f */stamp-* */tmp-*
1.1.1.2   root     1781: # Delete debugging dump files.
1.1       root     1782:        -rm -f *.greg *.lreg *.combine *.flow *.cse *.jump *.rtl *.tree *.loop
1.1.1.2   root     1783:        -rm -f *.dbr *.jump2 *.sched *.cse2 *.sched2 *.stack
1.1.1.7 ! root     1784:        -rm -f */*.greg */*.lreg */*.combine */*.flow */*.cse */*.jump */*.rtl
        !          1785:        -rm -f */*.tree */*.loop */*.dbr */*.jump2 */*.sched */*.cse2
        !          1786:        -rm -f */*.sched2 */*.stack
1.1.1.2   root     1787: # Delete some files made during installation.
1.1.1.5   root     1788:        -rm -f specs gfloat.h float.h-* enquire SYSCALLS.c.X SYSCALLS.c
1.1.1.7 ! root     1789:        -rm -f collect collect2 mips-tfile mips-tdump alloca.s
1.1.1.6   root     1790: # Delete files generated for fixproto
                   1791:        -rm -rf fix-header xsys-protos.h deduced.h tmp-deduced.h \
                   1792:          gen-protos fixproto.list fixtmp.* fixhdr.ready
1.1.1.2   root     1793: # Delete unwanted output files from TeX.
1.1       root     1794:        -rm -f *.toc *.log *.vr *.fn *.cp *.tp *.ky *.pg
1.1.1.7 ! root     1795:        -rm -f */*.toc */*.log */*.vr */*.fn */*.cp */*.tp */*.ky */*.pg
1.1.1.2   root     1796: # Delete sorted indices we don't actually use.
                   1797:        -rm -f gcc.vrs gcc.kys gcc.tps gcc.pgs gcc.fns
                   1798: # Delete core dumps.
1.1.1.7 ! root     1799:        -rm -f core */core
1.1       root     1800: 
1.1.1.3   root     1801: # Delete all files made by compilation
                   1802: # that don't exist in the distribution.
1.1.1.7 ! root     1803: clean: mostlyclean bytecode.clean lang.clean
1.1.1.3   root     1804: # It may not be quite desirable to delete unprotoize.c here,
                   1805: # but the spec for `make clean' requires it.
                   1806: # Using unprotoize.c is not quite right in the first place, 
                   1807: # but what better way is there?
1.1.1.7 ! root     1808:        -rm -f libgcc.a libgcc1.a libgcc2.a libgcc2.ready
        !          1809:        -rm -f libgcc1.null $(LIB2FUNCS_EXTRA)
1.1.1.3   root     1810:        -rm -f *.dvi
1.1.1.7 ! root     1811:        -rm -f */*.dvi
1.1.1.6   root     1812:        -if [ -f md.pre-cpp ]; then \
                   1813:          rm -f md ; \
                   1814:        fi
1.1.1.5   root     1815: # Delete the include directory.
1.1.1.7 ! root     1816:        -rm -rf stmp-* include objc-headers
        !          1817:        -rm -f */stmp-*
        !          1818: # Delete files used by the "multilib" facility (including libgcc subdirs).
        !          1819:        -rm -f multilib.h tmpmultilib*
        !          1820:        -if [ "x$(MULTILIB_DIRNAMES)" != x ] ; then \
        !          1821:          rm -rf $(MULTILIB_DIRNAMES); \
        !          1822:        else if [ "x$(MULTILIB_OPTIONS)" != x ] ; then \
        !          1823:          rm -rf `echo $(MULTILIB_OPTIONS) | sed -e 's/\// /g'`; \
        !          1824:        fi ; fi
1.1       root     1825: 
1.1.1.3   root     1826: # Delete all files that users would normally create
                   1827: # while building and installing GCC.
1.1.1.7 ! root     1828: distclean: clean bytecode.distclean lang.distclean
1.1.1.6   root     1829:        -rm -f tm.h aux-output.c config.h config.status tconfig.h hconfig.h
                   1830:        -rm -f md md.pre-cpp
1.1.1.3   root     1831:        -rm -f Makefile *.oaux
                   1832:        -rm -fr stage1 stage2 stage3 stage4
1.1.1.7 ! root     1833:        -rm -f */stage1 */stage2 */stage3 */stage4 */include
1.1.1.5   root     1834:        -rm -f objc-parse.output
                   1835:        -rm -f c-parse.output
1.1       root     1836: 
1.1.1.2   root     1837: # Delete anything likely to be found in the source directory
1.1       root     1838: # that shouldn't be in the distribution.
1.1.1.7 ! root     1839: extraclean: distclean lang.extraclean
1.1.1.5   root     1840:        -rm -rf =* ./"#"* *~* config/=* config/"#"* config/*~*
1.1.1.3   root     1841:        -rm -f patch* *.orig *.rej config/patch* config/*.orig config/*.rej
1.1.1.5   root     1842:        -rm -f config/*/=* config/*/"#"* config/*/*~*
                   1843:        -rm -f config/*/*.orig config/*/*.rej
                   1844:        -rm -f *.dvi *.oaux *.d *.[zZ] *.gz
                   1845:        -rm -f *.tar *.xtar *diff *.diff.* *.tar.* *.xtar.* *diffs
                   1846:        -rm -f *lose config/*lose config/*/*lose
1.1.1.4   root     1847:        -rm -f *.s *.s[0-9] *.i install1.texi config/ChangeLog
1.1.1.7 ! root     1848:        -rm -f */=* */"#"* */*~*
        !          1849:        -rm -f */patch* */*.orig */*.rej
        !          1850:        -rm -f */*.dvi */*.oaux */*.d */*.[zZ] */*.gz
        !          1851:        -rm -f */*.tar */*.xtar */*diff */*.diff.* */*.tar.* */*.xtar.* */*diffs
        !          1852:        -rm -f */*lose */*.s */*.s[0-9] */*.i
1.1       root     1853: 
                   1854: # Get rid of every file that's generated from some other file.
                   1855: # Most of these files ARE PRESENT in the GCC distribution.
1.1.1.7 ! root     1856: realclean: distclean bytecode.realclean lang.realclean
        !          1857:        -rm -f c-parse.y c-gperf.h objc-parse.y
1.1       root     1858:        -rm -f objc-parse.c objc-parse.output
                   1859:        -rm -f c-parse.c c-parse.h c-parse.output
                   1860:        -rm -f cexp.c cexp.output TAGS 
                   1861:        -rm -f cpp.info* cpp.??s cpp.*aux
                   1862:        -rm -f gcc.info* gcc.??s gcc.*aux
                   1863: 
                   1864: # Entry points `install' and `uninstall'.
                   1865: # Also use `install-collect2' to install collect2 when the config files don't.
                   1866: 
1.1.1.4   root     1867: # The semicolon is to prevent the install.sh -> install default rule
1.1.1.5   root     1868: # from doing anything.  Having it run true helps avoid problems and
                   1869: # noise from versions of make which don't like to have null commands.
                   1870: install: $(INSTALL_TARGET) ; @true
                   1871: 
                   1872: # Copy the compiler files into directories where they will be run.
1.1.1.6   root     1873: install-normal: install-common $(INSTALL_HEADERS) $(INSTALL_LIBGCC) \
1.1.1.7 ! root     1874:     install-man install-info lang.install-normal
1.1       root     1875: 
1.1.1.4   root     1876: # Do nothing while making gcc with a cross-compiler. The person who
                   1877: # makes gcc for the target machine has to know how to put a complete
                   1878: # gcc together by hand.
                   1879: install-build: force
                   1880:        @echo You have to install gcc on your target machine by hand.
                   1881: 
1.1       root     1882: # Run this on the target machine
                   1883: # to finish installation of cross compiler.
                   1884: install-cross-rest: install-float-h-cross
                   1885: 
                   1886: # Install float.h for cross compiler.
                   1887: # Run this on the target machine!
1.1.1.6   root     1888: install-float-h-cross: install-dir
1.1.1.5   root     1889: #      if [ -f enquire ] ; then true; else false; fi
                   1890: # Note: don't use -.  We should fail right away if enquire was not made.
                   1891:        ./enquire -f > $(tmpdir)/float.h
1.1       root     1892:        -rm -f $(libsubdir)/include/float.h
1.1.1.4   root     1893:        $(INSTALL_DATA) $(tmpdir)/float.h $(libsubdir)/include/float.h
                   1894:        -rm -f $(tmpdir)/float.h
1.1       root     1895:        chmod a-x $(libsubdir)/include/float.h
                   1896: 
                   1897: # Create the installation directory.
                   1898: install-dir:
1.1.1.3   root     1899:        -if [ -d $(libdir) ] ; then true ; else mkdir $(libdir) ; fi
                   1900:        -if [ -d $(libdir)/gcc-lib ] ; then true ; else mkdir $(libdir)/gcc-lib ; fi
1.1.1.6   root     1901: # This dir isn't currently searched by cpp.
1.1.1.5   root     1902: #      -if [ -d $(libdir)/gcc-lib/include ] ; then true ; else mkdir $(libdir)/gcc-lib/include ; fi
1.1.1.3   root     1903:        -if [ -d $(libdir)/gcc-lib/$(target) ] ; then true ; else mkdir $(libdir)/gcc-lib/$(target) ; fi
                   1904:        -if [ -d $(libdir)/gcc-lib/$(target)/$(version) ] ; then true ; else mkdir $(libdir)/gcc-lib/$(target)/$(version) ; fi
                   1905:        -if [ -d $(libdir)/gcc-lib/$(target)/$(version)/include ] ; then true ; else mkdir $(libdir)/gcc-lib/$(target)/$(version)/include ; fi
                   1906:        -if [ -d $(bindir) ] ; then true ; else mkdir $(bindir) ; fi
1.1.1.4   root     1907:        -if [ -d $(includedir) ] ; then true ; else mkdir $(includedir) ; fi
1.1.1.5   root     1908:        -if [ -d $(tooldir) ] ; then true ; else mkdir $(tooldir) ; fi
                   1909:        -if [ -d $(assertdir) ] ; then true ; else mkdir $(assertdir) ; fi
                   1910:        -if [ -d $(infodir) ] ; then true ; else mkdir $(infodir) ; fi
1.1       root     1911: # We don't use mkdir -p to create the parents of mandir,
                   1912: # because some systems don't support it.
                   1913: # Instead, we use this technique to create the immediate parent of mandir.
1.1.1.3   root     1914:        -parent=`echo $(mandir)|sed -e 's@/[^/]*$$@@'`; \
1.1       root     1915:        if [ -d $$parent ] ; then true ; else mkdir $$parent ; fi
                   1916:        -if [ -d $(mandir) ] ; then true ; else mkdir $(mandir) ; fi
                   1917: 
                   1918: # Install the compiler executables built during cross compilation.
1.1.1.7 ! root     1919: install-common: native install-dir xgcc $(EXTRA_PARTS) lang.install-common
1.1       root     1920:        for file in $(COMPILERS); do \
                   1921:          if [ -f $$file ] ; then \
                   1922:            rm -f $(libsubdir)/$$file; \
                   1923:            $(INSTALL_PROGRAM) $$file $(libsubdir)/$$file; \
                   1924:          else true; \
                   1925:          fi; \
                   1926:        done
1.1.1.7 ! root     1927:        for file in $(EXTRA_PASSES) $(EXTRA_PROGRAMS) $(USE_COLLECT2) ..; do \
1.1       root     1928:          if [ x"$$file" != x.. ]; then \
                   1929:            rm -f $(libsubdir)/$$file; \
                   1930:            $(INSTALL_PROGRAM) $$file $(libsubdir)/$$file; \
                   1931:          else true; fi; \
                   1932:        done
1.1.1.7 ! root     1933:        for file in $(EXTRA_PARTS) ..; do \
        !          1934:          if [ x"$$file" != x.. ]; then \
        !          1935:            rm -f $(libsubdir)/$$file; \
        !          1936:            $(INSTALL_DATA) $$file $(libsubdir)/$$file; \
        !          1937:          else true; fi; \
        !          1938:        done
1.1.1.4   root     1939: # Don't mess with specs if it doesn't exist yet.
                   1940:        -if [ -f specs ] ; then \
                   1941:          rm -f $(libsubdir)/specs; \
                   1942:          $(INSTALL_DATA) specs $(libsubdir)/specs; \
                   1943:        fi
1.1.1.5   root     1944: # Install the driver program as $(target)-gcc
1.1       root     1945: # and also as either gcc (if native) or $(tooldir)/bin/gcc.
                   1946:        -if [ -f gcc-cross ] ; then \
1.1.1.5   root     1947:          rm -f $(bindir)/$(target)-gcc; \
                   1948:          $(INSTALL_PROGRAM) gcc-cross $(bindir)/$(target)-gcc; \
1.1       root     1949:          if [ -d $(tooldir)/bin/. ] ; then \
                   1950:            rm -f $(tooldir)/bin/gcc; \
                   1951:            $(INSTALL_PROGRAM) gcc-cross $(tooldir)/bin/gcc; \
                   1952:          else true; fi; \
                   1953:        else \
                   1954:          rm -f $(bindir)/gcc; \
1.1.1.4   root     1955:          $(INSTALL_PROGRAM) xgcc $(bindir)/gcc; \
1.1.1.5   root     1956:          rm -f $(bindir)/$(target)-gcc-1; \
                   1957:          ln $(bindir)/gcc $(bindir)/$(target)-gcc-1; \
                   1958:          mv $(bindir)/$(target)-gcc-1 $(bindir)/$(target)-gcc; \
1.1       root     1959:        fi
1.1.1.4   root     1960: # Install protoize if it was compiled.
                   1961:        -if [ -f protoize ]; \
                   1962:        then \
                   1963:            rm -f $(bindir)/protoize; \
                   1964:            $(INSTALL_PROGRAM) protoize $(bindir)/protoize; \
                   1965:            rm -f $(bindir)/unprotoize; \
                   1966:            $(INSTALL_PROGRAM) unprotoize $(bindir)/unprotoize; \
                   1967:            rm -f $(libsubdir)/SYSCALLS.c.X; \
                   1968:            $(INSTALL_DATA) SYSCALLS.c.X $(libsubdir)/SYSCALLS.c.X; \
                   1969:            chmod a-x $(libsubdir)/SYSCALLS.c.X; \
                   1970:        fi
1.1       root     1971:        -rm -f $(libsubdir)/cpp
                   1972:        $(INSTALL_PROGRAM) cpp $(libsubdir)/cpp
                   1973: 
1.1.1.5   root     1974: # Install the info files.
1.1.1.7 ! root     1975: install-info: doc install-dir lang.install-info
1.1.1.5   root     1976:        -rm -f $(infodir)/cpp.info* $(infodir)/gcc.info*
                   1977:        cd $(srcdir); for f in cpp.info* gcc.info*; \
                   1978:        do $(INSTALL_DATA) $$f $(infodir)/$$f; done
                   1979:        -chmod a-x $(infodir)/cpp.info* $(infodir)/gcc.info*
                   1980: 
1.1       root     1981: # Install the man pages.
1.1.1.7 ! root     1982: install-man: install-dir $(srcdir)/gcc.1 $(srcdir)/cccp.1 lang.install-man
1.1       root     1983:        -rm -f $(mandir)/gcc$(manext)
1.1.1.3   root     1984:        -$(INSTALL_DATA) $(srcdir)/gcc.1 $(mandir)/gcc$(manext)
                   1985:        -chmod a-x $(mandir)/gcc$(manext)
1.1.1.2   root     1986:        -rm -f $(mandir)/cccp$(manext)
1.1.1.3   root     1987:        -$(INSTALL_DATA) $(srcdir)/cccp.1 $(mandir)/cccp$(manext)
                   1988:        -chmod a-x $(mandir)/cccp$(manext)
1.1       root     1989: 
                   1990: # Install the library.
1.1.1.3   root     1991: install-libgcc: libgcc.a install-dir
1.1       root     1992:        -if [ -f libgcc.a ] ; then \
                   1993:          rm -f $(libsubdir)/libgcc.a; \
                   1994:          $(INSTALL_DATA) libgcc.a $(libsubdir)/libgcc.a; \
                   1995:          if $(RANLIB_TEST) ; then \
                   1996:            (cd $(libsubdir); $(RANLIB) libgcc.a); else true; fi; \
                   1997:          chmod a-x $(libsubdir)/libgcc.a; \
                   1998:        else true; fi
                   1999: 
1.1.1.7 ! root     2000: # Install multiple versions of libgcc.a.
        !          2001: install-multilib: stmp-multilib install-dir
        !          2002:        for i in `$(GCC_FOR_TARGET) --print-multi-lib`; do \
        !          2003:          dir=`echo $$i | sed -e 's/;.*$$//'`; \
        !          2004:          if [ -d $(libsubdir)/$${dir} ]; then true; else mkdir $(libsubdir)/$${dir}; fi; \
        !          2005:          rm -f $(libsubdir)/$${dir}/libgcc.a; \
        !          2006:          $(INSTALL_DATA) $${dir}/libgcc.a $(libsubdir)/$${dir}/libgcc.a; \
        !          2007:          if $(RANLIB_TEST); then \
        !          2008:            (cd $(libsubdir)/$${dir}; $(RANLIB) libgcc.a); else true; fi; \
        !          2009:          chmod a-x $(libsubdir)/$${dir}/libgcc.a; \
        !          2010:        done
        !          2011: 
1.1.1.4   root     2012: # Install the objc run time library.
                   2013: install-libobjc: libobjc.a install-dir
                   2014:        -if [ -f libobjc.a ] ; then \
                   2015:          rm -f $(libsubdir)/libobjc.a; \
                   2016:          $(INSTALL_DATA) libobjc.a $(libsubdir)/libobjc.a; \
                   2017:          if $(RANLIB_TEST) ; then \
                   2018:            (cd $(libsubdir); $(RANLIB) libobjc.a); else true; fi; \
                   2019:          chmod a-x $(libsubdir)/libobjc.a; \
                   2020:        else true; fi
                   2021: 
1.1.1.5   root     2022: # Install all the header files built in the include subdirectory.
                   2023: install-headers: install-include-dir $(INSTALL_HEADERS_DIR) install-assert-h
                   2024: # Fix symlinks to absolute paths in the installed include directory to
                   2025: # point to the installed directory, not the build directory.
                   2026:        -files=`cd $(libsubdir)/include; find . -type l -print 2>/dev/null`; \
                   2027:        if [ $$? -eq 0 ]; then \
                   2028:          dir=`cd include; pwd`; \
                   2029:          for i in $$files; do \
                   2030:            dest=`ls -ld $(libsubdir)/include/$$i | sed -n 's/.*-> //p'`; \
                   2031:            if expr "$$dest" : "$$dir.*" > /dev/null; then \
                   2032:              rm -f $(libsubdir)/include/$$i; \
                   2033:              ln -s `echo $$i | sed "s|/[^/]*|/..|g" | sed 's|/..$$||'``echo "$$dest" | sed "s|$$dir||"` $(libsubdir)/include/$$i; \
                   2034:            fi; \
                   2035:          done; \
                   2036:        fi
1.1       root     2037: 
1.1.1.5   root     2038: # Create or recreate the gcc private include file directory.
                   2039: install-include-dir: install-dir
                   2040:        -rm -rf $(libsubdir)/include
                   2041:        mkdir $(libsubdir)/include
                   2042:        -chmod a+rx $(libsubdir)/include
                   2043: 
                   2044: # Install the include directory using tar.
1.1.1.6   root     2045: install-headers-tar: stmp-headers $(STMP_FIXPROTO) install-include-dir
1.1.1.7 ! root     2046:        (cd include; \
        !          2047:         tar -cf - .; exit 0) | (cd $(libsubdir)/include; tar $(TAROUTOPTS) - )
1.1.1.6   root     2048: # /bin/sh on some systems returns the status of the first tar,
                   2049: # and that can lose with GNU tar which always writes a full block.
                   2050: # So use `exit 0' to ignore its exit status.
1.1.1.5   root     2051: 
                   2052: # Install the include directory using cpio.
1.1.1.6   root     2053: install-headers-cpio: stmp-headers $(STMP_FIXPROTO) install-include-dir
1.1.1.7 ! root     2054:        (cd include; find . -print) | (cd include; cpio -pdum $(libsubdir)/include)
1.1.1.5   root     2055: 
                   2056: # Put assert.h where it won't override GNU libc's assert.h.
                   2057: # It goes in a dir that is searched after GNU libc's headers;
                   2058: # thus, the following conditionals are no longer needed.
                   2059: # But it's not worth deleting them now.
                   2060: ## Don't replace the assert.h already there if it is not from GCC.
                   2061: ## This code would be simpler if it tested for -f ... && ! grep ...
                   2062: ## but supposedly the ! operator is missing in sh on some systems.
                   2063: install-assert-h: assert.h install-dir
1.1.1.4   root     2064:        if [ -f $(assertdir)/assert.h ]; \
                   2065:        then \
1.1.1.5   root     2066:          if grep "__eprintf" $(assertdir)/assert.h >/dev/null; \
1.1.1.4   root     2067:            then \
                   2068:            rm -f $(assertdir)/assert.h; \
                   2069:            $(INSTALL_DATA) $(srcdir)/assert.h $(assertdir)/assert.h; \
                   2070:            chmod a-x $(assertdir)/assert.h; \
                   2071:          else true; \
                   2072:          fi; \
                   2073:        else \
                   2074:          rm -f $(assertdir)/assert.h; \
                   2075:          $(INSTALL_DATA) $(srcdir)/assert.h $(assertdir)/assert.h; \
                   2076:          chmod a-x $(assertdir)/assert.h; \
                   2077:        fi
1.1       root     2078: 
                   2079: # Use this target to install the program `collect2' under the name `ld'.
1.1.1.6   root     2080: install-collect2: collect2 install-dir
1.1       root     2081:        $(INSTALL_PROGRAM) collect2 $(libsubdir)/ld
                   2082: # Install the driver program as $(libsubdir)/gcc for collect2.
1.1.1.4   root     2083:        $(INSTALL_PROGRAM) xgcc $(libsubdir)/gcc
1.1       root     2084: 
                   2085: # Cancel installation by deleting the installed files.
1.1.1.7 ! root     2086: uninstall: lang.uninstall
1.1       root     2087:        -rm -rf $(libsubdir)
                   2088:        -rm -rf $(bindir)/gcc
                   2089:        -rm -rf $(bindir)/protoize
                   2090:        -rm -rf $(bindir)/unprotoize
                   2091:        -rm -rf $(mandir)/gcc$(manext)
1.1.1.2   root     2092:        -rm -rf $(mandir)/cccp$(manext)
1.1       root     2093:        -rm -rf $(mandir)/protoize$(manext)
                   2094:        -rm -rf $(mandir)/unprotoize$(manext)
                   2095: 
                   2096: # These exist for maintenance purposes.
                   2097: 
                   2098: # Update the tags table.
                   2099: TAGS: force
                   2100:        cd $(srcdir);                                                   \
                   2101:        mkdir temp;                                                     \
1.1.1.7 ! root     2102:        mv -f c-parse.[ch] objc-parse.c cexp.c =*.[chy] temp;           \
1.1       root     2103:        etags *.y *.h *.c;                                              \
                   2104:        mv temp/* .;                                                    \
                   2105:        rmdir temp
                   2106: 
                   2107: # Create the distribution tar file.
1.1.1.5   root     2108: #dist: gcc-$(version).tar.gz
                   2109: dist: gcc.xtar.gz
1.1       root     2110: 
1.1.1.5   root     2111: gcc.xtar.gz: gcc.xtar
1.1.1.7 ! root     2112:        gzip --best < gcc.xtar > tmp-gcc.xtar.gz
1.1.1.5   root     2113:        mv tmp-gcc.xtar.gz gcc.xtar.gz
1.1       root     2114: 
1.1.1.5   root     2115: #gcc-$(version).tar.gz: gcc-$(version).tar
                   2116: #      gzip < gcc-$(version).tar > gcc-$(version).tar.gz
1.1       root     2117: 
                   2118: #gcc-$(version).tar:
1.1.1.5   root     2119: gcc.xtar: distdir
                   2120: # Make the distribution.
1.1.1.7 ! root     2121:        tar -chf gcc.xtar gcc-$(version)
1.1.1.5   root     2122: 
1.1.1.7 ! root     2123: # This target exists to do the initial work before the language specific
        !          2124: # stuff gets done.
        !          2125: distdir-start: doc $(srcdir)/INSTALL c-parse.y $(srcdir)/c-gperf.h objc-parse.y \
        !          2126:   c-parse.c objc-parse.c cexp.c
1.1.1.6   root     2127:        @if grep -s "for version ${mainversion}" gcc.texi > /dev/null; \
1.1.1.3   root     2128:        then true; \
                   2129:        else echo "You must update the version number in \`gcc.texi'"; sleep 10;\
                   2130:        fi
                   2131: # Update the version number in README
                   2132:        awk '$$1 " " $$2 " " $$3 == "This directory contains" \
                   2133:                { $$6 = version; print $$0 } \
                   2134:             $$1 " " $$2 " " $$3 != "This directory contains"' \
                   2135:          version=$(version) README > tmp.README
                   2136:        mv tmp.README README
1.1       root     2137:        -rm -rf gcc-$(version) tmp      
                   2138: # Put all the files in a temporary subdirectory
                   2139: # which has the name that we want to have in the tar file.
                   2140:        mkdir tmp
                   2141:        mkdir tmp/config
1.1.1.7 ! root     2142:        mkdir tmp/ginclude
1.1.1.4   root     2143:        mkdir tmp/objc
1.1       root     2144:        for file in *[0-9a-zA-Z+]; do \
1.1.1.3   root     2145:          ln $$file tmp > /dev/null 2>&1 || cp $$file tmp; \
1.1       root     2146:        done
                   2147:        cd config; \
                   2148:        for file in *[0-9a-zA-Z+]; do \
1.1.1.5   root     2149:          if test -d $$file && test "$$file" != RCS; then \
                   2150:            mkdir ../tmp/config/$$file; \
                   2151:            cd $$file; \
                   2152:            for subfile in *[0-9a-zA-Z+]; do \
                   2153:              ln $$subfile ../../tmp/config/$$file >/dev/null 2>&1 \
                   2154:              || cp $$subfile ../../tmp/config/$$file; \
                   2155:            done; \
                   2156:            cd ..; \
                   2157:          else \
                   2158:            ln $$file ../tmp/config >/dev/null 2>&1 \
                   2159:            || cp $$file ../tmp/config; \
                   2160:          fi; \
1.1       root     2161:        done
1.1.1.7 ! root     2162:        cd ginclude; \
        !          2163:        for file in *[0-9a-zA-Z+]; do \
        !          2164:          ln $$file ../tmp/ginclude >/dev/null 2>&1 || cp $$file ../tmp/ginclude; \
        !          2165:        done
1.1.1.4   root     2166:        cd objc; \
                   2167:        for file in *[0-9a-zA-Z+]; do \
                   2168:          ln $$file ../tmp/objc >/dev/null 2>&1 || cp $$file ../tmp/objc; \
                   2169:        done
1.1       root     2170:        ln .gdbinit tmp
1.1.1.7 ! root     2171: 
        !          2172: # Finish making `distdir', after the languages have done their thing.
        !          2173: distdir-finish:
1.1       root     2174:        mv tmp gcc-$(version)
1.1.1.7 ! root     2175: # Get rid of everything we don't want in the distribution.  We'd want
        !          2176: # this to use Makefile.in, but it doesn't have the `lang.foo' targets
        !          2177: # expanded.
        !          2178:        cd gcc-$(version); make extraclean
        !          2179: 
        !          2180: distdir: distdir-start lang.distdir distdir-finish
1.1       root     2181: 
1.1.1.6   root     2182: # make diff oldversion=M.N 
                   2183: # creates a diff file between an older distribution and this one.
                   2184: # The -P option assumes this is GNU diff.
                   2185: diff:
1.1.1.7 ! root     2186:        diff -rc2P -x c-parse.y -x c-parse.c -x c-parse.h -x c-gperf.h \
        !          2187:          -x cexp.c -x bi-parser.c -x objc-parse.y -x objc-parse.c \
        !          2188:          -x TAGS \
        !          2189:          -x "gcc.??" -x "gcc.??s" -x gcc.aux -x "gcc.info*" \
        !          2190:          -x "cpp.??" -x "cpp.??s" -x cpp.aux -x "cpp.info*" \
        !          2191:          $(LANG_DIFF_EXCLUDES) \
1.1.1.6   root     2192:          gcc-$(oldversion) gcc-$(version) > diffs
                   2193: 
1.1       root     2194: # do make -f ../gcc/Makefile maketest DIR=../gcc
                   2195: # in the intended test directory to make it a suitable test directory.
                   2196: # THIS IS OBSOLETE; use the -srcdir operand in configure instead. 
                   2197: maketest:
                   2198:        ln -s $(DIR)/*.[chy] .
                   2199:        ln -s $(DIR)/configure .
                   2200:        ln -s $(DIR)/*.def .
                   2201:        -rm -f =*
                   2202:        ln -s $(DIR)/.gdbinit .
                   2203:        ln -s $(DIR)/$(FIXINCLUDES) .
                   2204:        -ln -s $(DIR)/bison.simple .
                   2205:        ln -s $(DIR)/config .
                   2206:        ln -s $(DIR)/move-if-change .
                   2207: # The then and else were swapped to avoid a problem on Ultrix.
                   2208:        if [ ! -f Makefile ] ; then ln -s $(DIR)/Makefile .; else false; fi
                   2209:        -rm tm.h aux-output.c config.h md
                   2210:        make clean
                   2211: # You must then run config to set up for compilation.
1.1.1.4   root     2212: 
1.1.1.3   root     2213: bootstrap: force
                   2214: # Only build the C compiler for stage1, because that is the only one that
                   2215: # we can guarantee will build with the native compiler, and also it is the
                   2216: # only thing useful for building stage2.
1.1.1.5   root     2217:        $(MAKE) CC="$(CC)" libdir=$(libdir) LANGUAGES=c
1.1       root     2218:        $(MAKE) stage1
                   2219: # This used to define ALLOCA as empty, but that would lead to bad results
                   2220: # for a subsequent `make install' since that would not have ALLOCA empty.
                   2221: # To prevent `make install' from compiling alloca.o and then relinking cc1
                   2222: # because alloca.o is newer, we permit these recursive makes to compile
                   2223: # alloca.o.  Then cc1 is newer, so it won't have to be relinked.
1.1.1.5   root     2224:        $(MAKE) CC="stage1/xgcc -Bstage1/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
1.1       root     2225:        $(MAKE) stage2
1.1.1.5   root     2226:        $(MAKE) CC="stage2/xgcc -Bstage2/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
1.1       root     2227: 
                   2228: bootstrap2: force
1.1.1.5   root     2229:        $(MAKE) CC="stage1/xgcc -Bstage1/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
1.1       root     2230:        $(MAKE) stage2
1.1.1.5   root     2231:        $(MAKE) CC="stage2/xgcc -Bstage2/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
1.1       root     2232: 
                   2233: bootstrap3: force
1.1.1.5   root     2234:        $(MAKE) CC="stage2/xgcc -Bstage2/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
1.1       root     2235: 
1.1.1.3   root     2236: # Compare the object files in the current directory with those in the
                   2237: # stage2 directory.
                   2238: 
1.1.1.6   root     2239: # ./ avoids bug in some versions of tail.
1.1.1.3   root     2240: compare: force
                   2241:        for file in *.o; do \
1.1.1.6   root     2242:          tail +16c ./$$file > tmp-foo1; \
1.1.1.4   root     2243:          tail +16c stage2/$$file > tmp-foo2 2>/dev/null \
                   2244:            && (cmp tmp-foo1 tmp-foo2 || echo $$file differs); \
1.1.1.3   root     2245:        done
1.1.1.7 ! root     2246:        for dir in tmp-foo $(SUBDIRS); do \
        !          2247:          if [ "`echo $$dir/*.o`" != "$$dir/*.o" ] ; then \
        !          2248:            for file in $$dir/*.o; do \
        !          2249:              tail +16c ./$$file > tmp-foo1; \
        !          2250:              tail +16c stage2/$$file > tmp-foo2 2>/dev/null \
        !          2251:                && (cmp tmp-foo1 tmp-foo2 || echo $$file differs); \
        !          2252:            done; \
        !          2253:          fi; \
        !          2254:        done
1.1.1.3   root     2255:        -rm -f tmp-foo*
                   2256: 
                   2257: # Similar, but compare with stage3 directory
                   2258: compare3: force
                   2259:        for file in *.o; do \
1.1.1.7 ! root     2260:          tail +16c ./$$file > tmp-foo1; \
1.1.1.4   root     2261:          tail +16c stage3/$$file > tmp-foo2 2>/dev/null \
                   2262:            && (cmp tmp-foo1 tmp-foo2 || echo $$file differs); \
1.1.1.3   root     2263:        done
1.1.1.7 ! root     2264:        for dir in tmp-foo $(SUBDIRS); do \
        !          2265:          if [ "`echo $$dir/*.o`" != "$$dir/*.o" ] ; then \
        !          2266:            for file in $$dir/*.o; do \
        !          2267:              tail +16c ./$$file > tmp-foo1; \
        !          2268:              tail +16c stage3/$$file > tmp-foo2 2>/dev/null \
        !          2269:                && (cmp tmp-foo1 tmp-foo2 || echo $$file differs); \
        !          2270:            done; \
        !          2271:          fi; \
        !          2272:        done
1.1.1.3   root     2273:        -rm -f tmp-foo*
                   2274: 
1.1.1.7 ! root     2275: # Compare the object files in the current directory with those in the
        !          2276: # stage2 directory.  Use gnu cmp (diffutils v2.4 or later) to avoid
        !          2277: # running tail and the overhead of twice copying each object file.
        !          2278: 
        !          2279: gnucompare: force
        !          2280:        for file in *.o; do \
        !          2281:          cmp --ignore-initial=16 $$file stage2/$$file || true ; \
        !          2282:        done
        !          2283:        for dir in tmp-foo $(SUBDIRS); do \
        !          2284:          if [ "`echo $$dir/*.o`" != "$$dir/*.o" ] ; then \
        !          2285:            for file in $$dir/*.o; do \
        !          2286:              cmp --ignore-initial=16 $$file stage2/$$file || true ; \
        !          2287:            done; \
        !          2288:          fi; \
        !          2289:        done
        !          2290: 
        !          2291: # Similar, but compare with stage3 directory
        !          2292: gnucompare3: force
        !          2293:        for file in *.o; do \
        !          2294:          cmp --ignore-initial=16 $$file stage3/$$file || true ; \
        !          2295:        done
        !          2296:        for dir in tmp-foo $(SUBDIRS); do \
        !          2297:          if [ "`echo $$dir/*.o`" != "$$dir/*.o" ] ; then \
        !          2298:            for file in $$dir/*.o; do \
        !          2299:              cmp --ignore-initial=16 $$file stage3/$$file || true ; \
        !          2300:            done; \
        !          2301:          fi; \
        !          2302:        done
        !          2303: 
1.1       root     2304: # Copy the object files from a particular stage into a subdirectory.
1.1.1.7 ! root     2305: stage1-start:
1.1.1.2   root     2306:        -if [ -d stage1 ] ; then true ; else mkdir stage1 ; fi
1.1.1.7 ! root     2307:        -for dir in . $(SUBDIRS) ; \
        !          2308:         do \
        !          2309:           if [ -d stage1/$$dir ] ; then true ; else mkdir stage1/$$dir ; fi ; \
        !          2310:         done
1.1       root     2311:        -mv $(STAGESTUFF) stage1
                   2312:        -rm -f stage1/libgcc.a
                   2313:        -cp libgcc.a stage1
                   2314:        -if $(RANLIB_TEST) ; then $(RANLIB) stage1/libgcc.a; else true; fi
1.1.1.7 ! root     2315: stage1: force stage1-start lang.stage1
1.1       root     2316: 
1.1.1.7 ! root     2317: stage2-start:
1.1.1.2   root     2318:        -if [ -d stage2 ] ; then true ; else mkdir stage2 ; fi
1.1.1.7 ! root     2319:        -for dir in . $(SUBDIRS) ; \
        !          2320:         do \
        !          2321:           if [ -d stage2/$$dir ] ; then true ; else mkdir stage2/$$dir ; fi ; \
        !          2322:         done
1.1       root     2323:        -mv $(STAGESTUFF) stage2
                   2324:        -rm -f stage2/libgcc.a
                   2325:        -cp libgcc.a stage2
                   2326:        -if $(RANLIB_TEST) ; then $(RANLIB) stage2/libgcc.a; else true; fi
1.1.1.7 ! root     2327: stage2: force stage2-start lang.stage2
1.1       root     2328: 
1.1.1.7 ! root     2329: stage3-start:
1.1.1.3   root     2330:        -if [ -d stage3 ] ; then true ; else mkdir stage3 ; fi
1.1.1.7 ! root     2331:        -for dir in . $(SUBDIRS) ; \
        !          2332:         do \
        !          2333:           if [ -d stage3/$$dir ] ; then true ; else mkdir stage3/$$dir ; fi ; \
        !          2334:         done
1.1       root     2335:        -mv $(STAGESTUFF) stage3
                   2336:        -rm -f stage3/libgcc.a
                   2337:        -cp libgcc.a stage3
                   2338:        -if $(RANLIB_TEST) ; then $(RANLIB) stage3/libgcc.a; else true; fi
1.1.1.7 ! root     2339: stage3: force stage3-start lang.stage3
1.1       root     2340: 
1.1.1.7 ! root     2341: stage4-start:
1.1.1.3   root     2342:        -if [ -d stage4 ] ; then true ; else mkdir stage4 ; fi
1.1.1.7 ! root     2343:        -for dir in . $(SUBDIRS) ; \
        !          2344:         do \
        !          2345:           if [ -d stage4/$$dir ] ; then true ; else mkdir stage4/$$dir ; fi ; \
        !          2346:         done
1.1       root     2347:        -mv $(STAGESTUFF) stage4
                   2348:        -rm -f stage4/libgcc.a
                   2349:        -cp libgcc.a stage4
                   2350:        -if $(RANLIB_TEST) ; then $(RANLIB) stage4/libgcc.a; else true; fi
1.1.1.7 ! root     2351: stage4: force stage4-start lang.stage4
1.1       root     2352: 
                   2353: # Copy just the executable files from a particular stage into a subdirectory,
                   2354: # and delete the object files.  Use this if you're just verifying a version
                   2355: # that is pretty sure to work, and you are short of disk space.
                   2356: risky-stage1: force
1.1.1.3   root     2357:        -if [ -d stage1 ] ; then true ; else mkdir stage1 ; fi
1.1.1.5   root     2358:        -mv $(GCC_PARTS) stage1
1.1       root     2359:        -rm -f stage1/libgcc.a
                   2360:        -cp libgcc.a stage1 && $(RANLIB) stage1/libgcc.a
                   2361:        -make clean
                   2362: 
                   2363: risky-stage2: force
1.1.1.3   root     2364:        -if [ -d stage2 ] ; then true ; else mkdir stage2 ; fi
1.1.1.5   root     2365:        -mv $(GCC_PARTS) stage2
1.1       root     2366:        -rm -f stage2/libgcc.a
                   2367:        -cp libgcc.a stage2 && $(RANLIB) stage2/libgcc.a
                   2368:        -make clean
                   2369: 
                   2370: risky-stage3: force
1.1.1.3   root     2371:        -if [ -d stage3 ] ; then true ; else mkdir stage3 ; fi
1.1.1.5   root     2372:        -mv $(GCC_PARTS) stage3
1.1       root     2373:        -rm -f stage3/libgcc.a
                   2374:        -cp libgcc.a stage3 && $(RANLIB) stage3/libgcc.a
                   2375:        -make clean
                   2376: 
                   2377: risky-stage4: force
1.1.1.3   root     2378:        -if [ -d stage4 ] ; then true ; else mkdir stage4 ; fi
1.1.1.5   root     2379:        -mv $(GCC_PARTS) stage4
1.1       root     2380:        -rm -f stage4/libgcc.a
                   2381:        -cp libgcc.a stage4 && $(RANLIB) stage4/libgcc.a
                   2382:        -make clean
                   2383: 
                   2384: #In GNU Make, ignore whether `stage*' exists.
                   2385: .PHONY: stage1 stage2 stage3 stage4 clean realclean TAGS bootstrap
                   2386: .PHONY: risky-stage1 risky-stage2 risky-stage3 risky-stage4
                   2387: 
                   2388: force:

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.