1c87b03e5Sespie# Makefile for GNU C compiler. 2c87b03e5Sespie# Copyright (C) 1987, 1988, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997 3c87b03e5Sespie# 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. 4c87b03e5Sespie 5c87b03e5Sespie#This file is part of GCC. 6c87b03e5Sespie 7c87b03e5Sespie#GCC is free software; you can redistribute it and/or modify 8c87b03e5Sespie#it under the terms of the GNU General Public License as published by 9c87b03e5Sespie#the Free Software Foundation; either version 2, or (at your option) 10c87b03e5Sespie#any later version. 11c87b03e5Sespie 12c87b03e5Sespie#GCC is distributed in the hope that it will be useful, 13c87b03e5Sespie#but WITHOUT ANY WARRANTY; without even the implied warranty of 14c87b03e5Sespie#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15c87b03e5Sespie#GNU General Public License for more details. 16c87b03e5Sespie 17c87b03e5Sespie#You should have received a copy of the GNU General Public License 18c87b03e5Sespie#along with GCC; see the file COPYING. If not, write to 19c87b03e5Sespie#the Free Software Foundation, 59 Temple Place - Suite 330, 20c87b03e5Sespie#Boston MA 02111-1307, USA. 21c87b03e5Sespie 22c87b03e5Sespie# The targets for external use include: 23c87b03e5Sespie# all, doc, proto, install, install-cross, install-cross-rest, 24c87b03e5Sespie# uninstall, TAGS, mostlyclean, clean, distclean, maintainer-clean, 25c87b03e5Sespie# stage1, stage2, stage3, stage4. 26c87b03e5Sespie 27c87b03e5Sespie# This is the default target. 28c87b03e5Sespieall: 29c87b03e5Sespie 30c87b03e5Sespie# Suppress smart makes who think they know how to automake Yacc files 31c87b03e5Sespie.y.c: 32c87b03e5Sespie 33c87b03e5Sespie# Directory where sources are, from where we are. 34c87b03e5Sespiesrcdir = @srcdir@ 35c87b03e5SespieVPATH = @srcdir@ 36f092f567SespieLIBIBERTY_INCLUDES=$(srcdir)/../include/ 37c87b03e5Sespie 38c87b03e5Sespie# Pointer to the GCC Project website 39c87b03e5Sespiewebsite=http://gcc.gnu.org 40c87b03e5Sespie 41c87b03e5Sespie# Variables that exist for you to override. 42c87b03e5Sespie# See below for how to change them for certain systems. 43c87b03e5Sespie 44c87b03e5Sespie# List of language subdirectories. 45c87b03e5Sespie# This is overridden by configure. 46c87b03e5SespieSUBDIRS =@subdirs@ 47c87b03e5Sespie 48c87b03e5Sespie# Selection of languages to be made. 49c87b03e5Sespie# This is overridden by configure. 50c87b03e5SespieCONFIG_LANGUAGES = @all_languages@ 51c87b03e5SespieLANGUAGES = c gcov$(exeext) $(CONFIG_LANGUAGES) 52c87b03e5Sespie 53c87b03e5Sespie# Selection of languages to be made during stage1 build. 54c87b03e5Sespie# This is overridden by configure. 55c87b03e5SespieBOOT_LANGUAGES = c @all_boot_languages@ 56c87b03e5Sespie 57c87b03e5Sespie# Various ways of specifying flags for compilations: 58c87b03e5Sespie# CFLAGS is for the user to override to, e.g., do a cross build with -O2. 59c87b03e5Sespie# For recursive bootstrap builds CFLAGS is used to pass in STAGE1_CFLAGS 60c87b03e5Sespie# or BOOT_CFLAGS 61c87b03e5Sespie# STAGE1_CFLAGS is set by configure on some targets or passed from toplevel 62c87b03e5Sespie# and sets the CFLAGS passed to stage1 of a bootstrap compilation. 63c87b03e5Sespie# BOOT_CFLAGS is the value of CFLAGS to pass to the stage2, stage3 and stage4 64c87b03e5Sespie# bootstrap compilations. 65c87b03e5Sespie# XCFLAGS is used for most compilations but not when using the GCC just built. 66c87b03e5Sespie# TCFLAGS is used for compilations with the GCC just built. 67c87b03e5SespieXCFLAGS = 68c87b03e5SespieTCFLAGS = 69c87b03e5SespieCFLAGS = -g 70c87b03e5SespieSTAGE1_CFLAGS = -g @stage1_cflags@ 71c87b03e5SespieBOOT_CFLAGS = -g -O2 72c87b03e5Sespie 73c87b03e5Sespie# Flags to determine code coverage. When coverage is disabled, this will 74c87b03e5Sespie# contain the optimization flags, as you normally want code coverage 75c87b03e5Sespie# without optimization. The -dumpbase $@ makes sure that the auxilary 76c87b03e5Sespie# files end up near the object files. 77c87b03e5SespieCOVERAGE_FLAGS = @coverage_flags@ 78c87b03e5Sespiecoverageexts = .{da,bb,bbg} 79c87b03e5Sespie 80c87b03e5Sespie# The warning flags are separate from BOOT_CFLAGS because people tend to 81c87b03e5Sespie# override optimization flags and we'd like them to still have warnings 82c87b03e5Sespie# turned on. These flags are also used to pass other stage dependent 83c87b03e5Sespie# flags from configure. The user is free to explicitly turn these flags 84c87b03e5Sespie# off if they wish. 85c87b03e5Sespie# LOOSE_WARN are the warning flags to use when compiling something 86c87b03e5Sespie# which is only compiled with gcc, such as libgcc and the frontends 87c87b03e5Sespie# other than C. 88c87b03e5Sespie# STRICT_WARN and STRICT2_WARN are the additional warning flags to 89c87b03e5Sespie# apply to the back end and the C front end, which may be compiled 90c87b03e5Sespie# with other compilers. This is partially controlled by configure in 91c87b03e5Sespie# stage1, as not all versions of gcc understand -Wno-long-long. 92c87b03e5SespieLOOSE_WARN = -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes 93c87b03e5SespieSTRICT_WARN = -Wtraditional @strict1_warn@ 94c87b03e5SespieSTRICT2_WARN = -Wtraditional -pedantic -Wno-long-long 95c87b03e5Sespie 96c87b03e5Sespie# This is set by --enable-checking. The idea is to catch forgotten 97c87b03e5Sespie# "extern" tags in header files. 98c87b03e5SespieNOCOMMON_FLAG = @nocommon_flag@ 99c87b03e5Sespie 100c87b03e5Sespie# These are set by --enable-checking=valgrind. 101c87b03e5SespieRUN_GEN = @valgrind_command@ 102c87b03e5SespieVALGRIND_DRIVER_DEFINES = @valgrind_path_defines@ 103c87b03e5Sespie 104c87b03e5Sespie# This is how we control whether or not the additional warnings are applied. 105c87b03e5Sespie.-warn = $(STRICT_WARN) 106c87b03e5SespieGCC_WARN_CFLAGS = $(LOOSE_WARN) $($(@D)-warn) $(NOCOMMON_FLAG) 107c87b03e5Sespie 108c87b03e5Sespie# All warnings have to be shut off in stage1 if the compiler used then 109c87b03e5Sespie# isn't gcc; configure determines that. WARN_CFLAGS will be either 110c87b03e5Sespie# $(GCC_WARN_CFLAGS), or nothing. 111c87b03e5SespieWARN_CFLAGS = @warn_cflags@ 112c87b03e5Sespie 113c87b03e5Sespie# These exists to be overridden by the x-* and t-* files, respectively. 114c87b03e5SespieX_CFLAGS = 115c87b03e5SespieT_CFLAGS = 116c87b03e5Sespie 117c87b03e5SespieX_CPPFLAGS = 118c87b03e5SespieT_CPPFLAGS = 119c87b03e5Sespie 120c87b03e5SespieADAC = @ADAC@ 121c87b03e5SespieAWK = @AWK@ 122c87b03e5SespieCC = @CC@ 123c87b03e5SespieBISON = @BISON@ 124c87b03e5SespieBISONFLAGS = 125c87b03e5SespieFLEX = @FLEX@ 126c87b03e5SespieFLEXFLAGS = 127c87b03e5SespieAR = ar 128c87b03e5SespieAR_FLAGS = rc 129c87b03e5SespieDLLTOOL = dlltool 130c87b03e5SespieRANLIB = @RANLIB@ 131c87b03e5SespieSHELL = @SHELL@ 132c87b03e5Sespie# pwd command to use. Allow user to override default by setting PWDCMD in 133c87b03e5Sespie# the environment to account for automounters. The make variable must not 134c87b03e5Sespie# be called PWDCMD, otherwise the value set here is passed to make 135c87b03e5Sespie# subprocesses and overrides the setting from the user's environment. 136c87b03e5Sespie# Don't use PWD since it is a common shell environment variable and we 137c87b03e5Sespie# don't want to corrupt it. 138c87b03e5SespiePWD_COMMAND = $${PWDCMD-pwd} 139c87b03e5Sespie# on sysV, define this as cp. 140c87b03e5SespieINSTALL = @INSTALL@ 141c87b03e5Sespie# Some systems may be missing symbolic links, regular links, or both. 142c87b03e5Sespie# Allow configure to check this and use "ln -s", "ln", or "cp" as appropriate. 143c87b03e5SespieLN=@LN@ 144c87b03e5SespieLN_S=@LN_S@ 145c87b03e5Sespie# These permit overriding just for certain files. 146c87b03e5SespieINSTALL_PROGRAM = @INSTALL_PROGRAM@ 147c87b03e5SespieINSTALL_DATA = @INSTALL_DATA@ 148c87b03e5SespieINSTALL_SCRIPT = @INSTALL@ 149c87b03e5SespieMAKEINFO = @MAKEINFO@ 150c87b03e5SespieMAKEINFOFLAGS = 151c87b03e5SespieTEXI2DVI = texi2dvi 152c87b03e5SespieTEXI2POD = perl $(srcdir)/../contrib/texi2pod.pl 153c87b03e5SespiePOD2MAN = pod2man --center="GNU" --release="gcc-$(version)" 154c87b03e5Sespie# For GNUmake: let us decide what gets passed to recursive makes. 155c87b03e5SespieMAKEOVERRIDES = 156c87b03e5Sespie@SET_MAKE@ 157c87b03e5Sespie# Some compilers can't handle cc -c blah.c -o foo/blah.o. 158c87b03e5Sespie# In stage2 and beyond, we force this to "-o $@" since we know we're using gcc. 159c87b03e5SespieOUTPUT_OPTION = @OUTPUT_OPTION@ 160c87b03e5Sespie 161c87b03e5Sespie# Some versions of `touch' (such as the version on Solaris 2.8) 162c87b03e5Sespie# do not correctly set the timestamp due to buggy versions of `utime' 163c87b03e5Sespie# in the kernel. So, we use `echo' instead. 164c87b03e5SespieSTAMP = echo timestamp > 165c87b03e5Sespie 166c87b03e5Sespie# This is where we get zlib from. zlibdir is -L../zlib and zlibinc is 167c87b03e5Sespie# -I../zlib, unless we were configured with --with-system-zlib, in which 168c87b03e5Sespie# case both are empty. 169c87b03e5SespieZLIB = @zlibdir@ -lz 170c87b03e5SespieZLIBINC = @zlibinc@ 171c87b03e5Sespie 172c87b03e5Sespie# Substitution type for target's getgroups 2nd arg. 173c87b03e5SespieTARGET_GETGROUPS_T = @TARGET_GETGROUPS_T@ 174c87b03e5Sespie 175c87b03e5Sespie# Target to use when installing include directory. Either 176c87b03e5Sespie# install-headers-tar, install-headers-cpio or install-headers-cp. 177c87b03e5SespieINSTALL_HEADERS_DIR = @build_install_headers_dir@ 178c87b03e5Sespie 179c87b03e5Sespie# Header files that are made available under the same name 180c87b03e5Sespie# to programs compiled with GCC. 181c87b03e5SespieUSER_H = $(srcdir)/ginclude/float.h \ 182c87b03e5Sespie $(srcdir)/ginclude/iso646.h \ 183c87b03e5Sespie $(srcdir)/ginclude/stdarg.h \ 184c87b03e5Sespie $(srcdir)/ginclude/stdbool.h \ 185c87b03e5Sespie $(srcdir)/ginclude/stddef.h \ 186c87b03e5Sespie $(srcdir)/ginclude/varargs.h \ 187c87b03e5Sespie $(srcdir)/unwind.h \ 188c87b03e5Sespie $(EXTRA_HEADERS) 189c87b03e5Sespie 190c87b03e5Sespie# The GCC to use for compiling libgcc.a and crt*.o. 191c87b03e5Sespie# Usually the one we just built. 192c87b03e5Sespie# Don't use this as a dependency--use $(GCC_PASSES) or $(GCC_PARTS). 193c87b03e5SespieGCC_FOR_TARGET = $(STAGE_CC_WRAPPER) ./xgcc -B./ -B$(build_tooldir)/bin/ -isystem $(build_tooldir)/include -isystem $(build_tooldir)/sys-include 194c87b03e5Sespie 195c87b03e5Sespie# This is used instead of ALL_CFLAGS when compiling with GCC_FOR_TARGET. 196c87b03e5Sespie# It omits XCFLAGS, and specifies -B./. 197c87b03e5Sespie# It also specifies -isystem ./include to find, e.g., stddef.h. 198c87b03e5SespieGCC_CFLAGS=$(INTERNAL_CFLAGS) $(X_CFLAGS) $(T_CFLAGS) $(LOOSE_WARN) -isystem ./include $(TCFLAGS) 199c87b03e5Sespie 200c87b03e5Sespie# Sed command to transform gcc to installed name. Overwritten by configure. 201c87b03e5Sespieprogram_transform_name = @program_transform_name@ 202c87b03e5Sespieprogram_transform_cross_name = s,^,$(target_alias)-, 203c87b03e5Sespie 204c87b03e5Sespiebuild_canonical = @build_canonical@ 205c87b03e5Sespiehost_canonical = @host_canonical@ 206c87b03e5Sespie 207c87b03e5Sespie# Tools to use when building a cross-compiler. 208c87b03e5Sespie# These are used because `configure' appends `cross-make' 209c87b03e5Sespie# to the makefile when making a cross-compiler. 210c87b03e5Sespie 211c87b03e5Sespie# Use the tools from the build tree, if they are available. 212c87b03e5Sespie 213c87b03e5Sespie# objdir is set by configure. 214c87b03e5Sespieobjdir = @objdir@ 215c87b03e5Sespie 216c87b03e5SespieAR_FOR_TARGET = ` \ 217c87b03e5Sespie if [ -f $(objdir)/../binutils/ar ] ; then \ 218c87b03e5Sespie echo $(objdir)/../binutils/ar ; \ 219c87b03e5Sespie else \ 220c87b03e5Sespie if [ "$(host_canonical)" = "$(target)" ] ; then \ 221c87b03e5Sespie echo ar; \ 222c87b03e5Sespie else \ 223c87b03e5Sespie t='$(program_transform_cross_name)'; echo ar | sed -e $$t ; \ 224c87b03e5Sespie fi; \ 225c87b03e5Sespie fi` 226c87b03e5SespieAR_FLAGS_FOR_TARGET = 227c87b03e5SespieAR_CREATE_FOR_TARGET = $(AR_FOR_TARGET) $(AR_FLAGS_FOR_TARGET) rc 228c87b03e5SespieAR_EXTRACT_FOR_TARGET = $(AR_FOR_TARGET) $(AR_FLAGS_FOR_TARGET) x 229c87b03e5SespieRANLIB_FOR_TARGET = ` \ 230c87b03e5Sespie if [ -f $(objdir)/../binutils/ranlib ] ; then \ 231c87b03e5Sespie echo $(objdir)/../binutils/ranlib ; \ 232c87b03e5Sespie else \ 233c87b03e5Sespie if [ "$(host_canonical)" = "$(target)" ] ; then \ 234c87b03e5Sespie echo ranlib; \ 235c87b03e5Sespie else \ 236c87b03e5Sespie t='$(program_transform_cross_name)'; echo ranlib | sed -e $$t ; \ 237c87b03e5Sespie fi; \ 238c87b03e5Sespie fi` 239c87b03e5SespieRANLIB_TEST_FOR_TARGET = \ 240c87b03e5Sespie [ -f $(RANLIB_FOR_TARGET) ] \ 241c87b03e5Sespie || ( [ "$(host_canonical)" = "$(target)" ] \ 242c87b03e5Sespie && [ -f /usr/bin/ranlib -o -f /bin/ranlib ] ) 243c87b03e5SespieNM_FOR_TARGET = ` \ 244c87b03e5Sespie if [ -f ./nm ] ; then \ 245c87b03e5Sespie echo ./nm ; \ 246c87b03e5Sespie elif [ -f $(objdir)/../binutils/nm-new ] ; then \ 247c87b03e5Sespie echo $(objdir)/../binutils/nm-new ; \ 248c87b03e5Sespie else \ 249c87b03e5Sespie if [ "$(host_canonical)" = "$(target)" ] ; then \ 250c87b03e5Sespie echo nm; \ 251c87b03e5Sespie else \ 252c87b03e5Sespie t='$(program_transform_cross_name)'; echo nm | sed -e $$t ; \ 253c87b03e5Sespie fi; \ 254c87b03e5Sespie fi` 255c87b03e5Sespie 256c87b03e5Sespie# Where to find some libiberty headers. 257f092f567SespieHASHTAB_H = $(LIBIBERTY_INCLUDES)/hashtab.h 258f092f567SespieOBSTACK_H = $(LIBIBERTY_INCLUDES)/obstack.h 259f092f567SespieSPLAY_TREE_H= $(LIBIBERTY_INCLUDES)/splay-tree.h 260f092f567SespieFIBHEAP_H = $(LIBIBERTY_INCLUDES)/fibheap.h 261f092f567SespiePARTITION_H = $(LIBIBERTY_INCLUDES)/partition.h 262c87b03e5Sespie 263c87b03e5Sespie# Default native SYSTEM_HEADER_DIR, to be overridden by targets. 264c87b03e5SespieNATIVE_SYSTEM_HEADER_DIR = /usr/include 265c87b03e5Sespie# Default cross SYSTEM_HEADER_DIR, to be overridden by targets. 26606dc6460SespieCROSS_SYSTEM_HEADER_DIR = @CROSS_SYSTEM_HEADER_DIR@ 267c87b03e5Sespie 268c87b03e5Sespie# autoconf sets SYSTEM_HEADER_DIR to one of the above. 269c87b03e5SespieSYSTEM_HEADER_DIR = @SYSTEM_HEADER_DIR@ 270c87b03e5Sespie 271c87b03e5Sespie# Control whether to run fixproto and fixincludes. 272c87b03e5SespieSTMP_FIXPROTO = @STMP_FIXPROTO@ 273c87b03e5SespieSTMP_FIXINC = @STMP_FIXINC@ 274c87b03e5Sespie 275c87b03e5Sespie# Test to see whether <limits.h> exists in the system header files. 276c87b03e5SespieLIMITS_H_TEST = [ -f $(SYSTEM_HEADER_DIR)/limits.h ] 277c87b03e5Sespie 27806dc6460Sespie# Directory for prefix to system directories, for 27906dc6460Sespie# each of $(system_prefix)/usr/include, $(system_prefix)/usr/lib, etc. 28006dc6460SespieTARGET_SYSTEM_ROOT = @TARGET_SYSTEM_ROOT@ 28106dc6460Sespie 282c87b03e5Sespietarget=@target@ 283c87b03e5Sespietarget_alias=@target_alias@ 284c87b03e5Sespiexmake_file=@dep_host_xmake_file@ 285c87b03e5Sespietmake_file=@dep_tmake_file@ 286c87b03e5Sespieout_file=$(srcdir)/config/@out_file@ 287c87b03e5Sespieout_object_file=@out_object_file@ 288c87b03e5Sespiemd_file=$(srcdir)/config/@md_file@ 289c87b03e5Sespietm_defines=@tm_defines@ 290c87b03e5Sespietm_p_file_list=@tm_p_file_list@ 291c87b03e5Sespietm_p_file=@tm_p_file@ 292c87b03e5Sespiebuild_xm_file_list=@build_xm_file_list@ 293c87b03e5Sespiebuild_xm_file=@build_xm_file@ 294c87b03e5Sespiebuild_xm_defines=@build_xm_defines@ 295c87b03e5Sespiehost_xm_file_list=@host_xm_file_list@ 296c87b03e5Sespiehost_xm_file=@host_xm_file@ 297c87b03e5Sespiehost_xm_defines=@host_xm_defines@ 298c87b03e5Sespiexm_file=@xm_file@ 299c87b03e5Sespiexm_defines=@xm_defines@ 300c87b03e5Sespielang_specs_files=@lang_specs_files@ 301c87b03e5Sespielang_options_files=@lang_options_files@ 302c87b03e5Sespielang_tree_files=@lang_tree_files@ 303c87b03e5Sespietarget_cpu_default=@target_cpu_default@ 304c87b03e5SespieGCC_THREAD_FILE=@thread_file@ 305c87b03e5SespieOBJC_BOEHM_GC=@objc_boehm_gc@ 306c87b03e5SespieGTHREAD_FLAGS=@gthread_flags@ 307c87b03e5Sespie# Be prepared for gcc2 merges. 308c87b03e5Sespiegcc_version=@gcc_version@ 309c87b03e5Sespiegcc_version_trigger=@gcc_version_trigger@ 310c87b03e5Sespieversion=$(gcc_version) 311c87b03e5Sespiemainversion=`grep version_string $(srcdir)/version.c | sed -e 's/.*\"\([0-9]*\.[0-9]*\).*/\1/'` 312c87b03e5Sespie 313c87b03e5Sespie# Common prefix for installation directories. 314c87b03e5Sespie# NOTE: This directory must exist when you start installation. 315c87b03e5Sespieprefix = @prefix@ 316c87b03e5Sespie# Directory in which to put localized header files. On the systems with 317c87b03e5Sespie# gcc as the native cc, `local_prefix' may not be `prefix' which is 318c87b03e5Sespie# `/usr'. 319c87b03e5Sespie# NOTE: local_prefix *should not* default from prefix. 320c87b03e5Sespielocal_prefix = @local_prefix@ 321c87b03e5Sespie# Directory in which to put host dependent programs and libraries 322c87b03e5Sespieexec_prefix = @exec_prefix@ 323c87b03e5Sespie# Directory in which to put the executable for the command `gcc' 324c87b03e5Sespiebindir = @bindir@ 325c87b03e5Sespie# Directory in which to put the directories used by the compiler. 326c87b03e5Sespielibdir = @libdir@ 327c87b03e5Sespie# Directory in which the compiler finds executables, libraries, etc. 328c87b03e5Sespielibsubdir = $(libdir)/gcc-lib/$(target_alias)/$(version) 329c87b03e5Sespie# Used to produce a relative $(gcc_tooldir) in gcc.o 330c87b03e5Sespieunlibsubdir = ../../.. 331c87b03e5Sespie# Directory in which to find other cross-compilation tools and headers. 332c87b03e5Sespiedollar = @dollar@ 333c87b03e5Sespie# Used in install-cross. 334c87b03e5Sespiegcc_tooldir = @gcc_tooldir@ 335c87b03e5Sespie# Used to install the shared libgcc. 336c87b03e5Sespieslibdir = @slibdir@ 337c87b03e5Sespie# Since gcc_tooldir does not exist at build-time, use -B$(build_tooldir)/bin/ 338c87b03e5Sespiebuild_tooldir = $(exec_prefix)/$(target_alias) 339c87b03e5Sespie# Directory in which the compiler finds target-independent g++ includes. 340c87b03e5Sespiegcc_gxx_include_dir = @gcc_gxx_include_dir@ 341c87b03e5Sespie# Directory to search for site-specific includes. 342c87b03e5Sespielocal_includedir = $(local_prefix)/include 343c87b03e5Sespieincludedir = $(prefix)/include 344c87b03e5Sespie# where the info files go 345c87b03e5Sespieinfodir = @infodir@ 346c87b03e5Sespie# Where cpp should go besides $prefix/bin if necessary 347c87b03e5Sespiecpp_install_dir = @cpp_install_dir@ 348c87b03e5Sespie# where the locale files go 349c87b03e5Sespiedatadir = @datadir@ 350c87b03e5Sespielocaledir = $(datadir)/locale 351c87b03e5Sespie# Extension (if any) to put in installed man-page filename. 352c87b03e5Sespieman1ext = .1 353c87b03e5Sespieman7ext = .7 354c87b03e5Sespieobjext = .o 355c87b03e5Sespieexeext = @host_exeext@ 356c87b03e5Sespiebuild_exeext = @build_exeext@ 357c87b03e5Sespie 358c87b03e5Sespie# Directory in which to put man pages. 359c87b03e5Sespiemandir = @mandir@ 360c87b03e5Sespieman1dir = $(mandir)/man1 361c87b03e5Sespieman7dir = $(mandir)/man7 362c87b03e5Sespie# Dir for temp files. 363c87b03e5Sespietmpdir = /tmp 364c87b03e5Sespie 365c87b03e5Sespie# Top build directory, relative to here. 366c87b03e5Sespietop_builddir = . 367c87b03e5Sespie 368c87b03e5Sespie# Whether we were configured with NLS. 369c87b03e5SespieUSE_NLS = @USE_NLS@ 370c87b03e5Sespie 371c87b03e5Sespie# Internationalization library. 372c87b03e5SespieINTLLIBS = @INTLLIBS@ 373c87b03e5SespieINTLDEPS = @INTLDEPS@ 374c87b03e5Sespie 375c87b03e5Sespie# Character encoding conversion library. 376c87b03e5SespieLIBICONV = @LIBICONV@ 377c87b03e5Sespie 378c87b03e5Sespie# List of internationalization subdirectories. 379c87b03e5SespieINTL_SUBDIRS = intl 380c87b03e5Sespie 381c87b03e5Sespie# The GC method to be used on this system. 382c87b03e5SespieGGC=@GGC@.o 383c87b03e5Sespie 384c87b03e5Sespie# If a supplementary library is being used for the GC. 385c87b03e5SespieGGC_LIB= 386c87b03e5Sespie 387c87b03e5Sespie# libgcc.a may be built directly or via stmp-multilib, 388c87b03e5Sespie# and installed likewise. Overridden by t-fragment. 389c87b03e5SespieLIBGCC = libgcc.a 390c87b03e5SespieINSTALL_LIBGCC = install-libgcc 391c87b03e5Sespie 392c87b03e5Sespie# Options to use when compiling libgcc2.a. 393c87b03e5Sespie# 394c87b03e5SespieLIBGCC2_DEBUG_CFLAGS = -g 3955982dd4aSetohLIBGCC2_CFLAGS = -O2 $(LIBGCC2_INCLUDES) $(GCC_CFLAGS) $(TARGET_LIBGCC2_CFLAGS) $(LIBGCC2_DEBUG_CFLAGS) $(GTHREAD_FLAGS) -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED @inhibit_libc@ -fno-stack-protector 396c87b03e5Sespie 397c87b03e5Sespie# Additional options to use when compiling libgcc2.a. 398c87b03e5Sespie# Some targets override this to -isystem include 399c87b03e5SespieLIBGCC2_INCLUDES = 400c87b03e5Sespie 401c87b03e5Sespie# Additional target-dependent options for compiling libgcc2.a. 402c87b03e5SespieTARGET_LIBGCC2_CFLAGS = 403c87b03e5Sespie 404c87b03e5Sespie# Options to use when compiling crtbegin/end. 405c87b03e5SespieCRTSTUFF_CFLAGS = -O2 $(GCC_CFLAGS) $(INCLUDES) $(MULTILIB_CFLAGS) -g0 \ 406c87b03e5Sespie -finhibit-size-directive -fno-inline-functions -fno-exceptions \ 407c87b03e5Sespie -fno-zero-initialized-in-bss 408c87b03e5Sespie 409c87b03e5Sespie# Additional sources to handle exceptions; overridden by targets as needed. 410c87b03e5SespieLIB2ADDEH = $(srcdir)/unwind-dw2.c $(srcdir)/unwind-dw2-fde.c \ 411c87b03e5Sespie $(srcdir)/unwind-sjlj.c $(srcdir)/unwind-c.c 412c87b03e5SespieLIB2ADDEHDEP = unwind.inc unwind-dw2-fde.h 413c87b03e5Sespie 414c87b03e5Sespie# nm flags to list global symbols in libgcc object files. 415c87b03e5SespieSHLIB_NM_FLAGS = -pg 416c87b03e5Sespie 417c87b03e5Sespie# List of extra executables that should be compiled for this target machine 418c87b03e5Sespie# that are used for compiling from source code to object code. 419c87b03e5Sespie# The rules for compiling them should be in the t-* file for the machine. 420c87b03e5SespieEXTRA_PASSES =@extra_passes@ 421c87b03e5Sespie 422c87b03e5Sespie# Like EXTRA_PASSES, but these are used when linking. 423c87b03e5SespieEXTRA_PROGRAMS = @extra_programs@ 424c87b03e5Sespie 425c87b03e5Sespie# List of extra object files that should be compiled for this target machine. 426c87b03e5Sespie# The rules for compiling them should be in the t-* file for the machine. 427c87b03e5SespieEXTRA_PARTS = @extra_parts@ 428c87b03e5Sespie 429c87b03e5Sespie# List of extra object files that should be compiled and linked with 430c87b03e5Sespie# compiler proper (cc1, cc1obj, cc1plus). 431c87b03e5SespieEXTRA_OBJS = @extra_objs@ 432c87b03e5Sespie 433c87b03e5Sespie# List of extra object files that should be compiled and linked with 434c87b03e5Sespie# the gcc driver. 435c87b03e5SespieEXTRA_GCC_OBJS =@host_extra_gcc_objs@ 436c87b03e5Sespie 437c87b03e5Sespie# List of additional header files to install. 438c87b03e5Sespie# Often this is edited directly by `configure'. 439c87b03e5SespieEXTRA_HEADERS =@extra_headers_list@ 440c87b03e5Sespie 441c87b03e5Sespie# It is convenient for configure to add the assignment at the beginning, 442c87b03e5Sespie# so don't override it here. 443c87b03e5SespieUSE_COLLECT2 = collect2$(exeext) 444c87b03e5Sespie 445c87b03e5Sespie# List of extra C and assembler files to add to static and shared libgcc2. 446c87b03e5Sespie# Assembler files should have names ending in `.asm'. 447c87b03e5SespieLIB2FUNCS_EXTRA = 448c87b03e5Sespie 449c87b03e5Sespie# List of extra C and assembler files to add to static libgcc2. 450c87b03e5Sespie# Assembler files should have names ending in `.asm'. 451c87b03e5SespieLIB2FUNCS_STATIC_EXTRA = 452c87b03e5Sespie 453c87b03e5Sespie# Program to convert libraries. 454c87b03e5SespieLIBCONVERT = 455c87b03e5Sespie 456c87b03e5Sespie# Control whether header files are installed. 457c87b03e5SespieINSTALL_HEADERS=install-headers install-mkheaders 458c87b03e5Sespie 459c87b03e5Sespie# Control whether Info documentation is built and installed. 460c87b03e5SespieBUILD_INFO = @BUILD_INFO@ 461c87b03e5Sespie 462c87b03e5Sespie# Control whether manpages generated by texi2pod.pl can be rebuilt. 463c87b03e5SespieGENERATED_MANPAGES = @GENERATED_MANPAGES@ 464c87b03e5Sespie 465c87b03e5Sespie# Additional directories of header files to run fixincludes on. 466c87b03e5Sespie# These should be directories searched automatically by default 467c87b03e5Sespie# just as /usr/include is. 468c87b03e5Sespie# *Do not* use this for directories that happen to contain 469c87b03e5Sespie# header files, but are not searched automatically by default. 470c87b03e5Sespie# On most systems, this is empty. 471c87b03e5SespieOTHER_FIXINCLUDES_DIRS= 472c87b03e5Sespie 473c87b03e5Sespie# A list of all the language-specific executables. 474c87b03e5Sespie# This is overridden by configure. 475c87b03e5SespieCOMPILERS = cc1$(exeext) @all_compilers@ 476c87b03e5Sespie 477c87b03e5Sespie# List of things which should already be built whenever we try to use xgcc 478c87b03e5Sespie# to compile anything (without linking). 479c87b03e5SespieGCC_PASSES=xgcc$(exeext) cc1$(exeext) specs $(EXTRA_PASSES) 480c87b03e5Sespie 481c87b03e5Sespie# List of things which should already be built whenever we try to use xgcc 482c87b03e5Sespie# to link anything. 483c87b03e5SespieGCC_PARTS=$(GCC_PASSES) $(LIBGCC) $(EXTRA_PROGRAMS) $(USE_COLLECT2) $(EXTRA_PARTS) 484c87b03e5Sespie 485c87b03e5Sespie# Directory to link to, when using the target `maketest'. 486c87b03e5SespieDIR = ../gcc 487c87b03e5Sespie 488c87b03e5Sespie# Flags to use when cross-building GCC. 489c87b03e5Sespie# Prefix to apply to names of object files when using them 490c87b03e5Sespie# to run on the machine we are compiling on. 491c87b03e5SespieBUILD_PREFIX = @BUILD_PREFIX@ 492c87b03e5Sespie# Prefix to apply to names of object files when compiling them 493c87b03e5Sespie# to run on the machine we are compiling on. 494c87b03e5Sespie# The default for this variable is chosen to keep these rules 495c87b03e5Sespie# out of the way of the other rules for compiling the same source files. 496c87b03e5SespieBUILD_PREFIX_1 = @BUILD_PREFIX_1@ 497c87b03e5Sespie# Native compiler for the build machine and its switches. 498c87b03e5SespieHOST_CC = @HOST_CC@ 499c87b03e5SespieHOST_CFLAGS= @HOST_CFLAGS@ -DGENERATOR_FILE 500c87b03e5Sespie 501c87b03e5Sespie# Native linker and preprocessor flags. For x-fragment overrides. 502c87b03e5SespieHOST_LDFLAGS=$(LDFLAGS) 503c87b03e5SespieHOST_CPPFLAGS=$(ALL_CPPFLAGS) 504c87b03e5Sespie 505c87b03e5Sespie# Actual name to use when installing a native compiler. 506c87b03e5SespieGCC_INSTALL_NAME = `echo gcc|sed '$(program_transform_name)'` 507c87b03e5SespieGCC_TARGET_INSTALL_NAME = $(target_alias)-`echo gcc|sed '$(program_transform_name)'` 508c87b03e5SespieCPP_INSTALL_NAME = `echo cpp|sed '$(program_transform_name)'` 509c87b03e5SespiePROTOIZE_INSTALL_NAME = `echo protoize|sed '$(program_transform_name)'` 510c87b03e5SespieUNPROTOIZE_INSTALL_NAME = `echo unprotoize|sed '$(program_transform_name)'` 511c87b03e5SespieGCOV_INSTALL_NAME = `echo gcov|sed '$(program_transform_name)'` 512c87b03e5SespieGCCBUG_INSTALL_NAME = `echo gccbug|sed '$(program_transform_name)'` 513c87b03e5Sespie 514c87b03e5Sespie# Actual name to use when installing a cross-compiler. 515c87b03e5SespieGCC_CROSS_NAME = `echo gcc|sed '$(program_transform_cross_name)'` 516c87b03e5SespieCPP_CROSS_NAME = `echo cpp|sed '$(program_transform_cross_name)'` 517c87b03e5SespiePROTOIZE_CROSS_NAME = `echo protoize|sed '$(program_transform_cross_name)'` 518c87b03e5SespieUNPROTOIZE_CROSS_NAME = `echo unprotoize|sed '$(program_transform_cross_name)'` 519c87b03e5Sespie 520c87b03e5Sespie# Set by autoconf to "all.internal" for a native build, or 521c87b03e5Sespie# "all.cross" to build a cross compiler. 522c87b03e5SespieALL = @ALL@ 523c87b03e5Sespie 524c87b03e5Sespie# Setup the testing framework, if you have one 525c87b03e5SespieEXPECT = `if [ -f $${rootme}/../expect/expect ] ; then \ 526c87b03e5Sespie echo $${rootme}/../expect/expect ; \ 527c87b03e5Sespie else echo expect ; fi` 528c87b03e5Sespie 529c87b03e5SespieRUNTEST = `if [ -f $${srcdir}/../dejagnu/runtest ] ; then \ 530c87b03e5Sespie echo $${srcdir}/../dejagnu/runtest ; \ 531c87b03e5Sespie else echo runtest; fi` 532c87b03e5SespieRUNTESTFLAGS = 533c87b03e5Sespie 534c87b03e5Sespie# Extra symbols for fixproto to define when parsing headers. 535c87b03e5SespieFIXPROTO_DEFINES = 536c87b03e5Sespie 537c87b03e5Sespie# Extra flags to use when compiling crt{begin,end}.o. 538c87b03e5SespieCRTSTUFF_T_CFLAGS = 539c87b03e5Sespie 540c87b03e5Sespie# Extra flags to use when compiling [m]crt0.o. 541c87b03e5SespieCRT0STUFF_T_CFLAGS = 542c87b03e5Sespie 543c87b03e5Sespie# "t" or nothing, for building multilibbed versions of, say, crtbegin.o. 544c87b03e5SespieT = 545c87b03e5Sespie 546c87b03e5Sespie# Should T contain a `=', libgcc.mk will make T_TARGET, setting 547c87b03e5Sespie# $(T_TARGET) to the name of the actual target filename. 548c87b03e5SespieT_TARGET = 549c87b03e5SespieT_TARGET : $(T_TARGET) 550c87b03e5Sespie 551c87b03e5Sespie# End of variables for you to override. 552c87b03e5Sespie 553c87b03e5Sespie# Definition of `all' is here so that new rules inserted by sed 554c87b03e5Sespie# do not specify the default target. 555c87b03e5Sespie# The real definition is under `all.internal' (for native compilers) 556c87b03e5Sespie# or `all.cross' (for cross compilers). 557c87b03e5Sespieall: all.indirect 558c87b03e5Sespie 559c87b03e5Sespie# This tells GNU Make version 3 not to put all variables in the environment. 560c87b03e5Sespie.NOEXPORT: 561c87b03e5Sespie 562c87b03e5Sespie# GCONFIG_H lists the config files that the generator files depend on, while 563c87b03e5Sespie# CONFIG_H lists the ones ordinary gcc files depend on, which includes 564c87b03e5Sespie# several files generated by those generators. 565c87b03e5SespieGCONFIG_H = config.h $(host_xm_file_list) 566c87b03e5SespieHCONFIG_H = hconfig.h $(build_xm_file_list) 567c87b03e5SespieCONFIG_H = $(GCONFIG_H) insn-constants.h insn-flags.h 568c87b03e5SespieTCONFIG_H = tconfig.h $(xm_file_list) 569c87b03e5SespieTARGET_H = target.h 570c87b03e5SespieHOOKS_H = hooks.h 571c87b03e5SespieLANGHOOKS_DEF_H = langhooks-def.h $(HOOKS_H) 572c87b03e5SespieTARGET_DEF_H = target-def.h $(HOOKS_H) 573c87b03e5SespieTM_P_H = tm_p.h $(tm_p_file_list) tm-preds.h 574c87b03e5Sespie 575c87b03e5SespieMACHMODE_H = machmode.h machmode.def @extra_modes_file@ 576c87b03e5SespieRTL_BASE_H = rtl.h rtl.def $(MACHMODE_H) 577c87b03e5SespieRTL_H = $(RTL_BASE_H) genrtl.h 578c87b03e5SespiePARAMS_H = params.h params.def 579c87b03e5SespieTREE_H = tree.h tree.def $(MACHMODE_H) tree-check.h version.h builtins.def \ 580c87b03e5Sespie location.h 581c87b03e5SespieBASIC_BLOCK_H = basic-block.h bitmap.h sbitmap.h varray.h $(PARTITION_H) \ 582c87b03e5Sespie hard-reg-set.h 583c87b03e5SespieDEMANGLE_H = $(srcdir)/../include/demangle.h 584c87b03e5SespieRECOG_H = recog.h 585c87b03e5SespieEXPR_H = expr.h 586c87b03e5SespieOPTABS_H = optabs.h insn-codes.h 587c87b03e5SespieREGS_H = regs.h varray.h $(MACHMODE_H) 588c87b03e5SespieINTEGRATE_H = integrate.h varray.h 589c87b03e5SespieLOOP_H = loop.h varray.h bitmap.h 590c87b03e5SespieGCC_H = gcc.h version.h 591c87b03e5SespieGGC_H = ggc.h varray.h gtype-desc.h 592c87b03e5SespieTIMEVAR_H = timevar.h timevar.def 593c87b03e5SespieINSN_ATTR_H = insn-attr.h $(srcdir)/insn-addr.h $(srcdir)/varray.h 594c87b03e5SespieC_COMMON_H = c-common.h $(SPLAY_TREE_H) $(CPPLIB_H) 595c87b03e5SespieC_TREE_H = c-tree.h $(C_COMMON_H) 596f092f567SespieSYSTEM_H = system.h hwint.h $(LIBIBERTY_INCLUDES)/libiberty.h 597c87b03e5SespiePREDICT_H = predict.h predict.def 598c87b03e5SespieCPPLIB_H = cpplib.h line-map.h 599c87b03e5Sespie 600c87b03e5Sespie# sed inserts variable overrides after the following line. 601c87b03e5Sespie####target overrides 602c87b03e5Sespie@target_overrides@ 603c87b03e5Sespie 604c87b03e5Sespie####host overrides 605c87b03e5Sespie@host_overrides@ 606c87b03e5Sespie# 607c87b03e5Sespie# Now figure out from those variables how to compile and link. 608c87b03e5Sespie 609c87b03e5Sespieall.indirect: $(ALL) 610c87b03e5Sespie 611c87b03e5Sespie# IN_GCC distinguishes between code compiled into GCC itself and other 612c87b03e5Sespie# programs built during a bootstrap. 613c87b03e5Sespie# autoconf inserts -DCROSS_COMPILE if we are building a cross compiler. 614c87b03e5SespieINTERNAL_CFLAGS = -DIN_GCC @CROSS@ 615c87b03e5Sespie 616c87b03e5Sespie# This is the variable actually used when we compile. 617c87b03e5Sespie# If you change this line, you probably also need to change the definition 618c87b03e5Sespie# of HOST_CFLAGS in build-make to match. 619c87b03e5SespieALL_CFLAGS = $(X_CFLAGS) $(T_CFLAGS) \ 620c87b03e5Sespie $(CFLAGS) $(INTERNAL_CFLAGS) $(COVERAGE_FLAGS) $(WARN_CFLAGS) $(XCFLAGS) @DEFS@ 621c87b03e5Sespie 622c87b03e5Sespie# Likewise. 623c87b03e5SespieALL_CPPFLAGS = $(CPPFLAGS) $(X_CPPFLAGS) $(T_CPPFLAGS) 624c87b03e5Sespie 625c87b03e5Sespie# Build and host support libraries. FORBUILD is either 626c87b03e5Sespie# .. or ../$(build_alias) depending on whether host != build. 627c87b03e5SespieLIBIBERTY = ../libiberty/libiberty.a 628c87b03e5SespieBUILD_LIBIBERTY = @FORBUILD@/libiberty/libiberty.a 629c87b03e5Sespie 630c87b03e5Sespie# Dependencies on the intl and portability libraries. 631c87b03e5SespieLIBDEPS= $(INTLDEPS) $(LIBIBERTY) 632c87b03e5Sespie 633c87b03e5Sespie# Likewise, for use in the tools that must run on this machine 634c87b03e5Sespie# even if we are cross-building GCC. 635c87b03e5SespieHOST_LIBDEPS= $(BUILD_LIBIBERTY) 636c87b03e5Sespie 637c87b03e5Sespie# How to link with both our special library facilities 638c87b03e5Sespie# and the system's installed libraries. 639c87b03e5SespieLIBS = $(INTLLIBS) @LIBS@ $(LIBIBERTY) 640c87b03e5Sespie 641c87b03e5Sespie# Any system libraries needed just for GNAT. 642c87b03e5SespieSYSLIBS = @GNAT_LIBEXC@ 643c87b03e5Sespie 644c87b03e5Sespie# Libs needed (at present) just for jcf-dump. 645c87b03e5SespieLDEXP_LIB = @LDEXP_LIB@ 646c87b03e5Sespie 647c87b03e5Sespie# Likewise, for use in the tools that must run on this machine 648c87b03e5Sespie# even if we are cross-building GCC. 649c87b03e5SespieHOST_LIBS = $(BUILD_LIBIBERTY) 650c87b03e5Sespie 651c87b03e5SespieHOST_RTL = $(BUILD_PREFIX)rtl.o read-rtl.o $(BUILD_PREFIX)bitmap.o \ 652c87b03e5Sespie $(BUILD_PREFIX)ggc-none.o 653c87b03e5SespieHOST_SUPPORT = gensupport.o insn-conditions.o 654c87b03e5SespieHOST_EARLY_SUPPORT = gensupport.o dummy-conditions.o 655c87b03e5Sespie 656c87b03e5SespieHOST_PRINT = print-rtl1.o 657c87b03e5SespieHOST_ERRORS = $(BUILD_PREFIX)errors.o 658c87b03e5SespieHOST_VARRAY = $(BUILD_PREFIX)varray.o 659c87b03e5Sespie 660c87b03e5Sespie# Specify the directories to be searched for header files. 661c87b03e5Sespie# Both . and srcdir are used, in that order, 662c87b03e5Sespie# so that *config.h will be found in the compilation 663c87b03e5Sespie# subdirectory rather than in the source directory. 664c87b03e5Sespie# -I$(@D) and -I$(srcdir)/$(@D) cause the subdirectory of the file 665c87b03e5Sespie# currently being compiled, in both source trees, to be examined as well. 666c87b03e5SespieINCLUDES = -I. -I$(@D) -I$(srcdir) -I$(srcdir)/$(@D) \ 667c87b03e5Sespie -I$(srcdir)/config -I$(srcdir)/../include 668c87b03e5Sespie 669c87b03e5Sespie# Always use -I$(srcdir)/config when compiling. 670c87b03e5Sespie.c.o: 671c87b03e5Sespie $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) $< $(OUTPUT_OPTION) 672c87b03e5Sespie 673c87b03e5Sespie# This tells GNU make version 3 not to export all the variables 674c87b03e5Sespie# defined in this file into the environment. 675c87b03e5Sespie.NOEXPORT: 676c87b03e5Sespie# 677c87b03e5Sespie# Support for additional languages (other than c and objc). 678c87b03e5Sespie# ??? objc can be supported this way too (leave for later). 679c87b03e5Sespie 680c87b03e5Sespie# These next lines are overridden by configure. 681c87b03e5SespieLANG_MAKEFILES = @all_lang_makefiles@ 682c87b03e5SespieLANG_STAGESTUFF = @all_stagestuff@ 683c87b03e5Sespie 684c87b03e5Sespie# Flags to pass to recursive makes. 685c87b03e5Sespie# CC is set by configure. Hosts without symlinks need special handling 686c87b03e5Sespie# because we need CC="stage1/xgcc -Bstage1/" to work in the language 687c87b03e5Sespie# subdirectories. 688c87b03e5Sespie# ??? The choices here will need some experimenting with. 689c87b03e5SespieORDINARY_FLAGS_TO_PASS = \ 690c87b03e5Sespie "AR=$(AR)" \ 691c87b03e5Sespie "AR_FLAGS_FOR_TARGET=$(AR_FLAGS_FOR_TARGET)" \ 692c87b03e5Sespie "AR_CREATE_FOR_TARGET=$(AR_CREATE_FOR_TARGET)" \ 693c87b03e5Sespie "AR_EXTRACT_FOR_TARGET=$(AR_EXTRACT_FOR_TARGET)" \ 694c87b03e5Sespie "AR_FOR_TARGET=$(AR_FOR_TARGET)" \ 695c87b03e5Sespie "BISON=$(BISON)" \ 696c87b03e5Sespie "BISONFLAGS=$(BISONFLAGS)" \ 697c87b03e5Sespie "CFLAGS=$(CFLAGS) $(WARN_CFLAGS)" \ 698c87b03e5Sespie "DESTDIR=$(DESTDIR)" \ 699c87b03e5Sespie "GCC_FOR_TARGET=$(GCC_FOR_TARGET)" \ 700c87b03e5Sespie "LDFLAGS=$(LDFLAGS)" \ 701c87b03e5Sespie "FLEX=$(FLEX)" \ 702c87b03e5Sespie "FLEXFLAGS=$(FLEXFLAGS)" \ 703c87b03e5Sespie "LN=$(LN)" \ 704c87b03e5Sespie "LN_S=$(LN_S)" \ 705c87b03e5Sespie "MAKEINFO=$(MAKEINFO)" \ 706c87b03e5Sespie "MAKEINFOFLAGS=$(MAKEINFOFLAGS)" \ 707c87b03e5Sespie "MAKEOVERRIDES=" \ 708c87b03e5Sespie "RANLIB_FOR_TARGET=$(RANLIB_FOR_TARGET)" \ 709c87b03e5Sespie "RANLIB_TEST_FOR_TARGET=$(RANLIB_TEST_FOR_TARGET)" \ 710c87b03e5Sespie "SHELL=$(SHELL)" \ 711c87b03e5Sespie "exeext=$(exeext)" \ 712c87b03e5Sespie "build_exeext=$(build_exeext)" \ 713c87b03e5Sespie "objext=$(objext)" \ 714c87b03e5Sespie "exec_prefix=$(exec_prefix)" \ 715c87b03e5Sespie "prefix=$(prefix)" \ 716c87b03e5Sespie "local_prefix=$(local_prefix)" \ 717c87b03e5Sespie "gxx_include_dir=$(gcc_gxx_include_dir)" \ 718c87b03e5Sespie "build_tooldir=$(build_tooldir)" \ 719c87b03e5Sespie "gcc_tooldir=$(gcc_tooldir)" \ 720c87b03e5Sespie "bindir=$(bindir)" \ 721c87b03e5Sespie "libsubdir=$(libsubdir)" \ 722c87b03e5Sespie "datadir=$(datadir)" \ 723c87b03e5Sespie "localedir=$(localedir)" 724c87b03e5SespieFLAGS_TO_PASS = $(ORDINARY_FLAGS_TO_PASS) "CC=@cc_set_by_configure@" \ 725c87b03e5Sespie "STAGE_PREFIX=@stage_prefix_set_by_configure@" 726c87b03e5SespiePREPEND_DOTDOT_TO_RELATIVE_PATHS = sed \ 727c87b03e5Sespie -e 's|^ *[^ /][^ /]*/|%&|' \ 728c87b03e5Sespie -e 's| -B| -B%|g' \ 729c87b03e5Sespie -e 's|% *[^- /]|%&|g' \ 730c87b03e5Sespie -e 's|%% *|../|g' \ 731c87b03e5Sespie -e 's|%||g' 732c87b03e5SespieSUBDIR_FLAGS_TO_PASS = $(ORDINARY_FLAGS_TO_PASS) \ 733c87b03e5Sespie "CC=`echo @quoted_cc_set_by_configure@ | $(PREPEND_DOTDOT_TO_RELATIVE_PATHS)`" \ 734c87b03e5Sespie "STAGE_PREFIX=`echo @quoted_stage_prefix_set_by_configure@ | $(PREPEND_DOTDOT_TO_RELATIVE_PATHS)`" 735c87b03e5Sespie# 736c87b03e5Sespie# Lists of files for various purposes. 737c87b03e5Sespie 738c87b03e5Sespie# Target specific, C specific object file 739c87b03e5SespieC_TARGET_OBJS=@c_target_objs@ 740c87b03e5Sespie 741c87b03e5Sespie# Target specific, C++ specific object file 742c87b03e5SespieCXX_TARGET_OBJS=@cxx_target_objs@ 743c87b03e5Sespie 744c87b03e5Sespie# Language-specific object files for C and Objective C. 745c87b03e5SespieC_AND_OBJC_OBJS = attribs.o c-errors.o c-lex.o c-pragma.o c-decl.o c-typeck.o \ 746cd3be6e5Savsm c-convert.o c-aux-info.o c-common.o c-opts.o c-format.o c-bounded.o \ 747cd3be6e5Savsm c-semantics.o c-objc-common.o c-dump.o libcpp.a $(C_TARGET_OBJS) 748c87b03e5Sespie 749c87b03e5Sespie# Language-specific object files for C. 750c87b03e5SespieC_OBJS = c-parse.o c-lang.o c-pretty-print.o $(C_AND_OBJC_OBJS) 751c87b03e5Sespie 752c87b03e5Sespie# Language-independent object files. 753c87b03e5Sespie 754c87b03e5SespieOBJS = alias.o bb-reorder.o bitmap.o builtins.o caller-save.o calls.o \ 755c87b03e5Sespie cfg.o cfganal.o cfgbuild.o cfgcleanup.o cfglayout.o cfgloop.o \ 756c87b03e5Sespie cfgrtl.o combine.o conflict.o convert.o cse.o cselib.o dbxout.o \ 757c87b03e5Sespie debug.o df.o diagnostic.o doloop.o dominance.o \ 758c87b03e5Sespie dwarf2asm.o dwarf2out.o dwarfout.o emit-rtl.o except.o explow.o \ 759c87b03e5Sespie expmed.o expr.o final.o flow.o fold-const.o function.o gcse.o \ 760c87b03e5Sespie genrtl.o ggc-common.o global.o graph.o gtype-desc.o \ 761c87b03e5Sespie haifa-sched.o hashtable.o hooks.o ifcvt.o insn-attrtab.o insn-emit.o \ 762c87b03e5Sespie insn-extract.o insn-opinit.o insn-output.o insn-peep.o insn-recog.o \ 763c87b03e5Sespie integrate.o intl.o jump.o langhooks.o lcm.o lists.o local-alloc.o \ 764c87b03e5Sespie loop.o mbchar.o optabs.o params.o predict.o print-rtl.o print-tree.o \ 765c87b03e5Sespie profile.o ra.o ra-build.o ra-colorize.o ra-debug.o ra-rewrite.o \ 766c87b03e5Sespie real.o recog.o reg-stack.o regclass.o regmove.o regrename.o \ 767c87b03e5Sespie reload.o reload1.o reorg.o resource.o rtl.o rtlanal.o rtl-error.o \ 768c87b03e5Sespie sbitmap.o sched-deps.o sched-ebb.o sched-rgn.o sched-vis.o sdbout.o \ 769c87b03e5Sespie sibcall.o simplify-rtx.o ssa.o ssa-ccp.o ssa-dce.o stmt.o \ 770c87b03e5Sespie stor-layout.o stringpool.o timevar.o toplev.o tracer.o tree.o tree-dump.o \ 771c87b03e5Sespie tree-inline.o unroll.o varasm.o varray.o version.o vmsdbgout.o xcoffout.o \ 7725982dd4aSetoh et-forest.o protector.o $(GGC) $(out_object_file) $(EXTRA_OBJS) 773c87b03e5Sespie 774c87b03e5SespieBACKEND = main.o libbackend.a 775c87b03e5Sespie 776c87b03e5Sespie# Files to be copied away after each stage in building. 777c87b03e5SespieSTAGESTUFF = *$(objext) insn-flags.h insn-config.h insn-codes.h \ 778c87b03e5Sespie insn-output.c insn-recog.c insn-emit.c insn-extract.c insn-peep.c \ 779c87b03e5Sespie insn-attr.h insn-attrtab.c insn-opinit.c insn-constants.h tm-preds.h \ 780c87b03e5Sespie tree-check.h insn-conditions.c \ 781c87b03e5Sespie s-flags s-config s-codes s-mlib s-genrtl s-gtype gtyp-gen.h \ 782c87b03e5Sespie s-output s-recog s-emit s-extract s-peep s-check s-conditions \ 783c87b03e5Sespie s-attr s-attrtab s-opinit s-preds s-constants s-crt0 \ 784c87b03e5Sespie genemit$(build_exeext) genoutput$(build_exeext) genrecog$(build_exeext) \ 785c87b03e5Sespie genextract$(build_exeext) genflags$(build_exeext) gencodes$(build_exeext) \ 786c87b03e5Sespie genconfig$(build_exeext) genpeep$(build_exeext) genattrtab$(build_exeext) \ 787c87b03e5Sespie genattr$(build_exeext) genopinit$(build_exeext) gengenrtl$(build_exeext) \ 788c87b03e5Sespie gencheck$(build_exeext) genpreds$(build_exeext) genconstants$(build_exeext) \ 789c87b03e5Sespie gengtype$(build_exeext) genconditions$(build_exeext) \ 790c87b03e5Sespie genrtl.c genrtl.h gt-*.h gtype-*.h gtype-desc.c \ 791c87b03e5Sespie xgcc$(exeext) cpp$(exeext) cc1$(exeext) $(EXTRA_PASSES) \ 792c87b03e5Sespie $(EXTRA_PARTS) $(EXTRA_PROGRAMS) gcc-cross$(exeext) cc1obj$(exeext) \ 793c87b03e5Sespie protoize$(exeext) unprotoize$(exeext) \ 794c87b03e5Sespie specs collect2$(exeext) $(USE_COLLECT2) \ 795c87b03e5Sespie gcov$(exeext) *.[0-9][0-9].* *.[si] libcpp.a libbackend.a libgcc.mk \ 796c87b03e5Sespie $(LANG_STAGESTUFF) 797c87b03e5Sespie 798c87b03e5Sespie# Library members defined in libgcc2.c. 799c87b03e5Sespie# Variable length limited to 255 charactes when passed to a shell script. 800c87b03e5SespieLIB2FUNCS_1 = _muldi3 _negdi2 _lshrdi3 _ashldi3 _ashrdi3 _ffsdi2 _clz \ 801c87b03e5Sespie _cmpdi2 _ucmpdi2 _floatdidf _floatdisf _fixunsdfsi _fixunssfsi \ 802c87b03e5Sespie _fixunsdfdi _fixdfdi _fixunssfdi _fixsfdi _fixxfdi _fixunsxfdi 803c87b03e5Sespie 804c87b03e5SespieLIB2FUNCS_2 = _floatdixf _fixunsxfsi _fixtfdi _fixunstfdi _floatditf \ 805c87b03e5Sespie _clear_cache _trampoline __main _exit _absvsi2 _absvdi2 _addvsi3 \ 8065982dd4aSetoh _addvdi3 _subvsi3 _subvdi3 _mulvsi3 _mulvdi3 _negvsi2 _negvdi2 _ctors _stack_smash_handler 807c87b03e5Sespie 808c87b03e5Sespie# Defined in libgcc2.c, included only in the static library. 809c87b03e5SespieLIB2FUNCS_ST = _eprintf _bb __gcc_bcmp 810c87b03e5Sespie 811c87b03e5SespieFPBIT_FUNCS = _pack_sf _unpack_sf _addsub_sf _mul_sf _div_sf \ 812c87b03e5Sespie _fpcmp_parts_sf _compare_sf _eq_sf _ne_sf _gt_sf _ge_sf \ 813c87b03e5Sespie _lt_sf _le_sf _unord_sf _si_to_sf _sf_to_si _negate_sf _make_sf \ 814c87b03e5Sespie _sf_to_df _sf_to_tf _thenan_sf _sf_to_usi _usi_to_sf 815c87b03e5Sespie 816c87b03e5SespieDPBIT_FUNCS = _pack_df _unpack_df _addsub_df _mul_df _div_df \ 817c87b03e5Sespie _fpcmp_parts_df _compare_df _eq_df _ne_df _gt_df _ge_df \ 818c87b03e5Sespie _lt_df _le_df _unord_df _si_to_df _df_to_si _negate_df _make_df \ 819c87b03e5Sespie _df_to_sf _df_to_tf _thenan_df _df_to_usi _usi_to_df 820c87b03e5Sespie 821c87b03e5SespieTPBIT_FUNCS = _pack_tf _unpack_tf _addsub_tf _mul_tf _div_tf \ 822c87b03e5Sespie _fpcmp_parts_tf _compare_tf _eq_tf _ne_tf _gt_tf _ge_tf \ 823c87b03e5Sespie _lt_tf _le_tf _unord_tf _si_to_tf _tf_to_si _negate_tf _make_tf \ 824c87b03e5Sespie _tf_to_df _tf_to_sf _thenan_tf _tf_to_usi _usi_to_tf 825c87b03e5Sespie 826c87b03e5Sespie# These might cause a divide overflow trap and so are compiled with 827c87b03e5Sespie# unwinder info. 828c87b03e5SespieLIB2_DIVMOD_FUNCS = _divdi3 _moddi3 _udivdi3 _umoddi3 _udiv_w_sdiv _udivmoddi4 829c87b03e5Sespie 830c87b03e5Sespie# The only suffixes we want for implicit rules are .c and .o, so clear 831c87b03e5Sespie# the list and add them. This speeds up GNU Make, and allows -r to work. 832c87b03e5Sespie# For i18n support, we also need .gmo, .po, .pox. 833c87b03e5Sespie# This must come before the language makefile fragments to allow them to 834c87b03e5Sespie# add suffixes and rules of their own. 835c87b03e5Sespie.SUFFIXES: 836c87b03e5Sespie.SUFFIXES: .c .o .po .pox .gmo 837c87b03e5Sespie 838c87b03e5Sespie# 839c87b03e5Sespie# Language makefile fragments. 840c87b03e5Sespie 841c87b03e5Sespie# The following targets define the interface between us and the languages. 842c87b03e5Sespie# 843c87b03e5Sespie# all.cross, start.encap, rest.encap, 844c87b03e5Sespie# info, dvi, 845c87b03e5Sespie# install-normal, install-common, install-info, install-man, 846c87b03e5Sespie# uninstall, 847c87b03e5Sespie# mostlyclean, clean, distclean, extraclean, maintainer-clean, 848c87b03e5Sespie# stage1, stage2, stage3, stage4 849c87b03e5Sespie# 850c87b03e5Sespie# Each language is linked in with a series of hooks (since we can't use `::' 851c87b03e5Sespie# targets). The name of each hooked is "lang.${target_name}" (eg: lang.info). 852c87b03e5Sespie# Configure computes and adds these here. 853c87b03e5Sespie 854c87b03e5Sespie####language hooks 855c87b03e5Sespie@language_hooks@ 856c87b03e5Sespie 857c87b03e5Sespie# sed inserts language fragments after the following line. 858c87b03e5Sespie####language fragments 859c87b03e5Sespie@language_fragments@ 860c87b03e5Sespie 861c87b03e5Sespie# End of language makefile fragments. 862c87b03e5Sespie# 863c87b03e5Sespie 864c87b03e5Sespieconfig.h: cs-config.h ; @true 865c87b03e5Sespiehconfig.h: cs-hconfig.h ; @true 866c87b03e5Sespietconfig.h: cs-tconfig.h ; @true 867c87b03e5Sespietm_p.h: cs-tm_p.h ; @true 868c87b03e5Sespie 869c87b03e5Sespiecs-config.h: Makefile 870c87b03e5Sespie TM_DEFINES="$(tm_defines)" \ 871c87b03e5Sespie HEADERS="$(host_xm_file)" XM_DEFINES="$(host_xm_defines)" \ 872c87b03e5Sespie TARGET_CPU_DEFAULT="$(target_cpu_default)" \ 873c87b03e5Sespie $(SHELL) $(srcdir)/mkconfig.sh config.h 874c87b03e5Sespie 875c87b03e5Sespiecs-hconfig.h: Makefile 876c87b03e5Sespie TM_DEFINES="$(tm_defines)" \ 877c87b03e5Sespie HEADERS="$(build_xm_file)" XM_DEFINES="$(build_xm_defines)" \ 878c87b03e5Sespie TARGET_CPU_DEFAULT="$(target_cpu_default)" \ 879c87b03e5Sespie $(SHELL) $(srcdir)/mkconfig.sh hconfig.h 880c87b03e5Sespie 881c87b03e5Sespiecs-tconfig.h: Makefile 882c87b03e5Sespie TM_DEFINES="$(tm_defines)" \ 883c87b03e5Sespie HEADERS="$(xm_file)" XM_DEFINES="$(xm_defines)" \ 884c87b03e5Sespie TARGET_CPU_DEFAULT="" \ 885c87b03e5Sespie $(SHELL) $(srcdir)/mkconfig.sh tconfig.h 886c87b03e5Sespie 887c87b03e5Sespiecs-tm_p.h: Makefile 888c87b03e5Sespie TM_DEFINES="" \ 889c87b03e5Sespie HEADERS="$(tm_p_file)" XM_DEFINES="" TARGET_CPU_DEFAULT="" \ 890c87b03e5Sespie $(SHELL) $(srcdir)/mkconfig.sh tm_p.h 891c87b03e5Sespie 892c87b03e5Sespie# Don't automatically run autoconf, since configure.in might be accidentally 893c87b03e5Sespie# newer than configure. Also, this writes into the source directory which 894c87b03e5Sespie# might be on a read-only file system. If configured for maintainer mode 895c87b03e5Sespie# then do allow autoconf to be run. 896c87b03e5Sespie 897c87b03e5Sespie$(srcdir)/configure: @MAINT@ $(srcdir)/configure.in 898c87b03e5Sespie (cd $(srcdir) && autoconf) 899c87b03e5Sespie 900c87b03e5Sespiegccbug: $(srcdir)/gccbug.in 901c87b03e5Sespie CONFIG_FILES=gccbug CONFIG_HEADERS= ./config.status 902c87b03e5Sespie 903c87b03e5Sespiemklibgcc: $(srcdir)/mklibgcc.in 904c87b03e5Sespie CONFIG_FILES=mklibgcc CONFIG_HEADERS= ./config.status 905c87b03e5Sespie 906c87b03e5Sespiemkheaders: $(srcdir)/mkheaders.in 907c87b03e5Sespie CONFIG_FILES=mkheaders CONFIG_HEADERS= ./config.status 908c87b03e5Sespie 909c87b03e5Sespie# cstamp-h.in controls rebuilding of config.in. 910c87b03e5Sespie# It is named cstamp-h.in and not stamp-h.in so the mostlyclean rule doesn't 911c87b03e5Sespie# delete it. A stamp file is needed as autoheader won't update the file if 912c87b03e5Sespie# nothing has changed. 913c87b03e5Sespie# It remains in the source directory and is part of the distribution. 914c87b03e5Sespie# This follows what is done in shellutils, fileutils, etc. 915c87b03e5Sespie# "echo timestamp" is used instead of touch to be consistent with other 916c87b03e5Sespie# packages that use autoconf (??? perhaps also to avoid problems with patch?). 917c87b03e5Sespie# ??? Newer versions have a maintainer mode that may be useful here. 918c87b03e5Sespie 919c87b03e5Sespie# Don't run autoheader automatically either. 920c87b03e5Sespie# Only run it if maintainer mode is enabled. 921c87b03e5Sespie@MAINT@ $(srcdir)/config.in: $(srcdir)/cstamp-h.in 922c87b03e5Sespie@MAINT@ $(srcdir)/cstamp-h.in: $(srcdir)/configure.in $(srcdir)/acconfig.h 923c87b03e5Sespie@MAINT@ (cd $(srcdir) && autoheader) 924c87b03e5Sespie@MAINT@ @rm -f $(srcdir)/cstamp-h.in 925c87b03e5Sespie@MAINT@ echo timestamp > $(srcdir)/cstamp-h.in 926c87b03e5Sespieauto-host.h: cstamp-h ; @true 927c87b03e5Sespiecstamp-h: config.in config.status 928c87b03e5Sespie CONFIG_HEADERS=auto-host.h:config.in LANGUAGES="$(CONFIG_LANGUAGES)" $(SHELL) config.status 929c87b03e5Sespie 9308f07a54aSdrahnauto-build.h: config.in config.status 9318f07a54aSdrahn CONFIG_HEADERS=auto-build.h:config.in LANGUAGES="$(CONFIG_LANGUAGES)" $(SHELL) config.status 9328f07a54aSdrahn 933c87b03e5Sespie# Really, really stupid make features, such as SUN's KEEP_STATE, may force 934c87b03e5Sespie# a target to build even if it is up-to-date. So we must verify that 935c87b03e5Sespie# config.status does not exist before failing. 936c87b03e5Sespieconfig.status: $(srcdir)/configure $(srcdir)/config.gcc version.c 937c87b03e5Sespie @if [ ! -f config.status ] ; then \ 938c87b03e5Sespie echo You must configure gcc. Look at http://gcc.gnu.org/install/ for details.; \ 939c87b03e5Sespie false; \ 940c87b03e5Sespie else \ 941c87b03e5Sespie LANGUAGES="$(CONFIG_LANGUAGES)" $(SHELL) config.status --recheck; \ 942c87b03e5Sespie fi 943c87b03e5Sespie 944c87b03e5Sespieall.internal: start.encap rest.encap doc 945c87b03e5Sespie# This is what to compile if making a cross-compiler. 946c87b03e5Sespieall.cross: native gcc-cross cpp$(exeext) specs \ 947c87b03e5Sespie $(LIBGCC) $(EXTRA_PARTS) lang.all.cross doc 948c87b03e5Sespie# This is what must be made before installing GCC and converting libraries. 949c87b03e5Sespiestart.encap: native xgcc$(exeext) cpp$(exeext) specs \ 950c87b03e5Sespie xlimits.h lang.start.encap 951c87b03e5Sespie# These can't be made until after GCC can run. 952c87b03e5Sespierest.encap: $(STMP_FIXPROTO) $(LIBGCC) $(EXTRA_PARTS) lang.rest.encap 953c87b03e5Sespie# This is what is made with the host's compiler 954c87b03e5Sespie# whether making a cross compiler or not. 955c87b03e5Sespienative: config.status auto-host.h intl.all build-@POSUB@ $(LANGUAGES) \ 956c87b03e5Sespie $(EXTRA_PASSES) $(EXTRA_PROGRAMS) $(USE_COLLECT2) 957c87b03e5Sespie 958c87b03e5Sespie# Define the names for selecting languages in LANGUAGES. 959c87b03e5SespieC c: cc1$(exeext) 960c87b03e5SespiePROTO: proto 961c87b03e5Sespie 962c87b03e5Sespie# Tell GNU make these are phony targets. 963c87b03e5Sespie.PHONY: C c PROTO proto 964c87b03e5Sespie 965c87b03e5Sespie# On the target machine, finish building a cross compiler. 966c87b03e5Sespie# This does the things that can't be done on the host machine. 967c87b03e5Sespierest.cross: $(LIBGCC) specs 968c87b03e5Sespie 969c87b03e5Sespie# Recompile all the language-independent object files. 970c87b03e5Sespie# This is used only if the user explicitly asks for it. 971c87b03e5Sespiecompilations: $(BACKEND) 972c87b03e5Sespie 973c87b03e5Sespie# Like libcpp.a, this archive is strictly for the host. 974c87b03e5Sespielibbackend.a: $(OBJS) 975c87b03e5Sespie -rm -rf libbackend.a 976c87b03e5Sespie $(AR) $(AR_FLAGS) libbackend.a $(OBJS) 977c87b03e5Sespie -$(RANLIB) libbackend.a 978c87b03e5Sespie 979c87b03e5Sespie# We call this executable `xgcc' rather than `gcc' 980c87b03e5Sespie# to avoid confusion if the current directory is in the path 981c87b03e5Sespie# and CC is `gcc'. It is renamed to `gcc' when it is installed. 982c87b03e5Sespiexgcc$(exeext): gcc.o gccspec.o version.o intl.o prefix.o \ 983c87b03e5Sespie version.o $(LIBDEPS) $(EXTRA_GCC_OBJS) 984c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ gcc.o gccspec.o intl.o \ 985c87b03e5Sespie prefix.o version.o $(EXTRA_GCC_OBJS) $(LIBS) 986c87b03e5Sespie 987c87b03e5Sespie# cpp is to cpp0 as gcc is to cc1. 988c87b03e5Sespie# The only difference from xgcc is that it's linked with cppspec.o 989c87b03e5Sespie# instead of gccspec.o. 990c87b03e5Sespiecpp$(exeext): gcc.o cppspec.o version.o intl.o prefix.o \ 991c87b03e5Sespie version.o $(LIBDEPS) $(EXTRA_GCC_OBJS) 992c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ gcc.o cppspec.o intl.o \ 993c87b03e5Sespie prefix.o version.o $(EXTRA_GCC_OBJS) $(LIBS) 994c87b03e5Sespie 995c87b03e5Sespie# Dump a specs file to make -B./ read these specs over installed ones. 996c87b03e5Sespiespecs: xgcc$(exeext) 997c87b03e5Sespie $(GCC_FOR_TARGET) -dumpspecs > tmp-specs 998c87b03e5Sespie mv tmp-specs specs 999c87b03e5Sespie 1000c87b03e5Sespie# We do want to create an executable named `xgcc', so we can use it to 1001c87b03e5Sespie# compile libgcc2.a. 1002c87b03e5Sespie# Also create gcc-cross, so that install-common will install properly. 1003c87b03e5Sespiegcc-cross: xgcc$(exeext) 1004c87b03e5Sespie cp xgcc$(exeext) gcc-cross$(exeext) 1005c87b03e5Sespie 1006c87b03e5Sespiecc1$(exeext): $(C_OBJS) $(BACKEND) $(LIBDEPS) 1007c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o cc1$(exeext) \ 1008c87b03e5Sespie $(C_OBJS) $(BACKEND) $(LIBS) 1009c87b03e5Sespie 1010c87b03e5Sespie# Build the version of limits.h that we will install. 1011c87b03e5Sespiexlimits.h: glimits.h limitx.h limity.h 1012c87b03e5Sespie if $(LIMITS_H_TEST) ; then \ 1013c87b03e5Sespie cat $(srcdir)/limitx.h $(srcdir)/glimits.h $(srcdir)/limity.h > tmp-xlimits.h; \ 1014c87b03e5Sespie else \ 1015c87b03e5Sespie cat $(srcdir)/glimits.h > tmp-xlimits.h; \ 1016c87b03e5Sespie fi 1017c87b03e5Sespie mv tmp-xlimits.h xlimits.h 1018c87b03e5Sespie# 1019c87b03e5Sespie# Build libgcc.a. 1020c87b03e5Sespie 1021c87b03e5SespieLIB2ADD = $(LIB2FUNCS_EXTRA) 1022c87b03e5SespieLIB2ADD_ST = $(LIB2FUNCS_STATIC_EXTRA) 1023c87b03e5Sespie 1024c87b03e5Sespielibgcc.mk: config.status Makefile mklibgcc $(LIB2ADD) $(LIB2ADD_ST) xgcc$(exeext) specs 1025c87b03e5Sespie objext='$(objext)' \ 1026c87b03e5Sespie LIB1ASMFUNCS='$(LIB1ASMFUNCS)' \ 1027c87b03e5Sespie LIB2FUNCS_1='$(LIB2FUNCS_1)' \ 1028c87b03e5Sespie LIB2FUNCS_2='$(LIB2FUNCS_2)' \ 1029c87b03e5Sespie LIB2FUNCS_ST='$(LIB2FUNCS_ST)' \ 1030c87b03e5Sespie LIB2ADD='$(LIB2ADD)' \ 1031c87b03e5Sespie LIB2ADD_ST='$(LIB2ADD_ST)' \ 1032c87b03e5Sespie LIB2ADDEH='$(LIB2ADDEH)' \ 1033c87b03e5Sespie LIB2ADDEHDEP='$(LIB2ADDEHDEP)' \ 1034c87b03e5Sespie FPBIT='$(FPBIT)' \ 1035c87b03e5Sespie FPBIT_FUNCS='$(FPBIT_FUNCS)' \ 1036c87b03e5Sespie LIB2_DIVMOD_FUNCS='$(LIB2_DIVMOD_FUNCS)' \ 1037c87b03e5Sespie DPBIT='$(DPBIT)' \ 1038c87b03e5Sespie DPBIT_FUNCS='$(DPBIT_FUNCS)' \ 1039c87b03e5Sespie TPBIT='$(TPBIT)' \ 1040c87b03e5Sespie TPBIT_FUNCS='$(TPBIT_FUNCS)' \ 1041c87b03e5Sespie MULTILIBS=`$(GCC_FOR_TARGET) --print-multi-lib` \ 1042c87b03e5Sespie EXTRA_MULTILIB_PARTS='$(EXTRA_MULTILIB_PARTS)' \ 1043c87b03e5Sespie SHLIB_LINK='$(SHLIB_LINK)' \ 1044c87b03e5Sespie SHLIB_INSTALL='$(SHLIB_INSTALL)' \ 1045c87b03e5Sespie SHLIB_EXT='$(SHLIB_EXT)' \ 1046c87b03e5Sespie SHLIB_MULTILIB='$(SHLIB_MULTILIB)' \ 1047c87b03e5Sespie SHLIB_MKMAP='$(SHLIB_MKMAP)' \ 1048c87b03e5Sespie SHLIB_MKMAP_OPTS='$(SHLIB_MKMAP_OPTS)' \ 1049c87b03e5Sespie SHLIB_MAPFILES='$(SHLIB_MAPFILES)' \ 1050c87b03e5Sespie SHLIB_NM_FLAGS='$(SHLIB_NM_FLAGS)' \ 1051c87b03e5Sespie MULTILIB_OSDIRNAMES='$(MULTILIB_OSDIRNAMES)' \ 1052c87b03e5Sespie mkinstalldirs='$(SHELL) $(srcdir)/mkinstalldirs' \ 1053c87b03e5Sespie $(SHELL) mklibgcc > tmp-libgcc.mk 1054c87b03e5Sespie mv tmp-libgcc.mk libgcc.mk 1055c87b03e5Sespie 1056c87b03e5Sespie# All the things that might cause us to want to recompile bits of libgcc. 1057c87b03e5SespieLIBGCC_DEPS = $(GCC_PASSES) $(LANGUAGES) stmp-int-hdrs $(STMP_FIXPROTO) \ 1058c87b03e5Sespie libgcc.mk $(srcdir)/libgcc2.c $(TCONFIG_H) \ 1059c87b03e5Sespie $(MACHMODE_H) longlong.h gbl-ctors.h config.status stmp-int-hdrs \ 1060c87b03e5Sespie tsystem.h $(FPBIT) $(DPBIT) $(TPBIT) $(LIB2ADD) \ 1061c87b03e5Sespie $(LIB2ADD_ST) $(LIB2ADDEH) $(LIB2ADDEHDEP) $(EXTRA_PARTS) \ 1062c87b03e5Sespie $(srcdir)/config/$(LIB1ASMSRC) 1063c87b03e5Sespie 1064c87b03e5Sespielibgcc.a: $(LIBGCC_DEPS) 1065c87b03e5Sespie $(MAKE) GCC_FOR_TARGET="$(GCC_FOR_TARGET)" \ 1066c87b03e5Sespie BUILD_PREFIX="$(BUILD_PREFIX)" BUILD_PREFIX_1="$(BUILD_PREFIX_1)" \ 1067c87b03e5Sespie AR_FOR_TARGET="$(AR_FOR_TARGET)" \ 1068c87b03e5Sespie AR_CREATE_FOR_TARGET="$(AR_CREATE_FOR_TARGET)" \ 1069c87b03e5Sespie AR_FLAGS_FOR_TARGET="$(AR_FLAGS_FOR_TARGET)" \ 1070c87b03e5Sespie CFLAGS="$(CFLAGS) $(WARN_CFLAGS)" \ 1071c87b03e5Sespie RANLIB_FOR_TARGET="$(RANLIB_FOR_TARGET)" \ 1072c87b03e5Sespie RANLIB_TEST_FOR_TARGET="$(RANLIB_TEST_FOR_TARGET)" \ 1073c87b03e5Sespie NM_FOR_TARGET="$(NM_FOR_TARGET)" AWK="$(AWK)" \ 1074c87b03e5Sespie LIBGCC2_CFLAGS="$(LIBGCC2_CFLAGS)" \ 1075c87b03e5Sespie INCLUDES="$(INCLUDES)" \ 1076c87b03e5Sespie CONFIG_H="$(TCONFIG_H)" MACHMODE_H="$(MACHMODE_H)" \ 1077c87b03e5Sespie LIB1ASMSRC='$(LIB1ASMSRC)' \ 1078c87b03e5Sespie MAKEOVERRIDES= \ 1079c87b03e5Sespie -f libgcc.mk all 1080c87b03e5Sespie 1081c87b03e5Sespie# Use the genmultilib shell script to generate the information the gcc 1082c87b03e5Sespie# driver program needs to select the library directory based on the 1083c87b03e5Sespie# switches. 1084c87b03e5Sespiemultilib.h: s-mlib; @true 1085c87b03e5Sespies-mlib: $(srcdir)/genmultilib Makefile 1086c87b03e5Sespie if test @enable_multilib@ = yes \ 1087c87b03e5Sespie || test -n "$(MULTILIB_OSDIRNAMES)"; then \ 1088c87b03e5Sespie $(SHELL) $(srcdir)/genmultilib \ 1089c87b03e5Sespie "$(MULTILIB_OPTIONS)" \ 1090c87b03e5Sespie "$(MULTILIB_DIRNAMES)" \ 1091c87b03e5Sespie "$(MULTILIB_MATCHES)" \ 1092c87b03e5Sespie "$(MULTILIB_EXCEPTIONS)" \ 1093c87b03e5Sespie "$(MULTILIB_EXTRA_OPTS)" \ 1094c87b03e5Sespie "$(MULTILIB_EXCLUSIONS)" \ 1095c87b03e5Sespie "$(MULTILIB_OSDIRNAMES)" \ 1096c87b03e5Sespie "@enable_multilib@" \ 1097c87b03e5Sespie > tmp-mlib.h; \ 1098c87b03e5Sespie else \ 1099c87b03e5Sespie $(SHELL) $(srcdir)/genmultilib '' '' '' '' '' '' '' no \ 1100c87b03e5Sespie > tmp-mlib.h; \ 1101c87b03e5Sespie fi 1102c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-mlib.h multilib.h 1103c87b03e5Sespie $(STAMP) s-mlib 1104c87b03e5Sespie 1105c87b03e5Sespie# Build multiple copies of libgcc.a, one for each target switch. 1106c87b03e5Sespiestmp-multilib: $(LIBGCC_DEPS) 1107c87b03e5Sespie $(MAKE) GCC_FOR_TARGET="$(GCC_FOR_TARGET)" \ 1108c87b03e5Sespie BUILD_PREFIX="$(BUILD_PREFIX)" BUILD_PREFIX_1="$(BUILD_PREFIX_1)" \ 1109c87b03e5Sespie AR_FOR_TARGET="$(AR_FOR_TARGET)" \ 1110c87b03e5Sespie AR_CREATE_FOR_TARGET="$(AR_CREATE_FOR_TARGET)" \ 1111c87b03e5Sespie AR_FLAGS_FOR_TARGET="$(AR_FLAGS_FOR_TARGET)" \ 1112c87b03e5Sespie CFLAGS="$(CFLAGS) $(WARN_CFLAGS)" \ 1113c87b03e5Sespie RANLIB_FOR_TARGET="$(RANLIB_FOR_TARGET)" \ 1114c87b03e5Sespie RANLIB_TEST_FOR_TARGET="$(RANLIB_TEST_FOR_TARGET)" \ 1115c87b03e5Sespie NM_FOR_TARGET="$(NM_FOR_TARGET)" AWK="$(AWK)" \ 1116c87b03e5Sespie LIBGCC2_CFLAGS="$(LIBGCC2_CFLAGS)" \ 1117c87b03e5Sespie INCLUDES="$(INCLUDES)" \ 1118c87b03e5Sespie CONFIG_H="$(CONFIG_H)" MACHMODE_H="$(MACHMODE_H)" \ 1119c87b03e5Sespie LIB1ASMSRC='$(LIB1ASMSRC)' \ 1120c87b03e5Sespie MAKEOVERRIDES= \ 1121c87b03e5Sespie -f libgcc.mk all 1122c87b03e5Sespie $(STAMP) stmp-multilib 1123c87b03e5Sespie 1124c87b03e5Sespie# Compile two additional files that are linked with every program 1125c87b03e5Sespie# linked using GCC on systems using COFF or ELF, for the sake of C++ 1126c87b03e5Sespie# constructors. 1127c87b03e5Sespie$(T)crtbegin.o: crtstuff.c $(GCC_PASSES) $(TCONFIG_H) auto-host.h \ 1128c87b03e5Sespie gbl-ctors.h stmp-int-hdrs tsystem.h 1129c87b03e5Sespie $(GCC_FOR_TARGET) $(CRTSTUFF_CFLAGS) $(CRTSTUFF_T_CFLAGS) \ 1130c87b03e5Sespie @inhibit_libc@ -c $(srcdir)/crtstuff.c -DCRT_BEGIN \ 1131c87b03e5Sespie -o $(T)crtbegin$(objext) 1132c87b03e5Sespie 1133c87b03e5Sespie$(T)crtend.o: crtstuff.c $(GCC_PASSES) $(TCONFIG_H) auto-host.h \ 1134c87b03e5Sespie gbl-ctors.h stmp-int-hdrs tsystem.h 1135c87b03e5Sespie $(GCC_FOR_TARGET) $(CRTSTUFF_CFLAGS) $(CRTSTUFF_T_CFLAGS) \ 1136c87b03e5Sespie @inhibit_libc@ -c $(srcdir)/crtstuff.c -DCRT_END \ 1137c87b03e5Sespie -o $(T)crtend$(objext) 1138c87b03e5Sespie 1139c87b03e5Sespie# These are versions of crtbegin and crtend for shared libraries. 1140c87b03e5Sespie$(T)crtbeginS.o: crtstuff.c $(GCC_PASSES) $(TCONFIG_H) auto-host.h \ 1141c87b03e5Sespie gbl-ctors.h stmp-int-hdrs tsystem.h 1142c87b03e5Sespie $(GCC_FOR_TARGET) $(CRTSTUFF_CFLAGS) $(CRTSTUFF_T_CFLAGS_S) \ 1143c87b03e5Sespie @inhibit_libc@ -c $(srcdir)/crtstuff.c -DCRT_BEGIN -DCRTSTUFFS_O \ 1144c87b03e5Sespie -o $(T)crtbeginS$(objext) 1145c87b03e5Sespie 1146c87b03e5Sespie$(T)crtendS.o: crtstuff.c $(GCC_PASSES) $(TCONFIG_H) auto-host.h \ 1147c87b03e5Sespie gbl-ctors.h stmp-int-hdrs tsystem.h 1148c87b03e5Sespie $(GCC_FOR_TARGET) $(CRTSTUFF_CFLAGS) $(CRTSTUFF_T_CFLAGS_S) \ 1149c87b03e5Sespie @inhibit_libc@ -c $(srcdir)/crtstuff.c -DCRT_END -DCRTSTUFFS_O \ 1150c87b03e5Sespie -o $(T)crtendS$(objext) 1151c87b03e5Sespie 1152c87b03e5Sespie# This is a version of crtbegin for -static links. 1153c87b03e5Sespie$(T)crtbeginT.o: crtstuff.c $(GCC_PASSES) $(TCONFIG_H) auto-host.h \ 1154c87b03e5Sespie gbl-ctors.h stmp-int-hdrs tsystem.h 1155c87b03e5Sespie $(GCC_FOR_TARGET) $(CRTSTUFF_CFLAGS) $(CRTSTUFF_T_CFLAGS) \ 1156c87b03e5Sespie @inhibit_libc@ -c $(srcdir)/crtstuff.c -DCRT_BEGIN -DCRTSTUFFT_O \ 1157c87b03e5Sespie -o $(T)crtbeginT$(objext) 1158c87b03e5Sespie 1159c87b03e5Sespie# Compile the start modules crt0.o and mcrt0.o that are linked with 1160c87b03e5Sespie# every program 1161c87b03e5Sespiecrt0.o: s-crt0 ; @true 1162c87b03e5Sespiemcrt0.o: s-crt0; @true 1163c87b03e5Sespie 1164c87b03e5Sespies-crt0: $(CRT0_S) $(MCRT0_S) $(GCC_PASSES) $(CONFIG_H) 1165c87b03e5Sespie $(GCC_FOR_TARGET) $(GCC_CFLAGS) $(CRT0STUFF_T_CFLAGS) \ 1166c87b03e5Sespie -o crt0.o -c $(CRT0_S) 1167c87b03e5Sespie $(GCC_FOR_TARGET) $(GCC_CFLAGS) $(CRT0STUFF_T_CFLAGS) \ 1168c87b03e5Sespie -o mcrt0.o -c $(MCRT0_S) 1169c87b03e5Sespie $(STAMP) s-crt0 1170c87b03e5Sespie# 1171c87b03e5Sespie# Compiling object files from source files. 1172c87b03e5Sespie 1173c87b03e5Sespie# Note that dependencies on obstack.h are not written 1174c87b03e5Sespie# because that file is not part of GCC. 1175c87b03e5Sespie 1176c87b03e5Sespie# C language specific files. 1177c87b03e5Sespie 1178c87b03e5Sespiec-errors.o: c-errors.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(C_TREE_H) flags.h \ 1179c87b03e5Sespie diagnostic.h $(TM_P_H) 1180f092f567Sespiec-parse.o : c-parse.c $(CONFIG_H) $(TREE_H) $(GGC_H) intl.h \ 1181c87b03e5Sespie $(C_TREE_H) input.h flags.h $(SYSTEM_H) toplev.h output.h $(CPPLIB_H) \ 1182c87b03e5Sespie gt-c-parse.h 1183c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \ 1184f092f567Sespie -c c-parse.c $(OUTPUT_OPTION) 1185c87b03e5Sespie 1186f092f567Sespiec-parse.c: c-parse.y 1187c87b03e5Sespie if $(BISON) $(BISONFLAGS) -o c-p$$$$.c c-parse.y; then \ 1188c87b03e5Sespie test -f c-p$$$$.output && mv -f c-p$$$$.output c-parse.output ; \ 1189c87b03e5Sespie mv -f c-p$$$$.c c-parse.c ; \ 1190c87b03e5Sespie else \ 1191c87b03e5Sespie rm -f c-p$$$$.* ; \ 1192c87b03e5Sespie false ; \ 1193c87b03e5Sespie fi 1194c87b03e5Sespie 1195f092f567Sespiec-parse.y: $(srcdir)/c-parse.in 1196c87b03e5Sespie echo '/*WARNING: This file is automatically generated!*/' >tmp-c-parse.y 1197c87b03e5Sespie sed -e "/^ifobjc$$/,/^end ifobjc$$/d" \ 1198c87b03e5Sespie -e "/^ifc$$/d" -e "/^end ifc$$/d" \ 1199c87b03e5Sespie $(srcdir)/c-parse.in >>tmp-c-parse.y 1200f092f567Sespie $(SHELL) $(srcdir)/move-if-change tmp-c-parse.y c-parse.y 1201c87b03e5Sespie 1202c87b03e5Sespiec-decl.o : c-decl.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(RTL_H) $(C_TREE_H) \ 1203c87b03e5Sespie $(GGC_H) $(TARGET_H) flags.h function.h output.h $(EXPR_H) \ 1204c87b03e5Sespie debug.h toplev.h intl.h $(TM_P_H) tree-inline.h $(TIMEVAR_H) c-pragma.h \ 1205c87b03e5Sespie gt-c-decl.h libfuncs.h except.h 1206c87b03e5Sespiec-typeck.o : c-typeck.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(C_TREE_H) \ 1207c87b03e5Sespie $(TARGET_H) flags.h intl.h output.h $(EXPR_H) $(RTL_H) toplev.h $(TM_P_H) 1208c87b03e5Sespiec-lang.o : c-lang.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(C_TREE_H) \ 1209c87b03e5Sespie $(GGC_H) langhooks.h $(LANGHOOKS_DEF_H) c-common.h gtype-c.h 1210c87b03e5Sespiec-lex.o : c-lex.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(RTL_H) \ 1211c87b03e5Sespie debug.h $(C_TREE_H) c-common.h real.h \ 1212c87b03e5Sespie c-pragma.h input.h intl.h flags.h toplev.h output.h \ 1213c87b03e5Sespie mbchar.h $(CPPLIB_H) $(EXPR_H) $(TM_P_H) 1214c87b03e5Sespiec-objc-common.o : c-objc-common.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) \ 1215c87b03e5Sespie $(C_TREE_H) $(RTL_H) insn-config.h integrate.h $(EXPR_H) $(C_TREE_H) \ 1216c87b03e5Sespie flags.h toplev.h tree-inline.h diagnostic.h integrate.h $(VARRAY_H) \ 1217c87b03e5Sespie langhooks.h $(GGC_H) gt-c-objc-common.h $(TARGET_H) 1218c87b03e5Sespiec-aux-info.o : c-aux-info.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(C_TREE_H) \ 1219c87b03e5Sespie flags.h toplev.h 1220c87b03e5Sespiec-convert.o : c-convert.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) flags.h toplev.h \ 1221c87b03e5Sespie $(C_COMMON_H) 1222c87b03e5Sespiec-pragma.o: c-pragma.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) function.h \ 1223c87b03e5Sespie c-pragma.h toplev.h output.h $(GGC_H) $(TM_P_H) $(C_COMMON_H) gt-c-pragma.h 1224c87b03e5Sespiembchar.o: mbchar.c $(CONFIG_H) $(SYSTEM_H) mbchar.h 1225c87b03e5Sespiegraph.o: graph.c $(CONFIG_H) $(SYSTEM_H) toplev.h flags.h output.h $(RTL_H) \ 1226c87b03e5Sespie function.h hard-reg-set.h $(BASIC_BLOCK_H) graph.h 1227c87b03e5Sespiesbitmap.o: sbitmap.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h hard-reg-set.h \ 1228c87b03e5Sespie $(BASIC_BLOCK_H) 1229c87b03e5Sespie 1230c87b03e5SespieCOLLECT2_OBJS = collect2.o tlink.o intl.o version.o 1231c87b03e5SespieCOLLECT2_LIBS = @COLLECT2_LIBS@ 1232c87b03e5Sespiecollect2$(exeext): $(COLLECT2_OBJS) $(LIBDEPS) 1233c87b03e5Sespie# Don't try modifying collect2 (aka ld) in place--it might be linking this. 1234c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o T$@ \ 1235c87b03e5Sespie $(COLLECT2_OBJS) $(LIBS) $(COLLECT2_LIBS) 1236c87b03e5Sespie mv -f T$@ $@ 1237c87b03e5Sespie 1238c87b03e5Sespiecollect2.o : collect2.c $(CONFIG_H) $(SYSTEM_H) gstab.h intl.h \ 1239c87b03e5Sespie $(OBSTACK_H) $(DEMANGLE_H) collect2.h version.h 1240c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \ 1241c87b03e5Sespie -DTARGET_MACHINE=\"$(target_alias)\" \ 1242c87b03e5Sespie -c $(srcdir)/collect2.c $(OUTPUT_OPTION) 1243c87b03e5Sespie 1244c87b03e5Sespietlink.o: tlink.c $(DEMANGLE_H) $(HASHTAB_H) $(CONFIG_H) $(SYSTEM_H) \ 1245c87b03e5Sespie $(OBSTACK_H) collect2.h intl.h 1246c87b03e5Sespie 1247c87b03e5Sespie# A file used by all variants of C. 1248c87b03e5Sespie 1249c87b03e5Sespiec-common.o : c-common.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(OBSTACK_H) \ 1250c87b03e5Sespie $(C_COMMON_H) flags.h toplev.h output.h c-pragma.h $(RTL_H) $(GGC_H) \ 1251c87b03e5Sespie $(EXPR_H) $(TM_P_H) builtin-types.def builtin-attrs.def $(TARGET_H) \ 1252c87b03e5Sespie diagnostic.h except.h gt-c-common.h real.h langhooks.h c-tree.h 1253c87b03e5Sespiec-pretty-print.o : c-pretty-print.c c-pretty-print.h pretty-print.h \ 1254c87b03e5Sespie $(C_COMMON_H) $(CONFIG_H) $(SYSTEM_H) real.h 1255c87b03e5Sespie 1256c87b03e5Sespiec-opts.o : c-opts.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(C_COMMON_H) \ 1257c87b03e5Sespie c-pragma.h flags.h toplev.h langhooks.h tree-inline.h diagnostic.h \ 1258c87b03e5Sespie intl.h 1259c87b03e5Sespie 1260c87b03e5Sespie# A file used by all variants of C and some other languages. 1261c87b03e5Sespie 1262c87b03e5Sespieattribs.o : attribs.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) flags.h \ 1263c87b03e5Sespie toplev.h output.h c-pragma.h $(RTL_H) $(GGC_H) $(EXPR_H) $(TM_P_H) \ 1264c87b03e5Sespie builtin-types.def $(TARGET_H) langhooks.h 1265c87b03e5Sespie 1266c87b03e5Sespiec-format.o : c-format.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) langhooks.h \ 1267c87b03e5Sespie $(C_COMMON_H) flags.h toplev.h intl.h diagnostic.h 1268c87b03e5Sespie 1269cd3be6e5Savsmc-bounded.o : c-bounded.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) langhooks.h \ 1270cd3be6e5Savsm $(C_COMMON_H) flags.h toplev.h intl.h diagnostic.h 1271cd3be6e5Savsm 1272c87b03e5Sespiec-semantics.o : c-semantics.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(C_TREE_H) \ 1273c87b03e5Sespie flags.h toplev.h output.h c-pragma.h $(RTL_H) $(GGC_H) \ 1274c87b03e5Sespie $(EXPR_H) $(PREDICT_H) 1275c87b03e5Sespie 1276c87b03e5Sespiec-dump.o : c-dump.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(C_TREE_H) tree-dump.h 1277c87b03e5Sespie 1278c87b03e5Sespie# Language-independent files. 1279c87b03e5Sespie 1280c87b03e5SespieDRIVER_DEFINES = \ 1281c87b03e5Sespie -DSTANDARD_STARTFILE_PREFIX=\"$(unlibsubdir)/\" \ 1282c87b03e5Sespie -DSTANDARD_EXEC_PREFIX=\"$(libdir)/gcc-lib/\" \ 1283c87b03e5Sespie -DDEFAULT_TARGET_VERSION=\"$(version)\" \ 1284c87b03e5Sespie -DDEFAULT_TARGET_MACHINE=\"$(target_alias)\" \ 1285c87b03e5Sespie -DSTANDARD_BINDIR_PREFIX=\"$(bindir)/\" \ 1286c87b03e5Sespie -DTOOLDIR_BASE_PREFIX=\"$(unlibsubdir)/../\" \ 128706dc6460Sespie @TARGET_SYSTEM_ROOT_DEFINE@ \ 1288c87b03e5Sespie $(VALGRIND_DRIVER_DEFINES) \ 1289c87b03e5Sespie `test "X$${SHLIB_LINK}" = "X" || test "@enable_shared@" != "yes" || echo "-DENABLE_SHARED_LIBGCC"` \ 1290c87b03e5Sespie `test "X$${SHLIB_MULTILIB}" = "X" || echo "-DNO_SHARED_LIBGCC_MULTILIB"` 1291c87b03e5Sespie 1292c87b03e5Sespiegcc.o: gcc.c $(CONFIG_H) $(SYSTEM_H) intl.h multilib.h \ 1293c87b03e5Sespie Makefile $(lang_specs_files) specs.h prefix.h $(GCC_H) 1294c87b03e5Sespie (SHLIB_LINK='$(SHLIB_LINK)' \ 1295c87b03e5Sespie SHLIB_MULTILIB='$(SHLIB_MULTILIB)'; \ 1296c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \ 1297c87b03e5Sespie $(DRIVER_DEFINES) \ 1298c87b03e5Sespie -c $(srcdir)/gcc.c $(OUTPUT_OPTION)) 1299c87b03e5Sespie 1300c87b03e5Sespiegccspec.o: gccspec.c $(CONFIG_H) $(SYSTEM_H) $(GCC_H) 1301c87b03e5Sespie (SHLIB_LINK='$(SHLIB_LINK)' \ 1302c87b03e5Sespie SHLIB_MULTILIB='$(SHLIB_MULTILIB)'; \ 1303c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \ 1304c87b03e5Sespie $(DRIVER_DEFINES) \ 1305c87b03e5Sespie -c $(srcdir)/gccspec.c $(OUTPUT_OPTION)) 1306c87b03e5Sespie 1307c87b03e5Sespiecppspec.o: cppspec.c $(CONFIG_H) $(SYSTEM_H) $(GCC_H) 1308c87b03e5Sespie 1309c87b03e5Sespietree-check.h: s-check ; @true 1310c87b03e5Sespies-check : gencheck$(build_exeext) $(srcdir)/move-if-change 1311c87b03e5Sespie $(RUN_GEN) ./gencheck$(build_exeext) > tmp-check.h 1312c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-check.h tree-check.h 1313c87b03e5Sespie $(STAMP) s-check 1314c87b03e5Sespie 1315c87b03e5Sespiegencheck$(build_exeext) : gencheck.o $(HOST_LIBDEPS) 1316c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 1317c87b03e5Sespie gencheck.o $(HOST_LIBS) 1318c87b03e5Sespie 1319c87b03e5Sespiegencheck.o : gencheck.c gencheck.h tree.def $(HCONFIG_H) $(SYSTEM_H) \ 1320c87b03e5Sespie $(lang_tree_files) 1321c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) \ 1322c87b03e5Sespie $(srcdir)/gencheck.c $(OUTPUT_OPTION) 1323c87b03e5Sespie 1324c87b03e5Sespiegencheck.h : s-gencheck ; @true 1325c87b03e5Sespies-gencheck : Makefile 1326c87b03e5Sespie ltf="$(lang_tree_files)"; for f in $$ltf; do \ 1327c87b03e5Sespie echo "#include \"$$f\""; \ 1328c87b03e5Sespie done | sed 's|$(srcdir)/||' > tmp-gencheck.h 1329c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-gencheck.h gencheck.h 1330c87b03e5Sespie $(STAMP) s-gencheck 1331c87b03e5Sespie 1332c87b03e5Sespieoptions.h : s-options ; @true 1333c87b03e5Sespies-options : Makefile 1334c87b03e5Sespie lof="$(lang_options_files)"; for f in $$lof; do \ 1335c87b03e5Sespie echo "#include \"$$f\""; \ 1336c87b03e5Sespie done | sed 's|$(srcdir)/||' > tmp-options.h 1337c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-options.h options.h 1338c87b03e5Sespie $(STAMP) s-options 1339c87b03e5Sespie 1340c87b03e5Sespiespecs.h : s-specs ; @true 1341c87b03e5Sespies-specs : Makefile 1342c87b03e5Sespie lsf="$(lang_specs_files)"; for f in $$lsf; do \ 1343c87b03e5Sespie echo "#include \"$$f\""; \ 1344c87b03e5Sespie done | sed 's|$(srcdir)/||' > tmp-specs.h 1345c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-specs.h specs.h 1346c87b03e5Sespie $(STAMP) s-specs 1347c87b03e5Sespie 1348c87b03e5Sespiedumpvers: dumpvers.c 1349c87b03e5Sespie 1350c87b03e5Sespieversion.o: version.c version.h 1351c87b03e5Sespie 1352c87b03e5Sespiegtype-desc.o: gtype-desc.c $(CONFIG_H) $(SYSTEM_H) varray.h $(HASHTAB_H) \ 1353c87b03e5Sespie $(TREE_H) $(RTL_H) function.h insn-config.h $(EXPR_H) $(OPTABS_H) \ 1354c87b03e5Sespie libfuncs.h debug.h $(GGC_H) bitmap.h $(BASIC_BLOCK_H) hard-reg-set.h \ 1355c87b03e5Sespie ssa.h cselib.h insn-addr.h 1356c87b03e5Sespie 1357c87b03e5Sespieggc-common.o: ggc-common.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) \ 1358c87b03e5Sespie flags.h $(GGC_H) varray.h $(HASHTAB_H) $(TM_P_H) langhooks.h \ 1359c87b03e5Sespie $(PARAMS_H) 1360c87b03e5Sespie 1361c87b03e5Sespieggc-simple.o: ggc-simple.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h \ 1362c87b03e5Sespie $(GGC_H) varray.h $(TIMEVAR_H) $(TM_P_H) $(PARAMS_H) 1363c87b03e5Sespie 1364c87b03e5Sespieggc-page.o: ggc-page.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h \ 1365c87b03e5Sespie toplev.h $(GGC_H) $(TIMEVAR_H) $(TM_P_H) 1366c87b03e5Sespie 1367c87b03e5Sespiestringpool.o: stringpool.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(OBSTACK_H) \ 1368c87b03e5Sespie flags.h toplev.h $(GGC_H) 1369c87b03e5Sespie 1370c87b03e5Sespiehashtable.o: hashtable.c hashtable.h $(CONFIG_H) $(SYSTEM_H) $(OBSTACK_H) 1371c87b03e5Sespie 1372c87b03e5Sespieline-map.o: line-map.c line-map.h intl.h $(CONFIG_H) $(SYSTEM_H) 1373c87b03e5Sespie 1374c87b03e5Sespieggc-none.o: ggc-none.c $(GCONFIG_H) $(SYSTEM_H) $(GGC_H) 1375c87b03e5Sespie $(CC) -c $(ALL_CFLAGS) -DGENERATOR_FILE $(ALL_CPPFLAGS) $(INCLUDES) $< $(OUTPUT_OPTION) 1376c87b03e5Sespie 1377c87b03e5Sespieprefix.o: prefix.c $(CONFIG_H) $(SYSTEM_H) Makefile prefix.h 1378c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \ 1379c87b03e5Sespie -DPREFIX=\"$(prefix)\" \ 1380c87b03e5Sespie -c $(srcdir)/prefix.c $(OUTPUT_OPTION) 1381c87b03e5Sespie 1382c87b03e5Sespieconvert.o: convert.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) flags.h convert.h \ 1383c87b03e5Sespie toplev.h langhooks.h 1384c87b03e5Sespie 1385c87b03e5Sespielanghooks.o : langhooks.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) toplev.h \ 1386c87b03e5Sespie tree-inline.h $(RTL_H) insn-config.h integrate.h langhooks.h \ 1387c87b03e5Sespie $(LANGHOOKS_DEF_H) flags.h 1388c87b03e5Sespietree.o : tree.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) flags.h function.h toplev.h \ 1389c87b03e5Sespie $(GGC_H) $(HASHTAB_H) $(TARGET_H) output.h $(TM_P_H) langhooks.h \ 1390c87b03e5Sespie real.h gt-tree.h 1391c87b03e5Sespietree-dump.o: tree-dump.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(C_TREE_H) \ 1392c87b03e5Sespie flags.h langhooks.h toplev.h output.h c-pragma.h $(RTL_H) $(GGC_H) \ 1393c87b03e5Sespie $(EXPR_H) $(SPLAY_TREE_H) tree-dump.h 1394c87b03e5Sespietree-inline.o : tree-inline.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(RTL_H) \ 1395c87b03e5Sespie expr.h flags.h params.h input.h insn-config.h $(INTEGRATE_H) \ 1396c87b03e5Sespie $(VARRAY_H) $(HASHTAB_H) $(SPLAY_TREE_H) toplev.h langhooks.h \ 1397c87b03e5Sespie $(C_COMMON_H) tree-inline.h 1398c87b03e5Sespieprint-tree.o : print-tree.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(GGC_H) \ 1399c87b03e5Sespie langhooks.h real.h 1400c87b03e5Sespiestor-layout.o : stor-layout.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) flags.h \ 1401c87b03e5Sespie function.h $(EXPR_H) $(RTL_H) toplev.h $(GGC_H) $(TM_P_H) $(TARGET_H) \ 1402c87b03e5Sespie langhooks.h 1403c87b03e5Sespiefold-const.o : fold-const.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) flags.h real.h \ 1404c87b03e5Sespie toplev.h $(HASHTAB_H) $(EXPR_H) $(RTL_H) $(GGC_H) $(TM_P_H) langhooks.h 1405c87b03e5Sespiediagnostic.o : diagnostic.c diagnostic.h real.h diagnostic.def \ 1406c87b03e5Sespie $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(TM_P_H) flags.h $(GGC_H) \ 1407c87b03e5Sespie input.h toplev.h intl.h langhooks.h $(LANGHOOKS_DEF_H) 1408c87b03e5Sespietoplev.o : toplev.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(RTL_H) function.h \ 1409c87b03e5Sespie flags.h xcoffout.h input.h $(INSN_ATTR_H) output.h diagnostic.h \ 1410c87b03e5Sespie debug.h insn-config.h intl.h $(RECOG_H) Makefile toplev.h \ 1411c87b03e5Sespie dwarf2out.h sdbout.h dbxout.h $(EXPR_H) hard-reg-set.h $(BASIC_BLOCK_H) \ 1412c87b03e5Sespie graph.h $(LOOP_H) except.h $(REGS_H) $(TIMEVAR_H) $(lang_options_files) \ 1413c87b03e5Sespie ssa.h $(PARAMS_H) $(TM_P_H) reload.h dwarf2asm.h $(TARGET_H) \ 1414c87b03e5Sespie langhooks.h insn-flags.h options.h cfglayout.h real.h 1415c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \ 14165982dd4aSetoh -DSTACK_PROTECTOR -DTARGET_NAME=\"$(target_alias)\" \ 1417c87b03e5Sespie -c $(srcdir)/toplev.c $(OUTPUT_OPTION) 1418c87b03e5Sespiemain.o : main.c $(CONFIG_H) $(SYSTEM_H) toplev.h 1419c87b03e5Sespie 1420c87b03e5Sespiertl-error.o: rtl-error.c system.h $(RTL_H) $(INSN_ATTR_H) insn-config.h \ 1421c87b03e5Sespie input.h toplev.h intl.h diagnostic.h $(CONFIG_H) 1422c87b03e5Sespie 1423c87b03e5Sespiertl.o : rtl.c $(GCONFIG_H) $(SYSTEM_H) $(RTL_H) real.h $(GGC_H) errors.h 1424c87b03e5Sespie $(CC) -c $(ALL_CFLAGS) -DGENERATOR_FILE $(ALL_CPPFLAGS) $(INCLUDES) $< $(OUTPUT_OPTION) 1425c87b03e5Sespie 1426c87b03e5Sespieprint-rtl.o : print-rtl.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) \ 1427c87b03e5Sespie hard-reg-set.h $(BASIC_BLOCK_H) real.h 1428c87b03e5Sespiertlanal.o : rtlanal.c $(CONFIG_H) $(SYSTEM_H) toplev.h $(RTL_H) \ 1429c87b03e5Sespie hard-reg-set.h $(TM_P_H) insn-config.h $(RECOG_H) real.h flags.h 1430c87b03e5Sespie 1431c87b03e5Sespieerrors.o : errors.c $(GCONFIG_H) $(SYSTEM_H) errors.h 1432c87b03e5Sespie $(CC) -c $(ALL_CFLAGS) -DGENERATOR_FILE $(ALL_CPPFLAGS) $(INCLUDES) $< $(OUTPUT_OPTION) 1433c87b03e5Sespie 1434c87b03e5Sespievarasm.o : varasm.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(RTL_H) flags.h \ 1435c87b03e5Sespie function.h $(EXPR_H) hard-reg-set.h $(REGS_H) \ 1436c87b03e5Sespie output.h c-pragma.h toplev.h xcoffout.h debug.h $(GGC_H) $(TM_P_H) \ 1437c87b03e5Sespie $(HASHTAB_H) $(TARGET_H) langhooks.h gt-varasm.h real.h 1438c87b03e5Sespiefunction.o : function.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h \ 1439c87b03e5Sespie function.h $(EXPR_H) libfuncs.h $(REGS_H) hard-reg-set.h \ 1440c87b03e5Sespie insn-config.h $(RECOG_H) output.h toplev.h except.h $(HASHTAB_H) $(GGC_H) \ 1441c87b03e5Sespie $(TM_P_H) langhooks.h gt-function.h 1442c87b03e5Sespiestmt.o : stmt.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h function.h \ 1443c87b03e5Sespie insn-config.h hard-reg-set.h $(EXPR_H) libfuncs.h except.h \ 1444c87b03e5Sespie $(LOOP_H) $(RECOG_H) toplev.h output.h varray.h $(GGC_H) $(TM_P_H) \ 1445c87b03e5Sespie langhooks.h $(PREDICT_H) gt-stmt.h 1446c87b03e5Sespieexcept.o : except.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h \ 1447c87b03e5Sespie except.h function.h $(EXPR_H) libfuncs.h integrate.h langhooks.h \ 1448c87b03e5Sespie insn-config.h hard-reg-set.h $(BASIC_BLOCK_H) output.h \ 1449c87b03e5Sespie dwarf2asm.h dwarf2out.h toplev.h $(HASHTAB_H) intl.h $(GGC_H) \ 1450c87b03e5Sespie gt-except.h 1451c87b03e5Sespieexpr.o : expr.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h function.h \ 1452c87b03e5Sespie $(REGS_H) $(EXPR_H) $(OPTABS_H) libfuncs.h insn-attr.h insn-config.h \ 1453c87b03e5Sespie $(RECOG_H) output.h typeclass.h hard-reg-set.h toplev.h hard-reg-set.h \ 1454c87b03e5Sespie except.h reload.h $(GGC_H) langhooks.h intl.h $(TM_P_H) real.h 1455c87b03e5Sespiebuiltins.o : builtins.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h \ 1456c87b03e5Sespie $(TARGET_H) function.h $(REGS_H) $(EXPR_H) $(OPTABS_H) insn-config.h \ 1457c87b03e5Sespie $(RECOG_H) output.h typeclass.h hard-reg-set.h toplev.h hard-reg-set.h \ 1458c87b03e5Sespie except.h $(TM_P_H) $(PREDICT_H) libfuncs.h real.h langhooks.h 1459c87b03e5Sespiecalls.o : calls.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h \ 1460c87b03e5Sespie $(EXPR_H) langhooks.h $(TARGET_H) \ 1461c87b03e5Sespie libfuncs.h $(REGS_H) toplev.h output.h function.h $(TIMEVAR_H) $(TM_P_H) \ 1462c87b03e5Sespie except.h 1463c87b03e5Sespieexpmed.o : expmed.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h \ 1464c87b03e5Sespie insn-config.h $(EXPR_H) $(OPTABS_H) $(RECOG_H) real.h \ 1465c87b03e5Sespie toplev.h $(TM_P_H) langhooks.h 1466c87b03e5Sespieexplow.o : explow.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h \ 1467c87b03e5Sespie hard-reg-set.h insn-config.h $(EXPR_H) $(OPTABS_H) $(RECOG_H) \ 1468c87b03e5Sespie toplev.h function.h ggc.h $(TM_P_H) gt-explow.h 1469c87b03e5Sespieoptabs.o : optabs.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h \ 1470c87b03e5Sespie insn-config.h $(EXPR_H) $(OPTABS_H) libfuncs.h $(RECOG_H) reload.h \ 1471c87b03e5Sespie toplev.h $(GGC_H) real.h $(TM_P_H) except.h gt-optabs.h $(BASIC_BLOCK_H) 1472c87b03e5Sespiedbxout.o : dbxout.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(RTL_H) flags.h \ 1473c87b03e5Sespie $(REGS_H) debug.h $(TM_P_H) $(TARGET_H) function.h langhooks.h \ 1474c87b03e5Sespie insn-config.h reload.h gstab.h xcoffout.h output.h dbxout.h toplev.h 1475c87b03e5Sespiedebug.o : debug.c debug.h $(CONFIG_H) $(SYSTEM_H) 1476c87b03e5Sespiesdbout.o : sdbout.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(RTL_H) flags.h \ 1477c87b03e5Sespie function.h $(EXPR_H) output.h hard-reg-set.h $(REGS_H) real.h \ 1478c87b03e5Sespie insn-config.h xcoffout.h c-pragma.h ggc.h \ 1479c87b03e5Sespie sdbout.h toplev.h $(TM_P_H) except.h debug.h langhooks.h gt-sdbout.h 1480c87b03e5Sespiedwarfout.o : dwarfout.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(RTL_H) dwarf.h \ 1481c87b03e5Sespie flags.h insn-config.h reload.h output.h toplev.h $(TM_P_H) \ 1482c87b03e5Sespie debug.h langhooks.h 1483c87b03e5Sespiedwarf2out.o : dwarf2out.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(RTL_H) dwarf2.h \ 1484c87b03e5Sespie debug.h flags.h insn-config.h reload.h output.h diagnostic.h real.h \ 1485c87b03e5Sespie hard-reg-set.h $(REGS_H) $(EXPR_H) libfuncs.h toplev.h dwarf2out.h varray.h \ 1486c87b03e5Sespie $(GGC_H) except.h dwarf2asm.h $(TM_P_H) langhooks.h $(HASHTAB_H) gt-dwarf2out.h 1487c87b03e5Sespiedwarf2asm.o : dwarf2asm.c $(CONFIG_H) $(SYSTEM_H) flags.h $(RTL_H) $(TREE_H) \ 1488c87b03e5Sespie output.h dwarf2asm.h $(TM_P_H) $(GGC_H) 1489c87b03e5Sespievmsdbgout.o : vmsdbgout.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(RTL_H) flags.h \ 1490c87b03e5Sespie output.h vmsdbg.h debug.h langhooks.h function.h 1491c87b03e5Sespiexcoffout.o : xcoffout.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) $(RTL_H) xcoffout.h \ 1492c87b03e5Sespie flags.h toplev.h output.h dbxout.h $(GGC_H) $(TARGET_H) 1493c87b03e5Sespieemit-rtl.o : emit-rtl.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h \ 1494c87b03e5Sespie function.h $(REGS_H) insn-config.h $(RECOG_H) real.h $(GGC_H) \ 1495f092f567Sespie $(EXPR_H) $(OBSTACK_H) hard-reg-set.h bitmap.h toplev.h \ 1496c87b03e5Sespie $(HASHTAB_H) $(TM_P_H) debug.h langhooks.h 1497c87b03e5Sespiereal.o : real.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) toplev.h $(TM_P_H) 1498c87b03e5Sespieintegrate.o : integrate.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h \ 1499c87b03e5Sespie debug.h $(INTEGRATE_H) insn-config.h $(EXPR_H) real.h $(REGS_H) \ 1500c87b03e5Sespie intl.h function.h output.h $(RECOG_H) except.h toplev.h $(LOOP_H) \ 1501c87b03e5Sespie $(PARAMS_H) $(TM_P_H) $(TARGET_H) langhooks.h gt-integrate.h 1502c87b03e5Sespiejump.o : jump.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h hard-reg-set.h $(REGS_H) \ 1503c87b03e5Sespie insn-config.h $(RECOG_H) $(EXPR_H) real.h except.h function.h \ 1504c87b03e5Sespie toplev.h $(INSN_ATTR_H) $(TM_P_H) reload.h $(PREDICT_H) 1505c87b03e5Sespie 1506c87b03e5Sespiesimplify-rtx.o : simplify-rtx.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(REGS_H) \ 1507c87b03e5Sespie hard-reg-set.h flags.h real.h insn-config.h $(RECOG_H) $(EXPR_H) toplev.h \ 1508c87b03e5Sespie output.h function.h $(GGC_H) $(OBSTACK_H) $(TM_P_H) $(TREE_H) 1509c87b03e5Sespiecselib.o : cselib.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(REGS_H) \ 1510c87b03e5Sespie hard-reg-set.h flags.h real.h insn-config.h $(RECOG_H) $(EXPR_H) toplev.h \ 1511c87b03e5Sespie output.h function.h cselib.h $(GGC_H) $(TM_P_H) gt-cselib.h 1512c87b03e5Sespiecse.o : cse.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(REGS_H) hard-reg-set.h flags.h \ 1513c87b03e5Sespie real.h insn-config.h $(RECOG_H) $(EXPR_H) toplev.h output.h function.h \ 151406dc6460Sespie $(BASIC_BLOCK_H) $(GGC_H) $(TM_P_H) $(TIMEVAR_H) $(TARGET_H) 1515c87b03e5Sespiegcse.o : gcse.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(REGS_H) hard-reg-set.h \ 1516c87b03e5Sespie flags.h real.h insn-config.h ggc.h $(RECOG_H) $(EXPR_H) $(BASIC_BLOCK_H) \ 1517c87b03e5Sespie function.h output.h toplev.h $(TM_P_H) $(PARAMS_H) except.h gt-gcse.h 1518c87b03e5Sespiesibcall.o : sibcall.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(REGS_H) function.h \ 1519c87b03e5Sespie hard-reg-set.h flags.h insn-config.h $(RECOG_H) $(BASIC_BLOCK_H) 1520c87b03e5Sespieresource.o : resource.c $(CONFIG_H) $(RTL_H) hard-reg-set.h $(SYSTEM_H) \ 1521c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) flags.h output.h resource.h function.h toplev.h \ 1522c87b03e5Sespie $(INSN_ATTR_H) except.h $(PARAMS_H) $(TM_P_H) 1523c87b03e5Sespielcm.o : lcm.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(REGS_H) hard-reg-set.h flags.h \ 1524c87b03e5Sespie real.h insn-config.h $(INSN_ATTR_H) $(RECOG_H) $(EXPR_H) $(BASIC_BLOCK_H) \ 1525c87b03e5Sespie $(TM_P_H) df.h 1526c87b03e5Sespiessa.o : ssa.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(REGS_H) varray.h $(EXPR_H) \ 1527c87b03e5Sespie hard-reg-set.h flags.h function.h real.h insn-config.h $(RECOG_H) \ 1528c87b03e5Sespie $(BASIC_BLOCK_H) output.h ssa.h 1529c87b03e5Sespiessa-dce.o : ssa-dce.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) hard-reg-set.h \ 1530c87b03e5Sespie $(BASIC_BLOCK_H) ssa.h insn-config.h $(RECOG_H) output.h 1531c87b03e5Sespiessa-ccp.o : ssa-ccp.c $(CONFIG_H) system.h $(RTL_H) hard-reg-set.h \ 1532c87b03e5Sespie $(BASIC_BLOCK_H) ssa.h insn-config.h $(RECOG_H) output.h \ 1533c87b03e5Sespie errors.h $(GGC_H) df.h function.h 1534c87b03e5Sespiedf.o : df.c $(CONFIG_H) system.h $(RTL_H) insn-config.h $(RECOG_H) \ 1535c87b03e5Sespie function.h $(REGS_H) $(OBSTACK_H) hard-reg-set.h $(BASIC_BLOCK_H) df.h \ 1536c87b03e5Sespie $(FIBHEAP_H) 1537c87b03e5Sespieconflict.o : conflict.c $(CONFIG_H) $(SYSTEM_H) $(OBSTACK_H) $(HASHTAB_H) \ 1538c87b03e5Sespie $(RTL_H) hard-reg-set.h $(BASIC_BLOCK_H) 1539c87b03e5Sespieprofile.o : profile.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h \ 1540c87b03e5Sespie insn-config.h output.h $(REGS_H) $(EXPR_H) function.h \ 1541c87b03e5Sespie gcov-io.h toplev.h $(GGC_H) hard-reg-set.h $(BASIC_BLOCK_H) $(TARGET_H) \ 1542c87b03e5Sespie langhooks.h profile.h libfuncs.h gt-profile.h 1543c87b03e5Sespieloop.o : loop.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h $(LOOP_H) \ 1544c87b03e5Sespie insn-config.h $(REGS_H) hard-reg-set.h $(RECOG_H) $(EXPR_H) \ 1545c87b03e5Sespie real.h $(PREDICT_H) $(BASIC_BLOCK_H) function.h \ 154606dc6460Sespie toplev.h varray.h except.h cselib.h $(OPTABS_H) $(TM_P_H) $(GGC_H) 1547c87b03e5Sespiedoloop.o : doloop.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h $(LOOP_H) \ 1548c87b03e5Sespie $(EXPR_H) hard-reg-set.h $(BASIC_BLOCK_H) $(TM_P_H) toplev.h 1549c87b03e5Sespieunroll.o : unroll.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) insn-config.h function.h \ 1550c87b03e5Sespie $(INTEGRATE_H) $(REGS_H) $(RECOG_H) flags.h $(EXPR_H) $(LOOP_H) toplev.h \ 1551c87b03e5Sespie hard-reg-set.h varray.h $(BASIC_BLOCK_H) $(TM_P_H) $(PREDICT_H) $(PARAMS_H) 1552c87b03e5Sespieflow.o : flow.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h insn-config.h \ 1553c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h output.h toplev.h $(RECOG_H) \ 1554c87b03e5Sespie function.h except.h $(EXPR_H) ssa.h $(GGC_H) $(TM_P_H) 1555c87b03e5Sespiecfg.o : cfg.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h insn-config.h \ 1556c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h output.h toplev.h $(RECOG_H) \ 1557c87b03e5Sespie function.h except.h $(GGC_H) $(TM_P_H) 1558c87b03e5Sespiecfgrtl.o : cfgrtl.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h insn-config.h \ 1559c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h output.h toplev.h $(RECOG_H) \ 1560c87b03e5Sespie function.h except.h $(GGC_H) $(TM_P_H) insn-config.h 1561c87b03e5Sespiecfganal.o : cfganal.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(BASIC_BLOCK_H) \ 1562c87b03e5Sespie hard-reg-set.h insn-config.h $(RECOG_H) $(GGC_H) $(TM_P_H) 1563c87b03e5Sespiecfgbuild.o : cfgbuild.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h insn-config.h \ 1564c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h output.h toplev.h $(RECOG_H) \ 1565c87b03e5Sespie function.h except.h $(GGC_H) 1566c87b03e5Sespiecfgcleanup.o : cfgcleanup.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TIMEVAR_H)\ 1567c87b03e5Sespie $(BASIC_BLOCK_H) hard-reg-set.h output.h flags.h $(RECOG_H) toplev.h \ 1568c87b03e5Sespie $(GGC_H) insn-config.h cselib.h $(TARGET_H) $(TM_P_H) $(PARAMS_H) 1569c87b03e5Sespiecfgloop.o : cfgloop.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) \ 1570c87b03e5Sespie $(BASIC_BLOCK_H) hard-reg-set.h 1571c87b03e5Sespiedominance.o : dominance.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) hard-reg-set.h \ 1572c87b03e5Sespie $(BASIC_BLOCK_H) et-forest.h 1573c87b03e5Sespieet-forest.o : et-forest.c $(CONFIG_H) $(SYSTEM_H) et-forest.h 1574c87b03e5Sespiecombine.o : combine.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h function.h \ 1575c87b03e5Sespie insn-config.h $(INSN_ATTR_H) $(REGS_H) $(EXPR_H) \ 1576c87b03e5Sespie $(BASIC_BLOCK_H) $(RECOG_H) real.h hard-reg-set.h toplev.h $(TM_P_H) 1577c87b03e5Sespieregclass.o : regclass.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) hard-reg-set.h flags.h \ 1578c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) insn-config.h $(RECOG_H) reload.h real.h \ 1579c87b03e5Sespie toplev.h function.h output.h $(GGC_H) $(TM_P_H) $(EXPR_H) 1580c87b03e5Sespielocal-alloc.o : local-alloc.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h \ 1581c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h insn-config.h $(RECOG_H) \ 1582c87b03e5Sespie output.h function.h $(INSN_ATTR_H) toplev.h except.h $(TM_P_H) 1583c87b03e5Sespiebitmap.o : bitmap.c $(GCONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h \ 1584c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) $(GGC_H) 1585c87b03e5Sespie $(CC) -c $(ALL_CFLAGS) -DGENERATOR_FILE $(ALL_CPPFLAGS) $(INCLUDES) $< $(OUTPUT_OPTION) 1586c87b03e5Sespieglobal.o : global.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h reload.h function.h \ 1587c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h insn-config.h output.h toplev.h \ 1588c87b03e5Sespie $(TM_P_H) 1589c87b03e5Sespievarray.o : varray.c $(CONFIG_H) $(SYSTEM_H) varray.h $(GGC_H) errors.h 1590c87b03e5Sespiera.o : ra.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TM_P_H) insn-config.h \ 1591c87b03e5Sespie $(RECOG_H) integrate.h function.h $(REGS_H) $(OBSTACK_H) hard-reg-set.h \ 1592c87b03e5Sespie $(BASIC_BLOCK_H) df.h expr.h output.h toplev.h flags.h reload.h ra.h 1593c87b03e5Sespiera-build.o : ra-build.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TM_P_H) \ 1594c87b03e5Sespie insn-config.h $(RECOG_H) function.h $(REGS_H) hard-reg-set.h \ 1595c87b03e5Sespie $(BASIC_BLOCK_H) df.h output.h ggc.h ra.h gt-ra-build.h reload.h 1596c87b03e5Sespiera-colorize.o : ra-colorize.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TM_P_H) \ 1597c87b03e5Sespie function.h $(REGS_H) hard-reg-set.h $(BASIC_BLOCK_H) df.h output.h ra.h 1598c87b03e5Sespiera-debug.o : ra-debug.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) insn-config.h \ 1599c87b03e5Sespie $(RECOG_H) function.h hard-reg-set.h $(BASIC_BLOCK_H) df.h output.h ra.h \ 1600c87b03e5Sespie $(TM_P_H) 1601c87b03e5Sespiera-rewrite.o : ra-rewrite.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TM_P_H) \ 1602c87b03e5Sespie function.h $(REGS_H) hard-reg-set.h $(BASIC_BLOCK_H) df.h expr.h \ 1603c87b03e5Sespie output.h except.h ra.h reload.h insn-config.h 1604c87b03e5Sespiereload.o : reload.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h output.h \ 1605c87b03e5Sespie $(EXPR_H) $(OPTABS_H) reload.h $(RECOG_H) hard-reg-set.h insn-config.h \ 1606c87b03e5Sespie $(REGS_H) function.h real.h toplev.h $(TM_P_H) 1607c87b03e5Sespiereload1.o : reload1.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) real.h flags.h \ 1608c87b03e5Sespie $(EXPR_H) $(OPTABS_H) reload.h $(REGS_H) hard-reg-set.h insn-config.h \ 1609c87b03e5Sespie $(BASIC_BLOCK_H) $(RECOG_H) output.h function.h toplev.h cselib.h $(TM_P_H) \ 1610c87b03e5Sespie except.h $(TREE_H) 1611c87b03e5Sespiecaller-save.o : caller-save.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h \ 1612c87b03e5Sespie $(REGS_H) hard-reg-set.h insn-config.h $(BASIC_BLOCK_H) function.h \ 1613c87b03e5Sespie $(RECOG_H) reload.h $(EXPR_H) toplev.h $(TM_P_H) 1614c87b03e5Sespiereorg.o : reorg.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) conditions.h hard-reg-set.h \ 1615c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) insn-config.h $(INSN_ATTR_H) except.h \ 1616c87b03e5Sespie $(RECOG_H) function.h flags.h output.h $(EXPR_H) toplev.h $(PARAMS_H) $(TM_P_H) 1617c87b03e5Sespiealias.o : alias.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) flags.h hard-reg-set.h \ 1618c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) toplev.h output.h $(EXPR_H) \ 1619c87b03e5Sespie $(GGC_H) function.h cselib.h $(TREE_H) $(TM_P_H) langhooks.h $(TARGET_H) \ 1620c87b03e5Sespie gt-alias.h 1621c87b03e5Sespieregmove.o : regmove.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) insn-config.h \ 1622c87b03e5Sespie $(RECOG_H) output.h $(REGS_H) hard-reg-set.h flags.h function.h \ 1623c87b03e5Sespie $(EXPR_H) $(BASIC_BLOCK_H) toplev.h $(TM_P_H) except.h reload.h 1624c87b03e5Sespiehaifa-sched.o : haifa-sched.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) sched-int.h \ 1625c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h flags.h insn-config.h function.h \ 1626c87b03e5Sespie $(INSN_ATTR_H) toplev.h $(RECOG_H) except.h $(TM_P_H) $(TARGET_H) 1627c87b03e5Sespiesched-deps.o : sched-deps.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) sched-int.h \ 1628c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h flags.h insn-config.h function.h \ 1629c87b03e5Sespie $(INSN_ATTR_H) toplev.h $(RECOG_H) except.h cselib.h $(PARAMS_H) $(TM_P_H) 1630c87b03e5Sespiesched-rgn.o : sched-rgn.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) sched-int.h \ 1631c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h flags.h insn-config.h function.h \ 1632c87b03e5Sespie $(INSN_ATTR_H) toplev.h $(RECOG_H) except.h $(TM_P_H) $(TARGET_H) 1633c87b03e5Sespiesched-ebb.o : sched-ebb.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) sched-int.h \ 1634c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h flags.h insn-config.h function.h \ 1635c87b03e5Sespie $(INSN_ATTR_H) toplev.h $(RECOG_H) except.h $(TM_P_H) 1636c87b03e5Sespiesched-vis.o : sched-vis.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) sched-int.h \ 1637c87b03e5Sespie hard-reg-set.h $(BASIC_BLOCK_H) $(INSN_ATTR_H) $(REGS_H) $(TM_P_H) \ 1638c87b03e5Sespie $(TARGET_H) real.h 1639c87b03e5Sespiefinal.o : final.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h intl.h \ 1640c87b03e5Sespie $(REGS_H) $(RECOG_H) conditions.h insn-config.h $(INSN_ATTR_H) function.h \ 1641c87b03e5Sespie real.h output.h hard-reg-set.h except.h debug.h xcoffout.h profile.h \ 1642c87b03e5Sespie toplev.h reload.h dwarf2out.h $(BASIC_BLOCK_H) $(TM_P_H) $(TARGET_H) $(EXPR_H) 1643c87b03e5Sespierecog.o : recog.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) function.h $(BASIC_BLOCK_H) \ 1644c87b03e5Sespie $(REGS_H) $(RECOG_H) $(EXPR_H) hard-reg-set.h flags.h insn-config.h \ 1645c87b03e5Sespie $(INSN_ATTR_H) real.h toplev.h output.h reload.h $(TM_P_H) 1646c87b03e5Sespiereg-stack.o : reg-stack.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) $(RECOG_H) \ 1647c87b03e5Sespie $(REGS_H) hard-reg-set.h flags.h insn-config.h toplev.h reload.h \ 1648c87b03e5Sespie varray.h function.h $(TM_P_H) $(GGC_H) gt-reg-stack.h 1649c87b03e5Sespiepredict.o: predict.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) flags.h \ 1650c87b03e5Sespie insn-config.h $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h output.h toplev.h \ 1651c87b03e5Sespie $(RECOG_H) function.h except.h $(EXPR_H) $(TM_P_H) $(PREDICT_H) real.h \ 1652c87b03e5Sespie $(PARAMS_H) $(TARGET_H) 1653c87b03e5Sespielists.o: lists.c $(CONFIG_H) $(SYSTEM_H) toplev.h $(RTL_H) $(GGC_H) 1654c87b03e5Sespiebb-reorder.o : bb-reorder.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) \ 1655c87b03e5Sespie flags.h $(BASIC_BLOCK_H) hard-reg-set.h output.h cfglayout.h $(TARGET_H) 1656c87b03e5Sespietracer.o : tracer.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) \ 1657c87b03e5Sespie $(BASIC_BLOCK_H) hard-reg-set.h output.h cfglayout.h flags.h \ 1658c87b03e5Sespie $(PARAMS_H) profile.h 1659c87b03e5Sespiecfglayout.o : cfglayout.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(TREE_H) \ 1660c87b03e5Sespie insn-config.h $(BASIC_BLOCK_H) hard-reg-set.h output.h function.h \ 1661c87b03e5Sespie cfglayout.h 1662c87b03e5Sespietimevar.o : timevar.c $(CONFIG_H) $(SYSTEM_H) $(TIMEVAR_H) flags.h intl.h 1663c87b03e5Sespieregrename.o : regrename.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) insn-config.h \ 1664c87b03e5Sespie $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h output.h $(RECOG_H) function.h \ 1665c87b03e5Sespie resource.h $(OBSTACK_H) flags.h $(TM_P_H) 1666c87b03e5Sespieifcvt.o : ifcvt.c $(CONFIG_H) $(SYSTEM_H) $(RTL_H) $(REGS_H) toplev.h \ 1667c87b03e5Sespie flags.h insn-config.h function.h $(RECOG_H) $(BASIC_BLOCK_H) $(EXPR_H) \ 1668c87b03e5Sespie output.h except.h $(TM_P_H) real.h 1669c87b03e5Sespieparams.o : params.c $(CONFIG_H) $(SYSTEM_H) $(PARAMS_H) toplev.h 1670c87b03e5Sespiehooks.o: hooks.c $(CONFIG_H) $(SYSTEM_H) $(HOOKS_H) 1671*b6e06dcdSespieprotector.o: protector.c $(CONFIG_H) insn-config.h flags.h $(RTL_H) \ 1672*b6e06dcdSespie $(TREE_H) $(EXPR_H) $(REGS_H) $(RECOG_H) $(INSN_ATTR_H) \ 1673*b6e06dcdSespie $(C_TREE_H) real.h output.h except.h 1674*b6e06dcdSespie 1675c87b03e5Sespie 1676c87b03e5Sespie$(out_object_file): $(out_file) $(CONFIG_H) $(TREE_H) $(GGC_H) \ 1677c87b03e5Sespie $(RTL_H) $(REGS_H) hard-reg-set.h real.h insn-config.h conditions.h \ 1678c87b03e5Sespie output.h $(INSN_ATTR_H) $(SYSTEM_H) toplev.h $(TARGET_H) libfuncs.h \ 1679c87b03e5Sespie $(TARGET_DEF_H) function.h sched-int.h $(TM_P_H) $(EXPR_H) $(OPTABS_H) \ 1680c87b03e5Sespie langhooks.h 1681c87b03e5Sespie $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \ 1682c87b03e5Sespie $(out_file) $(OUTPUT_OPTION) 1683c87b03e5Sespie 1684c87b03e5Sespie# Build auxiliary files that support ecoff format. 1685c87b03e5Sespiemips-tfile: mips-tfile.o version.o $(LIBDEPS) 1686c87b03e5Sespie $(CC) $(CFLAGS) $(LDFLAGS) -o $@ mips-tfile.o version.o $(LIBS) 1687c87b03e5Sespie 1688c87b03e5Sespiemips-tfile.o : mips-tfile.c $(CONFIG_H) $(RTL_H) $(SYSTEM_H) version.h 1689c87b03e5Sespie 1690c87b03e5Sespiemips-tdump: mips-tdump.o version.o $(LIBDEPS) 1691c87b03e5Sespie $(CC) $(CFLAGS) $(LDFLAGS) -o $@ mips-tdump.o version.o $(LIBS) 1692c87b03e5Sespie 1693c87b03e5Sespiemips-tdump.o : mips-tdump.c $(CONFIG_H) $(RTL_H) $(SYSTEM_H) 1694c87b03e5Sespie 1695c87b03e5Sespie# 1696c87b03e5Sespie# Generate header and source files from the machine description, 1697c87b03e5Sespie# and compile them. 1698c87b03e5Sespie 1699c87b03e5Sespie.PRECIOUS: insn-config.h insn-flags.h insn-codes.h insn-constants.h \ 1700c87b03e5Sespie insn-emit.c insn-recog.c insn-extract.c insn-output.c insn-peep.c \ 1701c87b03e5Sespie insn-attr.h insn-attrtab.c 1702c87b03e5Sespie 1703c87b03e5Sespie# The following pair of rules has this effect: 1704c87b03e5Sespie# genconfig is run only if the md has changed since genconfig was last run; 1705c87b03e5Sespie# but the file insn-config.h is touched only when its contents actually change. 1706c87b03e5Sespie 1707c87b03e5Sespie# Each of the other insn-* files is handled by a similar pair of rules. 1708c87b03e5Sespie 1709c87b03e5Sespie# This causes an anomaly in the results of make -n 1710c87b03e5Sespie# because insn-* is older than s-* 1711c87b03e5Sespie# and thus make -n thinks that insn-* will be updated 1712c87b03e5Sespie# and force recompilation of things that depend on it. 1713c87b03e5Sespie# We use move-if-change precisely to avoid such recompilation. 1714c87b03e5Sespie# But there is no way to teach make -n that it will be avoided. 1715c87b03e5Sespie 1716c87b03e5Sespie# Each of the insn-*.[ch] rules has a semicolon at the end, 1717c87b03e5Sespie# for otherwise the system Make on SunOS 4.1 never tries 1718c87b03e5Sespie# to recompile insn-*.o. To avoid problems and extra noise from 1719c87b03e5Sespie# versions of make which don't like empty commands (nothing after the 1720c87b03e5Sespie# trailing `;'), we call true for each. 1721c87b03e5Sespie 1722c87b03e5Sespieinsn-config.h: s-config ; @true 1723c87b03e5Sespies-config : $(md_file) genconfig$(build_exeext) $(srcdir)/move-if-change 1724c87b03e5Sespie $(RUN_GEN) ./genconfig$(build_exeext) $(md_file) > tmp-config.h 1725c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-config.h insn-config.h 1726c87b03e5Sespie $(STAMP) s-config 1727c87b03e5Sespie 1728c87b03e5Sespieinsn-conditions.c: s-conditions ; @true 1729c87b03e5Sespies-conditions : $(md_file) genconditions$(build_exeext) $(srcdir)/move-if-change 1730c87b03e5Sespie $(RUN_GEN) ./genconditions$(build_exeext) $(md_file) > tmp-conditions.c 1731c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-conditions.c insn-conditions.c 1732c87b03e5Sespie $(STAMP) s-conditions 1733c87b03e5Sespie 1734c87b03e5Sespieinsn-conditions.o : insn-conditions.c $(GCONFIG_H) $(SYSTEM_H) $(RTL_H) \ 1735c87b03e5Sespie $(TM_P_H) $(REGS_H) function.h $(RECOG_H) real.h output.h flags.h \ 1736c87b03e5Sespie hard-reg-set.h resource.h toplev.h reload.h gensupport.h insn-constants.h 1737c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) insn-conditions.c 1738c87b03e5Sespie 1739c87b03e5Sespiedummy-conditions.o : dummy-conditions.c $(HCONFIG_H) $(SYSTEM_H) gensupport.h 1740c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) \ 1741c87b03e5Sespie $(srcdir)/dummy-conditions.c $(OUTPUT_OPTION) 1742c87b03e5Sespie 1743c87b03e5Sespieinsn-flags.h: s-flags ; @true 1744c87b03e5Sespies-flags : $(md_file) genflags$(build_exeext) $(srcdir)/move-if-change 1745c87b03e5Sespie $(RUN_GEN) ./genflags$(build_exeext) $(md_file) > tmp-flags.h 1746c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-flags.h insn-flags.h 1747c87b03e5Sespie $(STAMP) s-flags 1748c87b03e5Sespie 1749c87b03e5Sespieinsn-codes.h: s-codes ; @true 1750c87b03e5Sespies-codes : $(md_file) gencodes$(build_exeext) $(srcdir)/move-if-change 1751c87b03e5Sespie $(RUN_GEN) ./gencodes$(build_exeext) $(md_file) > tmp-codes.h 1752c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-codes.h insn-codes.h 1753c87b03e5Sespie $(STAMP) s-codes 1754c87b03e5Sespie 1755c87b03e5Sespieinsn-constants.h: s-constants ; @true 1756c87b03e5Sespies-constants : $(md_file) genconstants$(build_exeext) $(srcdir)/move-if-change 1757c87b03e5Sespie $(RUN_GEN) ./genconstants$(build_exeext) $(md_file) > tmp-constants.h 1758c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-constants.h insn-constants.h 1759c87b03e5Sespie $(STAMP) s-constants 1760c87b03e5Sespie 1761c87b03e5Sespieinsn-emit.o : insn-emit.c $(CONFIG_H) $(RTL_H) $(EXPR_H) real.h output.h \ 1762c87b03e5Sespie insn-config.h $(OPTABS_H) $(SYSTEM_H) reload.h $(RECOG_H) toplev.h \ 1763c87b03e5Sespie function.h flags.h hard-reg-set.h resource.h $(TM_P_H) 1764c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-emit.c \ 1765c87b03e5Sespie $(OUTPUT_OPTION) 1766c87b03e5Sespie 1767c87b03e5Sespieinsn-emit.c: s-emit ; @true 1768c87b03e5Sespies-emit : $(md_file) genemit$(build_exeext) $(srcdir)/move-if-change 1769c87b03e5Sespie $(RUN_GEN) ./genemit$(build_exeext) $(md_file) > tmp-emit.c 1770c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-emit.c insn-emit.c 1771c87b03e5Sespie $(STAMP) s-emit 1772c87b03e5Sespie 1773c87b03e5Sespieinsn-recog.o : insn-recog.c $(CONFIG_H) $(RTL_H) insn-config.h $(RECOG_H) \ 1774c87b03e5Sespie real.h output.h flags.h $(SYSTEM_H) function.h hard-reg-set.h resource.h \ 1775c87b03e5Sespie $(TM_P_H) toplev.h reload.h 1776c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-recog.c \ 1777c87b03e5Sespie $(OUTPUT_OPTION) 1778c87b03e5Sespie 1779c87b03e5Sespieinsn-recog.c: s-recog ; @true 1780c87b03e5Sespies-recog : $(md_file) genrecog$(build_exeext) $(srcdir)/move-if-change 1781c87b03e5Sespie $(RUN_GEN) ./genrecog$(build_exeext) $(md_file) > tmp-recog.c 1782c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-recog.c insn-recog.c 1783c87b03e5Sespie $(STAMP) s-recog 1784c87b03e5Sespie 1785c87b03e5Sespieinsn-opinit.o : insn-opinit.c $(CONFIG_H) $(RTL_H) \ 1786c87b03e5Sespie insn-config.h flags.h $(RECOG_H) $(EXPR_H) $(OPTABS_H) reload.h $(SYSTEM_H) 1787c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-opinit.c \ 1788c87b03e5Sespie $(OUTPUT_OPTION) 1789c87b03e5Sespie 1790c87b03e5Sespieinsn-opinit.c: s-opinit ; @true 1791c87b03e5Sespies-opinit : $(md_file) genopinit$(build_exeext) $(srcdir)/move-if-change 1792c87b03e5Sespie $(RUN_GEN) ./genopinit$(build_exeext) $(md_file) > tmp-opinit.c 1793c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-opinit.c insn-opinit.c 1794c87b03e5Sespie $(STAMP) s-opinit 1795c87b03e5Sespie 1796c87b03e5Sespieinsn-extract.o : insn-extract.c $(CONFIG_H) $(RTL_H) $(SYSTEM_H) toplev.h \ 1797c87b03e5Sespie insn-config.h $(RECOG_H) 1798c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-extract.c \ 1799c87b03e5Sespie $(OUTPUT_OPTION) 1800c87b03e5Sespie 1801c87b03e5Sespieinsn-extract.c: s-extract ; @true 1802c87b03e5Sespies-extract : $(md_file) genextract$(build_exeext) $(srcdir)/move-if-change 1803c87b03e5Sespie $(RUN_GEN) ./genextract$(build_exeext) $(md_file) > tmp-extract.c 1804c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-extract.c insn-extract.c 1805c87b03e5Sespie $(STAMP) s-extract 1806c87b03e5Sespie 1807c87b03e5Sespieinsn-peep.o : insn-peep.c $(CONFIG_H) $(RTL_H) $(REGS_H) output.h real.h \ 1808c87b03e5Sespie $(SYSTEM_H) insn-config.h $(RECOG_H) except.h function.h $(TM_P_H) 1809c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-peep.c \ 1810c87b03e5Sespie $(OUTPUT_OPTION) 1811c87b03e5Sespie 1812c87b03e5Sespieinsn-peep.c: s-peep ; @true 1813c87b03e5Sespies-peep : $(md_file) genpeep$(build_exeext) $(srcdir)/move-if-change 1814c87b03e5Sespie $(RUN_GEN) ./genpeep$(build_exeext) $(md_file) > tmp-peep.c 1815c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-peep.c insn-peep.c 1816c87b03e5Sespie $(STAMP) s-peep 1817c87b03e5Sespie 1818c87b03e5Sespieinsn-attrtab.o : insn-attrtab.c $(CONFIG_H) $(RTL_H) $(REGS_H) real.h \ 1819c87b03e5Sespie output.h $(INSN_ATTR_H) insn-config.h $(SYSTEM_H) toplev.h $(RECOG_H) \ 1820c87b03e5Sespie $(TM_P_H) flags.h 1821c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-attrtab.c \ 1822c87b03e5Sespie $(OUTPUT_OPTION) 1823c87b03e5Sespie 1824c87b03e5Sespieinsn-attr.h: s-attr ; @true 1825c87b03e5Sespies-attr : $(md_file) genattr$(build_exeext) $(srcdir)/move-if-change 1826c87b03e5Sespie $(RUN_GEN) ./genattr$(build_exeext) $(md_file) > tmp-attr.h 1827c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-attr.h insn-attr.h 1828c87b03e5Sespie $(STAMP) s-attr 1829c87b03e5Sespie 1830c87b03e5Sespieinsn-attrtab.c: s-attrtab ; @true 1831c87b03e5Sespies-attrtab : $(md_file) genattrtab$(build_exeext) $(srcdir)/move-if-change 1832c87b03e5Sespie $(RUN_GEN) ./genattrtab$(build_exeext) $(md_file) > tmp-attrtab.c 1833c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-attrtab.c insn-attrtab.c 1834c87b03e5Sespie $(STAMP) s-attrtab 1835c87b03e5Sespie 1836c87b03e5Sespieinsn-output.o : insn-output.c $(CONFIG_H) $(RTL_H) $(GGC_H) $(REGS_H) real.h \ 1837c87b03e5Sespie conditions.h hard-reg-set.h insn-config.h $(INSN_ATTR_H) $(EXPR_H) \ 1838c87b03e5Sespie output.h $(RECOG_H) function.h $(SYSTEM_H) toplev.h flags.h \ 1839c87b03e5Sespie insn-codes.h $(TM_P_H) 1840c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) -c insn-output.c \ 1841c87b03e5Sespie $(OUTPUT_OPTION) 1842c87b03e5Sespie 1843c87b03e5Sespieinsn-output.c: s-output ; @true 1844c87b03e5Sespies-output : $(md_file) genoutput$(build_exeext) $(srcdir)/move-if-change 1845c87b03e5Sespie $(RUN_GEN) ./genoutput$(build_exeext) $(md_file) > tmp-output.c 1846c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-output.c insn-output.c 1847c87b03e5Sespie $(STAMP) s-output 1848c87b03e5Sespie 1849c87b03e5Sespiegenrtl.o : genrtl.c $(CONFIG_H) $(RTL_H) $(SYSTEM_H) $(GGC_H) 1850c87b03e5Sespiegenrtl.c genrtl.h : s-genrtl 1851c87b03e5Sespie @true # force gnu make to recheck modification times. 1852c87b03e5Sespie 1853c87b03e5Sespies-genrtl: gengenrtl$(build_exeext) $(srcdir)/move-if-change $(RTL_BASE_H) 1854c87b03e5Sespie $(RUN_GEN) ./gengenrtl$(build_exeext) -h > tmp-genrtl.h 1855c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-genrtl.h genrtl.h 1856c87b03e5Sespie $(RUN_GEN) ./gengenrtl$(build_exeext) > tmp-genrtl.c 1857c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-genrtl.c genrtl.c 1858c87b03e5Sespie $(STAMP) s-genrtl 1859c87b03e5Sespie 1860c87b03e5Sespietm-preds.h: s-preds; @true 1861c87b03e5Sespie 1862c87b03e5Sespies-preds: genpreds$(build_exeext) $(srcdir)/move-if-change 1863c87b03e5Sespie $(RUN_GEN) ./genpreds$(build_exeext) > tmp-preds.h 1864c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-preds.h tm-preds.h 1865c87b03e5Sespie $(STAMP) s-preds 1866c87b03e5Sespie 1867c87b03e5SespieGTFILES = $(GCONFIG_H) $(srcdir)/location.h \ 1868c87b03e5Sespie $(HASHTAB_H) \ 1869c87b03e5Sespie $(srcdir)/bitmap.h $(srcdir)/function.h $(srcdir)/rtl.h $(srcdir)/optabs.h \ 1870c87b03e5Sespie $(srcdir)/tree.h $(srcdir)/libfuncs.h $(srcdir)/hashtable.h $(srcdir)/real.h \ 1871c87b03e5Sespie $(srcdir)/varray.h $(srcdir)/ssa.h $(srcdir)/insn-addr.h $(srcdir)/cselib.h \ 1872c87b03e5Sespie $(srcdir)/c-common.h $(srcdir)/c-tree.h \ 1873c87b03e5Sespie $(srcdir)/basic-block.h \ 1874c87b03e5Sespie $(srcdir)/alias.c $(srcdir)/bitmap.c $(srcdir)/cselib.c \ 1875c87b03e5Sespie $(srcdir)/dwarf2out.c $(srcdir)/emit-rtl.c \ 1876c87b03e5Sespie $(srcdir)/except.c $(srcdir)/explow.c $(srcdir)/expr.c \ 1877c87b03e5Sespie $(srcdir)/fold-const.c $(srcdir)/function.c \ 1878c87b03e5Sespie $(srcdir)/gcse.c $(srcdir)/integrate.c $(srcdir)/lists.c $(srcdir)/optabs.c \ 1879c87b03e5Sespie $(srcdir)/profile.c $(srcdir)/ra-build.c $(srcdir)/regclass.c \ 1880c87b03e5Sespie $(srcdir)/reg-stack.c \ 1881c87b03e5Sespie $(srcdir)/sdbout.c $(srcdir)/stmt.c $(srcdir)/stor-layout.c \ 1882c87b03e5Sespie $(srcdir)/tree.c $(srcdir)/varasm.c \ 1883c87b03e5Sespie $(out_file) \ 1884c87b03e5Sespie @all_gtfiles@ 1885c87b03e5Sespie 1886c87b03e5SespieGTFILES_FILES_LANGS = @all_gtfiles_files_langs@ 1887c87b03e5SespieGTFILES_FILES_FILES = @all_gtfiles_files_files@ 1888c87b03e5SespieGTFILES_LANG_DIR_NAMES = @subdirs@ 1889c87b03e5SespieGTFILES_SRCDIR = @srcdir@ 1890c87b03e5Sespie 1891c87b03e5Sespiegtype-desc.h gtype-desc.c gt-except.h gt-function.h : s-gtype; @true 1892c87b03e5Sespiegt-integrate.h gt-stmt.h gt-tree.h gt-varasm.h gt-emit-rtl.h : s-gtype; @true 1893c87b03e5Sespiegt-explow.h gt-stor-layout.h gt-regclass.h gt-lists.h : s-gtype; @true 1894c87b03e5Sespiegt-alias.h gt-cselib.h gt-fold-const.h gt-gcse.h gt-profile.h : s-gtype; @true 1895c87b03e5Sespiegt-expr.h gt-sdbout.h gt-optabs.h gt-bitmap.h gt-dwarf2out.h : s-gtype ; @true 1896c87b03e5Sespiegt-ra-build.h gt-reg-stack.h : s-gtype ; @true 1897c87b03e5Sespiegt-c-common.h gt-c-decl.h gt-c-parse.h gt-c-pragma.h : s-gtype; @true 1898c87b03e5Sespiegt-c-objc-common.h gtype-c.h gt-location.h : s-gtype ; @true 1899c87b03e5Sespie 1900c87b03e5Sespiegtyp-gen.h: Makefile 1901c87b03e5Sespie echo "/* This file is machine generated. Do not edit. */" > tmp-gtyp.h 1902c87b03e5Sespie echo "static const char *srcdir = " >> tmp-gtyp.h 1903c87b03e5Sespie echo "\"$(GTFILES_SRCDIR)\"" >> tmp-gtyp.h 1904c87b03e5Sespie echo ";" >> tmp-gtyp.h 1905c87b03e5Sespie echo "static const char *lang_files[] = {" >> tmp-gtyp.h 1906c87b03e5Sespie ll="$(GTFILES_FILES_FILES)"; \ 1907c87b03e5Sespie for f in $$ll; do \ 1908c87b03e5Sespie echo "\"$$f\", "; done >> tmp-gtyp.h 1909c87b03e5Sespie echo "NULL};" >> tmp-gtyp.h 1910c87b03e5Sespie echo "static const char *langs_for_lang_files[] = {" >> tmp-gtyp.h 1911c87b03e5Sespie ff="$(GTFILES_FILES_LANGS)"; \ 1912c87b03e5Sespie for f in $$ff; do \ 1913c87b03e5Sespie echo "\"$$f\", " ; done >> tmp-gtyp.h 1914c87b03e5Sespie echo "NULL};" >> tmp-gtyp.h 1915c87b03e5Sespie echo "static const char *all_files[] = {" >> tmp-gtyp.h 1916c87b03e5Sespie gf="$(GTFILES)"; \ 1917c87b03e5Sespie for f in $$gf; do \ 1918c87b03e5Sespie echo "\"$$f\", "; done >> tmp-gtyp.h 1919c87b03e5Sespie echo " NULL};" >> tmp-gtyp.h 1920c87b03e5Sespie echo "static const char *lang_dir_names[] = { \"c\", " >> tmp-gtyp.h 1921c87b03e5Sespie gf="$(GTFILES_LANG_DIR_NAMES)"; \ 1922c87b03e5Sespie for l in $$gf; do \ 1923c87b03e5Sespie echo "\"$$l\", "; done >> tmp-gtyp.h 1924c87b03e5Sespie echo "NULL};" >> tmp-gtyp.h 1925c87b03e5Sespie $(SHELL) $(srcdir)/move-if-change tmp-gtyp.h gtyp-gen.h 1926c87b03e5Sespie 1927c87b03e5Sespies-gtype: gengtype$(build_exeext) $(GTFILES) 1928c87b03e5Sespie $(RUN_GEN) ./gengtype 1929c87b03e5Sespie $(STAMP) s-gtype 1930c87b03e5Sespie 1931c87b03e5Sespie# 1932c87b03e5Sespie# Compile the programs that generate insn-* from the machine description. 1933c87b03e5Sespie# They are compiled with $(HOST_CC), and associated libraries, 1934c87b03e5Sespie# since they need to run on this machine 1935c87b03e5Sespie# even if GCC is being compiled to run on some other machine. 1936c87b03e5Sespie 1937c87b03e5Sespie# $(CONFIG_H) is omitted from the deps of the gen*.o 1938c87b03e5Sespie# because these programs don't really depend on anything 1939c87b03e5Sespie# about the target machine. They do depend on config.h itself, 1940c87b03e5Sespie# since that describes the host machine. 1941c87b03e5Sespie 1942c87b03e5Sespieread-rtl.o: read-rtl.c $(HCONFIG_H) $(SYSTEM_H) $(RTL_H) \ 1943c87b03e5Sespie $(OBSTACK_H) $(HASHTAB_H) 1944c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/read-rtl.c $(OUTPUT_OPTION) 1945c87b03e5Sespie 1946c87b03e5Sespiegensupport.o: gensupport.c $(RTL_H) $(OBSTACK_H) $(SYSTEM_H) errors.h gensupport.h 1947c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/gensupport.c $(OUTPUT_OPTION) 1948c87b03e5Sespie 1949c87b03e5Sespiegenconfig$(build_exeext) : genconfig.o $(HOST_RTL) $(HOST_SUPPORT) \ 1950c87b03e5Sespie $(HOST_PRINT) $(HOST_ERRORS) $(HOST_LIBDEPS) 1951c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 1952c87b03e5Sespie genconfig.o $(HOST_RTL) $(HOST_SUPPORT) $(HOST_PRINT) \ 1953c87b03e5Sespie $(HOST_ERRORS) $(HOST_LIBS) 1954c87b03e5Sespie 1955c87b03e5Sespiegenconfig.o : genconfig.c $(RTL_H) $(HCONFIG_H) \ 1956c87b03e5Sespie $(SYSTEM_H) errors.h gensupport.h 1957c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genconfig.c $(OUTPUT_OPTION) 1958c87b03e5Sespie 1959c87b03e5Sespiegenflags$(build_exeext) : genflags.o $(HOST_RTL) $(HOST_SUPPORT) \ 1960c87b03e5Sespie $(HOST_PRINT) $(HOST_ERRORS) $(HOST_LIBDEPS) 1961c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 1962c87b03e5Sespie genflags.o $(HOST_RTL) $(HOST_SUPPORT) $(HOST_PRINT) \ 1963c87b03e5Sespie $(HOST_ERRORS) $(HOST_LIBS) 1964c87b03e5Sespie 1965c87b03e5Sespiegenflags.o : genflags.c $(RTL_H) $(OBSTACK_H) $(HCONFIG_H) \ 1966c87b03e5Sespie $(SYSTEM_H) errors.h gensupport.h 1967c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genflags.c $(OUTPUT_OPTION) 1968c87b03e5Sespie 1969c87b03e5Sespiegencodes$(build_exeext) : gencodes.o $(HOST_RTL) $(HOST_SUPPORT) \ 1970c87b03e5Sespie $(HOST_PRINT) $(HOST_ERRORS) $(HOST_LIBDEPS) 1971c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 1972c87b03e5Sespie gencodes.o $(HOST_RTL) $(HOST_SUPPORT) $(HOST_PRINT) \ 1973c87b03e5Sespie $(HOST_ERRORS) $(HOST_LIBS) 1974c87b03e5Sespie 1975c87b03e5Sespiegencodes.o : gencodes.c $(RTL_H) $(HCONFIG_H) \ 1976c87b03e5Sespie $(SYSTEM_H) errors.h gensupport.h 1977c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/gencodes.c $(OUTPUT_OPTION) 1978c87b03e5Sespie 1979c87b03e5Sespiegenconstants$(build_exeext) : genconstants.o $(HOST_RTL) $(HOST_EARLY_SUPPORT) \ 1980c87b03e5Sespie $(HOST_ERRORS) $(HOST_LIBDEPS) 1981c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 1982c87b03e5Sespie genconstants.o $(HOST_EARLY_SUPPORT) $(HOST_RTL) \ 1983c87b03e5Sespie $(HOST_ERRORS) $(HOST_LIBS) 1984c87b03e5Sespie 1985c87b03e5Sespiegenconstants.o : genconstants.c $(RTL_H) $(HCONFIG_H) $(SYSTEM_H) errors.h 1986c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genconstants.c $(OUTPUT_OPTION) 1987c87b03e5Sespie 1988c87b03e5Sespiegenemit$(build_exeext) : genemit.o $(HOST_RTL) $(HOST_SUPPORT) \ 1989c87b03e5Sespie $(HOST_PRINT) $(HOST_ERRORS) $(HOST_LIBDEPS) 1990c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 1991c87b03e5Sespie genemit.o $(HOST_RTL) $(HOST_SUPPORT) $(HOST_PRINT) \ 1992c87b03e5Sespie $(HOST_ERRORS) $(HOST_LIBS) 1993c87b03e5Sespie 1994c87b03e5Sespiegenemit.o : genemit.c $(RTL_H) $(HCONFIG_H) $(SYSTEM_H) errors.h gensupport.h 1995c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genemit.c $(OUTPUT_OPTION) 1996c87b03e5Sespie 1997c87b03e5Sespiegenopinit$(build_exeext) : genopinit.o $(HOST_RTL) $(HOST_SUPPORT) \ 1998c87b03e5Sespie $(HOST_PRINT) $(HOST_ERRORS) $(HOST_LIBDEPS) 1999c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 2000c87b03e5Sespie genopinit.o $(HOST_RTL) $(HOST_SUPPORT) $(HOST_PRINT) \ 2001c87b03e5Sespie $(HOST_ERRORS) $(HOST_LIBS) 2002c87b03e5Sespie 2003c87b03e5Sespiegenopinit.o : genopinit.c $(RTL_H) $(HCONFIG_H) \ 2004c87b03e5Sespie $(SYSTEM_H) errors.h gensupport.h 2005c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genopinit.c $(OUTPUT_OPTION) 2006c87b03e5Sespie 2007c87b03e5Sespiegenrecog$(build_exeext) : genrecog.o $(HOST_RTL) $(HOST_SUPPORT) \ 2008c87b03e5Sespie $(HOST_PRINT) $(HOST_ERRORS) $(HOST_LIBDEPS) 2009c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 2010c87b03e5Sespie genrecog.o $(HOST_RTL) $(HOST_SUPPORT) $(HOST_PRINT) \ 2011c87b03e5Sespie $(HOST_ERRORS) $(HOST_LIBS) 2012c87b03e5Sespie 2013c87b03e5Sespiegenrecog.o : genrecog.c $(RTL_H) $(HCONFIG_H) \ 2014c87b03e5Sespie $(SYSTEM_H) errors.h gensupport.h 2015c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genrecog.c $(OUTPUT_OPTION) 2016c87b03e5Sespie 2017c87b03e5Sespiegenextract$(build_exeext) : genextract.o $(HOST_RTL) $(HOST_SUPPORT) \ 2018c87b03e5Sespie $(HOST_PRINT) $(HOST_ERRORS) $(HOST_LIBDEPS) 2019c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 2020c87b03e5Sespie genextract.o $(HOST_RTL) $(HOST_SUPPORT) $(HOST_PRINT) \ 2021c87b03e5Sespie $(HOST_ERRORS) $(HOST_LIBS) 2022c87b03e5Sespie 2023c87b03e5Sespiegenextract.o : genextract.c $(RTL_H) $(HCONFIG_H) \ 2024c87b03e5Sespie $(SYSTEM_H) insn-config.h errors.h gensupport.h 2025c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genextract.c $(OUTPUT_OPTION) 2026c87b03e5Sespie 2027c87b03e5Sespiegenpeep$(build_exeext) : genpeep.o $(HOST_RTL) $(HOST_SUPPORT) \ 2028c87b03e5Sespie $(HOST_PRINT) $(HOST_ERRORS) $(HOST_LIBDEPS) 2029c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 2030c87b03e5Sespie genpeep.o $(HOST_RTL) $(HOST_SUPPORT) $(HOST_PRINT) \ 2031c87b03e5Sespie $(HOST_ERRORS) $(HOST_LIBS) 2032c87b03e5Sespie 2033c87b03e5Sespiegenpeep.o : genpeep.c $(RTL_H) $(HCONFIG_H) $(SYSTEM_H) errors.h gensupport.h 2034c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genpeep.c $(OUTPUT_OPTION) 2035c87b03e5Sespie 2036c87b03e5Sespiegenattr$(build_exeext) : genattr.o $(HOST_RTL) $(HOST_SUPPORT) \ 2037c87b03e5Sespie $(HOST_PRINT) $(HOST_ERRORS) $(HOST_LIBDEPS) 2038c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 2039c87b03e5Sespie genattr.o $(HOST_RTL) $(HOST_SUPPORT) $(HOST_PRINT) \ 2040c87b03e5Sespie $(HOST_ERRORS) $(HOST_LIBS) 2041c87b03e5Sespie 2042c87b03e5Sespiegenattr.o : genattr.c $(RTL_H) $(HCONFIG_H) $(SYSTEM_H) errors.h gensupport.h 2043c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genattr.c $(OUTPUT_OPTION) 2044c87b03e5Sespie 2045c87b03e5Sespiegenattrtab$(build_exeext) : genattrtab.o genautomata.o \ 2046c87b03e5Sespie $(HOST_RTL) $(HOST_SUPPORT) $(HOST_PRINT) $(HOST_ERRORS) $(HOST_VARRAY) \ 2047c87b03e5Sespie $(HOST_LIBDEPS) 2048c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 2049c87b03e5Sespie genattrtab.o genautomata.o \ 2050c87b03e5Sespie $(HOST_RTL) $(HOST_SUPPORT) $(HOST_PRINT) $(HOST_ERRORS) \ 2051c87b03e5Sespie $(HOST_VARRAY) $(HOST_LIBS) -lm 2052c87b03e5Sespie 2053c87b03e5Sespiegenattrtab.o : genattrtab.c $(RTL_H) $(OBSTACK_H) $(HCONFIG_H) \ 2054c87b03e5Sespie $(SYSTEM_H) errors.h $(GGC_H) gensupport.h genattrtab.h 2055c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genattrtab.c $(OUTPUT_OPTION) 2056c87b03e5Sespie 2057c87b03e5Sespiegenautomata.o : genautomata.c $(RTL_H) $(OBSTACK_H) $(HCONFIG_H) \ 2058c87b03e5Sespie $(SYSTEM_H) errors.h varray.h genattrtab.h $(HASHTAB_H) 2059c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genautomata.c $(OUTPUT_OPTION) 2060c87b03e5Sespie 2061c87b03e5Sespiegenoutput$(build_exeext) : genoutput.o $(HOST_RTL) $(HOST_SUPPORT) \ 2062c87b03e5Sespie $(HOST_PRINT) $(HOST_ERRORS) $(HOST_LIBDEPS) 2063c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 2064c87b03e5Sespie genoutput.o $(HOST_RTL) $(HOST_SUPPORT) $(HOST_PRINT) \ 2065c87b03e5Sespie $(HOST_ERRORS) $(HOST_LIBS) 2066c87b03e5Sespie 2067c87b03e5Sespiegenoutput.o : genoutput.c $(RTL_H) $(HCONFIG_H) \ 2068c87b03e5Sespie $(SYSTEM_H) errors.h gensupport.h 2069c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genoutput.c $(OUTPUT_OPTION) 2070c87b03e5Sespie 2071c87b03e5Sespiegengenrtl$(build_exeext) : gengenrtl.o $(HOST_LIBDEPS) 2072c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 2073c87b03e5Sespie gengenrtl.o $(HOST_LIBS) 2074c87b03e5Sespie 2075c87b03e5Sespiegengenrtl.o : gengenrtl.c $(RTL_BASE_H) $(HCONFIG_H) $(SYSTEM_H) real.h 2076c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/gengenrtl.c $(OUTPUT_OPTION) 2077c87b03e5Sespie 2078c87b03e5Sespiegenpreds$(build_exeext) : genpreds.o $(HOST_LIBDEPS) 2079c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 2080c87b03e5Sespie genpreds.o $(HOST_LIBS) 2081c87b03e5Sespie 2082c87b03e5Sespiegenpreds.o : genpreds.c $(RTL_BASE_H) $(HCONFIG_H) $(SYSTEM_H) 2083c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/genpreds.c $(OUTPUT_OPTION) 2084c87b03e5Sespie 2085c87b03e5Sespiegengtype$(build_exeext) : gengtype.o gengtype-lex.o gengtype-yacc.o \ 2086c87b03e5Sespie $(HOST_LIBDEPS) 2087c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 2088c87b03e5Sespie gengtype.o gengtype-lex.o gengtype-yacc.o $(HOST_LIBS) 2089c87b03e5Sespie 2090c87b03e5Sespiegengtype.o : gengtype.c gengtype.h $(HCONFIG_H) $(SYSTEM_H) real.h rtl.def \ 2091c87b03e5Sespie gtyp-gen.h 2092c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) \ 2093c87b03e5Sespie $(srcdir)/gengtype.c $(OUTPUT_OPTION) 2094c87b03e5Sespie 20954fed0f8cSespiegengtype-lex.o : gengtype-lex.c gengtype.h gengtype-yacc.c \ 2096c87b03e5Sespie $(HCONFIG_H) $(SYSTEM_H) 2097c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) \ 20984fed0f8cSespie gengtype-lex.c $(OUTPUT_OPTION) 2099c87b03e5Sespie 21004fed0f8cSespiegengtype-yacc.o : gengtype-yacc.c gengtype.h $(HCONFIG_H) $(SYSTEM_H) 2101c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) \ 21024fed0f8cSespie gengtype-yacc.c $(OUTPUT_OPTION) 2103c87b03e5Sespie 2104c87b03e5Sespie# The sed command works around a bug in flex-2.5.4. 21054fed0f8cSespiegengtype-lex.c : $(srcdir)/gengtype-lex.l 21064fed0f8cSespie $(FLEX) $(FLEXFLAGS) -t -o$@ $(srcdir)/gengtype-lex.l | \ 2107c87b03e5Sespie sed 's/^\(char msg\[\];\)/yyconst \1/' > g-$$$$ ; \ 2108c87b03e5Sespie if test $$? -eq 0 ; then \ 2109c87b03e5Sespie mv -f g-$$$$ gengtype-lex.c ; \ 2110c87b03e5Sespie else \ 2111c87b03e5Sespie rm -f g-$$$$.* ; \ 2112c87b03e5Sespie false ; \ 2113c87b03e5Sespie fi 2114c87b03e5Sespie 21154fed0f8cSespiegengtype-yacc.c: $(srcdir)/gengtype-yacc.y 21164fed0f8cSespie $(BISON) $(BISONFLAGS) -d -o gengtype-yacc.c $(srcdir)/gengtype-yacc.y || \ 21174fed0f8cSespie ( rm -f $@ && false ) 2118c87b03e5Sespie 2119c87b03e5Sespiegenconditions$(build_exeext) : genconditions.o $(HOST_EARLY_SUPPORT) \ 2120c87b03e5Sespie $(HOST_RTL) $(HOST_ERRORS) $(HOST_LIBDEPS) 2121c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 2122c87b03e5Sespie genconditions.o $(HOST_EARLY_SUPPORT) $(HOST_RTL) \ 2123c87b03e5Sespie $(HOST_ERRORS) $(HOST_LIBS) 2124c87b03e5Sespie 2125c87b03e5Sespiegenconditions.o : genconditions.c $(RTL_H) $(HCONFIG_H) $(SYSTEM_H) errors.h 2126c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) \ 2127c87b03e5Sespie $(srcdir)/genconditions.c $(OUTPUT_OPTION) 2128c87b03e5Sespie 2129c87b03e5Sespie# 2130c87b03e5Sespie# Compile the libraries to be used by gen*. 2131c87b03e5Sespie# If we are not cross-building, gen* use the same .o's that cc1 will use, 2132c87b03e5Sespie# and BUILD_PREFIX_1 is `loser-', just to ensure these rules don't conflict 2133c87b03e5Sespie# with the rules for rtl.o, etc. 2134c87b03e5Sespie$(BUILD_PREFIX_1)rtl.o: $(srcdir)/rtl.c $(HCONFIG_H) $(SYSTEM_H) $(RTL_H) \ 2135c87b03e5Sespie real.h $(GGC_H) errors.h 2136c87b03e5Sespie rm -f $(BUILD_PREFIX)rtl.c 2137c87b03e5Sespie sed -e 's/config[.]h/hconfig.h/' $(srcdir)/rtl.c > $(BUILD_PREFIX)rtl.c 2138c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(BUILD_PREFIX)rtl.c $(OUTPUT_OPTION) 2139c87b03e5Sespie 2140c87b03e5Sespieprint-rtl1.o: $(srcdir)/print-rtl.c $(HCONFIG_H) \ 2141c87b03e5Sespie $(RTL_H) $(TREE_H) hard-reg-set.h $(BASIC_BLOCK_H) 2142c87b03e5Sespie rm -f print-rtl1.c 2143c87b03e5Sespie sed -e 's/config[.]h/hconfig.h/' $(srcdir)/print-rtl.c > print-rtl1.c 2144c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) print-rtl1.c $(OUTPUT_OPTION) 2145c87b03e5Sespie 2146c87b03e5Sespie$(BUILD_PREFIX_1)bitmap.o: $(srcdir)/bitmap.c $(HCONFIG_H) $(SYSTEM_H) \ 2147c87b03e5Sespie $(RTL_H) flags.h $(BASIC_BLOCK_H) $(REGS_H) $(GGC_H) 2148c87b03e5Sespie rm -f $(BUILD_PREFIX)bitmap.c 2149c87b03e5Sespie sed -e 's/config[.]h/hconfig.h/' $(srcdir)/bitmap.c > $(BUILD_PREFIX)bitmap.c 2150c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(BUILD_PREFIX)bitmap.c $(OUTPUT_OPTION) 2151c87b03e5Sespie 2152c87b03e5Sespie$(BUILD_PREFIX_1)errors.o: errors.c $(HCONFIG_H) $(SYSTEM_H) errors.h 2153c87b03e5Sespie rm -f $(BUILD_PREFIX)errors.c 2154c87b03e5Sespie sed -e 's/config[.]h/hconfig.h/' $(srcdir)/errors.c > $(BUILD_PREFIX)errors.c 2155c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(BUILD_PREFIX)errors.c $(OUTPUT_OPTION) 2156c87b03e5Sespie 2157c87b03e5Sespie$(BUILD_PREFIX_1)varray.o: varray.c $(HCONFIG_H) $(SYSTEM_H) varray.h \ 2158c87b03e5Sespie $(RTL_H) $(GGC_H) $(TREE_H) bitmap.h errors.h 2159c87b03e5Sespie rm -f $(BUILD_PREFIX)varray.c 2160c87b03e5Sespie sed -e 's/config[.]h/hconfig.h/' $(srcdir)/varray.c > \ 2161c87b03e5Sespie $(BUILD_PREFIX)varray.c 2162c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) \ 2163c87b03e5Sespie $(BUILD_PREFIX)varray.c $(OUTPUT_OPTION) 2164c87b03e5Sespie 2165c87b03e5Sespie$(BUILD_PREFIX_1)ggc-none.o: ggc-none.c $(HCONFIG_H) $(SYSTEM_H) $(GGC_H) 2166c87b03e5Sespie rm -f $(BUILD_PREFIX)ggc-none.c 2167c87b03e5Sespie sed -e 's/config[.]h/hconfig.h/' $(srcdir)/ggc-none.c > $(BUILD_PREFIX)ggc-none.c 2168c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(BUILD_PREFIX)ggc-none.c $(OUTPUT_OPTION) 2169c87b03e5Sespie 2170c87b03e5Sespie# 2171c87b03e5Sespie# Remake internationalization support. 2172c87b03e5Sespieintl.o: intl.c $(CONFIG_H) system.h intl.h Makefile 2173c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \ 2174c87b03e5Sespie -DLOCALEDIR=\"$(localedir)\" \ 2175c87b03e5Sespie -c $(srcdir)/intl.c $(OUTPUT_OPTION) 2176c87b03e5Sespie 2177c87b03e5Sespie$(top_builddir)/intl/libintl.a: intl.all 2178c87b03e5Sespie 2179c87b03e5Sespieintl.all intl.install intl.uninstall \ 2180c87b03e5Sespie intl.mostlyclean intl.clean intl.distclean intl.maintainer-clean: 2181c87b03e5Sespie @for d in $(INTL_SUBDIRS); do \ 2182c87b03e5Sespie target=`expr $@ : 'intl.\(.*\)'` && \ 2183c87b03e5Sespie echo "(cd $$d && $(MAKE) $$target)" && \ 2184c87b03e5Sespie (cd $$d && AWK='$(AWK)' $(MAKE) $(SUBDIR_FLAGS_TO_PASS) $$target); \ 2185c87b03e5Sespie if [ $$? -eq 0 ] ; then true ; else exit 1 ; fi ; \ 2186c87b03e5Sespie done 2187c87b03e5Sespie 2188c87b03e5Sespie# intl.all and intl.install need config.h to exist, and the files it includes. 2189c87b03e5Sespie# (FIXME: intl/*.c shouldn't need to see insn-foo.h!) 2190c87b03e5Sespieintl.all intl.install: config.h insn-flags.h insn-constants.h 2191c87b03e5Sespie 2192c87b03e5Sespie# Make-lang.in should add dependencies of po-generated on any generated 2193c87b03e5Sespie# files which need to be scanned by gettext (usually Yacc-generated parsers). 2194c87b03e5Sespiepo-generated: c-parse.c 2195c87b03e5Sespie 2196c87b03e5Sespie# 2197c87b03e5Sespie# Remake cpp and protoize. 2198c87b03e5Sespie 2199c87b03e5SespiePREPROCESSOR_DEFINES = \ 2200c87b03e5Sespie -DGCC_INCLUDE_DIR=\"$(libsubdir)/include\" \ 2201c87b03e5Sespie -DGPLUSPLUS_INCLUDE_DIR=\"$(gcc_gxx_include_dir)\" \ 2202c87b03e5Sespie -DGPLUSPLUS_TOOL_INCLUDE_DIR=\"$(gcc_gxx_include_dir)/$(target_alias)\" \ 2203c87b03e5Sespie -DGPLUSPLUS_BACKWARD_INCLUDE_DIR=\"$(gcc_gxx_include_dir)/backward\" \ 2204c87b03e5Sespie -DLOCAL_INCLUDE_DIR=\"$(local_includedir)\" \ 220506dc6460Sespie -DCROSS_INCLUDE_DIR=\"$(CROSS_SYSTEM_HEADER_DIR)\" \ 220606dc6460Sespie -DTOOL_INCLUDE_DIR=\"$(gcc_tooldir)/include\" \ 220706dc6460Sespie @TARGET_SYSTEM_ROOT_DEFINE@ 2208c87b03e5Sespie 2209c87b03e5SespieLIBCPP_OBJS = cpplib.o cpplex.o cppmacro.o cppexp.o cppfiles.o cpptrad.o \ 2210c87b03e5Sespie cpphash.o cpperror.o cppinit.o cppdefault.o cppmain.o \ 2211c87b03e5Sespie hashtable.o line-map.o mkdeps.o prefix.o mbchar.o 2212c87b03e5Sespie 2213c87b03e5SespieLIBCPP_DEPS = $(CPPLIB_H) cpphash.h line-map.h hashtable.h intl.h \ 2214c87b03e5Sespie $(OBSTACK_H) $(SYSTEM_H) 2215c87b03e5Sespie 2216c87b03e5Sespie# Most of the other archives built/used by this makefile are for 2217c87b03e5Sespie# targets. This one is strictly for the host. 2218c87b03e5Sespielibcpp.a: $(LIBCPP_OBJS) 2219c87b03e5Sespie -rm -rf libcpp.a 2220c87b03e5Sespie $(AR) $(AR_FLAGS) libcpp.a $(LIBCPP_OBJS) 2221c87b03e5Sespie -$(RANLIB) libcpp.a 2222c87b03e5Sespie 2223c87b03e5Sespiecppmain.o: cppmain.c $(CONFIG_H) $(LIBCPP_DEPS) 2224c87b03e5Sespie 2225c87b03e5Sespiecpperror.o: cpperror.c $(CONFIG_H) $(LIBCPP_DEPS) 2226c87b03e5Sespiecppexp.o: cppexp.c $(CONFIG_H) $(LIBCPP_DEPS) 2227c87b03e5Sespiecpplex.o: cpplex.c $(CONFIG_H) $(LIBCPP_DEPS) mbchar.h 2228c87b03e5Sespiecppmacro.o: cppmacro.c $(CONFIG_H) $(LIBCPP_DEPS) 2229c87b03e5Sespiecpplib.o: cpplib.c $(CONFIG_H) $(LIBCPP_DEPS) 2230c87b03e5Sespiecpphash.o: cpphash.c $(CONFIG_H) $(LIBCPP_DEPS) 2231c87b03e5Sespiecpptrad.o: cpptrad.c $(CONFIG_H) $(LIBCPP_DEPS) 2232c87b03e5Sespiecppfiles.o: cppfiles.c $(CONFIG_H) $(LIBCPP_DEPS) $(SPLAY_TREE_H) mkdeps.h 2233c87b03e5Sespiecppinit.o: cppinit.c $(CONFIG_H) $(LIBCPP_DEPS) cppdefault.h \ 2234c87b03e5Sespie mkdeps.h prefix.h 2235c87b03e5Sespie 2236c87b03e5Sespiecppdefault.o: cppdefault.c $(CONFIG_H) $(SYSTEM_H) cppdefault.h Makefile 2237c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \ 2238c87b03e5Sespie $(PREPROCESSOR_DEFINES) \ 2239c87b03e5Sespie -c $(srcdir)/cppdefault.c $(OUTPUT_OPTION) 2240c87b03e5Sespie 2241c87b03e5Sespiemkdeps.o: mkdeps.c $(CONFIG_H) $(SYSTEM_H) mkdeps.h 2242c87b03e5Sespie 2243c87b03e5Sespie# Note for the stamp targets, we run the program `true' instead of 2244c87b03e5Sespie# having an empty command (nothing following the semicolon). 2245c87b03e5Sespie 2246c87b03e5Sespieproto: config.status protoize$(exeext) unprotoize$(exeext) SYSCALLS.c.X 2247c87b03e5Sespie 2248c87b03e5SespiePROTO_OBJS = intl.o version.o cppdefault.o 2249c87b03e5Sespie 2250c87b03e5Sespieprotoize$(exeext): protoize.o $(PROTO_OBJS) $(LIBDEPS) 2251c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ protoize.o $(PROTO_OBJS) $(LIBS) 2252c87b03e5Sespie 2253c87b03e5Sespieunprotoize$(exeext): unprotoize.o $(PROTO_OBJS) $(LIBDEPS) 2254c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ unprotoize.o $(PROTO_OBJS) $(LIBS) 2255c87b03e5Sespie 22569a0429e4Sespieprotoize.o: protoize.c $(LIBIBERTY_INCLUDES)/getopt.h $(CONFIG_H) $(SYSTEM_H) \ 2257c87b03e5Sespie Makefile version.h 2258c87b03e5Sespie (SHLIB_LINK='$(SHLIB_LINK)' \ 2259c87b03e5Sespie SHLIB_MULTILIB='$(SHLIB_MULTILIB)'; \ 2260c87b03e5Sespie $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \ 2261c87b03e5Sespie $(DRIVER_DEFINES) \ 2262c87b03e5Sespie $(srcdir)/protoize.c $(OUTPUT_OPTION)) 2263c87b03e5Sespie 22649a0429e4Sespieunprotoize.o: protoize.c $(LIBIBERTY_INCLUDES)/getopt.h \ 2265c87b03e5Sespie $(CONFIG_H) $(SYSTEM_H) Makefile version.h 2266c87b03e5Sespie (SHLIB_LINK='$(SHLIB_LINK)' \ 2267c87b03e5Sespie SHLIB_MULTILIB='$(SHLIB_MULTILIB)'; \ 2268c87b03e5Sespie $(CC) -c -DUNPROTOIZE $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \ 2269c87b03e5Sespie $(DRIVER_DEFINES) \ 2270c87b03e5Sespie $(srcdir)/protoize.c $(OUTPUT_OPTION)) 2271c87b03e5Sespie 2272c87b03e5Sespie# This info describes the target machine, so compile with GCC just built. 2273c87b03e5SespieSYSCALLS.c.X: $(srcdir)/sys-types.h $(srcdir)/sys-protos.h $(GCC_PASSES) \ 2274c87b03e5Sespie stmp-int-hdrs 2275c87b03e5Sespie -rm -f SYSCALLS.c tmp-SYSCALLS.s 2276c87b03e5Sespie sed -e s/TARGET_GETGROUPS_T/$(TARGET_GETGROUPS_T)/ \ 2277c87b03e5Sespie $(srcdir)/sys-types.h $(srcdir)/sys-protos.h > SYSCALLS.c 2278c87b03e5Sespie $(GCC_FOR_TARGET) $(GCC_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \ 2279c87b03e5Sespie -aux-info $@ -S -o tmp-SYSCALLS.s SYSCALLS.c 2280c87b03e5Sespie -rm -f SYSCALLS.c tmp-SYSCALLS.s 2281c87b03e5Sespie 2282c87b03e5Sespie 2283c87b03e5Sespietest-protoize-simple: ./protoize ./unprotoize $(GCC_PASSES) 2284c87b03e5Sespie -rm -f tmp-proto.[cso] 2285c87b03e5Sespie cp $(srcdir)/protoize.c tmp-proto.c 2286c87b03e5Sespie chmod u+w tmp-proto.c 2287c87b03e5Sespie ./protoize -N -B ./ -x getopt.h -c "-B./ -Wall -Wwrite-strings \ 2288c87b03e5Sespie $(GCC_CFLAGS) $(INCLUDES) \ 2289c87b03e5Sespie -DGCC_INCLUDE_DIR=0 \ 2290c87b03e5Sespie -DGPLUSPLUS_INCLUDE_DIR=0 \ 2291c87b03e5Sespie -DCROSS_INCLUDE_DIR=0 \ 2292c87b03e5Sespie -DTOOL_INCLUDE_DIR=0 \ 2293c87b03e5Sespie -DSTANDARD_EXEC_PREFIX=0 \ 2294c87b03e5Sespie -DDEFAULT_TARGET_MACHINE=0 \ 2295c87b03e5Sespie -DDEFAULT_TARGET_VERSION=0" tmp-proto.c 2296c87b03e5Sespie @echo '**********' Expect 400 lines of differences. 2297c87b03e5Sespie -diff $(srcdir)/protoize.c tmp-proto.c > tmp-proto.diff 2298c87b03e5Sespie -wc -l tmp-proto.diff 2299c87b03e5Sespie ./unprotoize -N -x getopt.h -c "-B./ -Wall -Wwrite-strings \ 2300c87b03e5Sespie $(GCC_CFLAGS) $(INCLUDES) \ 2301c87b03e5Sespie -DGCC_INCLUDE_DIR=0 \ 2302c87b03e5Sespie -DGPLUSPLUS_INCLUDE_DIR=0 \ 2303c87b03e5Sespie -DCROSS_INCLUDE_DIR=0 \ 2304c87b03e5Sespie -DTOOL_INCLUDE_DIR=0 \ 2305c87b03e5Sespie -DSTANDARD_EXEC_PREFIX=0 \ 2306c87b03e5Sespie -DDEFAULT_TARGET_MACHINE=0 \ 2307c87b03e5Sespie -DDEFAULT_TARGET_VERSION=0" tmp-proto.c 2308c87b03e5Sespie @echo Expect zero differences. 2309c87b03e5Sespie diff $(srcdir)/protoize.c tmp-proto.c | cat 2310c87b03e5Sespie -rm -f tmp-proto.[cs] tmp-proto$(objext) 2311c87b03e5Sespie 2312c87b03e5Sespiegcov.o: gcov.c gcov-io.h intl.h $(SYSTEM_H) $(CONFIG_H) 2313c87b03e5Sespie 2314c87b03e5Sespie# Only one of 'gcov' or 'gcov.exe' is actually built, depending 2315c87b03e5Sespie# upon whether $(exeext) is empty or not. 2316c87b03e5SespieGCOV_OBJS = gcov.o intl.o version.o 2317c87b03e5Sespiegcov$(exeext): $(GCOV_OBJS) $(LIBDEPS) 2318c87b03e5Sespie $(CC) $(ALL_CFLAGS) $(LDFLAGS) $(GCOV_OBJS) $(LIBS) -o $@ 2319c87b03e5Sespie# 2320c87b03e5Sespie# Build the include directory. The stamp files are stmp-* rather than 2321c87b03e5Sespie# s-* so that mostlyclean does not force the include directory to 2322c87b03e5Sespie# be rebuilt. 2323c87b03e5Sespie 2324c87b03e5Sespie# Build the include directory 2325c87b03e5Sespiestmp-int-hdrs: $(STMP_FIXINC) $(USER_H) xlimits.h 2326c87b03e5Sespie# Copy in the headers provided with gcc. 2327c87b03e5Sespie# The sed command gets just the last file name component; 2328c87b03e5Sespie# this is necessary because VPATH could add a dirname. 2329c87b03e5Sespie# Using basename would be simpler, but some systems don't have it. 2330c87b03e5Sespie# The touch command is here to workaround an AIX/Linux NFS bug. 2331c87b03e5Sespie -if [ -d include ] ; then true; else mkdir include; chmod a+rx include; fi 2332c87b03e5Sespie for file in .. $(USER_H); do \ 2333c87b03e5Sespie if [ X$$file != X.. ]; then \ 2334c87b03e5Sespie realfile=`echo $$file | sed -e 's|.*/\([^/]*\)$$|\1|'`; \ 2335c87b03e5Sespie $(STAMP) include/$$realfile; \ 2336c87b03e5Sespie rm -f include/$$realfile; \ 2337c87b03e5Sespie cp $$file include; \ 2338c87b03e5Sespie chmod a+r include/$$realfile; \ 2339c87b03e5Sespie fi; \ 2340c87b03e5Sespie done 2341c87b03e5Sespie rm -f include/limits.h 2342c87b03e5Sespie cp xlimits.h include/limits.h 2343c87b03e5Sespie chmod a+r include/limits.h 2344c87b03e5Sespie# Install the README 2345c87b03e5Sespie rm -f include/README 2346c87b03e5Sespie cp $(srcdir)/README-fixinc include/README 2347c87b03e5Sespie chmod a+r include/README 2348c87b03e5Sespie $(STAMP) $@ 2349c87b03e5Sespie 2350c87b03e5Sespie# fixinc.sh depends on this, not on specs directly. 2351c87b03e5Sespie# The idea is to make sure specs gets built, but not rerun fixinc.sh 2352c87b03e5Sespie# after each stage just because specs' mtime has changed. 2353c87b03e5Sespiespecs.ready: specs 2354c87b03e5Sespie -if [ -f specs.ready ] ; then \ 2355c87b03e5Sespie true; \ 2356c87b03e5Sespie else \ 2357c87b03e5Sespie $(STAMP) specs.ready; \ 2358c87b03e5Sespie fi 2359c87b03e5Sespie 2360c87b03e5SespieFIXINCSRCDIR=$(srcdir)/fixinc 2361c87b03e5Sespiefixinc.sh: $(FIXINCSRCDIR)/mkfixinc.sh $(FIXINCSRCDIR)/fixincl.c \ 2362c87b03e5Sespie $(FIXINCSRCDIR)/procopen.c $(FIXINCSRCDIR)/gnu-regex.c \ 2363c87b03e5Sespie $(FIXINCSRCDIR)/server.c $(FIXINCSRCDIR)/gnu-regex.h \ 2364c87b03e5Sespie $(FIXINCSRCDIR)/server.h $(FIXINCSRCDIR)/inclhack.def specs.ready 2365c87b03e5Sespie (MAKE="$(MAKE)"; srcdir=`cd $(srcdir)/fixinc && ${PWD_COMMAND}` ; \ 2366c87b03e5Sespie CC="$(HOST_CC)"; CFLAGS="$(HOST_CFLAGS)"; LDFLAGS="$(HOST_LDFLAGS)"; \ 236706dc6460Sespie WARN_CFLAGS="$(WARN_CFLAGS)"; LIBERTY=`pwd`/"$(BUILD_LIBIBERTY)"; \ 236806dc6460Sespie export MAKE srcdir CC CFLAGS LDFLAGS WARN_CFLAGS LIBERTY; \ 236906dc6460Sespie cd ./fixinc && \ 2370c87b03e5Sespie $(SHELL) $${srcdir}/mkfixinc.sh $(build_canonical) $(target)) 2371c87b03e5Sespie 237206dc6460Sespie.PHONY: install-gcc-tooldir 237306dc6460Sespieinstall-gcc-tooldir: 237406dc6460Sespie $(SHELL) ${srcdir}/mkinstalldirs $(gcc_tooldir) 237506dc6460Sespie 2376c87b03e5Sespie# Build fixed copies of system files. 2377c87b03e5Sespiestmp-fixinc: fixinc.sh gsyslimits.h 237806dc6460Sespie @if test ! -d ${SYSTEM_HEADER_DIR}; then \ 237906dc6460Sespie echo The directory that should contain system headers does not exist: >&2 ; \ 238006dc6460Sespie echo " ${SYSTEM_HEADER_DIR}" >&2 ; \ 238106dc6460Sespie if test "x${SYSTEM_HEADER_DIR}" = "x${gcc_tooldir}/sys-include"; \ 238206dc6460Sespie then sleep 1; else exit 1; fi; \ 238306dc6460Sespie fi 2384c87b03e5Sespie rm -rf include; mkdir include 2385c87b03e5Sespie -chmod a+rx include 2386c87b03e5Sespie (TARGET_MACHINE='$(target)'; srcdir=`cd $(srcdir); ${PWD_COMMAND}`; \ 2387c87b03e5Sespie SHELL='$(SHELL)' ;\ 2388c87b03e5Sespie export TARGET_MACHINE srcdir SHELL ; \ 2389c87b03e5Sespie $(SHELL) ./fixinc.sh `${PWD_COMMAND}`/include $(SYSTEM_HEADER_DIR) $(OTHER_FIXINCLUDES_DIRS); \ 2390c87b03e5Sespie rm -f include/syslimits.h; \ 2391c87b03e5Sespie if [ -f include/limits.h ]; then \ 2392c87b03e5Sespie mv include/limits.h include/syslimits.h; \ 2393c87b03e5Sespie else \ 2394c87b03e5Sespie cp $(srcdir)/gsyslimits.h include/syslimits.h; \ 2395c87b03e5Sespie fi; \ 2396c87b03e5Sespie chmod a+r include/syslimits.h) 2397c87b03e5Sespie $(STAMP) stmp-fixinc 2398c87b03e5Sespie 2399c87b03e5Sespie# Files related to the fixproto script. 2400c87b03e5Sespie# gen-protos and fix-header are compiled with HOST_CC, but they are only 2401c87b03e5Sespie# used in native and host-x-target builds, so it's safe to link them with 2402c87b03e5Sespie# libiberty.a. 2403c87b03e5Sespie 2404c87b03e5Sespiededuced.h: $(GCC_PASSES) $(srcdir)/scan-types.sh stmp-int-hdrs 240506dc6460Sespie if [ -d "$(SYSTEM_HEADER_DIR)" ]; \ 2406c87b03e5Sespie then \ 2407c87b03e5Sespie CC="$(GCC_FOR_TARGET) $(GCC_CFLAGS) $(ALL_CPPFLAGS) -I. -I$(srcdir) -isystem include -isystem ${SYSTEM_HEADER_DIR}"; \ 2408c87b03e5Sespie export CC; \ 2409c87b03e5Sespie $(SHELL) $(srcdir)/scan-types.sh "$(srcdir)" >tmp-deduced.h; \ 2410c87b03e5Sespie mv tmp-deduced.h deduced.h; \ 2411c87b03e5Sespie else \ 2412c87b03e5Sespie $(STAMP) deduced.h; \ 2413c87b03e5Sespie fi 2414c87b03e5Sespie 2415c87b03e5SespieGEN_PROTOS_OBJS = gen-protos.o scan.o 2416c87b03e5Sespiegen-protos$(build_exeext): $(GEN_PROTOS_OBJS) 2417c87b03e5Sespie ${HOST_CC} $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ \ 2418c87b03e5Sespie $(GEN_PROTOS_OBJS) $(HOST_LIBS) 2419c87b03e5Sespie 2420c87b03e5Sespiegen-protos.o: gen-protos.c scan.h $(HCONFIG_H) $(SYSTEM_H) 2421c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/gen-protos.c $(OUTPUT_OPTION) 2422c87b03e5Sespie 2423c87b03e5Sespiescan.o: scan.c scan.h $(HCONFIG_H) $(SYSTEM_H) 2424c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/scan.c $(OUTPUT_OPTION) 2425c87b03e5Sespie 2426c87b03e5Sespiexsys-protos.h: $(GCC_PASSES) $(srcdir)/sys-protos.h deduced.h gen-protos$(build_exeext) Makefile 2427c87b03e5Sespie sed -e s/TARGET_GETGROUPS_T/$(TARGET_GETGROUPS_T)/ \ 2428c87b03e5Sespie deduced.h $(srcdir)/sys-protos.h > tmp-fixtmp.c 2429c87b03e5Sespie mv tmp-fixtmp.c fixtmp.c 2430c87b03e5Sespie $(GCC_FOR_TARGET) fixtmp.c -w -U__SIZE_TYPE__ -U__PTRDIFF_TYPE__ -U__WCHAR_TYPE__ -E \ 2431c87b03e5Sespie | sed -e 's/ / /g' -e 's/ *(/ (/g' -e 's/ [ ]*/ /g' -e 's/( )/()/' \ 2432c87b03e5Sespie | $(RUN_GEN) ./gen-protos >xsys-protos.hT 2433c87b03e5Sespie mv xsys-protos.hT xsys-protos.h 2434c87b03e5Sespie rm -rf fixtmp.c 2435c87b03e5Sespie 2436c87b03e5Sespie# This is nominally a 'build' program, but it's run only when host==build, 2437c87b03e5Sespie# so we can (indeed, must) use $(LIBDEPS) and $(LIBS). 2438c87b03e5Sespiefix-header$(build_exeext): fix-header.o scan-decls.o scan.o xsys-protos.h \ 2439c87b03e5Sespie $(LIBDEPS) libcpp.a 2440c87b03e5Sespie $(HOST_CC) $(HOST_CFLAGS) $(HOST_LDFLAGS) -o $@ fix-header.o \ 2441c87b03e5Sespie scan-decls.o scan.o libcpp.a $(LIBS) 2442c87b03e5Sespie 2443c87b03e5Sespiefix-header.o: fix-header.c $(OBSTACK_H) scan.h \ 2444c87b03e5Sespie xsys-protos.h $(HCONFIG_H) $(SYSTEM_H) $(CPPLIB_H) 2445c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/fix-header.c $(OUTPUT_OPTION) 2446c87b03e5Sespie 2447c87b03e5Sespiescan-decls.o: scan-decls.c scan.h $(CPPLIB_H) $(HCONFIG_H) $(SYSTEM_H) 2448c87b03e5Sespie $(HOST_CC) -c $(HOST_CFLAGS) $(HOST_CPPFLAGS) $(INCLUDES) $(srcdir)/scan-decls.c $(OUTPUT_OPTION) 2449c87b03e5Sespie 2450c87b03e5Sespie# stmp-fixproto depends on this, not on fix-header directly. 2451c87b03e5Sespie# The idea is to make sure fix-header gets built, 2452c87b03e5Sespie# but not rerun fixproto after each stage 2453c87b03e5Sespie# just because fix-header's mtime has changed. 2454c87b03e5Sespiefixhdr.ready: fix-header$(build_exeext) 2455c87b03e5Sespie -if [ -f fixhdr.ready ] ; then \ 2456c87b03e5Sespie true; \ 2457c87b03e5Sespie else \ 2458c87b03e5Sespie $(STAMP) fixhdr.ready; \ 2459c87b03e5Sespie fi 2460c87b03e5Sespie 2461c87b03e5Sespie# stmp-int-headers is to make sure fixincludes has already finished. 2462c87b03e5Sespie# The if statement is so that we don't run fixproto a second time 2463c87b03e5Sespie# if it has already been run on the files in `include'. 2464c87b03e5Sespiestmp-fixproto: fixhdr.ready fixproto stmp-int-hdrs 2465c87b03e5Sespie if [ -f include/fixed ] ; then true; \ 2466c87b03e5Sespie else \ 2467c87b03e5Sespie : This line works around a 'make' bug in BSDI 1.1.; \ 2468c87b03e5Sespie FIXPROTO_DEFINES="$(FIXPROTO_DEFINES)"; export FIXPROTO_DEFINES; \ 2469c87b03e5Sespie mkinstalldirs="$(SHELL) $(srcdir)/mkinstalldirs"; \ 2470c87b03e5Sespie export mkinstalldirs; \ 247106dc6460Sespie if [ -d "$(SYSTEM_HEADER_DIR)" ]; then \ 2472c87b03e5Sespie $(SHELL) ${srcdir}/fixproto include include $(SYSTEM_HEADER_DIR); \ 2473c87b03e5Sespie if [ $$? -eq 0 ] ; then true ; else exit 1 ; fi ; \ 2474c87b03e5Sespie else true; fi; \ 2475c87b03e5Sespie $(STAMP) include/fixed; \ 2476c87b03e5Sespie fi 2477c87b03e5Sespie $(STAMP) stmp-fixproto 2478c87b03e5Sespie# 2479c87b03e5Sespie# Remake the info files. 2480c87b03e5Sespie 2481c87b03e5Sespiedocdir = $(srcdir)/doc 2482c87b03e5Sespie 2483c87b03e5Sespiedoc: $(BUILD_INFO) $(GENERATED_MANPAGES) gccbug 24843fc3b67eSespieinfo: cpp.info gcc.info gccint.info gccinstall.info lang.info cppinternals.info 2485c87b03e5Sespie 2486c87b03e5SespieTEXI_CPP_FILES = $(docdir)/cpp.texi $(docdir)/include/fdl.texi \ 2487c87b03e5Sespie $(docdir)/cppenv.texi $(docdir)/cppopts.texi 2488c87b03e5Sespie 2489c87b03e5SespieTEXI_GCC_FILES = $(docdir)/gcc.texi $(docdir)/include/gcc-common.texi \ 2490c87b03e5Sespie $(docdir)/frontends.texi $(docdir)/standards.texi \ 2491c87b03e5Sespie $(docdir)/invoke.texi $(docdir)/extend.texi $(docdir)/md.texi \ 2492c87b03e5Sespie $(docdir)/objc.texi $(docdir)/gcov.texi $(docdir)/trouble.texi \ 2493c87b03e5Sespie $(docdir)/bugreport.texi $(docdir)/service.texi \ 2494c87b03e5Sespie $(docdir)/contribute.texi $(docdir)/compat.texi \ 2495c87b03e5Sespie $(docdir)/include/funding.texi $(docdir)/gnu.texi \ 2496c87b03e5Sespie $(docdir)/include/gpl.texi $(docdir)/include/fdl.texi \ 2497c87b03e5Sespie $(docdir)/contrib.texi $(docdir)/cppenv.texi $(docdir)/cppopts.texi 2498c87b03e5Sespie 2499c87b03e5SespieTEXI_GCCINT_FILES = $(docdir)/gccint.texi \ 2500c87b03e5Sespie $(docdir)/include/gcc-common.texi $(docdir)/contribute.texi \ 2501c87b03e5Sespie $(docdir)/makefile.texi $(docdir)/configterms.texi \ 2502c87b03e5Sespie $(docdir)/portability.texi $(docdir)/interface.texi \ 2503c87b03e5Sespie $(docdir)/passes.texi $(docdir)/c-tree.texi \ 2504c87b03e5Sespie $(docdir)/rtl.texi $(docdir)/md.texi $(docdir)/tm.texi \ 2505c87b03e5Sespie $(docdir)/hostconfig.texi $(docdir)/fragments.texi \ 2506c87b03e5Sespie $(docdir)/configfiles.texi $(docdir)/collect2.texi \ 2507c87b03e5Sespie $(docdir)/headerdirs.texi $(docdir)/include/funding.texi \ 2508c87b03e5Sespie $(docdir)/gnu.texi $(docdir)/include/gpl.texi \ 2509c87b03e5Sespie $(docdir)/include/fdl.texi $(docdir)/contrib.texi \ 2510c87b03e5Sespie $(docdir)/languages.texi $(docdir)/sourcebuild.texi \ 2511c87b03e5Sespie $(docdir)/gty.texi 2512c87b03e5Sespie 2513c87b03e5SespieTEXI_GCCINSTALL_FILES = $(docdir)/install.texi $(docdir)/install-old.texi \ 2514c87b03e5Sespie $(docdir)/include/fdl.texi 2515c87b03e5Sespie 2516c87b03e5SespieTEXI_CPPINT_FILES = $(docdir)/cppinternals.texi 2517c87b03e5Sespie 25183fc3b67eSespiecpp.info: $(TEXI_CPP_FILES) 25193fc3b67eSespie $(MAKEINFO) $(MAKEINFOFLAGS) -I $(srcdir)/doc -I $(srcdir)/doc/include -o cpp.info $(srcdir)/doc/cpp.texi 2520c87b03e5Sespie 25213fc3b67eSespiegcc.info: $(TEXI_GCC_FILES) 25223fc3b67eSespie $(MAKEINFO) $(MAKEINFOFLAGS) -I $(srcdir)/doc -I $(srcdir)/doc/include -o gcc.info $(srcdir)/doc/gcc.texi 2523c87b03e5Sespie 25243fc3b67eSespiegccint.info: $(TEXI_GCCINT_FILES) 25253fc3b67eSespie $(MAKEINFO) $(MAKEINFOFLAGS) -I $(srcdir)/doc -I $(srcdir)/doc/include -o gccint.info $(srcdir)/doc/gccint.texi 2526c87b03e5Sespie 25273fc3b67eSespiegccinstall.info: $(TEXI_GCCINSTALL_FILES) 25283fc3b67eSespie $(MAKEINFO) $(MAKEINFOFLAGS) -I $(srcdir)/doc -I $(srcdir)/doc/include -o gccinstall.info $(srcdir)/doc/install.texi 2529c87b03e5Sespie 25303fc3b67eSespiecppinternals.info: $(TEXI_CPPINT_FILES) 25313fc3b67eSespie $(MAKEINFO) $(MAKEINFOFLAGS) -I $(srcdir)/doc -I $(srcdir)/doc/include -o cppinternals.info \ 25323fc3b67eSespie $(srcdir)/doc/cppinternals.texi 2533c87b03e5Sespie 2534c87b03e5Sespiedvi: gcc.dvi gccint.dvi gccinstall.dvi cpp.dvi lang.dvi cppinternals.dvi 2535c87b03e5Sespie 2536c87b03e5Sespie# This works with GNU Make's default rule. 2537c87b03e5Sespiecpp.dvi: $(TEXI_CPP_FILES) 2538c87b03e5Sespie $(TEXI2DVI) -I $(docdir) -I $(docdir)/include $(docdir)/cpp.texi 2539c87b03e5Sespie 2540c87b03e5Sespiegcc.dvi: $(TEXI_GCC_FILES) 2541c87b03e5Sespie $(TEXI2DVI) -I $(docdir) -I $(docdir)/include $(docdir)/gcc.texi 2542c87b03e5Sespie 2543c87b03e5Sespiegccint.dvi: $(TEXI_GCCINT_FILES) 2544c87b03e5Sespie $(TEXI2DVI) -I $(docdir) -I $(docdir)/include $(docdir)/gccint.texi 2545c87b03e5Sespie 2546c87b03e5Sespiegccinstall.dvi: $(TEXI_GCCINSTALL_FILES) 2547c87b03e5Sespie s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \ 2548c87b03e5Sespie $(TEXI2DVI) -I $$s/doc -I $$s/doc/include -o $@ $$s/doc/install.texi 2549c87b03e5Sespie 2550c87b03e5Sespiecppinternals.dvi: $(TEXI_CPPINT_FILES) 2551c87b03e5Sespie $(TEXI2DVI) -I $(docdir) -I $(docdir)/include $(docdir)/cppinternals.texi 2552c87b03e5Sespie 25534fed0f8cSespiegenerated-manpages: gcov.1 cpp.1 gcc.1 \ 25544fed0f8cSespie gfdl.7 gpl.7 fsf-funding.7 \ 2555c87b03e5Sespie lang.generated-manpages 2556c87b03e5Sespie 25574fed0f8cSespiegcov.1: $(docdir)/gcov.texi 25584fed0f8cSespie $(STAMP) gcov.1 2559c87b03e5Sespie -$(TEXI2POD) $(docdir)/gcov.texi > gcov.pod 25604fed0f8cSespie -($(POD2MAN) --section=1 gcov.pod > gcov.1.T$$$$ && \ 25614fed0f8cSespie mv -f gcov.1.T$$$$ gcov.1) || \ 25624fed0f8cSespie (rm -f gcov.1.T$$$$ && exit 1) 2563c87b03e5Sespie -rm -f gcov.pod 2564c87b03e5Sespie 25654fed0f8cSespiecpp.1: $(docdir)/cpp.texi $(docdir)/cppenv.texi \ 2566c87b03e5Sespie $(docdir)/cppopts.texi 25674fed0f8cSespie $(STAMP) cpp.1 2568c87b03e5Sespie -$(TEXI2POD) $(docdir)/cpp.texi > cpp.pod 25694fed0f8cSespie -($(POD2MAN) --section=1 cpp.pod > cpp.1.T$$$$ && \ 25704fed0f8cSespie mv -f cpp.1.T$$$$ cpp.1) || \ 25714fed0f8cSespie (rm -f cpp.1.T$$$$ && exit 1) 2572c87b03e5Sespie -rm -f cpp.pod 2573c87b03e5Sespie 25744fed0f8cSespiegcc.1: $(docdir)/invoke.texi $(docdir)/cppenv.texi \ 2575c87b03e5Sespie $(docdir)/cppopts.texi 25764fed0f8cSespie $(STAMP) gcc.1 2577c87b03e5Sespie -$(TEXI2POD) $(docdir)/invoke.texi > gcc.pod 25784fed0f8cSespie -($(POD2MAN) --section=1 gcc.pod > gcc.1.T$$$$ && \ 25794fed0f8cSespie mv -f gcc.1.T$$$$ gcc.1) || \ 25804fed0f8cSespie (rm -f gcc.1.T$$$$ && exit 1) 2581c87b03e5Sespie -rm -f gcc.pod 2582c87b03e5Sespie 25834fed0f8cSespiegfdl.7: $(docdir)/include/fdl.texi 25844fed0f8cSespie $(STAMP) gfdl.7 2585c87b03e5Sespie -$(TEXI2POD) $(docdir)/include/fdl.texi > gfdl.pod 25864fed0f8cSespie -($(POD2MAN) --section=7 gfdl.pod > gfdl.7.T$$$$ && \ 25874fed0f8cSespie mv -f gfdl.7.T$$$$ gfdl.7) || \ 25884fed0f8cSespie (rm -f gfdl.7.T$$$$ && exit 1) 2589c87b03e5Sespie -rm -f gfdl.pod 2590c87b03e5Sespie 25914fed0f8cSespiegpl.7: $(docdir)/include/gpl.texi 25924fed0f8cSespie $(STAMP) gpl.7 2593c87b03e5Sespie -$(TEXI2POD) $(docdir)/include/gpl.texi > gpl.pod 25944fed0f8cSespie -($(POD2MAN) --section=7 gpl.pod > gpl.7.T$$$$ && \ 25954fed0f8cSespie mv -f gpl.7.T$$$$ gpl.7) || \ 25964fed0f8cSespie (rm -f gpl.7.T$$$$ && exit 1) 2597c87b03e5Sespie -rm -f gpl.pod 2598c87b03e5Sespie 25994fed0f8cSespiefsf-funding.7: $(docdir)/include/funding.texi 26004fed0f8cSespie $(STAMP) fsf-funding.7 2601c87b03e5Sespie -$(TEXI2POD) $(docdir)/include/funding.texi > fsf-funding.pod 2602c87b03e5Sespie -($(POD2MAN) --section=7 fsf-funding.pod \ 26034fed0f8cSespie > fsf-funding.7.T$$$$ && \ 26044fed0f8cSespie mv -f fsf-funding.7.T$$$$ fsf-funding.7) || \ 26054fed0f8cSespie (rm -f fsf-funding.7.T$$$$ && exit 1) 2606c87b03e5Sespie -rm -f fsf-funding.pod 2607c87b03e5Sespie 2608c87b03e5Sespie# 2609c87b03e5Sespie# Deletion of files made during compilation. 2610c87b03e5Sespie# There are four levels of this: 2611c87b03e5Sespie# `mostlyclean', `clean', `distclean' and `maintainer-clean'. 2612c87b03e5Sespie# `mostlyclean' is useful while working on a particular type of machine. 2613c87b03e5Sespie# It deletes most, but not all, of the files made by compilation. 2614c87b03e5Sespie# It does not delete libgcc.a or its parts, so it won't have to be recompiled. 2615c87b03e5Sespie# `clean' deletes everything made by running `make all'. 2616c87b03e5Sespie# `distclean' also deletes the files made by config. 2617c87b03e5Sespie# `maintainer-clean' also deletes everything that could be regenerated 2618c87b03e5Sespie# automatically, except for `configure'. 2619c87b03e5Sespie# We remove as much from the language subdirectories as we can 2620c87b03e5Sespie# (less duplicated code). 2621c87b03e5Sespie 2622c87b03e5SespieINTL_MOSTLYCLEAN = intl.mostlyclean 2623c87b03e5Sespiemostlyclean: $(INTL_MOSTLYCLEAN) lang.mostlyclean 2624c87b03e5Sespie -rm -f $(STAGESTUFF) 2625c87b03e5Sespie -rm -f *$(coverageexts) 2626c87b03e5Sespie -rm -rf libgcc 2627c87b03e5Sespie# Delete the temporary source copies for cross compilation. 2628c87b03e5Sespie -rm -f $(BUILD_PREFIX_1)rtl.c $(BUILD_PREFIX_1)print-rtl.c 2629c87b03e5Sespie -rm -f $(BUILD_PREFIX_1)bitmap.c $(BUILD_PREFIX_1)errors.c 2630c87b03e5Sespie -rm -f $(BUILD_PREFIX_1)ggc-none.c 2631c87b03e5Sespie# Delete the temp files made in the course of building libgcc.a. 2632c87b03e5Sespie -rm -f xlimits.h 2633c87b03e5Sespie# Delete other built files. 2634c87b03e5Sespie -rm -f xsys-protos.hT 2635c87b03e5Sespie -rm -f specs.h options.h gencheck.h 2636c87b03e5Sespie# Delete the stamp and temporary files. 2637c87b03e5Sespie -rm -f s-* tmp-* stamp-* stmp-* 2638c87b03e5Sespie -rm -f */stamp-* */tmp-* 2639c87b03e5Sespie# Delete debugging dump files. 2640c87b03e5Sespie -rm -f *.[0-9][0-9].* */*.[0-9][0-9].* 2641c87b03e5Sespie# Delete some files made during installation. 2642c87b03e5Sespie -rm -f specs SYSCALLS.c.X SYSCALLS.c 2643c87b03e5Sespie -rm -f collect collect2 mips-tfile mips-tdump 2644c87b03e5Sespie# Delete files generated for fixproto 2645c87b03e5Sespie -rm -rf fix-header$(build_exeext) xsys-protos.h deduced.h tmp-deduced.h \ 2646c87b03e5Sespie gen-protos$(build_exeext) fixproto.list fixtmp.* fixhdr.ready 2647c87b03e5Sespie# Delete files generated for fixincl 2648c87b03e5Sespie -rm -rf fixincl fixinc.sh specs.ready 2649c87b03e5Sespie (cd fixinc && $(MAKE) clean) 2650c87b03e5Sespie# Delete unwanted output files from TeX. 2651c87b03e5Sespie -rm -f *.toc *.log *.vr *.fn *.cp *.tp *.ky *.pg 2652c87b03e5Sespie -rm -f */*.toc */*.log */*.vr */*.fn */*.cp */*.tp */*.ky */*.pg 2653c87b03e5Sespie# Delete sorted indices we don't actually use. 2654c87b03e5Sespie -rm -f gcc.vrs gcc.kys gcc.tps gcc.pgs gcc.fns 2655c87b03e5Sespie# Delete core dumps. 2656c87b03e5Sespie -rm -f core */core 2657c87b03e5Sespie# Delete file generated for gengtype.c 2658c87b03e5Sespie -rm -f gtyp-gen.h 2659c87b03e5Sespie# Delete files generated by gengtype.c 2660c87b03e5Sespie -rm -f gtype-* 2661c87b03e5Sespie -rm -f gt-* 2662c87b03e5Sespie 2663c87b03e5Sespie# Delete all files made by compilation 2664c87b03e5Sespie# that don't exist in the distribution. 2665c87b03e5SespieINTL_CLEAN = intl.clean 2666c87b03e5Sespieclean: mostlyclean $(INTL_CLEAN) lang.clean 2667c87b03e5Sespie -rm -f libgcc.a libgcc_eh.a libgcc_s$(SHLIB_EXT) libgcc_s$(SHLIB_EXT).1 2668c87b03e5Sespie -rm -f config.h tconfig.h hconfig.h tm_p.h 2669c87b03e5Sespie -rm -f cs-* 2670c87b03e5Sespie -rm -rf libgcc 2671c87b03e5Sespie -rm -f *.dvi 2672c87b03e5Sespie -rm -f */*.dvi 2673c87b03e5Sespie# Delete the include directory. 2674c87b03e5Sespie -rm -rf include 2675c87b03e5Sespie# Delete files used by the "multilib" facility (including libgcc subdirs). 2676c87b03e5Sespie -rm -f multilib.h tmpmultilib* 2677c87b03e5Sespie -if [ "x$(MULTILIB_DIRNAMES)" != x ] ; then \ 2678c87b03e5Sespie rm -rf $(MULTILIB_DIRNAMES); \ 2679c87b03e5Sespie else if [ "x$(MULTILIB_OPTIONS)" != x ] ; then \ 2680c87b03e5Sespie rm -rf `echo $(MULTILIB_OPTIONS) | sed -e 's/\// /g'`; \ 2681c87b03e5Sespie fi ; fi 2682c87b03e5Sespie -rm -fr stage1 stage2 stage3 stage4 2683c87b03e5Sespie# Delete stamps of bootstrap stages 2684c87b03e5Sespie -rm -f stage?_* 2685c87b03e5Sespie -rm -f clean?_* 2686c87b03e5Sespie -rm -f stage_last 2687c87b03e5Sespie 2688c87b03e5Sespie# Delete all files that users would normally create 2689c87b03e5Sespie# while building and installing GCC. 2690c87b03e5SespieINTL_DISTCLEAN = intl.distclean 2691c87b03e5Sespiedistclean: clean $(INTL_DISTCLEAN) lang.distclean 2692c87b03e5Sespie -rm -f auto-host.h auto-build.h 2693c87b03e5Sespie -rm -f cstamp-h 2694c87b03e5Sespie -rm -f config.status config.run config.cache config.bak 2695c87b03e5Sespie -rm -f Make-lang Make-hooks Make-host Make-target 2696c87b03e5Sespie -rm -f Makefile *.oaux 2697c87b03e5Sespie -rm -f gthr-default.h 2698c87b03e5Sespie -rm -f */stage1 */stage2 */stage3 */stage4 */include 2699c87b03e5Sespie -rm -f c-parse.output 2700c87b03e5Sespie -rm -f *.asm 2701c87b03e5Sespie -rm -f site.exp site.bak testsuite/site.exp testsuite/site.bak 2702c87b03e5Sespie -rm -f testsuite/*.log testsuite/*.sum 2703c87b03e5Sespie -cd testsuite && rm -f x *.x *.x? *.exe *.rpo *.o *.s *.S *.c 2704c87b03e5Sespie -cd testsuite && rm -f *.out *.gcov *.bb *.bbg 2705c87b03e5Sespie -rm -rf ${QMTEST_DIR} stamp-qmtest 2706c87b03e5Sespie -rm -f intl/libintl.h libintl.h 2707c87b03e5Sespie -rm -f cxxmain.c 2708c87b03e5Sespie -rm -f mklibgcc mkheaders gccbug .gdbinit configargs.h 2709c87b03e5Sespie -rm -f gcov.pod 2710c87b03e5Sespie -rm -f fixinc/Makefile 2711c87b03e5Sespie# Delete po/*.gmo only if we are not building in the source directory. 2712c87b03e5Sespie -if [ ! -f po/exgettext ]; then rm -f po/*.gmo; fi 2713c87b03e5Sespie -rmdir ada cp f java objc fixinc intl po testsuite 2>/dev/null 2714c87b03e5Sespie 2715c87b03e5Sespie# Delete anything likely to be found in the source directory 2716c87b03e5Sespie# that shouldn't be in the distribution. 2717c87b03e5Sespieextraclean: distclean lang.extraclean 2718c87b03e5Sespie -rm -rf =* ./"#"* *~* config/=* config/"#"* config/*~* 2719c87b03e5Sespie -rm -f patch* *.orig *.rej config/patch* config/*.orig config/*.rej 2720c87b03e5Sespie -rm -f config/*/=* config/*/"#"* config/*/*~* 2721c87b03e5Sespie -rm -f config/*/*.orig config/*/*.rej 2722c87b03e5Sespie -rm -f *.dvi *.ps *.oaux *.d *.[zZ] *.gz 2723c87b03e5Sespie -rm -f *.tar *.xtar *diff *.diff.* *.tar.* *.xtar.* *diffs 2724c87b03e5Sespie -rm -f *lose config/*lose config/*/*lose 2725c87b03e5Sespie -rm -f *.s *.s[0-9] *.i config/ChangeLog 2726c87b03e5Sespie -rm -f y.tab.c yacc.* 2727c87b03e5Sespie -rm -f */=* */"#"* */*~* 2728c87b03e5Sespie -rm -f */patch* */*.orig */*.rej 2729c87b03e5Sespie -rm -f */*.dvi */*.oaux */*.d */*.[zZ] */*.gz 2730c87b03e5Sespie -rm -f */*.tar */*.xtar */*diff */*.diff.* */*.tar.* */*.xtar.* */*diffs 2731c87b03e5Sespie -rm -f */*lose */*.s */*.s[0-9] */*.i 2732c87b03e5Sespie 2733c87b03e5Sespie# Get rid of every file that's generated from some other file, except for `configure'. 2734c87b03e5Sespie# Most of these files ARE PRESENT in the GCC distribution. 2735c87b03e5Sespie# We define INTL_DISTCLEAN, INTL_CLEAN & INTL_MOSTLYCLEAN to be empty in the 2736c87b03e5Sespie# submake, so that we don't descend into intl after its makefile has been 2737c87b03e5Sespie# removed. 2738c87b03e5Sespiemaintainer-clean: 2739c87b03e5Sespie @echo 'This command is intended for maintainers to use; it' 2740c87b03e5Sespie @echo 'deletes files that may need special tools to rebuild.' 2741c87b03e5Sespie $(MAKE) INTL_DISTCLEAN= INTL_CLEAN= INTL_MOSTLYCLEAN= \ 2742c87b03e5Sespie intl.maintainer-clean lang.maintainer-clean distclean 2743c87b03e5Sespie -rm -f c-parse.y c-parse.c c-parse.output TAGS 2744c87b03e5Sespie -rm -f cpp.??s cpp.*aux 2745c87b03e5Sespie -rm -f gcc.??s gcc.*aux 27463fc3b67eSespie -rm -f cpp.info* gcc.info* gccint.info* 27473fc3b67eSespie -rm -f cppinternals.info* 27483fc3b67eSespie -rm -f gcov.1 cpp.1 gcc.1 27493fc3b67eSespie -rm -f fsf-funding.7 gfdl.7 gpl.7 2750c87b03e5Sespie# 2751c87b03e5Sespie# Entry points `install' and `uninstall'. 2752c87b03e5Sespie# Also use `install-collect2' to install collect2 when the config files don't. 2753c87b03e5Sespie 2754c87b03e5Sespie# Copy the compiler files into directories where they will be run. 2755c87b03e5Sespie# Install the driver last so that the window when things are 2756c87b03e5Sespie# broken is small. 2757c87b03e5Sespieinstall: install-common $(INSTALL_HEADERS) $(INSTALL_LIBGCC) \ 2758c87b03e5Sespie install-cpp install-man install-info intl.install install-@POSUB@ \ 2759c87b03e5Sespie lang.install-normal install-driver 2760c87b03e5Sespie 2761c87b03e5Sespie# Handle cpp installation. 2762c87b03e5Sespieinstall-cpp: cpp$(exeext) 2763c87b03e5Sespie -if [ -f gcc-cross$(exeext) ] ; then \ 2764c87b03e5Sespie rm -f $(DESTDIR)$(bindir)/$(CPP_CROSS_NAME)$(exeext); \ 2765c87b03e5Sespie $(INSTALL_PROGRAM) -m 755 cpp$(exeext) $(DESTDIR)$(bindir)/$(CPP_CROSS_NAME)$(exeext); \ 2766c87b03e5Sespie if [ x$(cpp_install_dir) != x ]; then \ 2767c87b03e5Sespie rm -f $(DESTDIR)$(prefix)/$(cpp_install_dir)/$(CPP_CROSS_NAME)$(exeext); \ 2768c87b03e5Sespie $(INSTALL_PROGRAM) -m 755 cpp$(exeext) $(DESTDIR)$(prefix)/$(cpp_install_dir)/$(CPP_CROSS_NAME)$(exeext); \ 2769c87b03e5Sespie else true; fi; \ 2770c87b03e5Sespie else \ 2771c87b03e5Sespie rm -f $(DESTDIR)$(bindir)/$(CPP_INSTALL_NAME)$(exeext); \ 2772c87b03e5Sespie $(INSTALL_PROGRAM) -m 755 cpp$(exeext) $(DESTDIR)$(bindir)/$(CPP_INSTALL_NAME)$(exeext); \ 2773c87b03e5Sespie if [ x$(cpp_install_dir) != x ]; then \ 2774c87b03e5Sespie rm -f $(DESTDIR)$(prefix)/$(cpp_install_dir)/$(CPP_INSTALL_NAME)$(exeext); \ 2775c87b03e5Sespie $(INSTALL_PROGRAM) -m 755 cpp$(exeext) $(DESTDIR)$(prefix)/$(cpp_install_dir)/$(CPP_INSTALL_NAME)$(exeext); \ 2776c87b03e5Sespie else true; fi; \ 2777c87b03e5Sespie fi 2778c87b03e5Sespie 2779c87b03e5Sespie# Create the installation directories. 2780c87b03e5Sespie# $(libdir)/gcc-lib/include isn't currently searched by cpp. 2781c87b03e5Sespieinstalldirs: 2782c87b03e5Sespie $(SHELL) ${srcdir}/mkinstalldirs $(DESTDIR)$(libsubdir) 2783c87b03e5Sespie $(SHELL) ${srcdir}/mkinstalldirs $(DESTDIR)$(bindir) 2784c87b03e5Sespie $(SHELL) ${srcdir}/mkinstalldirs $(DESTDIR)$(includedir) 2785c87b03e5Sespie $(SHELL) ${srcdir}/mkinstalldirs $(DESTDIR)$(infodir) 2786c87b03e5Sespie $(SHELL) ${srcdir}/mkinstalldirs $(DESTDIR)$(slibdir) 2787c87b03e5Sespie $(SHELL) ${srcdir}/mkinstalldirs $(DESTDIR)$(man1dir) 2788c87b03e5Sespie $(SHELL) ${srcdir}/mkinstalldirs $(DESTDIR)$(man7dir) 2789c87b03e5Sespie 2790c87b03e5Sespie# Install the compiler executables built during cross compilation. 2791c87b03e5Sespieinstall-common: native $(EXTRA_PARTS) lang.install-common 2792c87b03e5Sespie for file in $(COMPILERS); do \ 2793c87b03e5Sespie if [ -f $$file ] ; then \ 2794c87b03e5Sespie rm -f $(DESTDIR)$(libsubdir)/$$file; \ 2795c87b03e5Sespie $(INSTALL_PROGRAM) $$file $(DESTDIR)$(libsubdir)/$$file; \ 2796c87b03e5Sespie else true; \ 2797c87b03e5Sespie fi; \ 2798c87b03e5Sespie done 2799c87b03e5Sespie for file in $(EXTRA_PASSES) $(EXTRA_PROGRAMS) $(USE_COLLECT2) ..; do \ 2800c87b03e5Sespie if [ x"$$file" != x.. ]; then \ 2801c87b03e5Sespie rm -f $(DESTDIR)$(libsubdir)/$$file; \ 2802c87b03e5Sespie $(INSTALL_PROGRAM) $$file $(DESTDIR)$(libsubdir)/$$file; \ 2803c87b03e5Sespie else true; fi; \ 2804c87b03e5Sespie done 2805c87b03e5Sespie for file in $(EXTRA_PARTS) ..; do \ 2806c87b03e5Sespie if [ x"$$file" != x.. ]; then \ 2807c87b03e5Sespie rm -f $(DESTDIR)$(libsubdir)/$$file; \ 2808c87b03e5Sespie $(INSTALL_DATA) $$file $(DESTDIR)$(libsubdir)/$$file; \ 2809c87b03e5Sespie chmod a-x $(DESTDIR)$(libsubdir)/$$file; \ 2810c87b03e5Sespie else true; fi; \ 2811c87b03e5Sespie done 2812c87b03e5Sespie# Don't mess with specs if it doesn't exist yet. 2813c87b03e5Sespie -if [ -f specs ] ; then \ 2814c87b03e5Sespie rm -f $(DESTDIR)$(libsubdir)/specs; \ 2815c87b03e5Sespie $(INSTALL_DATA) specs $(DESTDIR)$(libsubdir)/specs; \ 2816c87b03e5Sespie chmod a-x $(DESTDIR)$(libsubdir)/specs; \ 2817c87b03e5Sespie fi 2818c87b03e5Sespie# Install protoize if it was compiled. 2819c87b03e5Sespie -if [ -f protoize$(exeext) ]; \ 2820c87b03e5Sespie then \ 2821c87b03e5Sespie if [ -f gcc-cross$(exeext) ] ; then \ 2822c87b03e5Sespie rm -f $(DESTDIR)$(bindir)/$(PROTOIZE_CROSS_NAME)$(exeext); \ 2823c87b03e5Sespie $(INSTALL_PROGRAM) protoize$(exeext) $(DESTDIR)$(bindir)/$(PROTOIZE_CROSS_NAME)$(exeext); \ 2824c87b03e5Sespie rm -f $(DESTDIR)$(bindir)/$(UNPROTOIZE_CROSS_NAME)$(exeext); \ 2825c87b03e5Sespie $(INSTALL_PROGRAM) unprotoize$(exeext) $(DESTDIR)$(bindir)/$(UNPROTOIZE_CROSS_NAME)$(exeext); \ 2826c87b03e5Sespie else \ 2827c87b03e5Sespie rm -f $(DESTDIR)$(bindir)/$(PROTOIZE_INSTALL_NAME)$(exeext); \ 2828c87b03e5Sespie $(INSTALL_PROGRAM) protoize$(exeext) $(DESTDIR)$(bindir)/$(PROTOIZE_INSTALL_NAME)$(exeext); \ 2829c87b03e5Sespie rm -f $(DESTDIR)$(bindir)/$(UNPROTOIZE_INSTALL_NAME)$(exeext); \ 2830c87b03e5Sespie $(INSTALL_PROGRAM) unprotoize$(exeext) $(DESTDIR)$(bindir)/$(UNPROTOIZE_INSTALL_NAME)$(exeext); \ 2831c87b03e5Sespie fi ; \ 2832c87b03e5Sespie rm -f $(DESTDIR)$(libsubdir)/SYSCALLS.c.X; \ 2833c87b03e5Sespie $(INSTALL_DATA) SYSCALLS.c.X $(DESTDIR)$(libsubdir)/SYSCALLS.c.X; \ 2834c87b03e5Sespie chmod a-x $(DESTDIR)$(libsubdir)/SYSCALLS.c.X; \ 2835c87b03e5Sespie fi 2836c87b03e5Sespie# Install gcov if it was compiled. 2837c87b03e5Sespie -if [ -f gcov$(exeext) ]; \ 2838c87b03e5Sespie then \ 2839c87b03e5Sespie rm -f $(DESTDIR)$(bindir)/gcov$(exeext); \ 2840c87b03e5Sespie $(INSTALL_PROGRAM) gcov$(exeext) $(DESTDIR)$(bindir)/$(GCOV_INSTALL_NAME)$(exeext); \ 2841c87b03e5Sespie fi 2842c87b03e5Sespie $(INSTALL_SCRIPT) gccbug $(DESTDIR)$(bindir)/$(GCCBUG_INSTALL_NAME) 2843c87b03e5Sespie 2844c87b03e5Sespie# Install the driver program as $(target_alias)-gcc, 2845c87b03e5Sespie# $(target-alias)-gcc-$(version) 2846c87b03e5Sespie# and also as either gcc (if native) or $(gcc_tooldir)/bin/gcc. 2847c87b03e5Sespieinstall-driver: installdirs xgcc$(exeext) 2848c87b03e5Sespie -if [ -f gcc-cross$(exeext) ] ; then \ 2849c87b03e5Sespie rm -f $(DESTDIR)$(bindir)/$(GCC_CROSS_NAME)$(exeext); \ 2850c87b03e5Sespie $(INSTALL_PROGRAM) gcc-cross$(exeext) $(DESTDIR)$(bindir)/$(GCC_CROSS_NAME)$(exeext); \ 2851c87b03e5Sespie rm -f $(DESTDIR)$(bindir)/$(target_alias)-gcc-$(version); \ 2852c87b03e5Sespie ( cd $(DESTDIR)$(bindir) && \ 2853c87b03e5Sespie $(LN) $(GCC_CROSS_NAME)$(exeext) $(target_alias)-gcc-$(version) ); \ 2854c87b03e5Sespie if [ -d $(DESTDIR)$(gcc_tooldir)/bin/. ] ; then \ 2855c87b03e5Sespie rm -f $(DESTDIR)$(gcc_tooldir)/bin/gcc$(exeext); \ 2856c87b03e5Sespie $(INSTALL_PROGRAM) gcc-cross$(exeext) $(DESTDIR)$(gcc_tooldir)/bin/gcc$(exeext); \ 2857c87b03e5Sespie else true; fi; \ 2858c87b03e5Sespie else \ 2859c87b03e5Sespie rm -f $(DESTDIR)$(bindir)/$(GCC_INSTALL_NAME)$(exeext); \ 2860c87b03e5Sespie $(INSTALL_PROGRAM) xgcc$(exeext) $(DESTDIR)$(bindir)/$(GCC_INSTALL_NAME)$(exeext); \ 2861c87b03e5Sespie rm -f $(DESTDIR)$(bindir)/$(target_alias)-gcc-$(version); \ 2862c87b03e5Sespie ( cd $(DESTDIR)$(bindir) && \ 2863c87b03e5Sespie $(LN) $(GCC_INSTALL_NAME)$(exeext) $(target_alias)-gcc-$(version) ); \ 2864c87b03e5Sespie rm -f $(DESTDIR)$(bindir)/$(target_alias)-gcc-tmp$(exeext); \ 2865c87b03e5Sespie ( cd $(DESTDIR)$(bindir) && \ 2866c87b03e5Sespie $(LN) $(GCC_INSTALL_NAME)$(exeext) $(target_alias)-gcc-tmp$(exeext) && \ 2867c87b03e5Sespie mv -f $(target_alias)-gcc-tmp$(exeext) $(GCC_TARGET_INSTALL_NAME)$(exeext) ); \ 2868c87b03e5Sespie fi 2869c87b03e5Sespie 2870c87b03e5Sespie# Install the info files. 2871c87b03e5Sespie# $(INSTALL_DATA) might be a relative pathname, so we can't cd into srcdir 2872c87b03e5Sespie# to do the install. 2873c87b03e5Sespieinstall-info: doc installdirs lang.install-info 2874c87b03e5Sespie -rm -f $(DESTDIR)$(infodir)/cpp.info* $(DESTDIR)$(infodir)/gcc.info* 2875c87b03e5Sespie -rm -f $(DESTDIR)$(infodir)/cppinternals.info* $(DESTDIR)$(infodir)/gccint.info* 28763fc3b67eSespie if [ -f gcc.info ]; then \ 28773fc3b67eSespie for f in cpp.info* gcc.info* \ 28783fc3b67eSespie cppinternals.info* gccint.info*; do \ 2879c87b03e5Sespie realfile=`echo $$f | sed -e 's|.*/\([^/]*\)$$|\1|'`; \ 2880c87b03e5Sespie $(INSTALL_DATA) $$f $(DESTDIR)$(infodir)/$$realfile; \ 2881c87b03e5Sespie done; \ 2882c87b03e5Sespie else true; fi 2883c87b03e5Sespie -if $(SHELL) -c 'install-info --version' >/dev/null 2>&1; then \ 2884c87b03e5Sespie if [ -f $(DESTDIR)$(infodir)/dir ] ; then \ 2885c87b03e5Sespie for f in cpp.info gcc.info gccint.info cppinternals.info; do \ 2886c87b03e5Sespie if [ -f $(DESTDIR)$(infodir)/$$f ]; then \ 2887c87b03e5Sespie install-info --dir-file=$(DESTDIR)$(infodir)/dir $(DESTDIR)$(infodir)/$$f; \ 2888c87b03e5Sespie else true; fi; \ 2889c87b03e5Sespie done; \ 2890c87b03e5Sespie else true; fi; \ 2891c87b03e5Sespie else true; fi; 2892c87b03e5Sespie -chmod a-x $(DESTDIR)$(infodir)/cpp.info* $(DESTDIR)$(infodir)/gcc.info* 2893c87b03e5Sespie -chmod a-x $(DESTDIR)$(infodir)/cppinternals.info* $(DESTDIR)$(infodir)/gccint.info* 2894c87b03e5Sespie 2895c87b03e5Sespie# Install the man pages. 2896c87b03e5Sespieinstall-man: installdirs $(GENERATED_MANPAGES) lang.install-man 2897c87b03e5Sespie -if [ -f gcc-cross$(exeext) ] ; then \ 2898c87b03e5Sespie rm -f $(DESTDIR)$(man1dir)/$(GCC_CROSS_NAME)$(man1ext); \ 2899c87b03e5Sespie $(INSTALL_DATA) $(docdir)/gcc.1 $(DESTDIR)$(man1dir)/$(GCC_CROSS_NAME)$(man1ext); \ 2900c87b03e5Sespie chmod a-x $(DESTDIR)$(man1dir)/$(GCC_CROSS_NAME)$(man1ext); \ 2901c87b03e5Sespie else \ 2902c87b03e5Sespie rm -f $(DESTDIR)$(man1dir)/$(GCC_INSTALL_NAME)$(man1ext); \ 2903c87b03e5Sespie $(INSTALL_DATA) $(docdir)/gcc.1 $(DESTDIR)$(man1dir)/$(GCC_INSTALL_NAME)$(man1ext); \ 2904c87b03e5Sespie chmod a-x $(DESTDIR)$(man1dir)/$(GCC_INSTALL_NAME)$(man1ext); \ 2905c87b03e5Sespie fi 2906c87b03e5Sespie -rm -f $(DESTDIR)$(man1dir)/cpp$(man1ext) 2907c87b03e5Sespie -$(INSTALL_DATA) $(docdir)/cpp.1 $(DESTDIR)$(man1dir)/cpp$(man1ext) 2908c87b03e5Sespie -chmod a-x $(DESTDIR)$(man1dir)/cpp$(man1ext) 2909c87b03e5Sespie -rm -f $(DESTDIR)$(man1dir)/gcov$(man1ext) 2910c87b03e5Sespie -$(INSTALL_DATA) $(docdir)/gcov.1 $(DESTDIR)$(man1dir)/gcov$(man1ext) 2911c87b03e5Sespie -chmod a-x $(DESTDIR)$(man1dir)/gcov$(man1ext) 2912c87b03e5Sespie -rm -f $(DESTDIR)$(man7dir)/fsf-funding$(man7ext) 2913c87b03e5Sespie -$(INSTALL_DATA) $(docdir)/fsf-funding.7 $(DESTDIR)$(man7dir)/fsf-funding$(man7ext) 2914c87b03e5Sespie -chmod a-x $(DESTDIR)$(man7dir)/fsf-funding$(man7ext) 2915c87b03e5Sespie -rm -f $(DESTDIR)$(man7dir)/gfdl$(man7ext) 2916c87b03e5Sespie -$(INSTALL_DATA) $(docdir)/gfdl.7 $(DESTDIR)$(man7dir)/gfdl$(man7ext) 2917c87b03e5Sespie -chmod a-x $(DESTDIR)$(man7dir)/gfdl$(man7ext) 2918c87b03e5Sespie -rm -f $(DESTDIR)$(man7dir)/gpl$(man7ext) 2919c87b03e5Sespie -$(INSTALL_DATA) $(docdir)/gpl.7 $(DESTDIR)$(man7dir)/gpl$(man7ext) 2920c87b03e5Sespie -chmod a-x $(DESTDIR)$(man7dir)/gpl$(man7ext) 2921c87b03e5Sespie 2922c87b03e5Sespie# Install the library. 2923c87b03e5Sespieinstall-libgcc: libgcc.mk libgcc.a installdirs 2924c87b03e5Sespie if $(RANLIB_TEST_FOR_TARGET); then \ 2925c87b03e5Sespie r_f_t=$(RANLIB_FOR_TARGET); \ 2926c87b03e5Sespie else \ 2927c87b03e5Sespie r_f_t=: ; \ 2928c87b03e5Sespie fi; \ 2929c87b03e5Sespie $(MAKE) GCC_FOR_TARGET="$(GCC_FOR_TARGET)" \ 2930c87b03e5Sespie BUILD_PREFIX="$(BUILD_PREFIX)" BUILD_PREFIX_1="$(BUILD_PREFIX_1)" \ 2931c87b03e5Sespie AR_FOR_TARGET="$(AR_FOR_TARGET)" \ 2932c87b03e5Sespie AR_CREATE_FOR_TARGET="$(AR_CREATE_FOR_TARGET)" \ 2933c87b03e5Sespie AR_FLAGS_FOR_TARGET="$(AR_FLAGS_FOR_TARGET)" \ 2934c87b03e5Sespie CFLAGS="$(CFLAGS) $(WARN_CFLAGS)" \ 2935c87b03e5Sespie RANLIB_TEST_FOR_TARGET="$(RANLIB_TEST_FOR_TARGET)" \ 2936c87b03e5Sespie NM_FOR_TARGET="$(NM_FOR_TARGET)" AWK="$(AWK)" \ 2937c87b03e5Sespie LIBGCC2_CFLAGS="$(LIBGCC2_CFLAGS)" \ 2938c87b03e5Sespie INCLUDES="$(INCLUDES)" \ 2939c87b03e5Sespie CONFIG_H="$(TCONFIG_H)" MACHMODE_H="$(MACHMODE_H)" \ 2940c87b03e5Sespie LIB1ASMSRC='$(LIB1ASMSRC)' \ 2941c87b03e5Sespie MAKEOVERRIDES= \ 2942c87b03e5Sespie INSTALL_DATA="$(INSTALL_DATA)" \ 2943c87b03e5Sespie RANLIB_FOR_TARGET="$$r_f_t" \ 2944c87b03e5Sespie DESTDIR="$(DESTDIR)" \ 2945c87b03e5Sespie libsubdir="$(libsubdir)" \ 2946c87b03e5Sespie slibdir="$(slibdir)" \ 2947c87b03e5Sespie -f libgcc.mk install 2948c87b03e5Sespie 2949c87b03e5Sespie# Install multiple versions of libgcc.a. 2950c87b03e5Sespieinstall-multilib: stmp-multilib installdirs 2951c87b03e5Sespie if $(RANLIB_TEST_FOR_TARGET); then \ 2952c87b03e5Sespie r_f_t=$(RANLIB_FOR_TARGET); \ 2953c87b03e5Sespie else \ 2954c87b03e5Sespie r_f_t=: ; \ 2955c87b03e5Sespie fi; \ 2956c87b03e5Sespie $(MAKE) GCC_FOR_TARGET="$(GCC_FOR_TARGET)" \ 2957c87b03e5Sespie BUILD_PREFIX="$(BUILD_PREFIX)" BUILD_PREFIX_1="$(BUILD_PREFIX_1)" \ 2958c87b03e5Sespie AR_FOR_TARGET="$(AR_FOR_TARGET)" \ 2959c87b03e5Sespie AR_CREATE_FOR_TARGET="$(AR_CREATE_FOR_TARGET)" \ 2960c87b03e5Sespie AR_FLAGS_FOR_TARGET="$(AR_FLAGS_FOR_TARGET)" \ 2961c87b03e5Sespie CFLAGS="$(CFLAGS) $(WARN_CFLAGS)" \ 2962c87b03e5Sespie RANLIB_TEST_FOR_TARGET="$(RANLIB_TEST_FOR_TARGET)" \ 2963c87b03e5Sespie NM_FOR_TARGET="$(NM_FOR_TARGET)" AWK="$(AWK)" \ 2964c87b03e5Sespie LIBGCC2_CFLAGS="$(LIBGCC2_CFLAGS)" \ 2965c87b03e5Sespie INCLUDES="$(INCLUDES)" \ 2966c87b03e5Sespie CONFIG_H="$(CONFIG_H)" MACHMODE_H="$(MACHMODE_H)" \ 2967c87b03e5Sespie LIB1ASMSRC='$(LIB1ASMSRC)' \ 2968c87b03e5Sespie MAKEOVERRIDES= \ 2969c87b03e5Sespie INSTALL_DATA="$(INSTALL_DATA)" \ 2970c87b03e5Sespie RANLIB_FOR_TARGET="$$r_f_t" \ 2971c87b03e5Sespie DESTDIR="$(DESTDIR)" \ 2972c87b03e5Sespie libsubdir="$(libsubdir)" \ 2973c87b03e5Sespie slibdir="$(slibdir)" \ 2974c87b03e5Sespie -f libgcc.mk install 2975c87b03e5Sespie 2976c87b03e5Sespie# Install all the header files built in the include subdirectory. 2977c87b03e5Sespieinstall-headers: $(INSTALL_HEADERS_DIR) 2978c87b03e5Sespie# Fix symlinks to absolute paths in the installed include directory to 2979c87b03e5Sespie# point to the installed directory, not the build directory. 2980c87b03e5Sespie# Don't need to use LN_S here since we really do need ln -s and no substitutes. 2981c87b03e5Sespie -files=`cd $(DESTDIR)$(libsubdir)/include; find . -type l -print 2>/dev/null`; \ 2982c87b03e5Sespie if [ $$? -eq 0 ]; then \ 2983c87b03e5Sespie dir=`cd include; ${PWD_COMMAND}`; \ 2984c87b03e5Sespie for i in $$files; do \ 2985c87b03e5Sespie dest=`ls -ld $(DESTDIR)$(libsubdir)/include/$$i | sed -n 's/.*-> //p'`; \ 2986c87b03e5Sespie if expr "$$dest" : "$$dir.*" > /dev/null; then \ 2987c87b03e5Sespie rm -f $(DESTDIR)$(libsubdir)/include/$$i; \ 2988c87b03e5Sespie ln -s `echo $$i | sed "s|/[^/]*|/..|g" | sed 's|/..$$||'``echo "$$dest" | sed "s|$$dir||"` $(DESTDIR)$(libsubdir)/include/$$i; \ 2989c87b03e5Sespie fi; \ 2990c87b03e5Sespie done; \ 2991c87b03e5Sespie fi 2992c87b03e5Sespie 2993c87b03e5Sespie# Create or recreate the gcc private include file directory. 2994c87b03e5Sespieinstall-include-dir: installdirs 2995c87b03e5Sespie -rm -rf $(DESTDIR)$(libsubdir)/include 2996c87b03e5Sespie mkdir $(DESTDIR)$(libsubdir)/include 2997c87b03e5Sespie -chmod a+rx $(DESTDIR)$(libsubdir)/include 2998c87b03e5Sespie 2999c87b03e5Sespie# Install the include directory using tar. 3000c87b03e5Sespieinstall-headers-tar: stmp-int-hdrs $(STMP_FIXPROTO) install-include-dir 3001c87b03e5Sespie# We use `pwd`/include instead of just include to problems with CDPATH 3002c87b03e5Sespie# Unless a full pathname is provided, some shells would print the new CWD, 3003c87b03e5Sespie# found in CDPATH, corrupting the output. We could just redirect the 3004c87b03e5Sespie# output of `cd', but some shells lose on redirection within `()'s 3005c87b03e5Sespie (cd `${PWD_COMMAND}`/include ; \ 3006c87b03e5Sespie tar -cf - .; exit 0) | (cd $(DESTDIR)$(libsubdir)/include; tar xpf - ) 3007c87b03e5Sespie# /bin/sh on some systems returns the status of the first tar, 3008c87b03e5Sespie# and that can lose with GNU tar which always writes a full block. 3009c87b03e5Sespie# So use `exit 0' to ignore its exit status. 3010c87b03e5Sespie 3011c87b03e5Sespie# Install the include directory using cpio. 3012c87b03e5Sespieinstall-headers-cpio: stmp-int-hdrs $(STMP_FIXPROTO) install-include-dir 3013c87b03e5Sespie# See discussion about the use of `pwd` above 3014c87b03e5Sespie cd `${PWD_COMMAND}`/include ; \ 3015c87b03e5Sespie find . -print | cpio -pdum $(DESTDIR)$(libsubdir)/include 3016c87b03e5Sespie 3017c87b03e5Sespie# Install the include directory using cp. 3018c87b03e5Sespieinstall-headers-cp: stmp-int-hdrs $(STMP_FIXPROTO) install-include-dir 3019c87b03e5Sespie cp -p -r include $(DESTDIR)$(libsubdir) 3020c87b03e5Sespie 3021c87b03e5Sespieitoolsdir = $(libsubdir)/install-tools 3022c87b03e5Sespie# Don't install the headers. Instead, install appropriate scripts 3023c87b03e5Sespie# and supporting files for fixincludes to be run later. 3024c87b03e5Sespieinstall-mkheaders: stmp-int-hdrs $(STMP_FIXPROTO) install-include-dir \ 3025c87b03e5Sespie mkheaders xlimits.h 3026c87b03e5Sespie -rm -rf $(DESTDIR)$(itoolsdir) 3027c87b03e5Sespie $(SHELL) $(srcdir)/mkinstalldirs $(DESTDIR)$(itoolsdir)/include 3028c87b03e5Sespie for file in $(USER_H); do \ 3029c87b03e5Sespie realfile=`echo $$file | sed -e 's|.*/\([^/]*\)$$|\1|'`; \ 3030c87b03e5Sespie $(INSTALL_DATA) $$file \ 3031c87b03e5Sespie $(DESTDIR)$(itoolsdir)/include/$$realfile ; \ 3032c87b03e5Sespie done 3033c87b03e5Sespie $(INSTALL_DATA) xlimits.h $(DESTDIR)$(itoolsdir)/include/limits.h 3034c87b03e5Sespie if [ x$(STMP_FIXINC) != x ] ; then \ 3035c87b03e5Sespie $(INSTALL_DATA) $(srcdir)/README-fixinc \ 3036c87b03e5Sespie $(DESTDIR)$(itoolsdir)/include/README ; \ 3037c87b03e5Sespie $(INSTALL_PROGRAM) fixinc.sh $(DESTDIR)$(itoolsdir)/fixinc.sh ; \ 3038c87b03e5Sespie $(INSTALL_PROGRAM) fixinc/fixincl $(DESTDIR)$(itoolsdir)/fixincl ; \ 3039c87b03e5Sespie $(INSTALL_DATA) $(srcdir)/gsyslimits.h $(DESTDIR)$(itoolsdir)/gsyslimits.h ; \ 3040c87b03e5Sespie else :; fi 3041c87b03e5Sespie if [ x$(STMP_FIXPROTO) != x ] ; then \ 3042c87b03e5Sespie $(INSTALL_PROGRAM) $(srcdir)/mkinstalldirs \ 3043c87b03e5Sespie $(DESTDIR)$(itoolsdir)/mkinstalldirs ; \ 3044c87b03e5Sespie $(INSTALL_PROGRAM) $(srcdir)/fixproto $(DESTDIR)$(itoolsdir)/fixproto ; \ 3045c87b03e5Sespie $(INSTALL_PROGRAM) fix-header$(build_exeext) \ 3046c87b03e5Sespie $(DESTDIR)$(itoolsdir)/fix-header$(build_exeext) ; \ 3047c87b03e5Sespie else :; fi 3048c87b03e5Sespie $(INSTALL_PROGRAM) mkheaders $(DESTDIR)$(itoolsdir)/mkheaders 304906dc6460Sespie echo 'SYSTEM_HEADER_DIR="'"$(SYSTEM_HEADER_DIR)"'"' \ 3050c87b03e5Sespie > $(DESTDIR)$(itoolsdir)/mkheaders.conf 3051c87b03e5Sespie echo 'OTHER_FIXINCLUDES_DIRS="$(OTHER_FIXINCLUDES_DIRS)"' \ 3052c87b03e5Sespie >> $(DESTDIR)$(itoolsdir)/mkheaders.conf 3053c87b03e5Sespie echo 'FIXPROTO_DEFINES="$(FIXPROTO_DEFINES)"' \ 3054c87b03e5Sespie >> $(DESTDIR)$(itoolsdir)/mkheaders.conf 3055c87b03e5Sespie echo 'STMP_FIXPROTO="$(STMP_FIXPROTO)"' >> $(DESTDIR)$(itoolsdir)/mkheaders.conf 3056c87b03e5Sespie echo 'STMP_FIXINC="$(STMP_FIXINC)"' >> $(DESTDIR)$(itoolsdir)/mkheaders.conf 3057c87b03e5Sespie 3058c87b03e5Sespie# Use this target to install the program `collect2' under the name `collect2'. 3059c87b03e5Sespieinstall-collect2: collect2 installdirs 3060c87b03e5Sespie $(INSTALL_PROGRAM) collect2$(exeext) $(DESTDIR)$(libsubdir)/collect2$(exeext) 3061c87b03e5Sespie# Install the driver program as $(libsubdir)/gcc for collect2. 3062c87b03e5Sespie $(INSTALL_PROGRAM) xgcc$(exeext) $(DESTDIR)$(libsubdir)/gcc$(exeext) 3063c87b03e5Sespie 3064c87b03e5Sespie# Cancel installation by deleting the installed files. 3065c87b03e5Sespieuninstall: intl.uninstall lang.uninstall 3066c87b03e5Sespie -rm -rf $(DESTDIR)$(libsubdir) 3067c87b03e5Sespie -rm -rf $(DESTDIR)$(bindir)/$(GCC_INSTALL_NAME)$(exeext) 3068c87b03e5Sespie -rm -rf $(DESTDIR)$(bindir)/$(GCC_CROSS_NAME)$(exeext) 3069c87b03e5Sespie -rm -f $(DESTDIR)$(bindir)/$(CPP_INSTALL_NAME)$(exeext) 3070c87b03e5Sespie -rm -f $(DESTDIR)$(bindir)/$(CPP_CROSS_NAME)$(exeext) 3071c87b03e5Sespie -if [ x$(cpp_install_dir) != x ]; then \ 3072c87b03e5Sespie rm -f $(DESTDIR)$(prefix)/$(cpp_install_dir)/$(CPP_INSTALL_NAME)$(exeext); \ 3073c87b03e5Sespie rm -f $(DESTDIR)$(prefix)/$(cpp_install_dir)/$(CPP_CROSS_NAME)$(exeext); \ 3074c87b03e5Sespie else true; fi 3075c87b03e5Sespie -rm -rf $(DESTDIR)$(bindir)/$(PROTOIZE_INSTALL_NAME)$(exeext) 3076c87b03e5Sespie -rm -rf $(DESTDIR)$(bindir)/$(PROTOIZE_CROSS_NAME)$(exeext) 3077c87b03e5Sespie -rm -rf $(DESTDIR)$(bindir)/$(UNPROTOIZE_INSTALL_NAME)$(exeext) 3078c87b03e5Sespie -rm -rf $(DESTDIR)$(bindir)/$(UNPROTOIZE_CROSS_NAME)$(exeext) 3079c87b03e5Sespie -rm -rf $(DESTDIR)$(bindir)/$(GCOV_INSTALL_NAME)$(exeext) 3080c87b03e5Sespie -rm -rf $(DESTDIR)$(man1dir)/$(GCC_INSTALL_NAME)$(man1ext) 3081c87b03e5Sespie -rm -rf $(DESTDIR)$(man1dir)/$(GCC_CROSS_NAME)$(man1ext) 3082c87b03e5Sespie -rm -rf $(DESTDIR)$(man1dir)/cpp$(man1ext) 3083c87b03e5Sespie -rm -rf $(DESTDIR)$(man1dir)/protoize$(man1ext) 3084c87b03e5Sespie -rm -rf $(DESTDIR)$(man1dir)/unprotoize$(man1ext) 3085c87b03e5Sespie -rm -f $(DESTDIR)$(infodir)/cpp.info* $(DESTDIR)$(infodir)/gcc.info* 3086c87b03e5Sespie -rm -f $(DESTDIR)$(infodir)/cppinternals.info* $(DESTDIR)$(infodir)/gccint.info* 3087c87b03e5Sespie# 3088c87b03e5Sespie# These targets are for the dejagnu testsuites. The file site.exp 3089c87b03e5Sespie# contains global variables that all the testsuites will use. 3090c87b03e5Sespie 3091c87b03e5Sespie# Set to $(target_alias)/ for cross. 3092c87b03e5Sespietarget_subdir = @target_subdir@ 3093c87b03e5Sespie 3094c87b03e5Sespiesite.exp: ./config.status Makefile 3095c87b03e5Sespie @echo "Making a new config file..." 3096c87b03e5Sespie -@rm -f ./tmp? 3097c87b03e5Sespie @$(STAMP) site.exp 3098c87b03e5Sespie -@mv site.exp site.bak 3099c87b03e5Sespie @echo "## these variables are automatically generated by make ##" > ./tmp0 3100c87b03e5Sespie @echo "# Do not edit here. If you wish to override these values" >> ./tmp0 3101c87b03e5Sespie @echo "# add them to the last section" >> ./tmp0 3102c87b03e5Sespie @echo "set rootme \"`${PWD_COMMAND}`\"" >> ./tmp0 3103c87b03e5Sespie @echo "set srcdir \"`cd ${srcdir}; ${PWD_COMMAND}`\"" >> ./tmp0 3104c87b03e5Sespie @echo "set host_triplet $(host_canonical)" >> ./tmp0 3105c87b03e5Sespie @echo "set build_triplet $(build_canonical)" >> ./tmp0 3106c87b03e5Sespie @echo "set target_triplet $(target)" >> ./tmp0 3107c87b03e5Sespie @echo "set target_alias $(target_alias)" >> ./tmp0 3108c87b03e5Sespie# CFLAGS is set even though it's empty to show we reserve the right to set it. 3109c87b03e5Sespie @echo "set CFLAGS \"\"" >> ./tmp0 3110c87b03e5Sespie @echo "set CXXFLAGS \"-I$(objdir)/../$(target_subdir)libio -I\$$srcdir/../libg++/src -I\$$srcdir/../libio -I\$$srcdir/../libstdc++ -I\$$srcdir/../libstdc++/stl -L$(objdir)/../$(target_subdir)libg++ -L$(objdir)/../$(target_subdir)libstdc++\"" >> ./tmp0 3111c87b03e5Sespie @echo "set TESTING_IN_BUILD_TREE 1" >> ./tmp0 3112c87b03e5Sespie @echo "set HAVE_LIBSTDCXX_V3 1" >> ./tmp0 3113c87b03e5Sespie# If newlib has been configured, we need to pass -B to gcc so it can find 3114c87b03e5Sespie# newlib's crt0.o if it exists. This will cause a "path prefix not used" 3115c87b03e5Sespie# message if it doesn't, but the testsuite is supposed to ignore the message - 3116c87b03e5Sespie# it's too difficult to tell when to and when not to pass -B (not all targets 3117c87b03e5Sespie# have crt0's). We could only add the -B if ../newlib/crt0.o exists, but that 3118c87b03e5Sespie# seems like too selective a test. 3119c87b03e5Sespie# ??? Another way to solve this might be to rely on linker scripts. Then 3120c87b03e5Sespie# theoretically the -B won't be needed. 3121c87b03e5Sespie# We also need to pass -L ../ld so that the linker can find ldscripts. 3122c87b03e5Sespie @if [ -d $(objdir)/../$(target_subdir)newlib ] ; then \ 3123c87b03e5Sespie echo "set newlib_cflags \"-I$(objdir)/../$(target_subdir)newlib/targ-include -I\$$srcdir/../newlib/libc/include\"" >> ./tmp0; \ 3124c87b03e5Sespie echo "set newlib_ldflags \"-B$(objdir)/../$(target_subdir)newlib/\"" >> ./tmp0; \ 3125c87b03e5Sespie echo "append CFLAGS \" \$$newlib_cflags\"" >> ./tmp0; \ 3126c87b03e5Sespie echo "append CXXFLAGS \" \$$newlib_cflags\"" >> ./tmp0; \ 3127c87b03e5Sespie echo "append LDFLAGS \" \$$newlib_ldflags\"" >> ./tmp0; \ 3128c87b03e5Sespie else true; \ 3129c87b03e5Sespie fi 3130c87b03e5Sespie @if [ -d $(objdir)/../ld ] ; then \ 3131c87b03e5Sespie echo "append LDFLAGS \" -L$(objdir)/../ld\"" >> ./tmp0; \ 3132c87b03e5Sespie else true; \ 3133c87b03e5Sespie fi 3134c87b03e5Sespie echo "set tmpdir $(objdir)/testsuite" >> ./tmp0 3135c87b03e5Sespie @echo "set srcdir \"\$${srcdir}/testsuite\"" >> ./tmp0 3136c87b03e5Sespie @if [ "X$(ALT_CXX_UNDER_TEST)" != "X" ] ; then \ 3137c87b03e5Sespie echo "set ALT_CXX_UNDER_TEST $(ALT_CXX_UNDER_TEST)" >> ./tmp0; \ 3138c87b03e5Sespie else true; \ 3139c87b03e5Sespie fi 3140c87b03e5Sespie @if [ "X$(COMPAT_OPTIONS)" != "X" ] ; then \ 3141c87b03e5Sespie echo "set COMPAT_OPTIONS $(COMPAT_OPTIONS)" >> ./tmp0; \ 3142c87b03e5Sespie else true; \ 3143c87b03e5Sespie fi 3144c87b03e5Sespie @echo "## All variables above are generated by configure. Do Not Edit ##" >> ./tmp0 3145c87b03e5Sespie @cat ./tmp0 > site.exp 3146c87b03e5Sespie @cat site.bak | sed \ 3147c87b03e5Sespie -e '1,/^## All variables above are.*##/ d' >> site.exp 3148c87b03e5Sespie -@rm -f ./tmp? 3149c87b03e5Sespie 3150c87b03e5SespieCHECK_TARGETS = check-gcc @check_languages@ 3151c87b03e5Sespie 3152c87b03e5Sespiecheck-c++ : check-g++ 3153c87b03e5Sespiecheck-f77 : check-g77 3154c87b03e5Sespiecheck-java : 3155c87b03e5Sespie 3156c87b03e5Sespiecheck: $(CHECK_TARGETS) 3157c87b03e5Sespie 3158c87b03e5Sespie# The idea is to parallelize testing of multilibs, for example: 3159c87b03e5Sespie# make -j3 check-gcc//sh-hms-sim/{-m1,-m2,-m3,-m3e,-m4}/{,-nofpu} 3160c87b03e5Sespie# will run 3 concurrent sessions of check-gcc, eventually testing 3161c87b03e5Sespie# all 10 combinations. GNU make is required, as is a shell that expands 3162c87b03e5Sespie# alternations within braces. 3163c87b03e5Sespiecheck-gcc//% check-g++//% check-g77//% check-objc//%: site.exp 3164c87b03e5Sespie target=`echo "$@" | sed 's,//.*,,'`; \ 3165c87b03e5Sespie variant=`echo "$@" | sed 's,^[^/]*//,,'`; \ 3166c87b03e5Sespie vardots=`echo "$$variant" | sed 's,/,.,g'`; \ 3167c87b03e5Sespie $(MAKE) TESTSUITEDIR="testsuite.$$vardots" \ 3168c87b03e5Sespie RUNTESTFLAGS="--target_board=$$variant $(RUNTESTFLAGS)" \ 3169c87b03e5Sespie "$$target" 3170c87b03e5Sespie 3171c87b03e5SespieTESTSUITEDIR = testsuite 3172c87b03e5Sespie 3173c87b03e5Sespie$(TESTSUITEDIR)/site.exp: site.exp 3174c87b03e5Sespie test -d $(TESTSUITEDIR) || mkdir $(TESTSUITEDIR) 3175c87b03e5Sespie -rm -f $@ 3176c87b03e5Sespie sed '/set tmpdir/ s|testsuite|$(TESTSUITEDIR)|' < site.exp > $@ 3177c87b03e5Sespie 3178c87b03e5Sespiecheck-g++: $(TESTSUITEDIR)/site.exp 3179c87b03e5Sespie -(rootme=`${PWD_COMMAND}`; export rootme; \ 3180c87b03e5Sespie srcdir=`cd ${srcdir}; ${PWD_COMMAND}` ; export srcdir ; \ 3181c87b03e5Sespie cd $(TESTSUITEDIR); \ 3182c87b03e5Sespie EXPECT=${EXPECT} ; export EXPECT ; \ 3183c87b03e5Sespie if [ -f $${rootme}/../expect/expect ] ; then \ 3184c87b03e5Sespie TCL_LIBRARY=`cd .. ; cd ${srcdir}/../tcl/library ; ${PWD_COMMAND}` ; \ 3185c87b03e5Sespie export TCL_LIBRARY ; fi ; \ 3186c87b03e5Sespie $(RUNTEST) --tool g++ $(RUNTESTFLAGS)) 3187c87b03e5Sespie 3188c87b03e5Sespiecheck-gcc: $(TESTSUITEDIR)/site.exp 3189c87b03e5Sespie -(rootme=`${PWD_COMMAND}`; export rootme; \ 3190c87b03e5Sespie srcdir=`cd ${srcdir}; ${PWD_COMMAND}` ; export srcdir ; \ 3191c87b03e5Sespie cd $(TESTSUITEDIR); \ 3192c87b03e5Sespie EXPECT=${EXPECT} ; export EXPECT ; \ 3193c87b03e5Sespie if [ -f $${rootme}/../expect/expect ] ; then \ 3194c87b03e5Sespie TCL_LIBRARY=`cd .. ; cd ${srcdir}/../tcl/library ; ${PWD_COMMAND}` ; \ 3195c87b03e5Sespie export TCL_LIBRARY ; fi ; \ 3196c87b03e5Sespie $(RUNTEST) --tool gcc $(RUNTESTFLAGS)) 3197c87b03e5Sespie 3198c87b03e5Sespiecheck-g77: $(TESTSUITEDIR)/site.exp 3199c87b03e5Sespie -(rootme=`${PWD_COMMAND}`; export rootme; \ 3200c87b03e5Sespie srcdir=`cd ${srcdir}; ${PWD_COMMAND}` ; export srcdir ; \ 3201c87b03e5Sespie cd $(TESTSUITEDIR); \ 3202c87b03e5Sespie EXPECT=${EXPECT} ; export EXPECT ; \ 3203c87b03e5Sespie if [ -f $${rootme}/../expect/expect ] ; then \ 3204c87b03e5Sespie TCL_LIBRARY=`cd .. ; cd ${srcdir}/../tcl/library ; ${PWD_COMMAND}` ; \ 3205c87b03e5Sespie export TCL_LIBRARY ; fi ; \ 3206c87b03e5Sespie $(RUNTEST) --tool g77 $(RUNTESTFLAGS)) 3207c87b03e5Sespie 3208c87b03e5Sespiecheck-objc: $(TESTSUITEDIR)/site.exp 3209c87b03e5Sespie -(rootme=`${PWD_COMMAND}`; export rootme; \ 3210c87b03e5Sespie srcdir=`cd ${srcdir}; ${PWD_COMMAND}` ; export srcdir ; \ 3211c87b03e5Sespie cd $(TESTSUITEDIR); \ 3212c87b03e5Sespie EXPECT=${EXPECT} ; export EXPECT ; \ 3213c87b03e5Sespie if [ -f $${rootme}/../expect/expect ] ; then \ 3214c87b03e5Sespie TCL_LIBRARY=`cd .. ; cd ${srcdir}/../tcl/library ; ${PWD_COMMAND}` ; \ 3215c87b03e5Sespie export TCL_LIBRARY ; fi ; \ 3216c87b03e5Sespie $(RUNTEST) --tool objc $(RUNTESTFLAGS)) 3217c87b03e5Sespie 3218c87b03e5Sespiecheck-consistency: testsuite/site.exp 3219c87b03e5Sespie -rootme=`${PWD_COMMAND}`; export rootme; \ 3220c87b03e5Sespie srcdir=`cd ${srcdir}; ${PWD_COMMAND}` ; export srcdir ; \ 3221c87b03e5Sespie cd testsuite; \ 3222c87b03e5Sespie EXPECT=${EXPECT} ; export EXPECT ; \ 3223c87b03e5Sespie if [ -f $${rootme}/../expect/expect ] ; then \ 3224c87b03e5Sespie TCL_LIBRARY=`cd .. ; cd ${srcdir}/../tcl/library ; ${PWD_COMMAND}` ; \ 3225c87b03e5Sespie export TCL_LIBRARY ; fi ; \ 3226c87b03e5Sespie $(RUNTEST) --tool consistency $(RUNTESTFLAGS) 3227c87b03e5Sespie 3228c87b03e5Sespie# QMTest targets 3229c87b03e5Sespie 3230c87b03e5Sespie# The path to qmtest. 3231c87b03e5SespieQMTEST_PATH=qmtest 3232c87b03e5Sespie 3233c87b03e5Sespie# The flags to pass to qmtest. 3234c87b03e5SespieQMTESTFLAGS= 3235c87b03e5Sespie 3236c87b03e5Sespie# The flags to pass to "qmtest run". 3237c87b03e5SespieQMTESTRUNFLAGS= 3238c87b03e5Sespie 3239c87b03e5Sespie# The command to use to invoke qmtest. 3240c87b03e5SespieQMTEST=${QMTEST_PATH} ${QMTESTFLAGS} 3241c87b03e5Sespie 3242c87b03e5Sespie# The tests (or suites) to run. 3243c87b03e5SespieQMTEST_GPP_TESTS=gpp 3244c87b03e5Sespie 3245c87b03e5Sespie# The subdirectory of the OBJDIR that will be used to store the QMTest 3246c87b03e5Sespie# test database configuration and that will be used for temporary 3247c87b03e5Sespie# scratch space during QMTest's execution. 3248c87b03e5SespieQMTEST_DIR=qmtestsuite 3249c87b03e5Sespie 3250c87b03e5Sespie# Create the QMTest database configuration. 3251c87b03e5Sespie${QMTEST_DIR} stamp-qmtest: 3252c87b03e5Sespie debug_options=""; \ 3253c87b03e5Sespie ${STAMP} empty.C; \ 3254c87b03e5Sespie for option in \ 3255c87b03e5Sespie -gdwarf-2 -gstabs -gstabs+ -gxcoff -gxcoff+ -gcoff; do \ 3256c87b03e5Sespie (./cc1plus -q $${option} empty.C 2>&1 | \ 3257c87b03e5Sespie grep "unknown or unsupported -g option" > /dev/null) || \ 3258c87b03e5Sespie debug_options="$${debug_options}$${option} "; done; \ 3259c87b03e5Sespie ${QMTEST} -D ${QMTEST_DIR} create-tdb \ 3260c87b03e5Sespie -c gcc_database.GCCDatabase \ 3261c87b03e5Sespie -a GCCDatabase.testsuite_root=`cd ${srcdir}/testsuite && pwd` \ 3262c87b03e5Sespie -a GCCDatabase.debug_options="$${debug_options}" 3263c87b03e5Sespie rm -f empty.C empty.s 3264c87b03e5Sespie $(STAMP) stamp-qmtest 3265c87b03e5Sespie 3266c87b03e5Sespie# Create the QMTest context file. 3267c87b03e5Sespie${QMTEST_DIR}/context: stamp-qmtest 3268c87b03e5Sespie echo "GCCTest.flags=-B${objdir}" >> $@ 3269c87b03e5Sespie echo "GCCTest.objdir=${objdir}/.." >> $@ 3270c87b03e5Sespie echo "GCCTest.host=${host_canonical}" >> $@ 3271c87b03e5Sespie echo "GCCTest.target=${target}" >> $@ 3272c87b03e5Sespie echo "GCCTest.gcov=${objdir}/gcov" >> $@ 3273c87b03e5Sespie echo "GPPTest.gpp=${objdir}/g++" >> $@ 3274c87b03e5Sespie echo "DGTest.demangler=${objdir}/c++filt" >> $@ 3275c87b03e5Sespie 3276c87b03e5Sespie# Run the G++ testsuite using QMTest. 3277c87b03e5Sespieqmtest-g++: ${QMTEST_DIR}/context ${QMTEST_DIR}/gpp-expected.qmr 3278c87b03e5Sespie cd ${QMTEST_DIR} && ${QMTEST} run ${QMTESTRUNFLAGS} -C context \ 3279c87b03e5Sespie -o gpp.qmr -O gpp-expected.qmr \ 3280c87b03e5Sespie ${QMTEST_GPP_TESTS} 3281c87b03e5Sespie 3282c87b03e5Sespie# Use the QMTest GUI. 3283c87b03e5Sespieqmtest-gui: ${QMTEST_DIR}/context 3284c87b03e5Sespie cd ${QMTEST_DIR} && ${QMTEST} gui -C context 3285c87b03e5Sespie 3286c87b03e5Sespie# Build the set of expected G++ failures. 3287c87b03e5Sespie${QMTEST_DIR}/gpp-expected.qmr: ${QMTEST_DIR}/context 3288c87b03e5Sespie echo "Determining expected results..." 3289c87b03e5Sespie cd ${QMTEST_DIR} && ${QMTEST} run ${QMTESTRUNFLAGS} -C context \ 3290c87b03e5Sespie -c "GCCTest.generate_xfails=1" -o gpp-expected.qmr \ 3291c87b03e5Sespie ${QMTEST_GPP_TESTS} \ 3292c87b03e5Sespie > /dev/null 3293c87b03e5Sespie 3294c87b03e5Sespie.PHONY: qmtest-g++ 3295c87b03e5Sespie 3296c87b03e5Sespie# Run Paranoia on real.c. 3297c87b03e5Sespie 3298c87b03e5Sespieparanoia.o: $(srcdir)/../contrib/paranoia.cc $(CONFIG_H) $(SYSTEM_H) \ 3299c87b03e5Sespie real.h $(TREE_H) 3300c87b03e5Sespie g++ -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) $< $(OUTPUT_OPTION) 3301c87b03e5Sespie 3302c87b03e5Sespieparanoia: paranoia.o real.o $(LIBIBERTY) 3303c87b03e5Sespie g++ -o $@ paranoia.o real.o $(LIBIBERTY) 3304c87b03e5Sespie 3305c87b03e5Sespie# These exist for maintenance purposes. 3306c87b03e5Sespie 3307c87b03e5Sespie# Update the tags table. 3308c87b03e5SespieTAGS: force 3309c87b03e5Sespie (cd $(srcdir); \ 3310c87b03e5Sespie mkdir tmp-tags; \ 3311c87b03e5Sespie mv -f c-parse.[ch] =*.[chy] tmp-tags; \ 3312c87b03e5Sespie etags *.y *.h *.c; \ 3313c87b03e5Sespie mv tmp-tags/* .; \ 3314c87b03e5Sespie rmdir tmp-tags) 3315c87b03e5Sespie 3316c87b03e5Sespie# A list of files to be destroyed during "lean" builds. 3317c87b03e5SespieVOL_FILES=`echo $(BACKEND) $(OBJS) $(C_OBJS) $(LIBCPP_OBJS) *.c *.h gen*` 3318c87b03e5Sespie 3319c87b03e5Sespie# Flags to pass to stage2 and later recursive makes. Note that the 3320c87b03e5Sespie# WARN_CFLAGS setting can't be to the expansion of GCC_WARN_CFLAGS in 3321c87b03e5Sespie# the context of the stage_x rule. 3322c87b03e5SespieSTAGE2_FLAGS_TO_PASS = \ 3323c87b03e5Sespie ADAC="\$$(CC)" \ 3324c87b03e5Sespie AR_FOR_TARGET="$(AR_FOR_TARGET)" \ 3325c87b03e5Sespie RANLIB_FOR_TARGET="$(RANLIB_FOR_TARGET)" \ 3326c87b03e5Sespie CFLAGS="$(BOOT_CFLAGS)" \ 3327c87b03e5Sespie LDFLAGS="$(BOOT_LDFLAGS)" \ 3328c87b03e5Sespie WARN_CFLAGS="\$$(GCC_WARN_CFLAGS)" \ 3329c87b03e5Sespie STRICT_WARN="$(STRICT2_WARN)" \ 3330c87b03e5Sespie libdir=$(libdir) \ 3331c87b03e5Sespie LANGUAGES="$(LANGUAGES)" \ 3332c87b03e5Sespie MAKEOVERRIDES= \ 3333c87b03e5Sespie OUTPUT_OPTION="-o \$$@" 3334c87b03e5Sespie 3335c87b03e5Sespie# Only build the C compiler for stage1, because that is the only one that 3336c87b03e5Sespie# we can guarantee will build with the native compiler, and also it is the 3337c87b03e5Sespie# only thing useful for building stage2. STAGE1_CFLAGS (via CFLAGS), 3338c87b03e5Sespie# MAKEINFO and MAKEINFOFLAGS are explicitly passed here to make them 3339c87b03e5Sespie# overrideable (for a bootstrap build stage1 also builds gcc.info). 3340c87b03e5Sespiestage1_build: 3341c87b03e5Sespie $(MAKE) AR_FOR_TARGET="$(AR_FOR_TARGET)" \ 3342c87b03e5Sespie RANLIB_FOR_TARGET="$(RANLIB_FOR_TARGET)" \ 3343c87b03e5Sespie CC="$(CC)" libdir=$(libdir) LANGUAGES="$(BOOT_LANGUAGES)" \ 3344c87b03e5Sespie CFLAGS="$(STAGE1_CFLAGS)" MAKEINFO="$(MAKEINFO)" \ 3345c87b03e5Sespie MAKEINFOFLAGS="$(MAKEINFOFLAGS)" COVERAGE_FLAGS= 3346c87b03e5Sespie $(STAMP) stage1_build 3347c87b03e5Sespie echo stage1_build > stage_last 3348c87b03e5Sespie 3349c87b03e5Sespiestage1_copy: stage1_build 3350c87b03e5Sespie $(MAKE) stage1 3351c87b03e5Sespie $(STAMP) stage1_copy 3352c87b03e5Sespie echo stage2_build > stage_last 3353c87b03e5Sespie 3354c87b03e5Sespiestage2_build: stage1_copy 3355c87b03e5Sespie $(MAKE) CC="$(STAGE_CC_WRAPPER) stage1/xgcc$(exeext) -Bstage1/ -B$(build_tooldir)/bin/" \ 3356c87b03e5Sespie STAGE_PREFIX=stage1/ \ 3357c87b03e5Sespie $(STAGE2_FLAGS_TO_PASS) 3358c87b03e5Sespie $(STAMP) stage2_build 3359c87b03e5Sespie echo stage2_build > stage_last 3360c87b03e5Sespie 3361c87b03e5Sespiestage2_copy: stage2_build 3362c87b03e5Sespie $(MAKE) stage2 3363c87b03e5Sespie $(STAMP) stage2_copy 3364c87b03e5Sespie echo stage3_build > stage_last 3365c87b03e5Sespie 3366c87b03e5Sespiestage3_build: stage2_copy 3367c87b03e5Sespie $(MAKE) CC="$(STAGE_CC_WRAPPER) stage2/xgcc$(exeext) -Bstage2/ -B$(build_tooldir)/bin/" \ 3368c87b03e5Sespie STAGE_PREFIX=stage2/ \ 3369c87b03e5Sespie $(STAGE2_FLAGS_TO_PASS) 3370c87b03e5Sespie $(STAMP) stage3_build 3371c87b03e5Sespie echo stage3_build > stage_last 3372c87b03e5Sespie 3373c87b03e5Sespie# For bootstrap4: 3374c87b03e5Sespiestage3_copy: stage3_build 3375c87b03e5Sespie $(MAKE) stage3 3376c87b03e5Sespie $(STAMP) stage3_copy 3377c87b03e5Sespie echo stage4_build > stage_last 3378c87b03e5Sespie 3379c87b03e5Sespiestage4_build: stage3_copy 3380c87b03e5Sespie $(MAKE) CC="$(STAGE_CC_WRAPPER) stage3/xgcc$(exeext) -Bstage3/ -B$(build_tooldir)/bin/" \ 3381c87b03e5Sespie STAGE_PREFIX=stage3/ \ 3382c87b03e5Sespie $(STAGE2_FLAGS_TO_PASS) 3383c87b03e5Sespie $(STAMP) stage4_build 3384c87b03e5Sespie echo stage4_build > stage_last 3385c87b03e5Sespie 3386c87b03e5Sespie# Additional steps for *-lean targets: 3387c87b03e5Sespieclean_s1: stage1_copy 3388c87b03e5Sespie -(cd stage1 && rm -f $(VOL_FILES)) 3389c87b03e5Sespie $(STAMP) clean_s1 3390c87b03e5Sespie 3391c87b03e5Sespieclean_s2: stage2_copy 3392c87b03e5Sespie -rm -rf stage1 3393c87b03e5Sespie $(STAMP) clean_s2 3394c87b03e5Sespie 3395c87b03e5Sespie# The various entry points for bootstrapping. 3396c87b03e5Sespie 3397c87b03e5Sespiebootstrap: stage3_build 3398c87b03e5Sespie @echo 3399c87b03e5Sespie @echo Bootstrap complete - make \"quickstrap\" to redo last build, 3400c87b03e5Sespie @echo \"restage1\" through \"restage3\" to rebuild specific stages, 3401c87b03e5Sespie @echo \"restrap\" to redo the bootstrap from stage1, or 3402c87b03e5Sespie @echo \"cleanstrap\" to redo the bootstrap from scratch. 3403c87b03e5Sespie 3404c87b03e5Sespiebootstrap-lean : clean_s1 clean_s2 stage3_build 3405c87b03e5Sespie @echo 3406c87b03e5Sespie @echo Bootstrap complete - make \"quickstrap\" to redo last build, 3407c87b03e5Sespie @echo or \"cleanstrap\" to redo the bootstrap from scratch. 3408c87b03e5Sespie 3409c87b03e5Sespiebootstrap2: bootstrap 3410c87b03e5Sespie 3411c87b03e5Sespiebootstrap2-lean : bootstrap-lean 3412c87b03e5Sespie 3413c87b03e5Sespiebootstrap3 bootstrap3-lean: bootstrap 3414c87b03e5Sespie 3415c87b03e5Sespiebootstrap4 bootstrap4-lean: stage4_build 3416c87b03e5Sespie 3417c87b03e5Sespieunstage1 unstage2 unstage3 unstage4: 3418c87b03e5Sespie -set -vx; stage=`echo $@ | sed -e 's/un//'`; \ 3419c87b03e5Sespie rm -f $$stage/as$(exeext); \ 3420c87b03e5Sespie rm -f $$stage/ld$(exeext); \ 3421c87b03e5Sespie rm -f $$stage/collect-ld$(exeext); \ 3422c87b03e5Sespie if test -d $$stage; then \ 3423c87b03e5Sespie mv $$stage/* . 2>/dev/null; \ 3424c87b03e5Sespie for i in `cd $$stage; echo *` ; do \ 3425c87b03e5Sespie if test -d $$stage/$$i; then \ 3426c87b03e5Sespie mv $$stage/$$i/* $$i/. 2>/dev/null; \ 3427c87b03e5Sespie else \ 3428c87b03e5Sespie mv $$stage/$$i .; \ 3429c87b03e5Sespie fi; \ 3430c87b03e5Sespie done \ 3431c87b03e5Sespie fi ; \ 3432c87b03e5Sespie rm -f $${stage}_build $${stage}_copy ;\ 3433c87b03e5Sespie echo $${stage}_build > stage_last 3434c87b03e5Sespie 3435c87b03e5Sespierestage1: unstage1 3436c87b03e5Sespie $(MAKE) stage1_build 3437c87b03e5Sespie 3438c87b03e5Sespierestage2: unstage2 3439c87b03e5Sespie $(MAKE) LANGUAGES="$(LANGUAGES)" stage2_build 3440c87b03e5Sespie 3441c87b03e5Sespierestage3: unstage3 3442c87b03e5Sespie $(MAKE) LANGUAGES="$(LANGUAGES)" stage3_build 3443c87b03e5Sespie 3444c87b03e5Sespierestage4: unstage4 3445c87b03e5Sespie $(MAKE) LANGUAGES="$(LANGUAGES)" stage4_build 3446c87b03e5Sespie 3447c87b03e5Sespiebubblestrap: 3448c87b03e5Sespie if test -f stage3_build; then true; else \ 3449c87b03e5Sespie echo; echo You must \"make bootstrap\" first.; \ 3450c87b03e5Sespie exit 1; \ 3451c87b03e5Sespie fi 3452c87b03e5Sespie for i in stage3 \ 3453c87b03e5Sespie unstage1 stage1_build stage1_copy \ 3454c87b03e5Sespie unstage2 stage2_build stage2_copy \ 3455c87b03e5Sespie unstage3 stage3_build ; \ 3456c87b03e5Sespie do \ 3457c87b03e5Sespie $(MAKE) LANGUAGES="$(LANGUAGES)" $$i || exit 1 ; \ 3458c87b03e5Sespie done 3459c87b03e5Sespie 3460c87b03e5Sespiequickstrap: 3461c87b03e5Sespie if test -f stage_last ; then \ 3462c87b03e5Sespie LAST=`cat stage_last`; rm $$LAST; $(MAKE) LANGUAGES="$(LANGUAGES)" $$LAST; \ 3463c87b03e5Sespie else \ 3464c87b03e5Sespie $(MAKE) stage1_build; \ 3465c87b03e5Sespie fi 3466c87b03e5Sespie 3467c87b03e5Sespiecleanstrap: 3468c87b03e5Sespie -$(MAKE) clean 3469c87b03e5Sespie $(MAKE) LANGUAGES="$(LANGUAGES)" bootstrap 3470c87b03e5Sespie 3471c87b03e5Sespieunstrap: 3472c87b03e5Sespie -rm -rf stage[234]* 3473c87b03e5Sespie $(MAKE) unstage1 3474c87b03e5Sespie 3475c87b03e5Sespie# Differs from cleanstrap in that it starts from the earlier stage1 build, 3476c87b03e5Sespie# not from scratch. 3477c87b03e5Sespierestrap: 3478c87b03e5Sespie $(MAKE) unstrap 3479c87b03e5Sespie $(MAKE) LANGUAGES="$(LANGUAGES)" bootstrap 3480c87b03e5Sespie 3481c87b03e5Sespie# Compare the object files in the current directory with those in the 3482c87b03e5Sespie# stage2 directory. 3483c87b03e5Sespie 3484c87b03e5Sespie# ./ avoids bug in some versions of tail. 3485c87b03e5Sespiecompare compare3 compare4 compare-lean compare3-lean compare4-lean: force 3486c87b03e5Sespie -rm -f .bad_compare 3487c87b03e5Sespie case "$@" in compare | compare-lean ) stage=2 ;; * ) stage=`echo $@ | sed -e 's,^compare\([0-9][0-9]*\).*,\1,'` ;; esac; \ 3488c87b03e5Sespie for file in *$(objext); do \ 3489c87b03e5Sespie tail +16c ./$$file > tmp-foo1; \ 3490c87b03e5Sespie tail +16c stage$$stage/$$file > tmp-foo2 \ 3491c87b03e5Sespie && (cmp tmp-foo1 tmp-foo2 > /dev/null 2>&1 || echo $$file differs >> .bad_compare) || true; \ 3492c87b03e5Sespie done 3493c87b03e5Sespie case "$@" in compare | compare-lean ) stage=2 ;; * ) stage=`echo $@ | sed -e 's,^compare\([0-9][0-9]*\).*,\1,'` ;; esac; \ 3494c87b03e5Sespie for dir in tmp-foo intl $(SUBDIRS); do \ 3495c87b03e5Sespie if [ "`echo $$dir/*$(objext)`" != "$$dir/*$(objext)" ] ; then \ 3496c87b03e5Sespie for file in $$dir/*$(objext); do \ 3497c87b03e5Sespie tail +16c ./$$file > tmp-foo1; \ 3498c87b03e5Sespie tail +16c stage$$stage/$$file > tmp-foo2 \ 3499c87b03e5Sespie && (cmp tmp-foo1 tmp-foo2 > /dev/null 2>&1 || echo $$file differs >> .bad_compare) || true; \ 3500c87b03e5Sespie done; \ 3501c87b03e5Sespie else true; fi; \ 3502c87b03e5Sespie done 3503c87b03e5Sespie -rm -f tmp-foo* 3504c87b03e5Sespie case "$@" in compare | compare-lean ) stage=2 ;; * ) stage=`echo $@ | sed -e 's,^compare\([0-9][0-9]*\).*,\1,'` ;; esac; \ 3505c87b03e5Sespie if [ -f .bad_compare ]; then \ 3506c87b03e5Sespie echo "Bootstrap comparison failure!"; \ 3507c87b03e5Sespie cat .bad_compare; \ 3508c87b03e5Sespie exit 1; \ 3509c87b03e5Sespie else \ 3510c87b03e5Sespie case "$@" in \ 3511c87b03e5Sespie *-lean ) rm -rf stage$$stage ;; \ 3512c87b03e5Sespie *) ;; \ 3513c87b03e5Sespie esac; true; \ 3514c87b03e5Sespie fi 3515c87b03e5Sespie 3516c87b03e5Sespie# Compare the object files in the current directory with those in the 3517c87b03e5Sespie# stage2 directory. Use gnu cmp (diffutils v2.4 or later) to avoid 3518c87b03e5Sespie# running tail and the overhead of twice copying each object file. 3519c87b03e5Sespie# An exit status of 1 is precisely the result we're looking for (other 3520c87b03e5Sespie# values mean other problems). 3521c87b03e5Sespiegnucompare gnucompare3 gnucompare4 gnucompare-lean gnucompare3-lean gnucompare4-lean: force 3522c87b03e5Sespie -rm -f .bad_compare 3523c87b03e5Sespie case "$@" in gnucompare | gnucompare-lean ) stage=2 ;; * ) stage=`echo $@ | sed -e 's,^gnucompare\([0-9][0-9]*\).*,\1,'` ;; esac; \ 3524c87b03e5Sespie for file in *$(objext); do \ 3525c87b03e5Sespie cmp --ignore-initial=16 $$file stage$$stage/$$file > /dev/null 2>&1; \ 3526c87b03e5Sespie test $$? -eq 1 && echo $$file differs >> .bad_compare || true; \ 3527c87b03e5Sespie done 3528c87b03e5Sespie case "$@" in gnucompare | gnucompare-lean ) stage=2 ;; * ) stage=`echo $@ | sed -e 's,^gnucompare\([0-9][0-9]*\).*,\1,'` ;; esac; \ 3529c87b03e5Sespie for dir in tmp-foo intl $(SUBDIRS); do \ 3530c87b03e5Sespie if [ "`echo $$dir/*$(objext)`" != "$$dir/*$(objext)" ] ; then \ 3531c87b03e5Sespie for file in $$dir/*$(objext); do \ 3532c87b03e5Sespie cmp --ignore-initial=16 $$file stage$$stage/$$file > /dev/null 2>&1; \ 3533c87b03e5Sespie test $$? -eq 1 && echo $$file differs >> .bad_compare || true; \ 3534c87b03e5Sespie done; \ 3535c87b03e5Sespie else true; fi; \ 3536c87b03e5Sespie done 3537c87b03e5Sespie case "$@" in gnucompare | gnucompare-lean ) stage=2 ;; * ) stage=`echo $@ | sed -e 's,^gnucompare\([0-9][0-9]*\).*,\1,'` ;; esac; \ 3538c87b03e5Sespie if [ -f .bad_compare ]; then \ 3539c87b03e5Sespie echo "Bootstrap comparison failure!"; \ 3540c87b03e5Sespie cat .bad_compare; \ 3541c87b03e5Sespie exit 1; \ 3542c87b03e5Sespie else \ 3543c87b03e5Sespie case "$@" in \ 3544c87b03e5Sespie *-lean ) rm -rf stage$$stage ;; \ 3545c87b03e5Sespie esac; true; \ 3546c87b03e5Sespie fi 3547c87b03e5Sespie 3548c87b03e5Sespie# Copy the object files from a particular stage into a subdirectory. 3549c87b03e5Sespiestage1-start: 3550c87b03e5Sespie -if [ -d stage1 ] ; then true ; else mkdir stage1 ; fi 3551c87b03e5Sespie $(MAKE) -f libgcc.mk libgcc-stage-start stage=stage1 3552c87b03e5Sespie -for dir in intl $(SUBDIRS) ; \ 3553c87b03e5Sespie do \ 3554c87b03e5Sespie if [ -d stage1/$$dir ] ; then true ; else mkdir stage1/$$dir ; fi ; \ 3555c87b03e5Sespie done 3556c87b03e5Sespie -mv $(STAGESTUFF) stage1 3557c87b03e5Sespie -mv intl/*$(objext) stage1/intl 3558c87b03e5Sespie# Copy as/ld if they exist to stage dir, so that running xgcc from the stage 3559c87b03e5Sespie# dir will work properly. 3560c87b03e5Sespie -if [ -f as$(exeext) ] ; then (cd stage1 && $(LN_S) ../as$(exeext) .) ; else true ; fi 3561c87b03e5Sespie -if [ -f ld$(exeext) ] ; then (cd stage1 && $(LN_S) ../ld$(exeext) .) ; else true ; fi 3562c87b03e5Sespie -if [ -f collect-ld$(exeext) ] ; then (cd stage1 && $(LN_S) ../collect-ld$(exeext) .) ; else true ; fi 356306dc6460Sespie -rm -f stage1/libgcc.a stage1/libgcc_eh.a stage1/libgcc_s*$(SHLIB_EXT) 3564c87b03e5Sespie -cp libgcc.a stage1 3565c87b03e5Sespie -if $(RANLIB_TEST_FOR_TARGET) ; then \ 3566c87b03e5Sespie $(RANLIB_FOR_TARGET) stage1/libgcc.a; \ 3567c87b03e5Sespie else true; fi 3568c87b03e5Sespie -if [ -f libgcc_eh.a ] ; then cp libgcc_eh.a stage1; \ 3569c87b03e5Sespie if $(RANLIB_TEST_FOR_TARGET) ; then \ 3570c87b03e5Sespie $(RANLIB_FOR_TARGET) stage1/libgcc_eh.a; \ 3571c87b03e5Sespie else true; fi; fi 357206dc6460Sespie -cp libgcc_s*$(SHLIB_EXT) stage1/ 3573c87b03e5Sespie -for f in .. $(EXTRA_MULTILIB_PARTS); do if [ x$${f} != x.. ]; then \ 3574c87b03e5Sespie cp stage1/$${f} . ; \ 3575c87b03e5Sespie else true; \ 3576c87b03e5Sespie fi; done 3577c87b03e5Sespiestage1: force stage1-start lang.stage1 3578c87b03e5Sespie 3579c87b03e5Sespiestage2-start: 3580c87b03e5Sespie -if [ -d stage2 ] ; then true ; else mkdir stage2 ; fi 3581c87b03e5Sespie $(MAKE) -f libgcc.mk libgcc-stage-start stage=stage2 3582c87b03e5Sespie -for dir in intl $(SUBDIRS) ; \ 3583c87b03e5Sespie do \ 3584c87b03e5Sespie if [ -d stage2/$$dir ] ; then true ; else mkdir stage2/$$dir ; fi ; \ 3585c87b03e5Sespie done 3586c87b03e5Sespie -mv $(STAGESTUFF) stage2 3587c87b03e5Sespie -mv intl/*$(objext) stage2/intl 3588c87b03e5Sespie# Copy as/ld if they exist to stage dir, so that running xgcc from the stage 3589c87b03e5Sespie# dir will work properly. 3590c87b03e5Sespie -if [ -f as$(exeext) ] ; then (cd stage2 && $(LN_S) ../as$(exeext) .) ; else true ; fi 3591c87b03e5Sespie -if [ -f ld$(exeext) ] ; then (cd stage2 && $(LN_S) ../ld$(exeext) .) ; else true ; fi 3592c87b03e5Sespie -if [ -f collect-ld$(exeext) ] ; then (cd stage2 && $(LN_S) ../collect-ld$(exeext) .) ; else true ; fi 359306dc6460Sespie -rm -f stage2/libgcc.a stage2/libgcc_eh.a stage2/libgcc_s*$(SHLIB_EXT) 3594c87b03e5Sespie -cp libgcc.a stage2 3595c87b03e5Sespie -if $(RANLIB_TEST_FOR_TARGET) ; then \ 3596c87b03e5Sespie $(RANLIB_FOR_TARGET) stage2/libgcc.a; \ 3597c87b03e5Sespie else true; fi 3598c87b03e5Sespie -if [ -f libgcc_eh.a ] ; then cp libgcc_eh.a stage2; \ 3599c87b03e5Sespie if $(RANLIB_TEST_FOR_TARGET) ; then \ 3600c87b03e5Sespie $(RANLIB_FOR_TARGET) stage2/libgcc_eh.a; \ 3601c87b03e5Sespie else true; fi; fi 360206dc6460Sespie -cp libgcc_s*$(SHLIB_EXT) stage2/ 3603c87b03e5Sespie -for f in .. $(EXTRA_MULTILIB_PARTS); do if [ x$${f} != x.. ]; then \ 3604c87b03e5Sespie cp stage2/$${f} . ; \ 3605c87b03e5Sespie else true; \ 3606c87b03e5Sespie fi; done 3607c87b03e5Sespiestage2: force stage2-start lang.stage2 3608c87b03e5Sespie 3609c87b03e5Sespiestage3-start: 3610c87b03e5Sespie -if [ -d stage3 ] ; then true ; else mkdir stage3 ; fi 3611c87b03e5Sespie $(MAKE) -f libgcc.mk libgcc-stage-start stage=stage3 3612c87b03e5Sespie -for dir in intl $(SUBDIRS) ; \ 3613c87b03e5Sespie do \ 3614c87b03e5Sespie if [ -d stage3/$$dir ] ; then true ; else mkdir stage3/$$dir ; fi ; \ 3615c87b03e5Sespie done 3616c87b03e5Sespie -mv $(STAGESTUFF) stage3 3617c87b03e5Sespie -mv intl/*$(objext) stage3/intl 3618c87b03e5Sespie# Copy as/ld if they exist to stage dir, so that running xgcc from the stage 3619c87b03e5Sespie# dir will work properly. 3620c87b03e5Sespie -if [ -f as$(exeext) ] ; then (cd stage3 && $(LN_S) ../as$(exeext) .) ; else true ; fi 3621c87b03e5Sespie -if [ -f ld$(exeext) ] ; then (cd stage3 && $(LN_S) ../ld$(exeext) .) ; else true ; fi 3622c87b03e5Sespie -if [ -f collect-ld$(exeext) ] ; then (cd stage3 && $(LN_S) ../collect-ld$(exeext) .) ; else true ; fi 362306dc6460Sespie -rm -f stage3/libgcc.a stage3/libgcc_eh.a stage3/libgcc_s*$(SHLIB_EXT) 3624c87b03e5Sespie -cp libgcc.a stage3 3625c87b03e5Sespie -if $(RANLIB_TEST_FOR_TARGET) ; then \ 3626c87b03e5Sespie $(RANLIB_FOR_TARGET) stage3/libgcc.a; \ 3627c87b03e5Sespie else true; fi 3628c87b03e5Sespie -if [ -f libgcc_eh.a ] ; then cp libgcc_eh.a stage3; \ 3629c87b03e5Sespie if $(RANLIB_TEST_FOR_TARGET) ; then \ 3630c87b03e5Sespie $(RANLIB_FOR_TARGET) stage3/libgcc_eh.a; \ 3631c87b03e5Sespie else true; fi; fi 363206dc6460Sespie -cp libgcc_s*$(SHLIB_EXT) stage3/ 3633c87b03e5Sespie -for f in .. $(EXTRA_MULTILIB_PARTS); do if [ x$${f} != x.. ]; then \ 3634c87b03e5Sespie cp stage3/$${f} . ; \ 3635c87b03e5Sespie else true; \ 3636c87b03e5Sespie fi; done 3637c87b03e5Sespiestage3: force stage3-start lang.stage3 3638c87b03e5Sespie 3639c87b03e5Sespiestage4-start: 3640c87b03e5Sespie -if [ -d stage4 ] ; then true ; else mkdir stage4 ; fi 3641c87b03e5Sespie $(MAKE) -f libgcc.mk libgcc-stage-start stage=stage4 3642c87b03e5Sespie -for dir in intl $(SUBDIRS) ; \ 3643c87b03e5Sespie do \ 3644c87b03e5Sespie if [ -d stage4/$$dir ] ; then true ; else mkdir stage4/$$dir ; fi ; \ 3645c87b03e5Sespie done 3646c87b03e5Sespie -mv $(STAGESTUFF) stage4 3647c87b03e5Sespie -mv intl/*$(objext) stage4/intl 3648c87b03e5Sespie# Copy as/ld if they exist to stage dir, so that running xgcc from the stage 3649c87b03e5Sespie# dir will work properly. 3650c87b03e5Sespie -if [ -f as$(exeext) ] ; then (cd stage4 && $(LN_S) ../as$(exeext) .) ; else true ; fi 3651c87b03e5Sespie -if [ -f ld$(exeext) ] ; then (cd stage4 && $(LN_S) ../ld$(exeext) .) ; else true ; fi 3652c87b03e5Sespie -if [ -f collect-ld$(exeext) ] ; then (cd stage4 && $(LN_S) ../collect-ld$(exeext) .) ; else true ; fi 365306dc6460Sespie -rm -f stage4/libgcc.a stage4/libgcc_eh.a stage4/libgcc_s*$(SHLIB_EXT) 3654c87b03e5Sespie -cp libgcc.a stage4 3655c87b03e5Sespie -if $(RANLIB_TEST_FOR_TARGET) ; then \ 3656c87b03e5Sespie $(RANLIB_FOR_TARGET) stage4/libgcc.a; \ 3657c87b03e5Sespie else true; fi 3658c87b03e5Sespie -if [ -f libgcc_eh.a ] ; then cp libgcc_eh.a stage4; \ 3659c87b03e5Sespie if $(RANLIB_TEST_FOR_TARGET) ; then \ 3660c87b03e5Sespie $(RANLIB_FOR_TARGET) stage4/libgcc_eh.a; \ 3661c87b03e5Sespie else true; fi; fi 366206dc6460Sespie -cp libgcc_s*$(SHLIB_EXT) stage4/ 3663c87b03e5Sespie -for f in .. $(EXTRA_MULTILIB_PARTS); do if [ x$${f} != x.. ]; then \ 3664c87b03e5Sespie cp stage4/$${f} . ; \ 3665c87b03e5Sespie else true; \ 3666c87b03e5Sespie fi; done 3667c87b03e5Sespiestage4: force stage4-start lang.stage4 3668c87b03e5Sespie 3669c87b03e5Sespie# Copy just the executable files from a particular stage into a subdirectory, 3670c87b03e5Sespie# and delete the object files. Use this if you're just verifying a version 3671c87b03e5Sespie# that is pretty sure to work, and you are short of disk space. 3672c87b03e5Sespierisky-stage1: stage1 3673c87b03e5Sespie -$(MAKE) clean 3674c87b03e5Sespie 3675c87b03e5Sespierisky-stage2: stage2 3676c87b03e5Sespie -$(MAKE) clean 3677c87b03e5Sespie 3678c87b03e5Sespierisky-stage3: stage3 3679c87b03e5Sespie -$(MAKE) clean 3680c87b03e5Sespie 3681c87b03e5Sespierisky-stage4: stage4 3682c87b03e5Sespie -$(MAKE) clean 3683c87b03e5Sespie 3684c87b03e5Sespie#In GNU Make, ignore whether `stage*' exists. 3685c87b03e5Sespie.PHONY: stage1 stage2 stage3 stage4 clean maintainer-clean TAGS bootstrap 3686c87b03e5Sespie.PHONY: risky-stage1 risky-stage2 risky-stage3 risky-stage4 3687c87b03e5Sespie 3688c87b03e5Sespieforce: 3689c87b03e5Sespie 3690c87b03e5Sespie# Rules for generating translated message descriptions. 3691c87b03e5Sespie# Disabled by autoconf if the tools are not available. 3692c87b03e5Sespie 3693c87b03e5SespieXGETTEXT = @XGETTEXT@ 3694c87b03e5SespieGMSGFMT = @GMSGFMT@ 3695c87b03e5SespieMSGMERGE = msgmerge 3696c87b03e5Sespie 3697c87b03e5SespiePACKAGE = @PACKAGE@ 3698c87b03e5SespieCATALOGS = @CATALOGS@ 3699c87b03e5Sespie 3700c87b03e5Sespie.PHONY: build- install- build-po install-po update-po 3701c87b03e5Sespie 3702c87b03e5Sespie# Dummy rules to deal with dependencies produced by use of 3703c87b03e5Sespie# "build-@POSUB@" and "install-@POSUB@" above, when NLS is disabled. 3704c87b03e5Sespiebuild-: ; @true 3705c87b03e5Sespieinstall-: ; @true 3706c87b03e5Sespie 3707c87b03e5Sespiebuild-po: $(CATALOGS) 3708c87b03e5Sespie 3709c87b03e5Sespie# This notation should be acceptable to all Make implementations used 3710c87b03e5Sespie# by people who are interested in updating .po files. 3711c87b03e5Sespieupdate-po: $(CATALOGS:.gmo=.pox) 3712c87b03e5Sespie 3713c87b03e5Sespie# N.B. We do not attempt to copy these into $(srcdir). The snapshot 3714c87b03e5Sespie# script does that. 3715c87b03e5Sespie.po.gmo: 3716c87b03e5Sespie -test -d po || mkdir po 3717c87b03e5Sespie $(GMSGFMT) --statistics -o $@ $< 3718c87b03e5Sespie 3719c87b03e5Sespie# The new .po has to be gone over by hand, so we deposit it into 3720c87b03e5Sespie# build/po with a different extension. 3721c87b03e5Sespie# If build/po/$(PACKAGE).pot exists, use it (it was just created), 3722c87b03e5Sespie# else use the one in srcdir. 3723c87b03e5Sespie.po.pox: 3724c87b03e5Sespie -test -d po || mkdir po 3725c87b03e5Sespie $(MSGMERGE) $< `if test -f po/$(PACKAGE).pot; \ 3726c87b03e5Sespie then echo po/$(PACKAGE).pot; \ 3727c87b03e5Sespie else echo $(srcdir)/po/$(PACKAGE).pot; fi` -o $@ 3728c87b03e5Sespie 3729c87b03e5Sespie# This rule has to look for .gmo modules in both srcdir and 3730c87b03e5Sespie# the cwd, and has to check that we actually have a catalog 3731c87b03e5Sespie# for each language, in case they weren't built or included 3732c87b03e5Sespie# with the distribution. 3733c87b03e5Sespieinstall-po: 3734c87b03e5Sespie $(SHELL) $(srcdir)/mkinstalldirs $(DESTDIR)$(datadir) 3735c87b03e5Sespie for cat in $(CATALOGS); do \ 3736c87b03e5Sespie lang=`basename $$cat | sed 's/\.gmo$$//'`; \ 3737c87b03e5Sespie if [ -f $$cat ]; then :; \ 3738c87b03e5Sespie elif [ -f $(srcdir)/$$cat ]; then cat=$(srcdir)/$$cat; \ 3739c87b03e5Sespie else continue; \ 3740c87b03e5Sespie fi; \ 3741c87b03e5Sespie dir=$(localedir)/$$lang/LC_MESSAGES; \ 3742c87b03e5Sespie echo $(SHELL) $(srcdir)/mkinstalldirs $(DESTDIR)$$dir; \ 3743c87b03e5Sespie $(SHELL) $(srcdir)/mkinstalldirs $(DESTDIR)$$dir || exit 1; \ 3744c87b03e5Sespie echo $(INSTALL_DATA) $$cat $(DESTDIR)$$dir/$(PACKAGE).mo; \ 3745c87b03e5Sespie $(INSTALL_DATA) $$cat $(DESTDIR)$$dir/$(PACKAGE).mo; \ 3746c87b03e5Sespie done 3747c87b03e5Sespie 3748c87b03e5Sespie# Rule for regenerating the message template (gcc.pot). 3749c87b03e5Sespie# Instead of forcing everyone to edit POTFILES.in, which proved impractical, 3750c87b03e5Sespie# this rule has no dependencies and always regenerates gcc.pot. This is 3751c87b03e5Sespie# relatively harmless since the .po files do not directly depend on it. 3752c87b03e5Sespie# Note that exgettext has an awk script embedded in it which requires a 3753c87b03e5Sespie# fairly modern (POSIX-compliant) awk. 3754c87b03e5Sespie# The .pot file is left in the build directory. 3755c87b03e5Sespie$(PACKAGE).pot: po/$(PACKAGE).pot 3756c87b03e5Sespiepo/$(PACKAGE).pot: force 3757c87b03e5Sespie -test -d po || mkdir po 3758c87b03e5Sespie $(MAKE) po-generated 3759c87b03e5Sespie AWK=$(AWK) $(SHELL) $(srcdir)/po/exgettext \ 3760c87b03e5Sespie $(XGETTEXT) $(PACKAGE) $(srcdir) 3761