1 # Makefile for GNU C compiler.
2 # Copyright (C) 1987, 88, 90-96, 1997 Free Software Foundation, Inc.
4 #This file is part of GNU CC.
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)
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.
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, 59 Temple Place - Suite 330,
19 #Boston MA 02111-1307, USA.
21 # The targets for external use include:
22 # all, doc, proto, install, install-cross, install-cross-rest,
23 # uninstall, TAGS, mostlyclean, clean, distclean, maintainer-clean,
24 # stage1, stage2, stage3, stage4.
26 # Suppress smart makes who think they know how to automake Yacc files
29 # Variables that exist for you to override.
30 # See below for how to change them for certain systems.
32 # List of language subdirectories.
33 # This is overridden by configure.
36 # Selection of languages to be made.
37 # This is overridden by configure.
38 LANGUAGES
= c objective-c proto gcov
40 # Selection of languages to be made during stage1 build.
41 # This is overridden by configure.
48 # Various ways of specifying flags for compilations:
49 # CFLAGS is for the user to override to, e.g., do a bootstrap with -O2.
50 # BOOT_CFLAGS is the value of CFLAGS to pass
51 # to the stage2 and stage3 compilations
52 # XCFLAGS is used for most compilations but not when using the GCC just built.
53 # TCFLAGS is used for compilations with the GCC just built.
57 BOOT_CFLAGS
= -O
$(CFLAGS
)
58 # These exists to be overridden by the x-* and t-* files, respectively.
74 # on sysV, define this as cp.
76 # These permit overriding just for certain files.
77 INSTALL_PROGRAM
= $(INSTALL
)
78 INSTALL_DATA
= $(INSTALL
)
82 # For GNUmake: let us decide what gets passed to recursive makes.
85 # Define this as & to perform parallel make on a Sequent.
86 # Note that this has some bugs, and it seems currently necessary
87 # to compile all the gen* files first by hand to avoid erroneous results.
90 # How to invoke ranlib.
92 # Test to use to see whether ranlib exists on the system.
93 RANLIB_TEST
= [ -f
/usr
/bin
/ranlib
-o
-f
/bin
/ranlib
]
95 # Compiler to use for compiling libgcc1.a.
96 # OLDCC should not be the GNU C compiler,
97 # since that would compile typical libgcc1.a functions such as mulsi3
98 # into infinite recursions.
101 # CFLAGS for use with OLDCC, for compiling libgcc1.a.
102 # NOTE: -O does not work on some Unix systems!
105 # Version of ar to use when compiling libgcc1.a.
108 # Target to use when installing include directory. Either
109 # install-headers-tar or install-headers-cpio.
110 INSTALL_HEADERS_DIR
= install-headers-tar
112 # Header files that are made available under the same name
113 # to programs compiled with GCC.
114 USER_H
= $(srcdir)/ginclude
/stdarg.h
$(srcdir)/ginclude
/stddef.h \
115 $(srcdir)/ginclude
/varargs.h
$(srcdir)/ginclude
/va-alpha.h \
116 $(srcdir)/ginclude
/va-h8300.h
$(srcdir)/ginclude
/va-i860.h \
117 $(srcdir)/ginclude
/va-i960.h
$(srcdir)/ginclude
/va-mips.h \
118 $(srcdir)/ginclude
/va-m88k.h
$(srcdir)/ginclude
/va-pa.h \
119 $(srcdir)/ginclude
/va-pyr.h
$(srcdir)/ginclude
/va-sparc.h \
120 $(srcdir)/ginclude
/va-clipper.h
$(srcdir)/ginclude
/va-spur.h \
121 $(srcdir)/ginclude
/va-m32r.h
$(srcdir)/ginclude
/va-sh.h \
122 $(srcdir)/ginclude
/iso646.h
$(srcdir)/ginclude
/va-ppc.h \
123 $(srcdir)/ginclude
/proto.h
$(EXTRA_HEADERS
) \
124 $(LANG_EXTRA_HEADERS
)
126 # Target to use whe installing assert.h. Some systems may
127 # want to set this empty.
128 INSTALL_ASSERT_H
= install-assert-h
130 # The GCC to use for compiling libgcc2.a, enquire, and libgcc1-test.
131 # Usually the one we just built.
132 # Don't use this as a dependency--use $(GCC_PASSES) or $(GCC_PARTS).
133 GCC_FOR_TARGET
= .
/xgcc
-B.
/
135 # This is used instead of ALL_CFLAGS when compiling with GCC_FOR_TARGET.
136 # It omits XCFLAGS, and specifies -B./.
137 # It also specifies -I./include to find, e.g., stddef.h.
138 GCC_CFLAGS
=$(INTERNAL_CFLAGS
) $(X_CFLAGS
) $(T_CFLAGS
) $(CFLAGS
) -I.
/include $(TCFLAGS
)
140 # Special flags for compiling enquire.
141 # We disable optimization to make floating point more reliable.
142 ENQUIRE_CFLAGS
= -DNO_MEM
-DNO_LONG_DOUBLE_IO
-O0
143 ENQUIRE_LDFLAGS
= $(LDFLAGS
)
145 # Sed command to transform gcc to installed name. Overwritten by configure.
146 program_transform_name
= -e s
,x
,x
,
147 program_transform_cross_name
= -e s
,^
,$(target_alias
)-,
149 # Tools to use when building a cross-compiler.
150 # These are used because `configure' appends `cross-make'
151 # to the makefile when making a cross-compiler.
153 TARGET_TOOLPREFIX
= $(tooldir
)/bin
/
154 AR_FOR_TARGET
= $(TARGET_TOOLPREFIX
)ar
155 AR_FOR_TARGET_FLAGS
= rc
156 RANLIB_FOR_TARGET
= $(TARGET_TOOLPREFIX
)ranlib
157 RANLIB_TEST_FOR_TARGET
= [ -f
$(TARGET_TOOLPREFIX
)ranlib
]
159 # Dir to search for system headers. Overridden by cross-make.
160 SYSTEM_HEADER_DIR
= /usr
/include
162 # Control whether to run fixproto.
163 STMP_FIXPROTO
= stmp-fixproto
165 # Test to see whether <limits.h> exists in the system header files.
166 LIMITS_H_TEST
= [ -f
$(SYSTEM_HEADER_DIR
)/limits.h
]
168 # There may be a premade insn-attrtab.c for this machine.
169 # (You could rebuild it with genattrtab as usual, but it takes a long time.)
170 # PREMADE_ATTRTAB is the file name of the file to use.
171 # PREMADE_ATTRTAB_MD is the md file it corresponds to.
172 PREMADE_ATTRTAB_MD
= Makefile
# Guaranteed not to cmp equal to md.
175 target
= ...
`configure' substitutes actual target name here.
176 target_alias= ... `configure
' substitutes specified target name here.
177 xmake_file= ... `configure' substitutes actual x- file name here.
178 tmake_file
= ...
`configure' substitutes actual t- file name here.
179 out_file= ... `configure
' substitutes actual out file name here.
180 out_object_file= ... `configure' substitutes actual out object file name here.
181 md_file
= ...
`configure' substitutes actual md file name here.
182 tm_file= ... `configure
' substitutes actual tm file name here.
183 build_xm_file= ... `configure' substitutes actual build xm- file name here.
184 host_xm_file
= ...
`configure' substitutes actual host xm- file name here.
185 lang_specs_files= ... `configure
' substitutes actual lang spec file names here.
186 lang_options_files= ... `configure' puts actual lang options file names here.
187 OBJC_THREAD_FILE
= ...
`configure' puts actual objc thread file name here.
188 version=`sed
-e
's/.*\"\([^ \"]*\)[ \"].*/\1/' < $(srcdir)/version.c
`
189 mainversion=`sed
-e
's/.*\"\([0-9]*\.[0-9]*\).*/\1/' < $(srcdir)/version.c
`
191 # Directory where sources are, from where we are.
193 # Common prefix for installation directories.
194 # NOTE: This directory must exist when you start installation.
196 # Directory in which to put localized header files. On the systems with
197 # gcc as the native cc, `local_prefix
' may not be `prefix' which is
199 # NOTE: local_prefix *should not* default from prefix.
200 local_prefix
= /usr
/local
201 # Directory in which to put host dependent programs and libraries
202 exec_prefix = $(prefix)
203 # Directory in which to put the executable for the command `gcc'
204 bindir = $(exec_prefix)/bin
205 # Directory in which to put the directories used by the compiler.
206 libdir = $(exec_prefix)/lib
207 # Directory in which the compiler finds executables, libraries, etc.
208 libsubdir
= $(libdir)/gcc-lib
/$(target_alias
)/$(version
)
209 # Directory in which the compiler finds g++ includes.
210 gxx_include_dir
= $(prefix)/include/g
++
211 # Directory in which the old g++ header files may be found.
212 old_gxx_include_dir
= $(libdir)/g
++-include
213 # Directory to search for site-specific includes.
214 includedir = $(local_prefix
)/include
215 # assertdir is overridden in cross-make.
216 # (But this currently agrees with what is in cross-make.)
217 assertdir
= $(tooldir
)/include
218 # where the info files go
219 infodir = $(prefix)/info
220 # Extension (if any) to put in installed man-page filename.
225 # Directory in which to put man pages.
226 mandir = $(prefix)/man
/man1
227 # Directory in which to find other cross-compilation tools and headers.
228 # Used in install-cross.
229 tooldir
= $(exec_prefix)/$(target_alias
)
230 # Dir for temp files.
233 # Additional system libraries to link with.
236 # Change this to a null string if obstacks are installed in the
240 # Specify the rule for actually making libgcc.a,
242 # and the rule for installing it.
243 INSTALL_LIBGCC
= install-libgcc
245 # Specify the rule for actually making libgcc1.a.
246 # The value may be empty; that means to do absolutely nothing
247 # with or for libgcc1.a.
250 # Specify the rule for making libgcc1.a for a cross-compiler.
251 # The default rule assumes that libgcc1.a is supplied by the user.
252 CROSS_LIBGCC1
= libgcc1.cross
254 # Specify the rule for actually making libgcc2.a.
257 # Options to use when compiling libgcc2.a.
258 # -g1 causes output of debug info only for file-scope entities.
259 # we use this here because that should be enough, and also
260 # so that -g1 will be tested.
261 LIBGCC2_DEBUG_CFLAGS
= -g1
262 LIBGCC2_CFLAGS
= -O2
$(LIBGCC2_INCLUDES
) $(GCC_CFLAGS
) $(TARGET_LIBGCC2_CFLAGS
) $(LIBGCC2_DEBUG_CFLAGS
) -DIN_LIBGCC2
-D__GCC_FLOAT_NOT_NEEDED
264 # Additional options to use when compiling libgcc2.a.
265 # Some targets override this to -Iinclude
268 # Additional target-dependent options for compiling libgcc2.a.
269 TARGET_LIBGCC2_CFLAGS
=
271 # Things which must be built before building libgcc2.a.
272 # Some targets override this to stmp-int-hdrs
275 # Enquire target (This is a variable so that a target can choose not to
279 # libgcc1-test target (must also be overridable for a target)
280 LIBGCC1_TEST
= libgcc1-test
282 # List of extra executables that should be compiled for this target machine
283 # that are used for compiling from source code to object code.
284 # The rules for compiling them should be in the t-* file for the machine.
287 # Like EXTRA_PASSES, but these are used when linking.
290 # List of extra object files that should be compiled for this target machine.
291 # The rules for compiling them should be in the t-* file for the machine.
294 # List of extra object files that should be compiled and linked with
295 # compiler proper (cc1, cc1obj, cc1plus).
298 # List of extra object files that should be compiled and linked with
302 # List of additional header files to install.
303 # Often this is edited directly by `configure'.
306 # Set this to `ld' to enable use of collect2.
308 # It is convenient for configure to add the assignment at the beginning,
309 # so don't override it here.
311 # List of extra C and assembler files to add to libgcc1.a.
312 # Assembler files should have names ending in `.asm'.
315 # List of extra C and assembler files to add to libgcc2.a.
316 # Assembler files should have names ending in `.asm'.
319 # Default float.h source to use for cross-compiler.
320 # This is overidden by configure.
321 CROSS_FLOAT_H
=float.h-cross
323 # Program to convert libraries.
326 # Control whether header files are installed.
327 INSTALL_HEADERS
=install-headers
329 # Options for tar when copying trees. So HPUX can override it.
332 # Select which version of fixincludes to use (I.E. regular versus SVR4)
333 # This value is overridden directly by configure.
334 FIXINCLUDES
=fixincludes
336 # Additional directories of header files to run fixincludes on.
337 # These should be directories searched automatically by default
338 # just as /usr/include is.
339 # *Do not* use this for directories that happen to contain
340 # header files, but are not searched automatically by default.
341 # On most systems, this is empty.
342 OTHER_FIXINCLUDES_DIRS
=
344 # A list of all the language-specific executables.
345 # This is overridden by configure.
346 COMPILERS
= cc1
$(exeext
) cc1obj
$(exeext
)
348 # List of things which should already be built whenever we try to use xgcc
349 # to compile anything (without linking).
350 GCC_PASSES
=xgcc
$(exeext
) cc1
$(exeext
) cpp$(exeext
) $(EXTRA_PASSES
)
352 # List of things which should already be built whenever we try to use xgcc
354 GCC_PARTS
=$(GCC_PASSES
) $(LIBGCC
) $(EXTRA_PROGRAMS
) $(USE_COLLECT2
) $(EXTRA_PARTS
)
356 # Directory to link to, when using the target `maketest'.
359 # Guaranteed to not exist when not passing md through cpp.
360 # This value is overridden directly by configure.
361 MD_FILE
= md-cpp-not-used
363 # Flags to use when cross-building GCC.
364 # Prefix to apply to names of object files when using them
365 # to run on the machine we are compiling on.
367 # Prefix to apply to names of object files when compiling them
368 # to run on the machine we are compiling on.
369 # The default for this variable is chosen to keep these rules
370 # out of the way of the other rules for compiling the same source files.
373 HOST_CFLAGS
=$(ALL_CFLAGS
)
375 HOST_LDFLAGS
=$(LDFLAGS
)
376 HOST_CPPFLAGS
=$(ALL_CPPFLAGS
)
377 HOST_ALLOCA
=$(ALLOCA
)
378 HOST_MALLOC
=$(MALLOC
)
379 HOST_OBSTACK
=$(OBSTACK
)
381 # Actual name to use when installing a native compiler.
382 GCC_INSTALL_NAME
= `t='$(program_transform_name)'; echo gcc | sed $$t`
384 # Actual name to use when installing a cross-compiler.
385 GCC_CROSS_NAME
= `t='$(program_transform_cross_name)'; echo gcc | sed $$t`
387 # Choose the real default target.
390 # Choose the real install target.
391 INSTALL_TARGET
=install-normal
393 # Source for float.h. Overridden by cross-make.
396 # Extra symbols for fixproto to define when parsing headers.
399 # Extra flags to use when compiling crt{begin,end}.o.
402 # Extra flags to use when compiling [m]crt0.o.
405 # End of variables for you to override.
407 # Definition of `all' is here so that new rules inserted by sed
408 # do not specify the default target.
409 # The real definition is under `all.internal' (for native compilers)
410 # or `all.cross' (for cross compilers).
413 # This tells GNU Make version 3 not to put all variables in the environment.
416 # sed inserts variable overrides after the following line.
422 # Now figure out from those variables how to compile and link.
426 # IN_GCC tells obstack.h that we are using gcc's <stddef.h> file.
427 # ??? IN_GCC should be obsolete now.
428 INTERNAL_CFLAGS
= $(CROSS
) -DIN_GCC
430 # This is the variable actually used when we compile.
431 ALL_CFLAGS
= $(INTERNAL_CFLAGS
) $(X_CFLAGS
) $(T_CFLAGS
) $(CFLAGS
) $(XCFLAGS
)
434 ALL_CPPFLAGS
= $(CPPFLAGS
) $(X_CPPFLAGS
) $(T_CPPFLAGS
)
436 # Even if ALLOCA is set, don't use it if compiling with GCC.
437 USE_ALLOCA
= ` case "${CC}" in "${OLDCC}") echo "${ALLOCA}" ;; esac `
438 USE_HOST_ALLOCA
= ` case "${HOST_CC}"@"${HOST_ALLOCA}" in "${OLDCC}"@?*) echo ${HOST_PREFIX}${HOST_ALLOCA} ;; esac `
439 USE_HOST_MALLOC
= ` case "${HOST_MALLOC}" in ?*) echo ${HOST_PREFIX}${HOST_MALLOC} ;; esac `
440 USE_HOST_OBSTACK
= ` case "${HOST_OBSTACK}" in ?*) echo ${HOST_PREFIX}${HOST_OBSTACK} ;; esac `
442 # Dependency on obstack, alloca, malloc or whatever library facilities
443 # are not installed in the system libraries.
444 # We don't use USE_ALLOCA because backquote expansion doesn't work in deps.
445 LIBDEPS
= $(OBSTACK
) $(ALLOCA
) $(MALLOC
)
447 # Likewise, for use in the tools that must run on this machine
448 # even if we are cross-building GCC.
449 # We don't use USE_ALLOCA because backquote expansion doesn't work in deps.
450 HOST_LIBDEPS
= $(HOST_PREFIX
)$(HOST_OBSTACK
) $(HOST_PREFIX
)$(HOST_ALLOCA
) $(HOST_PREFIX
)$(HOST_MALLOC
)
452 # How to link with both our special library facilities
453 # and the system's installed libraries.
454 LIBS
= $(OBSTACK
) $(USE_ALLOCA
) $(MALLOC
) $(CLIB
)
456 # Likewise, for use in the tools that must run on this machine
457 # even if we are cross-building GCC.
458 HOST_LIBS
= $(USE_HOST_OBSTACK
) $(USE_HOST_ALLOCA
) $(USE_HOST_MALLOC
) \
461 HOST_RTL
= $(HOST_PREFIX
)rtl.o
462 HOST_RTLANAL
= $(HOST_PREFIX
)rtlanal.o
463 HOST_PRINT
= $(HOST_PREFIX
)print-rtl.o
465 # Specify the directories to be searched for header files.
466 # Both . and srcdir are used, in that order,
467 # so that tm.h and config.h will be found in the compilation
468 # subdirectory rather than in the source directory.
469 INCLUDES
= -I.
-I
$(srcdir) -I
$(srcdir)/config
471 # Always use -I$(srcdir)/config when compiling.
473 $(CC
) -c
$(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) $<
475 # This tells GNU make version 3 not to export all the variables
476 # defined in this file into the environment.
479 # Support for additional languages (other than c and objc).
480 # ??? objc can be supported this way too (leave for later).
482 # These next lines are overridden by configure.
489 # Flags to pass to recursive makes.
490 # CC is set by configure. Hosts without symlinks need special handling
491 # because we need CC="stage1/xgcc -Bstage1/" to work in the language
493 # ??? The choices here will need some experimenting with.
495 "AR_FLAGS=$(AR_FLAGS)" \
496 "AR_FOR_TARGET=$(AR_FOR_TARGET)" \
498 "BISONFLAGS=$(BISONFLAGS)" \
499 "CC=set-by-configure" \
502 "GCC_FOR_TARGET=$(GCC_FOR_TARGET)" \
503 "LDFLAGS=$(LDFLAGS)" \
505 "LEXFLAGS=$(LEXFLAGS)" \
506 "MAKEINFO=$(MAKEINFO)" \
507 "MAKEINFOFLAGS=$(MAKEINFOFLAGS)" \
508 "RANLIB_FOR_TARGET=$(RANLIB_FOR_TARGET)" \
509 "RANLIB_TEST_FOR_TARGET=$(RANLIB_TEST_FOR_TARGET)" \
511 "STAGE_PREFIX=set-by-configure" \
514 "exec_prefix=$(exec_prefix)" \
516 "tooldir=$(tooldir)" \
518 "libsubdir=$(libsubdir)"
520 # Lists of files for various purposes.
522 # Language-specific object files for C.
523 C_OBJS
= c-parse.o c-lang.o c-lex.o c-pragma.o \
524 c-decl.o c-typeck.o c-convert.o c-aux-info.o c-common.o c-iterate.o
526 # Language-specific object files for Objective C.
527 OBJC_OBJS
= objc-parse.o objc-act.o c-lex.o c-pragma.o \
528 c-decl.o c-typeck.o c-convert.o c-aux-info.o c-common.o c-iterate.o
530 # Files specific to the C interpreter bytecode compiler(s).
531 BC_OBJS
= bc-emit.o bc-optab.o
533 # Bytecode header files constructed at build time; vmsconfig.com wants this.
534 BC_ALL
= bc-arity.h bc-opcode.h bc-opname.h
536 # Language-independent object files.
537 OBJS
= toplev.o version.o tree.o print-tree.o stor-layout.o fold-const.o \
538 function.o stmt.o except.o expr.o calls.o expmed.o explow.o optabs.o \
539 varasm.o rtl.o print-rtl.o rtlanal.o emit-rtl.o real.o \
540 dbxout.o sdbout.o dwarfout.o dwarf2out.o xcoffout.o \
541 integrate.o jump.o cse.o loop.o unroll.o flow.o stupid.o combine.o \
542 regclass.o local-alloc.o global.o reload.o reload1.o caller-save.o \
543 insn-peep.o reorg.o sched.o final.o recog.o reg-stack.o \
544 insn-opinit.o insn-recog.o insn-extract.o insn-output.o insn-emit.o \
546 insn-attrtab.o
$(out_object_file
) getpwd.o convert.o
$(EXTRA_OBJS
)
548 # GEN files are listed separately, so they can be built before doing parallel
549 # makes for cc1 or cc1plus. Otherwise sequent parallel make attempts to load
550 # them before rtl.o is compiled.
551 GEN
= genemit genoutput genrecog genextract genflags gencodes genconfig genpeep
554 # Uncomment this line if you want to use cppmain (w/cpplib) as cpp.
557 # Files to be copied away after each stage in building.
558 STAGESTUFF
= *$(objext
) insn-flags.h insn-config.h insn-codes.h \
559 insn-output.c insn-recog.c insn-emit.c insn-extract.c insn-peep.c \
560 insn-attr.h insn-attrtab.c insn-opinit.c \
561 stamp-flags stamp-config stamp-codes stamp-mlib \
562 stamp-output stamp-recog stamp-emit stamp-extract stamp-peep \
563 stamp-attr stamp-attrtab stamp-opinit stamp-proto stamp-crt stamp-crtS stamp-crt0 \
564 genemit
$(exeext
) genoutput
$(exeext
) genrecog
$(exeext
) genextract
$(exeext
) \
565 genflags
$(exeext
) gencodes
$(exeext
) genconfig
$(exeext
) genpeep
$(exeext
) \
566 genattrtab
$(exeext
) genattr
$(exeext
) genopinit
$(exeext
) \
568 stamp-bcarity stamp-bcopcode stamp-bcopname \
569 bi-arity
$(exeext
) bi-opcode
$(exeext
) bi-opname
$(exeext
) \
570 $(GCC_PASSES
) $(EXTRA_PARTS
) $(EXTRA_PROGRAMS
) gcc-cross
$(exeext
) \
571 $(CCCP
)$(exeext
) cc1obj
$(exeext
) enquire
$(exeext
) \
572 protoize
$(exeext
) unprotoize
$(exeext
) \
573 specs collect2
$(exeext
) $(USE_COLLECT2
) underscore.c \
575 *.greg
*.lreg
*.combine
*.flow
*.cse
*.jump
*.rtl
*.tree
*.loop \
576 *.dbr
*.jump2
*.sched
*.cse2
*.sched2
*.stack \
580 # Members of libgcc1.a.
581 LIB1FUNCS
= _mulsi3 _udivsi3 _divsi3 _umodsi3 _modsi3 \
582 _lshrsi3 _ashrsi3 _ashlsi3 \
583 _divdf3 _muldf3 _negdf2 _adddf3 _subdf3 \
584 _fixdfsi _fixsfsi _floatsidf _floatsisf _truncdfsf2 _extendsfdf2 \
585 _addsf3 _negsf2 _subsf3 _mulsf3 _divsf3 \
586 _eqdf2 _nedf2 _gtdf2 _gedf2 _ltdf2 _ledf2 \
587 _eqsf2 _nesf2 _gtsf2 _gesf2 _ltsf2 _lesf2
589 # Library members defined in libgcc2.c.
590 LIB2FUNCS
= _muldi3 _divdi3 _moddi3 _udivdi3 _umoddi3 _negdi2 \
591 _lshrdi3 _ashldi3 _ashrdi3 _ffsdi2 \
592 _udiv_w_sdiv _udivmoddi4 _cmpdi2 _ucmpdi2 _floatdidf _floatdisf \
593 _fixunsdfsi _fixunssfsi _fixunsdfdi _fixdfdi _fixunssfdi _fixsfdi \
594 _fixxfdi _fixunsxfdi _floatdixf _fixunsxfsi \
595 _fixtfdi _fixunstfdi _floatditf \
596 __gcc_bcmp _varargs __dummy _eprintf _op_new _op_vnew _new_handler \
597 _op_delete _op_vdel _bb _shtab _clear_cache _trampoline __main _exit \
600 # The files that "belong" in CONFIG_H are deliberately omitted
601 # because having them there would not be useful in actual practice.
602 # All they would do is cause complete recompilation every time
603 # one of the machine description files is edited.
604 # That may or may not be what one wants to do.
605 # If it is, rm *.o is an easy way to do it.
606 # CONFIG_H = $(host_xm_file) $(tm_file)
608 RTL_H
= rtl.h rtl.def machmode.h machmode.def
609 TREE_H
= tree.h real.h tree.def machmode.h machmode.def
610 BYTECODE_H
= bytecode.h bc-emit.h bc-optab.h
612 # "t" or nothing, for building multilibbed versions of, say, crtbegin.o.
615 # Language makefile fragments.
617 # The following targets define the interface between us and the languages.
619 # all.build, all.cross, start.encap, rest.encap,
621 # install-normal, install-common, install-info, install-man,
622 # uninstall, distdir,
623 # mostlyclean, clean, distclean, extraclean, maintainer-clean,
624 # stage1, stage2, stage3, stage4
626 # Each language is linked in with a series of hooks (since we can't use `::'
627 # targets). The name of each hooked is "lang.${target_name}" (eg: lang.info).
628 # Configure computes and adds these here.
632 # sed inserts language fragments after the following line.
633 ####language fragments
635 # End of language makefile fragments.
637 # Avoid a lot of time thinking about remaking Makefile.in and *.def.
640 Makefile
: $(srcdir)/Makefile.in
$(srcdir)/configure
$(srcdir)/version.c \
641 $(xmake_file
) $(tmake_file
) \
643 cp config.status config.run
647 all.internal
: start.encap rest.encap
648 # This is what to compile if making a cross-compiler.
649 # Note that we can compile enquire using the cross-compiler just built,
650 # although we can't run it on this machine.
651 all.cross
: native gcc-cross specs stmp-headers
$(LIBGCC
) $(STMP_FIXPROTO
) \
652 $(LIBGCC1_TEST
) $(EXTRA_PARTS
) lang.
all.cross
653 # This is what to compile if making gcc with a cross-compiler.
654 all.build
: native xgcc
$(EXTRA_PARTS
) lang.
all.build
655 # This is what must be made before installing GCC and converting libraries.
656 start.encap
: native xgcc specs
$(LIBGCC1
) xlimits.h lang.start.encap
657 # These can't be made until after GCC can run.
658 rest.encap
: stmp-headers
$(LIBGCC
) $(STMP_FIXPROTO
) $(EXTRA_PARTS
) lang.rest.encap
659 # This is what is made with the host's compiler
660 # whether making a cross compiler or not.
661 native
: config.status
cpp $(LANGUAGES
) $(EXTRA_PASSES
) $(EXTRA_PROGRAMS
) $(USE_COLLECT2
)
663 # Define the names for selecting languages in LANGUAGES.
665 OBJC objc
: cc1obj objc-runtime
666 OBJECTIVE-C objective-c
: cc1obj objc-runtime
669 # Tell GNU make these are phony targets.
670 .PHONY
: C c OBJC objc OBJECTIVE-C objective-c PROTO proto
672 # Really, really stupid make features, such as SUN's KEEP_STATE, may force
673 # a target to build even if it is up-to-date. So we must verify that
674 # config.status does not exist before failing.
676 @if
[ ! -f config.status
] ; then \
677 echo You must configure gcc. Look at the INSTALL file for details.
; \
683 # On the target machine, finish building a cross compiler.
684 # This does the things that can't be done on the host machine.
685 rest.cross
: $(LIBGCC
) gfloat.h specs
687 # Verify that it works to compile and link libgcc1-test.
688 # If it does, then there are sufficient replacements for libgcc1.a.
689 libgcc1-test
: libgcc1-test.o native
$(GCC_PARTS
)
690 @echo
"Testing libgcc1. Ignore linker warning messages."
691 $(GCC_FOR_TARGET
) $(GCC_CFLAGS
) libgcc1-test.o
-o libgcc1-test \
692 -nostartfiles
-nostdlib
`$(GCC_FOR_TARGET) --print-libgcc-file-name`
693 libgcc1-test.o
: libgcc1-test.c native xgcc
694 $(GCC_FOR_TARGET
) $(GCC_CFLAGS
) $(ALL_CPPFLAGS
) -c
$(srcdir)/libgcc1-test.c
696 # Recompile all the language-independent object files.
697 # This is used only if the user explicitly asks for it.
698 compilations
: ${OBJS}
700 # Create a list of the language-independent object files so the language
701 # subdirectories needn't mention their names explicitly.
702 stamp-objlist
: $(OBJS
) $(BC_OBJS
)
703 echo
" $(OBJS) $(BC_OBJS)" | sed
-e
's, \([a-z0-9]\), ../\1,g' -e
's/\.o/$(objext)/g' >stamp-objlist
705 # We call this executable `xgcc' rather than `gcc'
706 # to avoid confusion if the current directory is in the path
707 # and CC is `gcc'. It is renamed to `gcc' when it is installed.
708 xgcc
: gcc.o version.o choose-temp.o pexecute.o
$(LIBDEPS
) $(EXTRA_GCC_OBJS
)
709 $(CC
) $(ALL_CFLAGS
) $(LDFLAGS
) -o
$@ gcc.o version.o \
710 choose-temp.o pexecute.o
$(EXTRA_GCC_OBJS
) $(LIBS
)
712 # Dump a specs file to make -B./ read these specs over installed ones.
714 $(GCC_FOR_TARGET
) -dumpspecs
> tmp-specs
717 # We do want to create an executable named `xgcc', so we can use it to
719 # Also create gcc-cross, so that install-common will install properly.
721 cp xgcc
$(exeext
) gcc-cross
$(exeext
)
723 cc1
: $(P
) $(C_OBJS
) $(OBJS
) $(BC_OBJS
) $(LIBDEPS
)
724 $(CC
) $(ALL_CFLAGS
) $(LDFLAGS
) -o
$@
$(C_OBJS
) $(OBJS
) $(BC_OBJS
) $(LIBS
)
726 cc1obj
: $(P
) $(OBJC_OBJS
) $(OBJS
) $(BC_OBJS
) $(LIBDEPS
)
727 $(CC
) $(ALL_CFLAGS
) $(LDFLAGS
) -o
$@
$(OBJC_OBJS
) $(OBJS
) $(BC_OBJS
) $(LIBS
)
729 # Copy float.h from its source.
732 cp
$(FLOAT_H
) gfloat.h
734 # Create float.h source for the native machine.
736 -.
/enquire
-f
> tmp-float.h
737 mv tmp-float.h float.h-nat
739 # Create a dummy float.h source for a cross-compiler.
740 # ??? This isn't used anymore. Should we create config/float-unkn.h
741 # and make that the default float_format in configure?
743 echo
"#ifndef __GCC_FLOAT_NOT_NEEDED" > t-float.h-cross
744 echo
"#error float.h values not known for cross-compiler" >> t-float.h-cross
745 echo
"#endif" >> t-float.h-cross
746 mv t-float.h-cross float.h-cross
748 # Used to compile enquire with standard cc, but have forgotten why.
749 # Let's try with GCC.
750 enquire
: enquire.o
$(GCC_PARTS
)
751 $(GCC_FOR_TARGET
) $(GCC_CFLAGS
) $(ENQUIRE_LDFLAGS
) enquire.o
-o
$@
752 enquire.o
: $(srcdir)/enquire.c
$(GCC_PASSES
) stmp-int-hdrs
753 # Breaking this line caused a problem with one version of GNU make.
754 $(GCC_FOR_TARGET
) $(GCC_CFLAGS
) $(ALL_CPPFLAGS
) $(ENQUIRE_CFLAGS
) -I.
-c
$(srcdir)/enquire.c
756 # Build the version of limits.h that we will install.
757 xlimits.h
: glimits.h limitx.h limity.h
758 if
$(LIMITS_H_TEST
) ; then \
759 cat
$(srcdir)/limitx.h
$(srcdir)/glimits.h
$(srcdir)/limity.h
> tmp-xlimits.h
; \
761 cat
$(srcdir)/glimits.h
> tmp-xlimits.h
; \
763 mv tmp-xlimits.h xlimits.h
766 # This is done in two parts because some functions, in libgcc1.c,
767 # must be compiled with something other than GCC,
768 # while the rest, in libgcc2.c, must be compiled with xgcc.
769 # That means we can't do libgcc2.c until after xgcc, cc1, etc.
771 # Use this as value of LIBGCC1 to cause conversion to GNU library format.
772 # LIBCONVERT should put its output in libgcc1.conv.
773 libgcc1.conv
: libgcc1.a
774 $(LIBCONVERT
) libgcc1.a libgcc1.conv
776 # Use this as value of LIBGCC1 to inhibit use of libgcc1.c entirely.
777 # Make an empty file instead.
778 libgcc1.null
: $(GCC_PASSES
)
779 echo
"__foo () {}" > dummy.c
780 $(GCC_FOR_TARGET
) $(GCC_CFLAGS
) -c dummy.c
781 $(OLDAR
) $(OLDAR_FLAGS
) libgcc1.null dummy
$(objext
)
782 rm -f dummy
$(objext
) dummy.c
784 # This is $(LIBGCC1) for a cross-compiler.
785 # We have no automatic way of building libgcc1.a,
786 # so it's up to the installer to find a way to do that.
787 # This rule deliberately does not depend on libgcc1.a
788 # so that it will fail if the installer hasn't provided it.
790 mv libgcc1.a libgcc1.cross ||
(echo You must find a way to make libgcc1.a
; false
)
792 # Compile the library of arithmetic subroutines with the native compiler.
793 # Don't compile it with GCC!
794 # (That would cause most arithmetic functions to call themselves.)
796 # NOTE: If you modify these rules substantially, please be sure to
797 # check at least config/i386/t-sco5 and possibly other makefile
799 libgcc1.a
: libgcc1.c
$(CONFIG_H
) $(LIB1FUNCS_EXTRA
) config.status
801 # Actually build it in tmplibgcc1.a, then rename at end,
802 # so that libgcc1.a itself remains nonexistent if compilation is aborted.
803 # -e causes any failing command to make this rule fail.
804 # -e doesn't work in certain shells, so we test $$? as well.
805 # lynx has a broken ar, it always complains when the initial library is
806 # empty, thus this command works only if we don't do -e
807 # There is a trailing backslash (\) deleted from the following line.
809 for name in
$(LIB1FUNCS
); \
812 rm -f
$${name}$(objext
); \
813 $(OLDCC
) -DIN_LIBGCC1
$(CCLIBFLAGS
) $(INCLUDES
) -c
-DL
$${name} $(srcdir)/libgcc1.c
; \
814 if
[ $$?
-eq
0 ] ; then true
; else exit
1; fi
; \
815 mv libgcc1
$(objext
) $${name}$(objext
); \
816 $(OLDAR
) $(OLDAR_FLAGS
) tmplibgcc1.a
$${name}$(objext
); \
817 rm -f
$${name}$(objext
); \
819 # Some shells crash when a loop has no items.
820 # So make sure there is always at least one--`..'.
822 # We don't use -e here because there are if statements
823 # that should not make the command give up when the if condition is false.
824 # Instead, we test for failure after each command where it matters.
825 for file in ..
$(LIB1FUNCS_EXTRA
); \
827 if
[ x
$${file} != x..
]; then \
828 name
=`echo $${file} | sed -e 's/[.][cS]$$//' -e 's/[.]asm$$//'`; \
830 if
[ $${name}.asm
= $${file} ]; then \
831 cp
$${file} $${name}.s || exit
1; file
=$${name}.s
; \
833 $(OLDCC
) -DIN_LIBGCC1
$(CCLIBFLAGS
) $(INCLUDES
) -c
$${file}; \
834 if
[ $$?
-eq
0 ] ; then true
; else exit
1; fi
; \
835 $(OLDAR
) $(OLDAR_FLAGS
) tmplibgcc1.a
$${name}$(objext
); \
836 if
[ $$?
-eq
0 ] ; then true
; else exit
1; fi
; \
837 rm -f
$${name}.s
$${name}$(objext
); \
841 -if
$(RANLIB_TEST
) ; then
$(RANLIB
) tmplibgcc1.a
; else true
; fi
842 mv tmplibgcc1.a libgcc1.a
844 # Build libgcc1.a from assembler source. LIB1ASMFUNCS is the list of
845 # functions. LIB1ASMSRC is the name of the source file in the config
847 libgcc1-asm.a
: libgcc2.ready config.status
$(srcdir)/config
/$(LIB1ASMSRC
)
848 -rm -f tmplibgcc1.a libgcc1.S
849 cp
$(srcdir)/config
/$(LIB1ASMSRC
) libgcc1.S
850 # Actually build it in tmplibgcc1.a, then rename at end,
851 # so that libgcc1-asm.a itself remains nonexistent if compilation is aborted.
852 # -e causes any failing command to make this rule fail.
853 # -e doesn't work in certain shells, so we test $$? as well.
854 # lynx has a broken ar, it always complains when the initial library is
855 # empty, thus this command works only if we don't do -e
856 # There is a trailing backslash (\) deleted from the following line.
858 for name in
$(LIB1ASMFUNCS
); \
861 $(GCC_FOR_TARGET
) $(LIBGCC2_CFLAGS
) $(INCLUDES
) -c
-DL
$${name} libgcc1.S
; \
862 if
[ $$?
-eq
0 ] ; then true
; else exit
1; fi
; \
863 mv libgcc1
$(objext
) $${name}$(objext
); \
864 $(AR
) $(AR_FLAGS
) tmplibgcc1.a
$${name}$(objext
); \
865 rm -f
$${name}$(objext
); \
868 mv tmplibgcc1.a libgcc1-asm.a
870 # Generate assembly versions of the functions required for libgcc1.
871 # You'll still need to massage the code by hand (possibly hacking
872 # underscores and local labels) but this will get you started.
873 libgcc1.S
: libgcc1.c
$(CONFIG_H
) config.status
876 for name in
$(LIB1FUNCS
); \
879 $(OLDCC
) -DIN_LIBGCC1
$(CCLIBFLAGS
) $(INCLUDES
) -S
-DL
$${name} $(srcdir)/libgcc1.c
; \
880 if
[ $$?
-eq
0 ] ; then true
; else exit
1; fi
; \
881 echo
'#ifdef ' L
$${name} >> libgcc1.S
; \
882 cat libgcc1.s
>> libgcc1.S
; \
883 echo
'#endif /*' L
$${name} '*/' >> libgcc1.S
; \
884 echo
"" >> libgcc1.S
; \
887 # Compiling libgcc2.a requires making sure that cc1, etc. have been compiled.
888 # But recompiling cc1 should not force recompilation of libgcc2.a.
889 # If you want to force recompilation, delete libgcc2.a.
890 libgcc2.ready
: $(GCC_PASSES
) $(LIBGCC2_DEPS
) stmp-int-hdrs
891 -if
[ -f libgcc2.ready
] ; then \
894 touch libgcc2.ready
; \
897 libgcc2.a
: libgcc2.c libgcc2.ready
$(CONFIG_H
) $(LIB2FUNCS_EXTRA
) \
898 $(LANG_LIB2FUNCS
) machmode.h longlong.h gbl-ctors.h config.status
899 # Actually build it in tmplibgcc2.a, then rename at end,
900 # so that libgcc2.a itself remains nonexistent if compilation is aborted.
902 # -e causes any failing command to make this rule fail.
903 # -e doesn't work in certain shells, so we test $$? as well.
904 # lynx has a broken ar, it always complains when the initial library is
905 # empty, thus this command works only if we don't do -e
906 # There is a trailing backslash (\) deleted from the following line.
908 for name in
$(LIB2FUNCS
); \
911 $(GCC_FOR_TARGET
) $(LIBGCC2_CFLAGS
) $(INCLUDES
) -c
-DL
$${name} \
912 $(srcdir)/libgcc2.c
-o
$${name}$(objext
); \
913 if
[ $$?
-eq
0 ] ; then true
; else exit
1; fi
; \
914 $(AR
) $(AR_FLAGS
) tmplibgcc2.a
$${name}$(objext
); \
915 rm -f
$${name}$(objext
); \
917 # Some shells crash when a loop has no items.
918 # So make sure there is always at least one--`..'.
920 # We don't use -e here because there are if statements
921 # that should not make the command give up when the if condition is false.
922 # Instead, we test for failure after each command where it matters.
923 for file in ..
$(LIB2FUNCS_EXTRA
) $(LANG_LIB2FUNCS
); \
925 if
[ x
$${file} != x..
]; then \
926 name
=`echo $${file} | sed -e 's/[.][cSo]$$//' -e 's/[.]asm$$//' -e 's/[.]txt$$//'`; \
927 oname
=` echo $${name} | sed -e 's,.*/,,'`; \
928 if
[ $${name}.txt
= $${file} ]; then \
929 for f in ..
`cat $${file}`; do if
[ x
$${f} != x..
]; then \
930 $(MAKE
) GCC_FOR_TARGET
="$(GCC_FOR_TARGET)" \
931 AR
="$(AR)" AR_FLAGS
="$(AR_FLAGS)" CC
="$(CC)" \
932 CFLAGS
="$(CFLAGS)" HOST_PREFIX
="$(HOST_PREFIX)" \
933 HOST_PREFIX_1
="$(HOST_PREFIX_1)" \
934 LIBGCC2_CFLAGS
="$(LIBGCC2_CFLAGS)" $${f}; \
935 if
[ $$?
-eq
0 ] ; then true
; else exit
1; fi
; \
936 $(AR
) $(AR_FLAGS
) tmplibgcc2.a
$${f}; \
941 if
[ $${name}.asm
= $${file} ]; then \
942 cp
$${file} $${name}.s || exit
1; file
=$${name}.s
; \
944 $(GCC_FOR_TARGET
) $(LIBGCC2_CFLAGS
) $(INCLUDES
) -c
$${file}; \
945 if
[ $$?
-eq
0 ] ; then true
; else exit
1; fi
; \
946 $(AR
) $(AR_FLAGS
) tmplibgcc2.a
$${oname}$(objext
); \
947 rm -f
$${name}.s
$${oname}$(objext
); \
952 mv tmplibgcc2.a libgcc2.a
953 # These lines were deleted from above the mv command
954 # because ranlibing libgcc.a itself should suffice.
955 # -if [ x${HPUX_GAS} = x ] ; then \
956 # if $(RANLIB_TEST) ; then $(RANLIB) tmplibgcc2.a; else true; fi; \
959 # Combine the various libraries into a single library, libgcc.a.
960 libgcc.a
: $(LIBGCC1
) $(LIBGCC2
)
961 -rm -rf tmplibgcc.a libgcc.a tmpcopy
963 -if
[ x
$(LIBGCC1
) != x
]; \
964 then
(cd tmpcopy
; $(AR
) x ..
/$(LIBGCC1
)); \
967 # Some versions of ar (specifically the one in RISC/os 5.x), create an
968 # unwritable table of contents file, and then print an error message when
969 # the second ar command tries to overwrite this file. To avoid the error
970 # message from ar, we make sure all files are writable.
971 -(cd tmpcopy
; chmod
+w
* > /dev
/null
2>&1)
972 (cd tmpcopy
; $(AR
) x ..
/$(LIBGCC2
))
973 (cd tmpcopy
; $(AR
) $(AR_FLAGS
) ..
/tmplibgcc.a
*$(objext
))
975 -if
$(RANLIB_TEST
) ; then
$(RANLIB
) tmplibgcc.a
; else true
; fi
976 # Actually build it in tmplibgcc.a, then rename at end,
977 # so that libgcc.a itself remains nonexistent if compilation is aborted.
978 mv tmplibgcc.a libgcc.a
980 # Use the genmultilib shell script to generate the information the gcc
981 # driver program needs to select the library directory based on the
983 multilib.h
: stamp-mlib
; @true
984 stamp-mlib
: $(srcdir)/genmultilib Makefile
985 $(SHELL
) $(srcdir)/genmultilib \
986 "$(MULTILIB_OPTIONS)" \
987 "$(MULTILIB_DIRNAMES)" \
988 "$(MULTILIB_MATCHES)" \
989 "$(MULTILIB_EXCEPTIONS)" \
990 "$(MULTILIB_EXTRA_OPTS)" > tmp-mlib.h
991 $(srcdir)/move-if-change tmp-mlib.h multilib.h
994 # Build multiple copies of libgcc.a, one for each target switch.
995 stmp-multilib
: $(LIBGCC1
) libgcc2.c libgcc2.ready
$(CONFIG_H
) \
996 $(LIB2FUNCS_EXTRA
) $(LANG_LIB2FUNCS
) machmode.h longlong.h gbl-ctors.h \
998 for i in
`$(GCC_FOR_TARGET) --print-multi-lib`; do \
999 dir=`echo $$i | sed -e 's/;.*$$//'`; \
1000 flags
=`echo $$i | sed -e 's/^[^;]*;//' -e 's/@/ -/g'`; \
1001 $(MAKE
) GCC_FOR_TARGET
="$(GCC_FOR_TARGET)" \
1002 AR
="$(AR)" AR_FLAGS
="$(AR_FLAGS)" CC
="$(CC)" CFLAGS
="$(CFLAGS)" \
1003 RANLIB
="$(RANLIB)" RANLIB_TEST
="$(RANLIB_TEST)" \
1004 HOST_PREFIX
="$(HOST_PREFIX)" HOST_PREFIX_1
="$(HOST_PREFIX_1)" \
1005 LIBGCC2_CFLAGS
="$(LIBGCC2_CFLAGS) $${flags}" \
1006 MULTILIB_CFLAGS
="$${flags}" \
1007 LIBGCC1
="$(LIBGCC1)" LIBGCC2
="$(LIBGCC2)" \
1008 dir="$${dir}" stmp-multilib-sub
; \
1009 if
[ $$?
-eq
0 ] ; then true
; else exit
1; fi
; \
1013 # Subroutine of stmp-multilib so make -n works.
1016 if
[ -d
$(dir) ]; then \
1018 rm -f libgcc.a
$(EXTRA_MULTILIB_PARTS
); \
1021 $(MAKE
) GCC_FOR_TARGET
="$(GCC_FOR_TARGET)" \
1022 AR
="$(AR)" AR_FLAGS
="$(AR_FLAGS)" CC
="$(CC)" CFLAGS
="$(CFLAGS)" \
1023 HOST_PREFIX
="$(HOST_PREFIX)" HOST_PREFIX_1
="$(HOST_PREFIX_1)" \
1024 LIBGCC2_CFLAGS
="$(LIBGCC2_CFLAGS)" $(LIBGCC2
)
1025 if
[ x
$(LIBGCC1
) != xlibgcc1-asm.a
]; \
1027 else rm -f
$(LIBGCC1
); \
1029 if
[ x
$(LIBGCC1
) != xlibgcc1-asm.a
]; \
1032 $(MAKE
) GCC_FOR_TARGET
="$(GCC_FOR_TARGET)" \
1033 AR
="$(AR)" AR_FLAGS
="$(AR_FLAGS)" CC
="$(CC)" CFLAGS
="$(CFLAGS)" \
1034 HOST_PREFIX
="$(HOST_PREFIX)" HOST_PREFIX_1
="$(HOST_PREFIX_1)" \
1035 LIBGCC2_CFLAGS
="$(LIBGCC2_CFLAGS)" $(LIBGCC1
); \
1037 rm -rf tmplibgcc.a tmpcopy
1039 if
[ x
$(LIBGCC1
) != x
]; \
1040 then
(cd tmpcopy
; $(AR
) x ..
/$(LIBGCC1
)); \
1043 (cd tmpcopy
; $(AR
) x ..
/$(LIBGCC2
))
1044 (cd tmpcopy
; $(AR
) $(AR_FLAGS
) ..
/tmplibgcc.a
*$(objext
))
1045 rm -rf libgcc2.a tmpcopy
1046 if
$(RANLIB_TEST
) ; then
$(RANLIB
) tmplibgcc.a
; else true
; fi
1047 if
[ -d
$(dir) ]; then true
; else mkdir
$(dir); fi
1048 mv tmplibgcc.a
$(dir)/libgcc.a
1049 for f in ..
$(EXTRA_MULTILIB_PARTS
); do if
[ x
$${f} != x..
]; then \
1050 $(MAKE
) GCC_FOR_TARGET
="$(GCC_FOR_TARGET)" \
1051 AR
="$(AR)" AR_FLAGS
="$(AR_FLAGS)" CC
="$(CC)" CFLAGS
="$(CFLAGS)" \
1052 HOST_PREFIX
="$(HOST_PREFIX)" HOST_PREFIX_1
="$(HOST_PREFIX_1)" \
1053 MULTILIB_CFLAGS
="$(MULTILIB_CFLAGS)" T
="t" t
$${f}; \
1054 mv t
$${f} $(dir)/$${f}; \
1058 objc-runtime
: libobjc.a
1060 # Build the Objective C runtime library.
1061 libobjc.a
: cc1obj specs stmp-int-hdrs libgcc2.ready
$(USE_COLLECT2
) $(EXTRA_PARTS
)
1062 if
[ -d objc
]; then true
; else mkdir objc
; fi
1064 srcdir1
=`cd $(srcdir); pwd`; \
1066 $(MAKE
) -f
$${srcdir1}/objc
/Makefile libobjc.a \
1067 srcdir=$${srcdir1} tooldir
=$(tooldir
) AR
="$(AR)" AR_FLAGS
="$(AR_FLAGS)" \
1068 GCC_FOR_TARGET
="$${thisdir1}/xgcc -B$${thisdir1}/" \
1069 GCC_CFLAGS
="$(GCC_CFLAGS)" OBJC_THREAD_FILE
="$(OBJC_THREAD_FILE)"
1071 ln objc
/libobjc.a .
>/dev
/null
2>&1 || cp objc
/libobjc.a .
1072 -if
$(RANLIB_TEST
) ; then
$(RANLIB
) libobjc.a
; else true
; fi
1074 # This is used by objc/Makefile if the user runs that directly.
1075 sublibobjc.a
: cc1obj specs stmp-int-hdrs libgcc2.ready
1077 srcdir1
=`cd $(srcdir); pwd`; \
1079 $(MAKE
) -f
$$srcdir1/objc
/Makefile libobjc.a \
1080 srcdir=$$srcdir1 tooldir
=$(tooldir
) AR
="$(AR)" AR_FLAGS
="$(AR_FLAGS)" \
1081 GCC_FOR_TARGET
="$$thisdir1/xgcc -B$$thisdir1/" \
1082 GCC_CFLAGS
="$(GCC_CFLAGS)" OBJC_THREAD_FILE
="$(OBJC_THREAD_FILE)"
1084 # Compile two additional files that are linked with every program
1085 # linked using GCC on systems using COFF or ELF, for the sake of C++
1087 $(T
)crtbegin.o
: crtstuff.c
$(GCC_PASSES
) $(CONFIG_H
) gbl-ctors.h
1088 $(GCC_FOR_TARGET
) $(GCC_CFLAGS
) $(INCLUDES
) $(MULTILIB_CFLAGS
) -g0 \
1089 -finhibit-size-directive
-fno-inline-functions
$(CRTSTUFF_T_CFLAGS
) \
1090 -c
$(srcdir)/crtstuff.c
-DCRT_BEGIN
-o
$(T
)crtbegin
$(objext
)
1092 $(T
)crtend.o
: crtstuff.c
$(GCC_PASSES
) $(CONFIG_H
) gbl-ctors.h
1093 $(GCC_FOR_TARGET
) $(GCC_CFLAGS
) $(INCLUDES
) $(MULTILIB_CFLAGS
) -g0 \
1094 -finhibit-size-directive
-fno-inline-functions
$(CRTSTUFF_T_CFLAGS
) \
1095 -c
$(srcdir)/crtstuff.c
-DCRT_END
-o
$(T
)crtend
$(objext
)
1097 # On some systems we also want to install versions of these files
1098 # compiled using PIC for use in shared libraries.
1099 crtbeginS.o crtendS.o
: stamp-crtS
; @true
1101 stamp-crtS
: crtstuff.c
$(GCC_PASSES
) $(CONFIG_H
) gbl-ctors.h
1102 $(GCC_FOR_TARGET
) $(GCC_CFLAGS
) $(INCLUDES
) $(CRTSTUFF_T_CFLAGS_S
) \
1103 -DCRT_BEGIN
-finhibit-size-directive
-fno-inline-functions \
1104 -g0
-c
$(srcdir)/crtstuff.c
1105 mv crtstuff
$(objext
) crtbeginS
$(objext
)
1106 $(GCC_FOR_TARGET
) $(GCC_CFLAGS
) $(INCLUDES
) $(CRTSTUFF_T_CFLAGS_S
) \
1107 -DCRT_END
-finhibit-size-directive
-fno-inline-functions \
1108 -g0
-c
$(srcdir)/crtstuff.c
-o crtendS
$(objext
)
1111 # Compile the start modules crt0.o and mcrt0.o that are linked with every program
1112 crt0.o
: stamp-crt0
; @true
1113 mcrt0.o
: stamp-crt0
; @true
1115 stamp-crt0
: $(CRT0_S
) $(MCRT0_S
) $(GCC_PASSES
) $(CONFIG_H
)
1116 $(GCC_FOR_TARGET
) $(GCC_CFLAGS
) $(CRT0STUFF_T_CFLAGS
) \
1117 -o crt0.o
-c
$(CRT0_S
)
1118 $(GCC_FOR_TARGET
) $(GCC_CFLAGS
) $(CRT0STUFF_T_CFLAGS
) \
1119 -o mcrt0.o
-c
$(MCRT0_S
)
1122 # Compiling object files from source files.
1124 # Note that dependencies on obstack.h are not written
1125 # because that file is not part of GCC.
1127 # C language specific files.
1129 c-parse.o
: $(srcdir)/c-parse.c
$(CONFIG_H
) $(TREE_H
) c-lex.h \
1130 $(srcdir)/c-parse.h c-tree.h input.h flags.h
1131 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) -c
$(srcdir)/c-parse.c
1132 $(srcdir)/c-parse.h
: $(srcdir)/c-parse.c
1133 $(srcdir)/c-parse.c
: $(srcdir)/c-parse.y
1134 cd
$(srcdir); $(BISON
) $(BISONFLAGS
) -d c-parse.y
-o c-parse.c
1135 $(srcdir)/c-parse.y
: c-parse.in
1136 echo
'/*WARNING: This file is automatically generated!*/' >tmp-c-parse.y
1137 sed
-e
"/^ifobjc$$/,/^end ifobjc$$/d" \
1138 -e
"/^ifc$$/d" -e
"/^end ifc$$/d" \
1139 $(srcdir)/c-parse.in
>>tmp-c-parse.y
1140 $(srcdir)/move-if-change tmp-c-parse.y
$(srcdir)/c-parse.y
1142 $(srcdir)/c-gperf.h
: c-parse.gperf
1143 gperf
-p
-j1
-i
1 -g
-o
-t
-G
-N is_reserved_word
-k1
,3,$$ \
1144 $(srcdir)/c-parse.gperf
>tmp-gperf.h
1145 $(srcdir)/move-if-change tmp-gperf.h
$(srcdir)/c-gperf.h
1147 c-decl.o
: c-decl.c
$(CONFIG_H
) $(TREE_H
) c-tree.h c-lex.h flags.h output.h
1148 c-typeck.o
: c-typeck.c
$(CONFIG_H
) $(TREE_H
) c-tree.h flags.h output.h
1149 c-lang.o
: c-lang.c
$(CONFIG_H
) $(TREE_H
)
1150 c-lex.o
: c-lex.c
$(CONFIG_H
) $(TREE_H
) c-lex.h c-tree.h
$(srcdir)/c-parse.h \
1151 input.h flags.h
$(srcdir)/c-gperf.h c-pragma.h
1152 c-aux-info.o
: c-aux-info.c
$(CONFIG_H
) $(TREE_H
) c-tree.h flags.h
1153 c-convert.o
: c-convert.c
$(CONFIG_H
) $(TREE_H
) flags.h
1154 c-pragma.o
: c-pragma.c
$(CONFIG_H
) $(TREE_H
) except.h function.h \
1155 defaults.h c-pragma.h
1156 c-iterate.o
: c-iterate.c
$(CONFIG_H
) $(TREE_H
) $(RTL_H
) c-tree.h flags.h
1158 # To make a configuration always use collect2, set USE_COLLECT2 to ld.
1161 ln collect2
$(exeext
) ld$(exeext
) > /dev
/null
2>&1 \
1162 || cp collect2
$(exeext
) ld$(exeext
)
1164 collect2
: collect2.o cplus-dem.o underscore.o version.o \
1165 choose-temp.o
$(LIBDEPS
)
1166 # Don't try modifying collect2 (aka ld) in place--it might be linking this.
1167 -rm -f collect2
$(exeext
)
1168 $(CC
) $(ALL_CFLAGS
) $(LDFLAGS
) -o
$@ collect2.o \
1169 cplus-dem.o underscore.o version.o choose-temp.o
$(LIBS
)
1171 collect2.o
: collect2.c
$(CONFIG_H
) gstab.h obstack.h demangle.h
1172 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) \
1173 -DTARGET_MACHINE
=\"$(target_alias
)\" $(MAYBE_USE_COLLECT2
) \
1174 -c
`echo $(srcdir)/collect2.c | sed 's,^\./,,'`
1176 cplus-dem.o
: cplus-dem.c demangle.h
1178 underscore.c
: stamp-under
; @true
1180 stamp-under
: $(GCC_PASSES
)
1181 echo
"int xxy_us_dummy;" >tmp-dum.c
1182 $(GCC_FOR_TARGET
) -S tmp-dum.c
1183 echo
'/*WARNING: This file is automatically generated!*/' >tmp-under.c
1184 if grep _xxy_us_dummy tmp-dum.s
> /dev
/null
; then \
1185 echo
"int prepends_underscore = 1;" >>tmp-under.c
; \
1187 echo
"int prepends_underscore = 0;" >>tmp-under.c
; \
1189 $(srcdir)/move-if-change tmp-under.c underscore.c
1190 -rm -f tmp-dum.c tmp-dum.s
1193 # Objective C language specific files.
1195 objc-parse.o
: $(srcdir)/objc-parse.c
$(CONFIG_H
) $(TREE_H
) c-lex.h \
1196 c-tree.h input.h flags.h objc-act.h
1197 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) -c
$(srcdir)/objc-parse.c
1198 $(srcdir)/objc-parse.c
: $(srcdir)/objc-parse.y
1199 cd
$(srcdir); $(BISON
) $(BISONFLAGS
) objc-parse.y
-o objc-parse.c
1200 $(srcdir)/objc-parse.y
: $(srcdir)/c-parse.in
1201 echo
'/*WARNING: This file is automatically generated!*/' >tmp-objc-prs.y
1202 sed
-e
"/^ifc$$/,/^end ifc$$/d" \
1203 -e
"/^ifobjc$$/d" -e
"/^end ifobjc$$/d" \
1204 $(srcdir)/c-parse.in
>>tmp-objc-prs.y
1205 $(srcdir)/move-if-change tmp-objc-prs.y
$(srcdir)/objc-parse.y
1207 objc-act.o
: objc-act.c
$(CONFIG_H
) $(TREE_H
) $(RTL_H
) c-tree.h c-lex.h \
1208 flags.h objc-act.h input.h function.h
$(srcdir)/c-parse.h
1210 # A file used by all variants of C.
1212 c-common.o
: c-common.c
$(CONFIG_H
) $(TREE_H
) c-tree.h c-lex.h flags.h
1214 # Language-independent files.
1217 -DSTANDARD_STARTFILE_PREFIX
=\"$(libdir)/\" \
1218 -DSTANDARD_EXEC_PREFIX
=\"$(libdir)/gcc-lib
/\" \
1219 -DDEFAULT_TARGET_VERSION
=\"$(version
)\" \
1220 -DDEFAULT_TARGET_MACHINE
=\"$(target_alias
)\" \
1221 -DTOOLDIR_BASE_PREFIX
=\"$(exec_prefix)/\"
1222 gcc.o
: gcc.c
$(CONFIG_H
) multilib.h config.status
$(lang_specs_files
)
1223 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) \
1225 -c
`echo $(srcdir)/gcc.c | sed 's,^\./,,'`
1227 dumpvers
: dumpvers.c
1229 version.o
: version.c
1230 obstack.o
: obstack.c
1231 choose-temp.o
: choose-temp.c
1232 pexecute.o
: pexecute.c
1234 convert.o
: convert.c
$(CONFIG_H
) $(TREE_H
) flags.h convert.h
1236 tree.o
: tree.c
$(CONFIG_H
) $(TREE_H
) flags.h function.h
1237 print-tree.o
: print-tree.c
$(CONFIG_H
) $(TREE_H
)
1238 stor-layout.o
: stor-layout.c
$(CONFIG_H
) $(TREE_H
) flags.h function.h
1239 fold-const.o
: fold-const.c
$(CONFIG_H
) $(TREE_H
) flags.h
1240 toplev.o
: toplev.c
$(CONFIG_H
) $(TREE_H
) $(RTL_H
) bytecode.h bc-emit.h \
1241 flags.h input.h insn-attr.h xcoffout.h defaults.h output.h \
1242 $(lang_options_files
)
1243 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) $(MAYBE_USE_COLLECT2
) \
1244 -DTARGET_NAME
=\"$(target_alias
)\" \
1245 -c
`echo $(srcdir)/toplev.c | sed 's,^\./,,'`
1247 rtl.o
: rtl.c
$(CONFIG_H
) $(RTL_H
)
1249 print-rtl.o
: print-rtl.c
$(CONFIG_H
) $(RTL_H
)
1250 rtlanal.o
: rtlanal.c
$(CONFIG_H
) $(RTL_H
)
1252 varasm.o
: varasm.c
$(CONFIG_H
) $(TREE_H
) $(RTL_H
) flags.h function.h \
1253 defaults.h insn-codes.h expr.h hard-reg-set.h regs.h xcoffout.h \
1254 output.h bytecode.h c-pragma.h
1255 function.o
: function.c
$(CONFIG_H
) $(RTL_H
) $(TREE_H
) flags.h function.h \
1256 insn-flags.h insn-codes.h expr.h regs.h hard-reg-set.h insn-config.h \
1257 recog.h output.h bytecode.h bc-emit.h
1258 stmt.o
: stmt.c
$(CONFIG_H
) $(RTL_H
) $(TREE_H
) flags.h function.h \
1259 insn-flags.h insn-config.h insn-codes.h hard-reg-set.h expr.h except.h \
1260 loop.h recog.h bytecode.h bc-typecd.h bc-typecd.def bc-opcode.h \
1261 bc-optab.h bc-emit.h
1262 except.o
: except.c
$(CONFIG_H
) $(RTL_H
) $(TREE_H
) flags.h function.h \
1263 insn-flags.h insn-codes.h expr.h regs.h hard-reg-set.h insn-config.h \
1264 recog.h output.h except.h
1265 expr.o
: expr.c
$(CONFIG_H
) $(RTL_H
) $(TREE_H
) flags.h function.h regs.h \
1266 insn-flags.h insn-codes.h expr.h insn-config.h recog.h output.h \
1267 typeclass.h bytecode.h bc-opcode.h bc-typecd.h bc-typecd.def bc-optab.h \
1268 bc-emit.h modemap.def hard-reg-set.h
1269 calls.o
: calls.c
$(CONFIG_H
) $(RTL_H
) $(TREE_H
) flags.h expr.h insn-codes.h \
1271 expmed.o
: expmed.c
$(CONFIG_H
) $(RTL_H
) $(TREE_H
) flags.h \
1272 insn-flags.h insn-config.h insn-codes.h expr.h recog.h real.h
1273 explow.o
: explow.c
$(CONFIG_H
) $(RTL_H
) $(TREE_H
) flags.h hard-reg-set.h \
1274 insn-config.h expr.h recog.h insn-flags.h insn-codes.h
1275 optabs.o
: optabs.c
$(CONFIG_H
) $(RTL_H
) $(TREE_H
) flags.h \
1276 insn-flags.h insn-config.h insn-codes.h expr.h recog.h reload.h
1277 dbxout.o
: dbxout.c
$(CONFIG_H
) $(TREE_H
) $(RTL_H
) flags.h regs.h \
1278 insn-config.h reload.h gstab.h xcoffout.h defaults.h output.h
1279 sdbout.o
: sdbout.c
$(CONFIG_H
) $(TREE_H
) $(RTL_H
) flags.h except.h \
1280 function.h expr.h output.h hard-reg-set.h regs.h defaults.h real.h \
1281 bytecode.h obstack.h xcoffout.h c-pragma.h
1282 dwarfout.o
: dwarfout.c
$(CONFIG_H
) $(TREE_H
) $(RTL_H
) dwarf.h flags.h \
1283 insn-config.h reload.h output.h defaults.h
1284 dwarf2out.o
: dwarf2out.c
$(CONFIG_H
) $(TREE_H
) $(RTL_H
) dwarf2.h flags.h \
1285 insn-config.h reload.h output.h defaults.h hard-reg-set.h regs.h
1286 xcoffout.o
: xcoffout.c
$(CONFIG_H
) $(TREE_H
) $(RTL_H
) xcoffout.h flags.h
1287 emit-rtl.o
: emit-rtl.c
$(CONFIG_H
) $(RTL_H
) $(TREE_H
) flags.h \
1288 function.h regs.h insn-config.h insn-codes.h real.h expr.h bytecode.h \
1289 bc-opcode.h bc-typecd.h bc-typecd.def bc-optab.h bc-emit.h bc-opname.h
1290 real.o
: real.c
$(CONFIG_H
) $(TREE_H
)
1291 getpwd.o
: getpwd.c
$(CONFIG_H
)
1293 integrate.o
: integrate.c
$(CONFIG_H
) $(RTL_H
) $(TREE_H
) flags.h integrate.h \
1294 insn-flags.h insn-config.h insn-codes.h expr.h real.h regs.h function.h \
1297 jump.o
: jump.c
$(CONFIG_H
) $(RTL_H
) flags.h hard-reg-set.h regs.h \
1298 insn-config.h insn-flags.h insn-codes.h expr.h real.h
1299 stupid.o
: stupid.c
$(CONFIG_H
) $(RTL_H
) regs.h hard-reg-set.h flags.h
1301 cse.o
: cse.c
$(CONFIG_H
) $(RTL_H
) regs.h hard-reg-set.h flags.h real.h \
1302 insn-config.h recog.h
1303 profile.o
: profile.c
$(CONFIG_H
) $(RTL_H
) flags.h insn-flags.h gcov-io.h \
1305 loop.o
: loop.c
$(CONFIG_H
) $(RTL_H
) flags.h loop.h insn-config.h \
1306 insn-flags.h insn-codes.h regs.h hard-reg-set.h recog.h expr.h real.h
1307 unroll.o
: unroll.c
$(CONFIG_H
) $(RTL_H
) insn-config.h insn-codes.h \
1308 integrate.h regs.h flags.h expr.h loop.h
1309 flow.o
: flow.c
$(CONFIG_H
) $(RTL_H
) flags.h insn-config.h \
1310 basic-block.h regs.h hard-reg-set.h output.h
1311 combine.o
: combine.c
$(CONFIG_H
) $(RTL_H
) flags.h \
1312 insn-config.h insn-flags.h insn-codes.h insn-attr.h regs.h expr.h \
1313 basic-block.h recog.h real.h hard-reg-set.h
1314 regclass.o
: regclass.c
$(CONFIG_H
) $(RTL_H
) hard-reg-set.h flags.h \
1315 basic-block.h regs.h insn-config.h recog.h reload.h real.h bytecode.h
1316 local-alloc.o
: local-alloc.c
$(CONFIG_H
) $(RTL_H
) flags.h basic-block.h \
1317 regs.h hard-reg-set.h insn-config.h recog.h output.h
1318 global.o
: global.c
$(CONFIG_H
) $(RTL_H
) flags.h \
1319 basic-block.h regs.h hard-reg-set.h insn-config.h output.h
1321 reload.o
: reload.c
$(CONFIG_H
) $(RTL_H
) flags.h output.h expr.h\
1322 reload.h recog.h hard-reg-set.h insn-config.h insn-codes.h regs.h real.h
1323 reload1.o
: reload1.c
$(CONFIG_H
) $(RTL_H
) real.h flags.h expr.h \
1324 reload.h regs.h hard-reg-set.h insn-config.h insn-flags.h insn-codes.h \
1325 basic-block.h recog.h output.h
1326 caller-save.o
: caller-save.c
$(CONFIG_H
) $(RTL_H
) flags.h \
1327 regs.h hard-reg-set.h insn-codes.h insn-config.h basic-block.h recog.h \
1329 reorg.o
: reorg.c
$(CONFIG_H
) $(RTL_H
) conditions.h hard-reg-set.h \
1330 basic-block.h regs.h insn-config.h insn-attr.h insn-flags.h recog.h \
1332 sched.o
: sched.c
$(CONFIG_H
) $(RTL_H
) basic-block.h regs.h hard-reg-set.h \
1333 flags.h insn-config.h insn-attr.h
1334 final.o
: final.c
$(CONFIG_H
) $(RTL_H
) $(TREE_H
) flags.h regs.h \
1335 recog.h conditions.h insn-config.h insn-attr.h except.h real.h output.h \
1336 hard-reg-set.h insn-flags.h insn-codes.h gstab.h xcoffout.h defaults.h
1337 recog.o
: recog.c
$(CONFIG_H
) $(RTL_H
) \
1338 regs.h recog.h hard-reg-set.h flags.h insn-config.h insn-attr.h \
1339 insn-flags.h insn-codes.h real.h
1340 reg-stack.o
: reg-stack.c
$(CONFIG_H
) $(RTL_H
) $(TREE_H
) \
1341 regs.h hard-reg-set.h flags.h insn-config.h insn-flags.h
1343 $(out_object_file
): $(out_file
) $(CONFIG_H
) $(TREE_H
) \
1344 $(RTL_H
) regs.h hard-reg-set.h real.h insn-config.h conditions.h \
1345 insn-flags.h output.h insn-attr.h insn-codes.h
1346 $(CC
) -c
$(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) $(out_file
)
1348 # Build auxiliary files that support ecoff format.
1349 mips-tfile
: mips-tfile.o version.o
$(LIBDEPS
)
1350 $(CC
) $(CFLAGS
) $(LDFLAGS
) -o
$@ mips-tfile.o version.o
$(LIBS
)
1352 mips-tfile.o
: mips-tfile.c
$(CONFIG_H
) $(RTL_H
)
1354 mips-tdump
: mips-tdump.o version.o
$(LIBDEPS
)
1355 $(CC
) $(CFLAGS
) $(LDFLAGS
) -o
$@ mips-tdump.o version.o
$(LIBS
)
1357 mips-tdump.o
: mips-tdump.c
$(CONFIG_H
) $(RTL_H
)
1359 # Build file to support OSF/rose half-pic format.
1360 halfpic.o
: halfpic.c
$(CONFIG_H
) $(RTL_H
) $(TREE_H
)
1362 # Normally this target is not used; but it is used if you
1363 # define ALLOCA=alloca.o. In that case, you must get a suitable alloca.c
1364 # from the GNU Emacs distribution.
1366 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) $(ALLOCA_FLAGS
) \
1367 -c
`echo $(srcdir)/alloca.c | sed 's,^\./,,'`
1370 # Generate header and source files from the machine description,
1373 .PRECIOUS
: insn-config.h insn-flags.h insn-codes.h \
1374 insn-emit.c insn-recog.c insn-extract.c insn-output.c insn-peep.c \
1375 insn-attr.h insn-attrtab.c
1377 # The following pair of rules has this effect:
1378 # genconfig is run only if the md has changed since genconfig was last run;
1379 # but the file insn-config.h is touched only when its contents actually change.
1381 # Each of the other insn-* files is handled by a similar pair of rules.
1383 # This causes an anomaly in the results of make -n
1384 # because insn-* is older than stamp-*
1385 # and thus make -n thinks that insn-* will be updated
1386 # and force recompilation of things that depend on it.
1387 # We use move-if-change precisely to avoid such recompilation.
1388 # But there is no way to teach make -n that it will be avoided.
1390 # Each of the insn-*.[ch] rules has a semicolon at the end,
1391 # for otherwise the system Make on SunOS 4.1 never tries
1392 # to recompile insn-*.o. To avoid problems and extra noise from
1393 # versions of make which don't like empty commands (nothing after the
1394 # trailing `;'), we call true for each.
1396 insn-config.h
: stamp-config
; @true
1397 stamp-config
: $(md_file
) genconfig
$(srcdir)/move-if-change
1398 .
/genconfig
$(md_file
) > tmp-config.h
1399 $(srcdir)/move-if-change tmp-config.h insn-config.h
1402 insn-flags.h
: stamp-flags
; @true
1403 stamp-flags
: $(md_file
) genflags
$(srcdir)/move-if-change
1404 .
/genflags
$(md_file
) > tmp-flags.h
1405 $(srcdir)/move-if-change tmp-flags.h insn-flags.h
1408 insn-codes.h
: stamp-codes
; @true
1409 stamp-codes
: $(md_file
) gencodes
$(srcdir)/move-if-change
1410 .
/gencodes
$(md_file
) > tmp-codes.h
1411 $(srcdir)/move-if-change tmp-codes.h insn-codes.h
1414 insn-emit.o
: insn-emit.c
$(CONFIG_H
) $(RTL_H
) expr.h real.h output.h \
1415 insn-config.h insn-flags.h insn-codes.h
1416 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) -c insn-emit.c
1418 insn-emit.c
: stamp-emit
; @true
1419 stamp-emit
: $(md_file
) genemit
$(srcdir)/move-if-change
1420 .
/genemit
$(md_file
) > tmp-emit.c
1421 $(srcdir)/move-if-change tmp-emit.c insn-emit.c
1424 insn-recog.o
: insn-recog.c
$(CONFIG_H
) $(RTL_H
) insn-config.h recog.h \
1425 real.h output.h flags.h
1426 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) -c insn-recog.c
1428 insn-recog.c
: stamp-recog
; @true
1429 stamp-recog
: $(md_file
) genrecog
$(srcdir)/move-if-change
1430 .
/genrecog
$(md_file
) > tmp-recog.c
1431 $(srcdir)/move-if-change tmp-recog.c insn-recog.c
1434 insn-opinit.o
: insn-opinit.c
$(CONFIG_H
) $(RTL_H
) insn-codes.h insn-flags.h \
1435 insn-config.h flags.h rtl.h recog.h expr.h reload.h
1436 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) -c insn-opinit.c
1438 insn-opinit.c
: stamp-opinit
; @true
1439 stamp-opinit
: $(md_file
) genopinit
$(srcdir)/move-if-change
1440 .
/genopinit
$(md_file
) > tmp-opinit.c
1441 $(srcdir)/move-if-change tmp-opinit.c insn-opinit.c
1444 insn-extract.o
: insn-extract.c
$(CONFIG_H
) $(RTL_H
)
1445 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) -c insn-extract.c
1447 insn-extract.c
: stamp-extract
; @true
1448 stamp-extract
: $(md_file
) genextract
$(srcdir)/move-if-change
1449 .
/genextract
$(md_file
) > tmp-extract.c
1450 $(srcdir)/move-if-change tmp-extract.c insn-extract.c
1453 insn-peep.o
: insn-peep.c
$(CONFIG_H
) $(RTL_H
) regs.h output.h real.h
1454 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) -c insn-peep.c
1456 insn-peep.c
: stamp-peep
; @true
1457 stamp-peep
: $(md_file
) genpeep
$(srcdir)/move-if-change
1458 .
/genpeep
$(md_file
) > tmp-peep.c
1459 $(srcdir)/move-if-change tmp-peep.c insn-peep.c
1462 insn-attrtab.o
: insn-attrtab.c
$(CONFIG_H
) $(RTL_H
) regs.h real.h output.h \
1463 insn-attr.h insn-config.h
1464 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) -c insn-attrtab.c
1466 insn-attr.h
: stamp-attr
; @true
1467 stamp-attr
: $(md_file
) genattr
$(srcdir)/move-if-change
1468 .
/genattr
$(md_file
) > tmp-attr.h
1469 $(srcdir)/move-if-change tmp-attr.h insn-attr.h
1472 insn-attrtab.c
: stamp-attrtab
; @true
1473 stamp-attrtab
: $(md_file
) genattrtab
$(srcdir)/move-if-change
1474 if cmp
-s
$(PREMADE_ATTRTAB_MD
) $(md_file
); \
1476 echo Using
$(PREMADE_ATTRTAB
); \
1477 cp
$(PREMADE_ATTRTAB
) tmp-attrtab.c
; \
1479 .
/genattrtab
$(md_file
) > tmp-attrtab.c
; \
1481 $(srcdir)/move-if-change tmp-attrtab.c insn-attrtab.c
1484 insn-output.o
: insn-output.c
$(CONFIG_H
) $(RTL_H
) regs.h real.h conditions.h \
1485 hard-reg-set.h insn-config.h insn-flags.h insn-attr.h output.h recog.h \
1487 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) -c insn-output.c
1489 insn-output.c
: stamp-output
; @true
1490 stamp-output
: $(md_file
) genoutput
$(srcdir)/move-if-change
1491 .
/genoutput
$(md_file
) > tmp-output.c
1492 $(srcdir)/move-if-change tmp-output.c insn-output.c
1495 # Compile the programs that generate insn-* from the machine description.
1496 # They are compiled with $(HOST_CC), and associated libraries,
1497 # since they need to run on this machine
1498 # even if GCC is being compiled to run on some other machine.
1500 # $(CONFIG_H) is omitted from the deps of the gen*.o
1501 # because these programs don't really depend on anything
1502 # about the target machine. They do depend on config.h itself,
1503 # since that describes the host machine.
1505 # Pass the md file through cpp if the target requests it.
1506 $(MD_FILE
): $(MD_DEPS
)
1508 $(MD_CPP
) $(MD_CPPFLAGS
) $(md_file
) | sed
's/^# /; /g' > tmp-
$@
1511 genconfig
: genconfig.o
$(HOST_RTL
) $(HOST_LIBDEPS
)
1512 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1513 genconfig.o
$(HOST_RTL
) $(HOST_LIBS
)
1515 genconfig.o
: genconfig.c
$(RTL_H
) $(build_xm_file
)
1516 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/genconfig.c
1518 genflags
: genflags.o
$(HOST_RTL
) $(HOST_LIBDEPS
)
1519 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1520 genflags.o
$(HOST_RTL
) $(HOST_LIBS
)
1522 genflags.o
: genflags.c
$(RTL_H
) $(build_xm_file
)
1523 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/genflags.c
1525 gencodes
: gencodes.o
$(HOST_RTL
) $(HOST_LIBDEPS
)
1526 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1527 gencodes.o
$(HOST_RTL
) $(HOST_LIBS
)
1529 gencodes.o
: gencodes.c
$(RTL_H
) $(build_xm_file
)
1530 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/gencodes.c
1532 genemit
: genemit.o
$(HOST_RTL
) $(HOST_LIBDEPS
)
1533 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1534 genemit.o
$(HOST_RTL
) $(HOST_LIBS
)
1536 genemit.o
: genemit.c
$(RTL_H
) $(build_xm_file
)
1537 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/genemit.c
1539 genopinit
: genopinit.o
$(HOST_RTL
) $(HOST_LIBDEPS
)
1540 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1541 genopinit.o
$(HOST_RTL
) $(HOST_LIBS
)
1543 genopinit.o
: genopinit.c
$(RTL_H
) $(build_xm_file
)
1544 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/genopinit.c
1546 genrecog
: genrecog.o
$(HOST_RTL
) $(HOST_LIBDEPS
)
1547 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1548 genrecog.o
$(HOST_RTL
) $(HOST_LIBS
)
1550 genrecog.o
: genrecog.c
$(RTL_H
) $(build_xm_file
)
1551 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/genrecog.c
1553 genextract
: genextract.o
$(HOST_RTL
) $(HOST_LIBDEPS
)
1554 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1555 genextract.o
$(HOST_RTL
) $(HOST_LIBS
)
1557 genextract.o
: genextract.c
$(RTL_H
) $(build_xm_file
) insn-config.h
1558 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/genextract.c
1560 genpeep
: genpeep.o
$(HOST_RTL
) $(HOST_LIBDEPS
)
1561 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1562 genpeep.o
$(HOST_RTL
) $(HOST_LIBS
)
1564 genpeep.o
: genpeep.c
$(RTL_H
) $(build_xm_file
)
1565 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/genpeep.c
1567 genattr
: genattr.o
$(HOST_RTL
) $(HOST_LIBDEPS
)
1568 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1569 genattr.o
$(HOST_RTL
) $(HOST_LIBS
)
1571 genattr.o
: genattr.c
$(RTL_H
) $(build_xm_file
)
1572 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/genattr.c
1574 genattrtab
: genattrtab.o
$(HOST_RTL
) $(HOST_PRINT
) $(HOST_RTLANAL
) $(HOST_LIBDEPS
)
1575 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1576 genattrtab.o
$(HOST_RTL
) $(HOST_PRINT
) $(HOST_RTLANAL
) $(HOST_LIBS
)
1578 genattrtab.o
: genattrtab.c
$(RTL_H
) $(build_xm_file
) insn-config.h
1579 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/genattrtab.c
1581 genoutput
: genoutput.o
$(HOST_RTL
) $(HOST_LIBDEPS
)
1582 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1583 genoutput.o
$(HOST_RTL
) $(HOST_LIBS
)
1585 genoutput.o
: genoutput.c
$(RTL_H
) $(build_xm_file
)
1586 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/genoutput.c
1588 # Compile the libraries to be used by gen*.
1589 # If we are not cross-building, gen* use the same .o's that cc1 will use,
1590 # and HOST_PREFIX_1 is `foobar', just to ensure these rules don't conflict
1591 # with the rules for rtl.o, alloca.o, etc.
1592 $(HOST_PREFIX_1
)rtl.o
: $(srcdir)/rtl.c
$(CONFIG_H
) $(RTL_H
)
1593 rm -f
$(HOST_PREFIX
)rtl.c
1594 sed
-e
's/config[.]h/hconfig.h/' $(srcdir)/rtl.c
> $(HOST_PREFIX
)rtl.c
1595 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(HOST_PREFIX
)rtl.c
1597 $(HOST_PREFIX_1
)print-rtl.o
: $(srcdir)/print-rtl.c
$(CONFIG_H
) $(RTL_H
)
1598 rm -f
$(HOST_PREFIX
)print-rtl.c
1599 sed
-e
's/config[.]h/hconfig.h/' $(srcdir)/print-rtl.c
> $(HOST_PREFIX
)print-rtl.c
1600 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(HOST_PREFIX
)print-rtl.c
1602 $(HOST_PREFIX_1
)rtlanal.o
: $(srcdir)/rtlanal.c
$(CONFIG_H
) $(RTL_H
)
1603 rm -f
$(HOST_PREFIX
)rtlanal.c
1604 sed
-e
's/config[.]h/hconfig.h/' $(srcdir)/rtlanal.c
> $(HOST_PREFIX
)rtlanal.c
1605 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(HOST_PREFIX
)rtlanal.c
1607 $(HOST_PREFIX_1
)alloca.o
: alloca.c
1608 rm -f
$(HOST_PREFIX
)alloca.c
1609 cp
$(srcdir)/alloca.c
$(HOST_PREFIX
)alloca.c
1610 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(HOST_PREFIX
)alloca.c
1612 $(HOST_PREFIX_1
)obstack.o
: obstack.c
1613 rm -f
$(HOST_PREFIX
)obstack.c
1614 sed
-e
's/config[.]h/hconfig.h/' $(srcdir)/obstack.c
> $(HOST_PREFIX
)obstack.c
1615 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(HOST_PREFIX
)obstack.c
1617 $(HOST_PREFIX_1
)malloc.o
: malloc.c
1618 rm -f
$(HOST_PREFIX
)malloc.c
1619 sed
-e
's/config[.]h/hconfig.h/' $(srcdir)/malloc.c
> $(HOST_PREFIX
)malloc.c
1620 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(HOST_PREFIX
)malloc.c
1622 # This satisfies the dependency that we get if you cross-compile a compiler
1623 # that does not need to compile alloca, malloc or whatever.
1625 touch
$(HOST_PREFIX_1
)
1627 # Remake bytecode files.
1628 BI_OBJ
=bi-parser.o bi-lexer.o bi-reverse.o
1630 bc-emit.o
: bc-emit.c
$(CONFIG_H
) $(RTL_H
) real.h
$(BYTECODE_H
) \
1631 bc-arity.h bc-opcode.h bc-typecd.h bc-typecd.def bi-run.h bytetypes.h
1632 bc-optab.o
: bc-optab.c
$(CONFIG_H
) $(REAL_H
) $(BYTECODE_H
) \
1633 bc-opcode.h bc-typecd.h bc-typecd.def
1635 bi-arity
: bi-arity.o
$(BI_OBJ
) $(HOST_LIBDEPS
)
1636 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1637 bi-arity.o
$(BI_OBJ
) $(HOST_LIBS
)
1638 bi-opcode
: bi-opcode.o
$(BI_OBJ
) $(HOST_LIBDEPS
)
1639 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1640 bi-opcode.o
$(BI_OBJ
) $(HOST_LIBS
)
1641 bi-opname
: bi-opname.o
$(BI_OBJ
) $(HOST_LIBDEPS
)
1642 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1643 bi-opname.o
$(BI_OBJ
) $(HOST_LIBS
)
1645 $(srcdir)/bi-parser.h
: $(srcdir)/bi-parser.c
1646 $(srcdir)/bi-parser.c
: $(srcdir)/bi-parser.y
1647 cd
$(srcdir); $(BISON
) $(BISONFLAGS
) -d bi-parser.y
-o bi-parser.c
1649 bi-parser.o
: $(srcdir)/bi-parser.c bi-defs.h
$(build_xm_file
)
1650 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) \
1651 $(srcdir)/bi-parser.c
1652 bi-lexer.o
: bi-lexer.c
$(srcdir)/bi-parser.h
$(build_xm_file
)
1653 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) \
1654 $(srcdir)/bi-lexer.c
1655 bi-arity.o
: bi-arity.c bi-defs.h
$(build_xm_file
)
1656 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) \
1657 $(srcdir)/bi-arity.c
1658 bi-opcode.o
: bi-opcode.c bi-defs.h
$(build_xm_file
)
1659 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) \
1660 $(srcdir)/bi-opcode.c
1661 bi-opname.o
: bi-opname.c bi-defs.h
$(build_xm_file
)
1662 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) \
1663 $(srcdir)/bi-opname.c
1664 bi-reverse.o
: bi-reverse.c bi-defs.h
1665 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) \
1666 $(srcdir)/bi-reverse.c
1668 bc-arity.h
: stamp-bcarity
; @true
1669 stamp-bcarity
: $(srcdir)/bytecode.def bi-arity
$(srcdir)/move-if-change
1670 .
/bi-arity
< $(srcdir)/bytecode.def
>tmp-bc-arity.h
1671 $(srcdir)/move-if-change tmp-bc-arity.h bc-arity.h
1674 bc-opcode.h
: stamp-bcopcode
; @true
1675 stamp-bcopcode
: $(srcdir)/bytecode.def bi-opcode
$(srcdir)/move-if-change
1676 .
/bi-opcode
< $(srcdir)/bytecode.def
>tmp-bcopcd.h
1677 $(srcdir)/move-if-change tmp-bcopcd.h bc-opcode.h
1678 touch stamp-bcopcode
1680 bc-opname.h
: stamp-bcopname
; @true
1681 stamp-bcopname
: $(srcdir)/bytecode.def bi-opname
$(srcdir)/move-if-change
1682 .
/bi-opname
< $(srcdir)/bytecode.def
>tmp-bcopnm.h
1683 $(srcdir)/move-if-change tmp-bcopnm.h bc-opname.h
1684 touch stamp-bcopname
1686 bytecode.
mostlyclean:
1687 -rm -f bc-arity.h bc-opcode.h bc-opname.h
1689 bytecode.
distclean bytecode.
clean: bytecode.
mostlyclean
1690 -rm -f bi-arity bi-opcode bi-opname bi-lexer
1692 bytecode.maintainer-clean
: bytecode.
clean
1693 -rm -f bi-parser.c bi-parser.h
1696 # Remake cpp and protoize.
1698 # Making the preprocessor
1701 ln
$(CCCP
)$(exeext
) cpp$(exeext
) > /dev
/null
2>&1 \
1702 || cp
$(CCCP
)$(exeext
) cpp$(exeext
)
1703 cccp
: cccp.o cexp.o version.o
$(LIBDEPS
)
1704 $(CC
) $(ALL_CFLAGS
) $(LDFLAGS
) -o
$@ cccp.o cexp.o \
1706 cexp.o
: $(srcdir)/cexp.c
$(CONFIG_H
)
1707 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) -c
$(srcdir)/cexp.c
1708 $(srcdir)/cexp.c
: $(srcdir)/cexp.y
1709 cd
$(srcdir); $(BISON
) -o cexp.c cexp.y
1711 cccp.o
: cccp.c
$(CONFIG_H
) pcp.h version.c config.status
1712 # The reason we use $(libdir)/g++-include rather than using libsubdir
1713 # is for compatibility with the current version of libg++.
1714 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) \
1715 -DGCC_INCLUDE_DIR
=\"$(libsubdir
)/include\" \
1716 -DGPLUSPLUS_INCLUDE_DIR
=\"$(gxx_include_dir
)\" \
1717 -DOLD_GPLUSPLUS_INCLUDE_DIR
=\"$(old_gxx_include_dir
)\" \
1718 -DLOCAL_INCLUDE_DIR
=\"$(includedir)\" \
1719 -DCROSS_INCLUDE_DIR
=\"$(libsubdir
)/sys-include
\" \
1720 -DTOOL_INCLUDE_DIR
=\"$(tooldir
)/include\" \
1721 -c
`echo $(srcdir)/cccp.c | sed 's,^\./,,'`
1723 cppmain
: cppmain.o cpplib.o cpphash.o cppalloc.o cpperror.o cppexp.o \
1724 version.o
$(LIBDEPS
)
1725 $(CC
) $(ALL_CFLAGS
) $(LDFLAGS
) -o
$@ cppmain.o cpplib.o cpphash.o \
1726 cppalloc.o cpperror.o cppexp.o version.o
$(LIBS
)
1728 cppmain.o
: cppmain.c
$(CONFIG_H
) cpplib.h
1730 cpplib.o
: cpplib.c
$(CONFIG_H
) cpplib.h cpphash.h config.status
1731 $(CC
) $(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) \
1732 -DGCC_INCLUDE_DIR
=\"$(libsubdir
)/include\" \
1733 -DGPLUSPLUS_INCLUDE_DIR
=\"$(gxx_include_dir
)\" \
1734 -DOLD_GPLUSPLUS_INCLUDE_DIR
=\"$(old_gxx_include_dir
)\" \
1735 -DLOCAL_INCLUDE_DIR
=\"$(includedir)\" \
1736 -DCROSS_INCLUDE_DIR
=\"$(libsubdir
)/sys-include
\" \
1737 -DTOOL_INCLUDE_DIR
=\"$(tooldir
)/include\" \
1738 -c
`echo $(srcdir)/cpplib.c | sed 's,^\./,,'`
1740 cpperror.o
: cpperror.c
$(CONFIG_H
) cpplib.h
1742 cppexp.o
: cppexp.c
$(CONFIG_H
) cpplib.h
1744 cpphash.o
: cpphash.c cpplib.h cpphash.h
1746 cppalloc.o
: cppalloc.c
$(CONFIG_H
)
1748 # Note for the stamp targets, we run the program `true' instead of
1749 # having an empty command (nothing following the semicolon).
1751 proto
: config.status protoize unprotoize SYSCALLS.c.X
1753 protoize
: protoize.o getopt.o getopt1.o getpwd.o version.o \
1754 pexecute.o choose-temp.o
$(LIBDEPS
)
1755 $(CC
) $(ALL_CFLAGS
) $(LDFLAGS
) -o
$@ \
1756 protoize.o getopt.o getopt1.o getpwd.o version.o \
1757 pexecute.o choose-temp.o
$(LIBS
)
1758 protoize.o
: stamp-proto
; @true
1760 unprotoize
: unprotoize.o getopt.o getopt1.o getpwd.o version.o \
1761 pexecute.o choose-temp.o
$(LIBDEPS
)
1762 $(CC
) $(ALL_CFLAGS
) $(LDFLAGS
) -o
$@ \
1763 unprotoize.o getopt.o getopt1.o getpwd.o version.o \
1764 pexecute.o choose-temp.o
$(LIBS
)
1765 unprotoize.o
: stamp-proto
; @true
1767 stamp-proto
: protoize.c getopt.h
$(CONFIG_H
)
1768 $(CC
) -c
$(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) \
1769 -DGCC_INCLUDE_DIR
=\"$(libsubdir
)/include\" \
1770 -DGPLUSPLUS_INCLUDE_DIR
=\"$(gxx_include_dir
)\" \
1771 -DCROSS_INCLUDE_DIR
=\"$(libsubdir
)/sys-include
\" \
1772 -DTOOL_INCLUDE_DIR
=\"$(tooldir
)/include\" \
1773 -DLOCAL_INCLUDE_DIR
=\"$(includedir)\" \
1774 -DSTD_PROTO_DIR
=\"$(libsubdir
)\" \
1775 -DUNPROTOIZE
$(srcdir)/protoize.c
1776 mv protoize
$(objext
) unprotoize
$(objext
)
1777 $(CC
) -c
$(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) \
1778 -DGCC_INCLUDE_DIR
=\"$(libsubdir
)/include\" \
1779 -DGPLUSPLUS_INCLUDE_DIR
=\"$(gxx_include_dir
)\" \
1780 -DCROSS_INCLUDE_DIR
=\"$(libsubdir
)/sys-include
\" \
1781 -DTOOL_INCLUDE_DIR
=\"$(tooldir
)/include\" \
1782 -DLOCAL_INCLUDE_DIR
=\"$(includedir)\" \
1783 -DSTD_PROTO_DIR
=\"$(libsubdir
)\" \
1784 $(srcdir)/protoize.c
1787 getopt.o
: getopt.c getopt.h
1788 $(CC
) -c
$(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) $(srcdir)/getopt.c
1789 getopt1.o
: getopt1.c getopt.h
1790 $(CC
) -c
$(ALL_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) $(srcdir)/getopt1.c
1792 # This info describes the target machine, so compile with GCC just built.
1793 SYSCALLS.c.X
: $(srcdir)/sys-types.h
$(srcdir)/sys-protos.h
$(GCC_PASSES
) \
1795 -rm -f SYSCALLS.c tmp-SYSCALLS.s
1796 cat
$(srcdir)/sys-types.h
$(srcdir)/sys-protos.h
> SYSCALLS.c
1797 $(GCC_FOR_TARGET
) $(GCC_CFLAGS
) $(ALL_CPPFLAGS
) $(INCLUDES
) \
1798 -aux-info
$@
-S
-o tmp-SYSCALLS.s SYSCALLS.c
1799 -rm -f SYSCALLS.c tmp-SYSCALLS.s
1802 test-protoize-simple
: .
/protoize .
/unprotoize
$(GCC_PASSES
)
1803 -rm -f tmp-proto.
[cso
]
1804 cp
$(srcdir)/protoize.c tmp-proto.c
1805 chmod u
+w tmp-proto.c
1806 .
/protoize
-N
-B .
/ -x getopt.h
-c
"-B./ -Wall -Wwrite-strings \
1807 $(CFLAGS) $(INCLUDES) \
1808 -DGCC_INCLUDE_DIR=0 \
1809 -DGPLUSPLUS_INCLUDE_DIR=0 \
1810 -DCROSS_INCLUDE_DIR=0 \
1811 -DTOOL_INCLUDE_DIR=0 \
1812 -DSTD_PROTO_DIR=0" tmp-proto.c
1813 @echo
'**********' Expect
400 lines of differences.
1814 -diff
$(srcdir)/protoize.c tmp-proto.c
> tmp-proto.diff
1815 -wc
-l tmp-proto.diff
1816 .
/unprotoize
-N
-x getopt.h
-c
"-B./ -Wall -Wwrite-strings \
1817 $(CFLAGS) $(INCLUDES) \
1818 -DGCC_INCLUDE_DIR=0 \
1819 -DGPLUSPLUS_INCLUDE_DIR=0 \
1820 -DCROSS_INCLUDE_DIR=0 \
1821 -DTOOL_INCLUDE_DIR=0 \
1822 -DSTD_PROTO_DIR=0" tmp-proto.c
1823 @echo Expect zero differences.
1824 diff
$(srcdir)/protoize.c tmp-proto.c | cat
1825 -rm -f tmp-proto.
[cs
] tmp-proto
$(objext
)
1827 gcov.o
: gcov.c gcov-io.h
1829 gcov
: gcov.o
$(LIBDEPS
)
1830 $(CC
) $(ALL_CFLAGS
) $(LDFLAGS
) gcov.o
$(LIBS
) -o
$@
1832 # Build the include directory. The stamp files are stmp-* rather than
1833 # stamp-* so that mostlyclean does not force the include directory to
1836 # Build the include directory except for float.h (which depends upon
1838 stmp-int-hdrs
: stmp-fixinc
$(USER_H
) xlimits.h objc-headers
1839 # Copy in the headers provided with gcc.
1840 # The sed command gets just the last file name component;
1841 # this is necessary because VPATH could add a dirname.
1842 # Using basename would be simpler, but some systems don't have it.
1843 for file in ..
$(USER_H
); do \
1844 if
[ X
$$file != X..
]; then \
1845 realfile
=`echo $$file | sed -e 's|.*/\([^/]*\)$$|\1|'`; \
1846 rm -f
include/$$realfile; \
1847 cp
$$file include; \
1848 chmod a
+r
include/$$realfile; \
1851 rm -f
include/limits.h
1852 cp xlimits.h
include/limits.h
1853 chmod a
+r
include/limits.h
1854 # Install the README
1855 rm -f
include/README
1856 cp
$(srcdir)/README-fixinc
include/README
1857 chmod a
+r
include/README
1860 # Build the complete include directory.
1861 stmp-headers
: stmp-int-hdrs gfloat.h
1862 rm -f
include/float.h
1863 cp gfloat.h
include/float.h
1864 chmod a
+r
include/float.h
1867 # Build fixed copies of system files.
1868 stmp-fixinc
: $(FIXINCLUDES
) gsyslimits.h
1871 if
[ x
$(FIXINCLUDES
) != xMakefile.in
]; \
1873 for
dir in
$(SYSTEM_HEADER_DIR
) $(OTHER_FIXINCLUDES_DIRS
); do \
1876 $(SHELL
) $(srcdir)/$(FIXINCLUDES
) include $$dir; \
1881 rm -f
include/syslimits.h
1882 if
[ -f
include/limits.h
]; then \
1883 mv
include/limits.h
include/syslimits.h
; \
1885 cp
$(srcdir)/gsyslimits.h
include/syslimits.h
; \
1887 chmod a
+r
include/syslimits.h
1890 # copy objc header files into build directory
1891 objc-headers
: stmp-fixinc
1892 if
[ -d
include ]; then true
; else mkdir
include; fi
1893 if
[ -d objc
]; then true
; else mkdir objc
; fi
1895 srcdir1
=`cd $(srcdir); pwd`; \
1897 if
[ -f
$${srcdir1}/objc
/Makefile
]; then \
1898 $(MAKE
) -f
$${srcdir1}/objc
/Makefile copy-headers \
1899 srcdir=$${srcdir1} tooldir
=$(tooldir
) AR
="$(AR)" AR_FLAGS
="$(AR_FLAGS)" \
1900 GCC_FOR_TARGET
="$${thisdir1}/xgcc -B$${thisdir1}/" \
1901 GCC_CFLAGS
="$(GCC_CFLAGS)" incinstalldir
=$${thisdir1}/include; \
1905 # Files related to the fixproto script.
1907 deduced.h
: $(GCC_PASSES
) $(srcdir)/scan-types.sh stmp-int-hdrs
1908 CC
="$(GCC_FOR_TARGET) $(GCC_CFLAGS) $(ALL_CPPFLAGS) -I. -I$(srcdir) -Iinclude -I${SYSTEM_HEADER_DIR}"; \
1910 $(SHELL
) $(srcdir)/scan-types.sh
"$(srcdir)" >tmp-deduced.h
1911 mv tmp-deduced.h deduced.h
1913 gen-protos
: gen-protos.o scan.o cppalloc.o
$(HOST_LIBDEPS
)
1914 ${HOST_CC} $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ \
1915 gen-protos.o scan.o cppalloc.o
$(HOST_LIBS
)
1917 gen-protos.o
: gen-protos.c scan.h
$(build_xm_file
)
1918 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/gen-protos.c
1920 scan.o
: scan.c scan.h
$(build_xm_file
)
1921 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/scan.c
1923 xsys-protos.h
: $(GCC_PASSES
) $(srcdir)/sys-protos.h deduced.h gen-protos Makefile
1924 cat deduced.h
$(srcdir)/sys-protos.h
> tmp-fixtmp.c
1925 mv tmp-fixtmp.c fixtmp.c
1926 $(GCC_FOR_TARGET
) fixtmp.c
-w
-U__SIZE_TYPE__
-U__PTRDIFF_TYPE__
-U__WCHAR_TYPE__
-E \
1927 | sed
-e
's/ / /g' -e
's/ *(/ (/g' -e
's/ [ ]*/ /g' -e
's/( )/()/' \
1928 | .
/gen-protos
>xsys-protos.hT
1929 mv xsys-protos.hT xsys-protos.h
1932 fix-header
: fix-header.o scan-decls.o scan.o xsys-protos.h
$(HOST_LIBDEPS
) \
1933 cpplib.o cpphash.o cppalloc.o cppexp.o cpperror.o version.o
1934 $(HOST_CC
) $(HOST_CFLAGS
) $(HOST_LDFLAGS
) -o
$@ fix-header.o \
1935 scan-decls.o scan.o cpplib.o cpphash.o cppalloc.o version.o \
1936 cppexp.o
$(HOST_LIBS
)
1938 fix-header.o
: fix-header.c obstack.h scan.h xsys-protos.h
$(build_xm_file
)
1939 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/fix-header.c
1941 scan-decls.o
: scan-decls.c scan.h cpplib.h
$(build_xm_file
)
1942 $(HOST_CC
) -c
$(HOST_CFLAGS
) $(HOST_CPPFLAGS
) $(INCLUDES
) $(srcdir)/scan-decls.c
1944 # stmp-fixproto depends on this, not on fix-header directly.
1945 # The idea is to make sure fix-header gets built,
1946 # but not rerun fixproto after each stage
1947 # just because fix-header's mtime has changed.
1948 fixhdr.ready
: fix-header
1949 -if
[ -f fixhdr.ready
] ; then \
1952 touch fixhdr.ready
; \
1955 # stmp-headers is to make sure fixincludes has already finished.
1956 # The if statement is so that we don't run fixproto a second time
1957 # if it has already been run on the files in `include'.
1958 stmp-fixproto
: fixhdr.ready fixproto stmp-headers
1959 @echo
"Various warnings and error messages from fixproto are normal"
1960 -if
[ -d
include ] ; then true
; else mkdir
include; fi
1961 -if
[ -f
include/fixed
] ; then true
; \
1963 : This line works around a
'make' bug in BSDI
1.1.
; \
1964 FIXPROTO_DEFINES
="$(FIXPROTO_DEFINES)"; export FIXPROTO_DEFINES
; \
1965 $(SHELL
) ${srcdir}/fixproto
include include $(SYSTEM_HEADER_DIR
); \
1966 touch
include/fixed
; \
1970 # Remake the info files.
1973 info: $(srcdir)/cpp.
info $(srcdir)/gcc.
info lang.
info
1975 $(srcdir)/cpp.
info: cpp.texi
1976 cd
$(srcdir); $(MAKEINFO
) $(MAKEINFOFLAGS
) cpp.texi
1978 $(srcdir)/gcc.
info: gcc.texi extend.texi
install.texi invoke.texi \
1979 md.texi rtl.texi tm.texi gcov.texi
1980 cd
$(srcdir); $(MAKEINFO
) $(MAKEINFOFLAGS
) gcc.texi
1982 dvi: $(srcdir)/gcc.
dvi $(srcdir)/cpp.
dvi lang.
dvi
1984 # This works with GNU Make's default rule.
1985 $(srcdir)/gcc.
dvi: gcc.texi extend.texi
install.texi invoke.texi \
1986 md.texi rtl.texi tm.texi gcov.texi
1989 # This works with GNU Make's default rule.
1990 $(srcdir)/cpp.
dvi: cpp.texi
1993 $(srcdir)/INSTALL
: install1.texi
install.texi
1994 $(MAKEINFO
) -D INSTALLONLY
--no-header
--no-split \
1995 `echo $(srcdir)/install1.texi | sed 's,^\./,,'`
1997 # Deletion of files made during compilation.
1998 # There are four levels of this:
1999 # `mostlyclean', `clean', `distclean' and `maintainer-clean'.
2000 # `mostlyclean' is useful while working on a particular type of machine.
2001 # It deletes most, but not all, of the files made by compilation.
2002 # It does not delete libgcc.a or its parts, so it won't have to be recompiled.
2003 # `clean' deletes everything made by running `make all'.
2004 # `distclean' also deletes the files made by config.
2005 # `maintainer-clean' also deletes everything that could be regenerated
2006 # automatically. We remove as much from the language subdirectories as we can
2007 # (less duplicated code).
2010 mostlyclean: bytecode.
mostlyclean lang.
mostlyclean
2011 -rm -f
$(STAGESTUFF
)
2012 # Clean the objc subdir if we created one.
2013 if
[ -d objc
]; then \
2014 srcdir1
=`cd $(srcdir); pwd`; \
2015 cd objc
; $(MAKE
) -f
$$srcdir1/objc
/Makefile
mostlyclean; \
2018 # Delete the temporary source copies for cross compilation.
2019 -rm -f
$(HOST_PREFIX_1
)rtl.c
$(HOST_PREFIX_1
)rtlanal.c
2020 -rm -f
$(HOST_PREFIX_1
)alloca.c
$(HOST_PREFIX_1
)malloc.c
2021 -rm -f
$(HOST_PREFIX_1
)obstack.c
2022 # Delete the temp files made in the course of building libgcc.a.
2023 -rm -f tmplibgcc
* tmpcopy xlimits.h
2024 for name in
$(LIB1FUNCS
); do
rm -f
$${name}.c
; done
2025 # Delete other temporary files.
2026 -rm -f tmp-float.h tmp-gcc.xtar.gz
2027 -rm -f tmp-foo1 tmp-foo2 tmp-proto.
* tmp-unproto
.1 tmp-SYSCALLS.s
2028 -rm -f tmp-c-parse.y tmp-objc-prs.y tmp-gperf.h
2029 -rm -f tmp-specs t-float.h-cross tmp-xlimits.h
2030 -rm -f tmp-fixtmp.c xsys-protos.hT
2031 # Delete the stamp files.
2032 -rm -f stamp-
* tmp-
*
2033 -rm -f
*/stamp-
* */tmp-
*
2034 # Delete debugging dump files.
2035 -rm -f
*.greg
*.lreg
*.combine
*.flow
*.cse
*.jump
*.rtl
*.tree
*.loop
2036 -rm -f
*.dbr
*.jump2
*.sched
*.cse2
*.sched2
*.stack
2037 -rm -f
*/*.greg
*/*.lreg
*/*.combine
*/*.flow
*/*.cse
*/*.jump
*/*.rtl
2038 -rm -f
*/*.tree
*/*.loop
*/*.dbr
*/*.jump2
*/*.sched
*/*.cse2
2039 -rm -f
*/*.sched2
*/*.stack
2040 # Delete some files made during installation.
2041 -rm -f specs gfloat.h float.h-
* enquire SYSCALLS.c.X SYSCALLS.c
2042 -rm -f collect collect2 mips-tfile mips-tdump alloca.s
2043 # Delete files generated for fixproto
2044 -rm -rf fix-header xsys-protos.h deduced.h tmp-deduced.h \
2045 gen-protos fixproto.list fixtmp.
* fixhdr.ready
2046 # Delete unwanted output files from TeX.
2047 -rm -f
*.toc
*.log
*.vr
*.fn
*.cp
*.tp
*.ky
*.pg
2048 -rm -f
*/*.toc
*/*.log
*/*.vr
*/*.fn
*/*.cp
*/*.tp
*/*.ky
*/*.pg
2049 # Delete sorted indices we don't actually use.
2050 -rm -f gcc.vrs gcc.kys gcc.tps gcc.pgs gcc.fns
2051 # Delete core dumps.
2055 # Delete all files made by compilation
2056 # that don't exist in the distribution.
2057 clean: mostlyclean bytecode.
clean lang.
clean
2058 # It may not be quite desirable to delete unprotoize.c here,
2059 # but the spec for `make clean' requires it.
2060 # Using unprotoize.c is not quite right in the first place,
2061 # but what better way is there?
2062 -rm -f libgcc.a libgcc1.a libgcc1-asm.a libgcc2.a libgcc2.ready
2066 -if
[ -f md.pre-cpp
]; then \
2069 # Delete the include directory.
2070 -rm -rf stmp-
* include objc-headers
2072 # Delete files used by the "multilib" facility (including libgcc subdirs).
2073 -rm -f multilib.h tmpmultilib
*
2074 -if
[ "x$(MULTILIB_DIRNAMES)" != x
] ; then \
2075 rm -rf
$(MULTILIB_DIRNAMES
); \
2076 else if
[ "x$(MULTILIB_OPTIONS)" != x
] ; then \
2077 rm -rf
`echo $(MULTILIB_OPTIONS) | sed -e 's/\// /g'`; \
2080 # Delete all files that users would normally create
2081 # while building and installing GCC.
2082 distclean: clean bytecode.
distclean lang.
distclean
2083 -rm -f tm.h config.h tconfig.h hconfig.h md
2084 -rm -f config.status config.run
2085 -rm -f Makefile specs.h options.h
*.oaux
2086 -rm -fr stage1 stage2 stage3 stage4
2087 -rm -f
*/stage1
*/stage2
*/stage3
*/stage4
*/include
2088 -rm -f objc-parse.output
2089 -rm -f c-parse.output
2093 # Delete anything likely to be found in the source directory
2094 # that shouldn't be in the distribution.
2095 extraclean
: distclean lang.extraclean
2096 -rm -rf
=* .
/"#"* *~
* config
/=* config
/"#"* config
/*~
*
2097 -rm -f patch
* *.orig
*.rej config
/patch
* config
/*.orig config
/*.rej
2098 -rm -f config
/*/=* config
/*/"#"* config
/*/*~
*
2099 -rm -f config
/*/*.orig config
/*/*.rej
2100 -rm -f
*.
dvi *.ps
*.oaux
*.d
*.
[zZ
] *.gz
2101 -rm -f
*.
tar *.xtar
*diff
*.diff.
* *.
tar.
* *.xtar.
* *diffs
2102 -rm -f
*lose config
/*lose config
/*/*lose
2103 -rm -f
*.s
*.s
[0-9] *.i install1.texi config
/ChangeLog
2104 -rm -f
*/=* */"#"* */*~
*
2105 -rm -f
*/patch
* */*.orig
*/*.rej
2106 -rm -f
*/*.
dvi */*.oaux
*/*.d
*/*.
[zZ
] */*.gz
2107 -rm -f
*/*.
tar */*.xtar
*/*diff
*/*.diff.
* */*.
tar.
* */*.xtar.
* */*diffs
2108 -rm -f
*/*lose
*/*.s
*/*.s
[0-9] */*.i
2110 # Get rid of every file that's generated from some other file.
2111 # Most of these files ARE PRESENT in the GCC distribution.
2112 maintainer-clean
: distclean bytecode.maintainer-clean lang.maintainer-clean
2113 -rm -f c-parse.y c-gperf.h objc-parse.y
2114 -rm -f objc-parse.c objc-parse.output
2115 -rm -f c-parse.c c-parse.h c-parse.output
2116 -rm -f cexp.c cexp.output TAGS
2117 -rm -f
cpp.
info* cpp.??s
cpp.
*aux
2118 -rm -f gcc.
info* gcc.??s gcc.
*aux
2120 # Entry points `install' and `uninstall'.
2121 # Also use `install-collect2' to install collect2 when the config files don't.
2123 # The semicolon is to prevent the install.sh -> install default rule
2124 # from doing anything. Having it run true helps avoid problems and
2125 # noise from versions of make which don't like to have null commands.
2126 install: $(INSTALL_TARGET
) ; @true
2128 # Copy the compiler files into directories where they will be run.
2129 # Install the driver last so that the window when things are
2131 install-normal
: install-common
$(INSTALL_HEADERS
) $(INSTALL_LIBGCC
) \
2132 install-libobjc install-man install-info lang.install-normal install-driver
2134 # Do nothing while making gcc with a cross-compiler. The person who
2135 # makes gcc for the target machine has to know how to put a complete
2136 # gcc together by hand.
2137 install-build
: force
2138 @echo You have to
install gcc on your target machine by hand.
2140 # Run this on the target machine
2141 # to finish installation of cross compiler.
2142 install-cross-rest
: install-float-h-cross
2144 # Install float.h for cross compiler.
2145 # Run this on the target machine!
2146 install-float-h-cross
: installdirs
2147 # if [ -f enquire ] ; then true; else false; fi
2148 # Note: don't use -. We should fail right away if enquire was not made.
2149 .
/enquire
-f
> $(tmpdir
)/float.h
2150 -rm -f
$(libsubdir
)/include/float.h
2151 $(INSTALL_DATA
) $(tmpdir
)/float.h
$(libsubdir
)/include/float.h
2152 -rm -f
$(tmpdir
)/float.h
2153 chmod a-x
$(libsubdir
)/include/float.h
2155 # Create the installation directories.
2157 -if
[ -d
$(prefix) ] ; then true
; else mkdir
$(prefix) ; chmod a
+rx
$(prefix) ; fi
2158 -if
[ -d
$(exec_prefix) ] ; then true
; else mkdir
$(exec_prefix) ; chmod a
+rx
$(exec_prefix) ; fi
2159 -if
[ -d
$(libdir) ] ; then true
; else mkdir
$(libdir) ; chmod a
+rx
$(libdir) ; fi
2160 -if
[ -d
$(libdir)/gcc-lib
] ; then true
; else mkdir
$(libdir)/gcc-lib
; chmod a
+rx
$(libdir)/gcc-lib
; fi
2161 # This dir isn't currently searched by cpp.
2162 # -if [ -d $(libdir)/gcc-lib/include ] ; then true ; else mkdir $(libdir)/gcc-lib/include ; chmod a+rx $(libdir)/gcc-lib/include ; fi
2163 -if
[ -d
$(libdir)/gcc-lib
/$(target_alias
) ] ; then true
; else mkdir
$(libdir)/gcc-lib
/$(target_alias
) ; chmod a
+rx
$(libdir)/gcc-lib
/$(target_alias
) ; fi
2164 -if
[ -d
$(libdir)/gcc-lib
/$(target_alias
)/$(version
) ] ; then true
; else mkdir
$(libdir)/gcc-lib
/$(target_alias
)/$(version
) ; chmod a
+rx
$(libdir)/gcc-lib
/$(target_alias
)/$(version
) ; fi
2165 -if
[ -d
$(libdir)/gcc-lib
/$(target_alias
)/$(version
)/include ] ; then true
; else mkdir
$(libdir)/gcc-lib
/$(target_alias
)/$(version
)/include ; chmod a
+rx
$(libdir)/gcc-lib
/$(target_alias
)/$(version
)/include ; fi
2166 -if
[ -d
$(bindir) ] ; then true
; else mkdir
$(bindir) ; chmod a
+rx
$(bindir) ; fi
2167 -if
[ -d
$(includedir) ] ; then true
; else mkdir
$(includedir) ; chmod a
+rx
$(includedir) ; fi
2168 -if
[ -d
$(tooldir
) ] ; then true
; else mkdir
$(tooldir
) ; chmod a
+rx
$(tooldir
) ; fi
2169 -if
[ -d
$(assertdir
) ] ; then true
; else mkdir
$(assertdir
) ; chmod a
+rx
$(assertdir
) ; fi
2170 -if
[ -d
$(infodir) ] ; then true
; else mkdir
$(infodir) ; chmod a
+rx
$(infodir) ; fi
2171 # We don't use mkdir -p to create the parents of mandir,
2172 # because some systems don't support it.
2173 # Instead, we use this technique to create the immediate parent of mandir.
2174 -parent
=`echo $(mandir)|sed -e 's@/[^/]*$$@@'`; \
2175 if
[ -d
$$parent ] ; then true
; else mkdir
$$parent ; chmod a
+rx
$$parent ; fi
2176 -if
[ -d
$(mandir) ] ; then true
; else mkdir
$(mandir) ; chmod a
+rx
$(mandir) ; fi
2178 # Install the compiler executables built during cross compilation.
2179 install-common
: native
installdirs $(EXTRA_PARTS
) lang.install-common
2180 for file in
$(COMPILERS
); do \
2181 if
[ -f
$$file ] ; then \
2182 rm -f
$(libsubdir
)/$$file; \
2183 $(INSTALL_PROGRAM
) $$file $(libsubdir
)/$$file; \
2187 for file in
$(EXTRA_PASSES
) $(EXTRA_PROGRAMS
) $(USE_COLLECT2
) ..
; do \
2188 if
[ x
"$$file" != x..
]; then \
2189 rm -f
$(libsubdir
)/$$file; \
2190 $(INSTALL_PROGRAM
) $$file $(libsubdir
)/$$file; \
2193 for file in
$(EXTRA_PARTS
) ..
; do \
2194 if
[ x
"$$file" != x..
]; then \
2195 rm -f
$(libsubdir
)/$$file; \
2196 $(INSTALL_DATA
) $$file $(libsubdir
)/$$file; \
2199 # Don't mess with specs if it doesn't exist yet.
2200 -if
[ -f specs
] ; then \
2201 rm -f
$(libsubdir
)/specs
; \
2202 $(INSTALL_DATA
) specs
$(libsubdir
)/specs
; \
2204 # Install protoize if it was compiled.
2205 -if
[ -f protoize
$(exeext
) ]; \
2207 rm -f
$(bindir)/protoize
$(exeext
); \
2208 $(INSTALL_PROGRAM
) protoize
$(exeext
) $(bindir)/protoize
$(exeext
); \
2209 rm -f
$(bindir)/unprotoize
$(exeext
); \
2210 $(INSTALL_PROGRAM
) unprotoize
$(exeext
) $(bindir)/unprotoize
$(exeext
); \
2211 rm -f
$(libsubdir
)/SYSCALLS.c.X
; \
2212 $(INSTALL_DATA
) SYSCALLS.c.X
$(libsubdir
)/SYSCALLS.c.X
; \
2213 chmod a-x
$(libsubdir
)/SYSCALLS.c.X
; \
2215 -rm -f
$(libsubdir
)/cpp$(exeext
)
2216 $(INSTALL_PROGRAM
) cpp$(exeext
) $(libsubdir
)/cpp$(exeext
)
2217 # Install gcov if it was compiled.
2218 -if
[ -f gcov
$(exeext
) ]; \
2220 rm -f
$(bindir)/gcov
$(exeext
); \
2221 $(INSTALL_PROGRAM
) gcov
$(exeext
) $(bindir)/gcov
$(exeext
); \
2222 chmod a
+x
$(bindir)/gcov
$(exeext
); \
2225 # Install the driver program as $(target_alias)-gcc
2226 # and also as either gcc (if native) or $(tooldir)/bin/gcc.
2227 install-driver
: xgcc
2228 -if
[ -f gcc-cross
$(exeext
) ] ; then \
2229 rm -f
$(bindir)/$(GCC_CROSS_NAME
)$(exeext
); \
2230 $(INSTALL_PROGRAM
) gcc-cross
$(exeext
) $(bindir)/$(GCC_CROSS_NAME
)$(exeext
); \
2231 if
[ -d
$(tooldir
)/bin
/.
] ; then \
2232 rm -f
$(tooldir
)/bin
/gcc
$(exeext
); \
2233 $(INSTALL_PROGRAM
) gcc-cross
$(exeext
) $(tooldir
)/bin
/gcc
$(exeext
); \
2236 rm -f
$(bindir)/$(GCC_INSTALL_NAME
)$(exeext
); \
2237 $(INSTALL_PROGRAM
) xgcc
$(exeext
) $(bindir)/$(GCC_INSTALL_NAME
)$(exeext
); \
2238 rm -f
$(bindir)/$(target_alias
)-gcc-1
$(exeext
); \
2239 ln
$(bindir)/$(GCC_INSTALL_NAME
)$(exeext
) $(bindir)/$(target_alias
)-gcc-1
$(exeext
) \
2241 || cp
$(bindir)/$(GCC_INSTALL_NAME
)$(exeext
) $(bindir)/$(target_alias
)-gcc-1
$(exeext
); \
2242 mv
$(bindir)/$(target_alias
)-gcc-1
$(exeext
) $(bindir)/$(target_alias
)-gcc
$(exeext
); \
2245 # Install the info files.
2246 install-info
: doc
installdirs lang.install-info
2247 -rm -f
$(infodir)/cpp.
info* $(infodir)/gcc.
info*
2248 cd
$(srcdir); for f in
cpp.
info* gcc.
info*; \
2249 do
$(INSTALL_DATA
) $$f $(infodir)/$$f; done
2250 -chmod a-x
$(infodir)/cpp.
info* $(infodir)/gcc.
info*
2252 # Install the man pages.
2253 install-man
: installdirs $(srcdir)/gcc
.1 $(srcdir)/cccp
.1 lang.install-man
2254 -if
[ -f gcc-cross
] ; then \
2255 rm -f
$(mandir)/$(GCC_CROSS_NAME
)$(manext); \
2256 $(INSTALL_DATA
) $(srcdir)/gcc
.1 $(mandir)/$(GCC_CROSS_NAME
)$(manext); \
2257 chmod a-x
$(mandir)/$(GCC_CROSS_NAME
)$(manext); \
2259 rm -f
$(mandir)/$(GCC_INSTALL_NAME
)$(manext); \
2260 $(INSTALL_DATA
) $(srcdir)/gcc
.1 $(mandir)/$(GCC_INSTALL_NAME
)$(manext); \
2261 chmod a-x
$(mandir)/$(GCC_INSTALL_NAME
)$(manext); \
2263 -rm -f
$(mandir)/cccp
$(manext)
2264 -$(INSTALL_DATA
) $(srcdir)/cccp
.1 $(mandir)/cccp
$(manext)
2265 -chmod a-x
$(mandir)/cccp
$(manext)
2267 # Install the library.
2268 install-libgcc
: libgcc.a
installdirs
2269 -if
[ -f libgcc.a
] ; then \
2270 rm -f
$(libsubdir
)/libgcc.a
; \
2271 $(INSTALL_DATA
) libgcc.a
$(libsubdir
)/libgcc.a
; \
2272 if
$(RANLIB_TEST
) ; then \
2273 (cd
$(libsubdir
); $(RANLIB
) libgcc.a
); else true
; fi
; \
2274 chmod a-x
$(libsubdir
)/libgcc.a
; \
2277 # Install multiple versions of libgcc.a.
2278 install-multilib
: stmp-multilib
installdirs
2279 for i in
`$(GCC_FOR_TARGET) --print-multi-lib`; do \
2280 dir=`echo $$i | sed -e 's/;.*$$//'`; \
2281 if
[ -d
$(libsubdir
)/$${dir} ]; then true
; else mkdir
$(libsubdir
)/$${dir}; fi
; \
2282 for f in libgcc.a
$(EXTRA_MULTILIB_PARTS
); do \
2283 rm -f
$(libsubdir
)/$${dir}/$${f}; \
2284 $(INSTALL_DATA
) $${dir}/$${f} $(libsubdir
)/$${dir}/$${f}; \
2286 if
$(RANLIB_TEST
); then \
2287 (cd
$(libsubdir
)/$${dir}; $(RANLIB
) libgcc.a
); else true
; fi
; \
2288 chmod a-x
$(libsubdir
)/$${dir}/libgcc.a
; \
2291 # Install the objc run time library.
2292 install-libobjc
: installdirs
2293 -if
[ -f libobjc.a
] ; then \
2294 rm -f
$(libsubdir
)/libobjc.a
; \
2295 $(INSTALL_DATA
) libobjc.a
$(libsubdir
)/libobjc.a
; \
2296 if
$(RANLIB_TEST
) ; then \
2297 (cd
$(libsubdir
); $(RANLIB
) libobjc.a
); else true
; fi
; \
2298 chmod a-x
$(libsubdir
)/libobjc.a
; \
2301 # Install all the header files built in the include subdirectory.
2302 install-headers
: install-include-dir
$(INSTALL_HEADERS_DIR
) $(INSTALL_ASSERT_H
)
2303 # Fix symlinks to absolute paths in the installed include directory to
2304 # point to the installed directory, not the build directory.
2305 -files
=`cd $(libsubdir)/include; find . -type l -print 2>/dev/null`; \
2306 if
[ $$?
-eq
0 ]; then \
2307 dir=`cd include; pwd`; \
2308 for i in
$$files; do \
2309 dest
=`ls -ld $(libsubdir)/include/$$i | sed -n 's/.*-> //p'`; \
2310 if expr
"$$dest" : "$$dir.*" > /dev
/null
; then \
2311 rm -f
$(libsubdir
)/include/$$i; \
2312 ln
-s
`echo $$i | sed "s|/[^/]*|/..|g" | sed 's|/..$$||'``echo "$$dest" | sed "s|$$dir||"` $(libsubdir
)/include/$$i; \
2317 # Create or recreate the gcc private include file directory.
2318 install-include-dir
: installdirs
2319 -rm -rf
$(libsubdir
)/include
2320 mkdir
$(libsubdir
)/include
2321 -chmod a
+rx
$(libsubdir
)/include
2323 # Install the include directory using tar.
2324 install-headers-tar
: stmp-headers
$(STMP_FIXPROTO
) install-include-dir
2326 tar -cf
- .
; exit
0) |
(cd
$(libsubdir
)/include; tar $(TAROUTOPTS
) - )
2327 # /bin/sh on some systems returns the status of the first tar,
2328 # and that can lose with GNU tar which always writes a full block.
2329 # So use `exit 0' to ignore its exit status.
2331 # Install the include directory using cpio.
2332 install-headers-cpio
: stmp-headers
$(STMP_FIXPROTO
) install-include-dir
2333 (cd
include; find .
-print) |
(cd
include; cpio
-pdum
$(libsubdir
)/include)
2335 # Put assert.h where it won't override GNU libc's assert.h.
2336 # It goes in a dir that is searched after GNU libc's headers;
2337 # thus, the following conditionals are no longer needed.
2338 # But it's not worth deleting them now.
2339 ## Don't replace the assert.h already there if it is not from GCC.
2340 ## This code would be simpler if it tested for -f ... && ! grep ...
2341 ## but supposedly the ! operator is missing in sh on some systems.
2342 install-assert-h
: assert.h
installdirs
2343 if
[ -f
$(assertdir
)/assert.h
]; \
2345 if grep
"__eprintf" $(assertdir
)/assert.h
>/dev
/null
; \
2347 rm -f
$(assertdir
)/assert.h
; \
2348 $(INSTALL_DATA
) $(srcdir)/assert.h
$(assertdir
)/assert.h
; \
2349 chmod a-x
$(assertdir
)/assert.h
; \
2353 rm -f
$(assertdir
)/assert.h
; \
2354 $(INSTALL_DATA
) $(srcdir)/assert.h
$(assertdir
)/assert.h
; \
2355 chmod a-x
$(assertdir
)/assert.h
; \
2358 # Use this target to install the program `collect2' under the name `ld'.
2359 install-collect2
: collect2
installdirs
2360 $(INSTALL_PROGRAM
) collect2
$(exeext
) $(libsubdir
)/ld$(exeext
)
2361 # Install the driver program as $(libsubdir)/gcc for collect2.
2362 $(INSTALL_PROGRAM
) xgcc
$(exeext
) $(libsubdir
)/gcc
$(exeext
)
2364 # Cancel installation by deleting the installed files.
2365 uninstall: lang.
uninstall
2366 -rm -rf
$(libsubdir
)
2367 -rm -rf
$(bindir)/$(GCC_INSTALL_NAME
)$(exeext
)
2368 -rm -rf
$(bindir)/$(GCC_CROSS_NAME
)$(exeext
)
2369 -rm -rf
$(bindir)/protoize
$(exeext
)
2370 -rm -rf
$(bindir)/unprotoize
$(exeext
)
2371 -rm -rf
$(mandir)/$(GCC_INSTALL_NAME
)$(manext)
2372 -rm -rf
$(mandir)/$(GCC_CROSS_NAME
)$(manext)
2373 -rm -rf
$(mandir)/cccp
$(manext)
2374 -rm -rf
$(mandir)/protoize
$(manext)
2375 -rm -rf
$(mandir)/unprotoize
$(manext)
2377 # These exist for maintenance purposes.
2379 # Update the tags table.
2383 mv
-f c-parse.
[ch
] objc-parse.c cexp.c
=*.
[chy
] temp
; \
2384 etags
*.y
*.h
*.c
; \
2388 # Create the distribution tar file.
2389 #dist: gcc-$(version).tar.gz
2392 gcc.xtar.gz
: gcc.xtar
2393 gzip
--best
< gcc.xtar
> tmp-gcc.xtar.gz
2394 mv tmp-gcc.xtar.gz gcc.xtar.gz
2396 #gcc-$(version).tar.gz: gcc-$(version).tar
2397 # gzip < gcc-$(version).tar > gcc-$(version).tar.gz
2399 #gcc-$(version).tar:
2401 # Make the distribution.
2402 tar -chf gcc.xtar gcc-
$(version
)
2404 # This target exists to do the initial work before the language specific
2406 distdir-start
: doc
$(srcdir)/INSTALL
$(srcdir)/c-parse.y
$(srcdir)/c-gperf.h \
2407 $(srcdir)/objc-parse.y
$(srcdir)/c-parse.c
$(srcdir)/objc-parse.c \
2409 @if grep
-s
"for version ${mainversion}" gcc.texi
> /dev
/null
; \
2411 else echo
"You must update the version number in \`gcc.texi'"; sleep
10;\
2413 # Update the version number in README
2414 awk
'$$1 " " $$2 " " $$3 == "This directory contains" \
2415 { $$6 = version; print $$0 } \
2416 $$1 " " $$2 " " $$3 != "This directory contains"' \
2417 version
=$(version
) README
> tmp.README
2418 mv tmp.README README
2419 -rm -rf gcc-
$(version
) tmp
2420 # Put all the files in a temporary subdirectory
2421 # which has the name that we want to have in the tar file.
2426 for file in
*[0-9a-zA-Z
+]; do \
2427 ln
$$file tmp
> /dev
/null
2>&1 || cp
$$file tmp
; \
2430 for file in
*[0-9a-zA-Z
+]; do \
2431 if
test -d
$$file && test "$$file" != RCS
; then \
2432 mkdir ..
/tmp
/config
/$$file; \
2434 for subfile in
*[0-9a-zA-Z
+]; do \
2435 ln
$$subfile ..
/..
/tmp
/config
/$$file >/dev
/null
2>&1 \
2436 || cp
$$subfile ..
/..
/tmp
/config
/$$file; \
2440 ln
$$file ..
/tmp
/config
>/dev
/null
2>&1 \
2441 || cp
$$file ..
/tmp
/config
; \
2445 for file in
*[0-9a-zA-Z
+]; do \
2446 ln
$$file ..
/tmp
/ginclude
>/dev
/null
2>&1 \
2447 || cp
$$file ..
/tmp
/ginclude
; \
2450 for file in
*[0-9a-zA-Z
+]; do \
2451 ln
$$file ..
/tmp
/objc
>/dev
/null
2>&1 || cp
$$file ..
/tmp
/objc
; \
2455 # Finish making `distdir', after the languages have done their thing.
2457 mv tmp gcc-
$(version
)
2458 # Get rid of everything we don't want in the distribution. We'd want
2459 # this to use Makefile.in, but it doesn't have the `lang.foo' targets
2461 cd gcc-
$(version
); make extraclean
2463 distdir
: distdir-start lang.distdir distdir-finish
2465 # make diff oldversion=M.N
2466 # creates a diff file between an older distribution and this one.
2467 # The -P option assumes this is GNU diff.
2469 diff
-rc2P
-x c-parse.y
-x c-parse.c
-x c-parse.h
-x c-gperf.h \
2470 -x cexp.c
-x bi-parser.c
-x objc-parse.y
-x objc-parse.c \
2472 -x
"gcc.??" -x
"gcc.??s" -x gcc.aux
-x
"gcc.info*" \
2473 -x
"cpp.??" -x
"cpp.??s" -x
cpp.aux
-x
"cpp.info*" \
2474 $(LANG_DIFF_EXCLUDES
) \
2475 gcc-
$(oldversion
) gcc-
$(version
) > diffs
2478 # Only build the C compiler for stage1, because that is the only one that
2479 # we can guarantee will build with the native compiler, and also it is the
2480 # only thing useful for building stage2.
2481 $(MAKE
) CC
="$(CC)" libdir=$(libdir) LANGUAGES
="$(BOOT_LANGUAGES)"
2483 # This used to define ALLOCA as empty, but that would lead to bad results
2484 # for a subsequent `make install' since that would not have ALLOCA empty.
2485 # To prevent `make install' from compiling alloca.o and then relinking cc1
2486 # because alloca.o is newer, we permit these recursive makes to compile
2487 # alloca.o. Then cc1 is newer, so it won't have to be relinked.
2488 $(MAKE
) CC
="stage1/xgcc -Bstage1/" CFLAGS
="$(BOOT_CFLAGS)" LDFLAGS
="$(BOOT_LDFLAGS)" libdir=$(libdir) STAGE_PREFIX
=stage1
/ LANGUAGES
="$(LANGUAGES)"
2490 $(MAKE
) CC
="stage2/xgcc -Bstage2/" CFLAGS
="$(BOOT_CFLAGS)" LDFLAGS
="$(BOOT_LDFLAGS)" libdir=$(libdir) STAGE_PREFIX
=stage2
/ LANGUAGES
="$(LANGUAGES)"
2493 $(MAKE
) CC
="stage1/xgcc -Bstage1/" CFLAGS
="$(BOOT_CFLAGS)" LDFLAGS
="$(BOOT_LDFLAGS)" libdir=$(libdir) STAGE_PREFIX
=stage1
/ LANGUAGES
="$(LANGUAGES)"
2495 $(MAKE
) CC
="stage2/xgcc -Bstage2/" CFLAGS
="$(BOOT_CFLAGS)" LDFLAGS
="$(BOOT_LDFLAGS)" libdir=$(libdir) STAGE_PREFIX
=stage2
/ LANGUAGES
="$(LANGUAGES)"
2498 $(MAKE
) CC
="stage2/xgcc -Bstage2/" CFLAGS
="$(BOOT_CFLAGS)" LDFLAGS
="$(BOOT_LDFLAGS)" libdir=$(libdir) STAGE_PREFIX
=stage2
/ LANGUAGES
="$(LANGUAGES)"
2500 # Compare the object files in the current directory with those in the
2503 # ./ avoids bug in some versions of tail.
2505 for file in
*$(objext
); do \
2506 tail
+16c .
/$$file > tmp-foo1
; \
2507 tail
+16c stage2
/$$file > tmp-foo2
2>/dev
/null \
2508 && (cmp tmp-foo1 tmp-foo2 || echo
$$file differs
) || true
; \
2510 for
dir in tmp-foo
$(SUBDIRS
); do \
2511 if
[ "`echo $$dir/*$(objext)`" != "$$dir/*$(objext)" ] ; then \
2512 for file in
$$dir/*$(objext
); do \
2513 tail
+16c .
/$$file > tmp-foo1
; \
2514 tail
+16c stage2
/$$file > tmp-foo2
2>/dev
/null \
2515 && (cmp tmp-foo1 tmp-foo2 || echo
$$file differs
) || true
; \
2521 # Similar, but compare with stage3 directory
2523 for file in
*$(objext
); do \
2524 tail
+16c .
/$$file > tmp-foo1
; \
2525 tail
+16c stage3
/$$file > tmp-foo2
2>/dev
/null \
2526 && (cmp tmp-foo1 tmp-foo2 || echo
$$file differs
) || true
; \
2528 for
dir in tmp-foo
$(SUBDIRS
); do \
2529 if
[ "`echo $$dir/*$(objext)`" != "$$dir/*$(objext)" ] ; then \
2530 for file in
$$dir/*$(objext
); do \
2531 tail
+16c .
/$$file > tmp-foo1
; \
2532 tail
+16c stage3
/$$file > tmp-foo2
2>/dev
/null \
2533 && (cmp tmp-foo1 tmp-foo2 || echo
$$file differs
) || true
; \
2539 # Compare the object files in the current directory with those in the
2540 # stage2 directory. Use gnu cmp (diffutils v2.4 or later) to avoid
2541 # running tail and the overhead of twice copying each object file.
2544 for file in
*$(objext
); do \
2545 cmp
--ignore-initial
=16 $$file stage2
/$$file || true
; \
2547 for
dir in tmp-foo
$(SUBDIRS
); do \
2548 if
[ "`echo $$dir/*$(objext)`" != "$$dir/*$(objext)" ] ; then \
2549 for file in
$$dir/*$(objext
); do \
2550 cmp
--ignore-initial
=16 $$file stage2
/$$file || true
; \
2555 # Similar, but compare with stage3 directory
2557 for file in
*$(objext
); do \
2558 cmp
--ignore-initial
=16 $$file stage3
/$$file || true
; \
2560 for
dir in tmp-foo
$(SUBDIRS
); do \
2561 if
[ "`echo $$dir/*$(objext)`" != "$$dir/*$(objext)" ] ; then \
2562 for file in
$$dir/*$(objext
); do \
2563 cmp
--ignore-initial
=16 $$file stage3
/$$file || true
; \
2568 # Copy the object files from a particular stage into a subdirectory.
2570 -if
[ -d stage1
] ; then true
; else mkdir stage1
; fi
2571 -for
dir in .
$(SUBDIRS
) ; \
2573 if
[ -d stage1
/$$dir ] ; then true
; else mkdir stage1
/$$dir ; fi
; \
2575 -mv
$(STAGESTUFF
) stage1
2576 # Copy as/ld if they exist to stage dir, so that running xgcc from the stage
2577 # dir will work properly.
2578 -if
[ -f
as$(exeext
) ] ; then ln
-s ..
/as$(exeext
) stage1 || cp
as$(exeext
) stage1
; else true
; fi
2579 -if
[ -f
ld$(exeext
) ] ; then ln
-s ..
/ld$(exeext
) stage1 || cp
ld$(exeext
) stage1
; else true
; fi
2580 -if
[ -f collect-ld
$(exeext
) ] ; then ln
-s ..
/collect-ld
$(exeext
) stage1 || cp collect-ld
$(exeext
) stage1
; else true
; fi
2581 -rm -f stage1
/libgcc.a
2583 -if
$(RANLIB_TEST
) ; then
$(RANLIB
) stage1
/libgcc.a
; else true
; fi
2584 -for f in ..
$(EXTRA_MULTILIB_PARTS
); do if
[ x
$${f} != x..
]; then \
2585 cp stage1
/$${f} .
; \
2587 stage1
: force stage1-start lang.stage1
2590 -if
[ -d stage2
] ; then true
; else mkdir stage2
; fi
2591 -for
dir in .
$(SUBDIRS
) ; \
2593 if
[ -d stage2
/$$dir ] ; then true
; else mkdir stage2
/$$dir ; fi
; \
2595 -mv
$(STAGESTUFF
) stage2
2596 # Copy as/ld if they exist to stage dir, so that running xgcc from the stage
2597 # dir will work properly.
2598 -if
[ -f
as$(exeext
) ] ; then ln
-s ..
/as$(exeext
) stage2 || cp
as$(exeext
) stage2
; else true
; fi
2599 -if
[ -f
ld$(exeext
) ] ; then ln
-s ..
/ld$(exeext
) stage2 || cp
ld$(exeext
) stage2
; else true
; fi
2600 -if
[ -f collect-ld
] ; then ln
-s ..
/collect-ld
$(exeext
) stage2 || cp collect-ld
$(exeext
) stage2
; else true
; fi
2601 -rm -f stage2
/libgcc.a
2603 -if
$(RANLIB_TEST
) ; then
$(RANLIB
) stage2
/libgcc.a
; else true
; fi
2604 -for f in ..
$(EXTRA_MULTILIB_PARTS
); do if
[ x
$${f} != x..
]; then \
2605 cp stage2
/$${f} .
; \
2607 stage2
: force stage2-start lang.stage2
2610 -if
[ -d stage3
] ; then true
; else mkdir stage3
; fi
2611 -for
dir in .
$(SUBDIRS
) ; \
2613 if
[ -d stage3
/$$dir ] ; then true
; else mkdir stage3
/$$dir ; fi
; \
2615 -mv
$(STAGESTUFF
) stage3
2616 # Copy as/ld if they exist to stage dir, so that running xgcc from the stage
2617 # dir will work properly.
2618 -if
[ -f
as$(exeext
) ] ; then ln
-s ..
/as$(exeext
) stage3 || cp
as$(exeext
) stage3
; else true
; fi
2619 -if
[ -f
ld$(exeext
) ] ; then ln
-s ..
/ld$(exeext
) stage3 || cp
ld$(exeext
) stage3
; else true
; fi
2620 -if
[ -f collect-ld
$(exeext
) ] ; then ln
-s ..
/collect-ld
$(exeext
) stage3 || cp collect-ld
$(exeext
) stage3
; else true
; fi
2621 -rm -f stage3
/libgcc.a
2623 -if
$(RANLIB_TEST
) ; then
$(RANLIB
) stage3
/libgcc.a
; else true
; fi
2624 -for f in ..
$(EXTRA_MULTILIB_PARTS
); do if
[ x
$${f} != x..
]; then \
2625 cp stage3
/$${f} .
; \
2627 stage3
: force stage3-start lang.stage3
2630 -if
[ -d stage4
] ; then true
; else mkdir stage4
; fi
2631 -for
dir in .
$(SUBDIRS
) ; \
2633 if
[ -d stage4
/$$dir ] ; then true
; else mkdir stage4
/$$dir ; fi
; \
2635 -mv
$(STAGESTUFF
) stage4
2636 # Copy as/ld if they exist to stage dir, so that running xgcc from the stage
2637 # dir will work properly.
2638 -if
[ -f
as$(exeext
) ] ; then ln
-s ..
/as$(exeext
) stage4 || cp
as$(exeext
) stage4
; else true
; fi
2639 -if
[ -f
ld$(exeext
) ] ; then ln
-s ..
/ld$(exeext
) stage4 || cp
ld$(exeext
) stage4
; else true
; fi
2640 -if
[ -f collect-ld
$(exeext
) ] ; then ln
-s ..
/collect-ld
$(exeext
) stage4 || cp collect-ld
$(exeext
) stage4
; else true
; fi
2641 -rm -f stage4
/libgcc.a
2643 -if
$(RANLIB_TEST
) ; then
$(RANLIB
) stage4
/libgcc.a
; else true
; fi
2644 -for f in ..
$(EXTRA_MULTILIB_PARTS
); do if
[ x
$${f} != x..
]; then \
2645 cp stage4
/$${f} .
; \
2647 stage4
: force stage4-start lang.stage4
2649 # Copy just the executable files from a particular stage into a subdirectory,
2650 # and delete the object files. Use this if you're just verifying a version
2651 # that is pretty sure to work, and you are short of disk space.
2652 risky-stage1
: stage1
2655 risky-stage2
: stage2
2658 risky-stage3
: stage3
2661 risky-stage4
: stage4
2664 #In GNU Make, ignore whether `stage*' exists.
2665 .PHONY
: stage1 stage2 stage3 stage4
clean maintainer-clean TAGS bootstrap
2666 .PHONY
: risky-stage1 risky-stage2 risky-stage3 risky-stage4