Compare commits

..

2 Commits

Author SHA1 Message Date
No Author
9d67cee022 This commit was manufactured by cvs2svn to create tag 'start'.
From-SVN: r14881
1997-08-21 22:58:49 +00:00
No Author
2f08086dbb This commit was manufactured by cvs2svn to create branch 'gcc3'.
From-SVN: r14765
1997-08-11 15:58:14 +00:00
6039 changed files with 304890 additions and 779890 deletions

View File

@@ -3,6 +3,7 @@
*-dirs
*-done
*-info
*-install
*-install-info
*-src
*-stamp-*

View File

@@ -2,7 +2,7 @@
Version 2, June 1991
Copyright (C) 1991 Free Software Foundation, Inc.
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
675 Mass Ave, Cambridge, MA 02139, USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
@@ -464,8 +464,7 @@ convey the exclusion of warranty; and each file should have at least the
You should have received a copy of the GNU Library General Public
License along with this library; if not, write to the Free
Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
MA 02111-1307, USA
Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
Also add information on how to contact you by electronic and paper mail.

1165
ChangeLog

File diff suppressed because it is too large Load Diff

View File

@@ -1,9 +0,0 @@
This directory has been obsoleted for egcs snapshots and CVS access.
Instead check out the toplevel "wwwdocs" as a sibling of your egcs
tree or read these files via the egcs web site
http://www.gnu.org/software/gcc/
Copies of the relevant files will be copied into this directory for
releases.

View File

@@ -1,107 +0,0 @@
Blanket Write Privs.
Craig Burley craig@jcb-sc.com
John Carr jfc@mit.edu
Richard Henderson rth@cygnus.com
Jeff Law law@cygnus.com
Michael Meissner meissner@cygnus.com
David S. Miller davem@redhat.com
Jim Wilson wilson@cygnus.com
Various Maintainers
sh port Joern Renecke amylaar@cygnus.com
v850 port Nick Clifton nickc@cygnus.com
v850 port Michael Meissner meissner@cygnus.com
arm port Nick Clifton nickc@cygnus.com
arm port Richard Earnshaw rearnsha@arm.com
m32r port Nick Clifton nickc@cygnus.com
Michael Meissner meissner@cygnus.com
h8 port Jeff Law law@cygnus.com
mn10200 port Jeff Law law@cygnus.com
mn10300 port Jeff Law law@cygnus.com
hppa port Jeff Law law@cygnus.com
m68k port (?) Jeff Law law@cygnus.com
rs6000 port Michael Meissner meissner@cygnus.com
rs6000 port David Edelsohn dje@watson.ibm.com
mips port Jim Wilson wilson@cygnus.com
i960 port Jim Wilson wilson@cygnus.com
a29k port Jim Wilson wilson@cygnus.com
alpha port Richard Henderson rth@cygnus.com
sparc port Richard Henderson rth@cygnus.com
sparc port David S. Miller davem@redhat.com
x86 ports Stan Cox scox@cygnus.com
c4x port Michael Hayes m.hayes@elec.canterbury.ac.nz
fortran Craig Burley craig@jcb-sc.com
fortran Richard Henderson rth@cygnus.com
c++ Jason Merrill jason@cygnus.com
c++ Mark Mitchell mark@codesourcery.com
chill Dave Brolley brolley@cygnus.com
chill Per Bothner bothner@cygnus.com
java Per Bothner bothner@cygnus.com
objective-c Ovidiu Predescu ovidiu@cup.hp.com
cpplib Dave Brolley brolley@cygnus.com
cpplib Per Bothner bothner@cygnus.com
fixincludes Ian Taylor ian@cygnus.com
alias analysis John Carr jfc@mit.edu
loop unrolling Jim Wilson wilson@cygnus.com
scheduler (+ haifa) Jim Wilson wilson@cygnus.com
scheduler (+ haifa) Michael Meissner meissner@cygnus.com
scheduler (+ haifa) Jeff Law law@cygnus.com
reorg Jeff Law law@cygnus.com
caller-save.c Jeff Law law@cygnus.com
debugging code Jim Wilson wilson@cygnus.com
dwarf debugging code Jason Merrill jason@cygnus.com
c++ runtime libs Ulrich Drepper drepper@cygnus.com
C++ runtime libs Gabriel Dos Reis dosreis@cmla.ens-cachan.fr
*synthetic multiply Torbjorn Granlund tege@swox.com
*c-torture Torbjorn Granlund tege@swox.com
*f-torture Kate Hedstrom kate@ahab.rutgers.edu
sco5, unixware, sco udk Robert Lipe robertlipe@usa.net
new fixincludes Bruce Korb korbb@datadesign.com
gcse.c Jeff Law law@cygnus.com
global opt framework Jeff Law law@cygnus.com
jump.c David S. Miller davem@redhat.com
web pages Gerald Pfeifer pfeifer@dbai.tuwien.ac.at
C front end/isoc9x Gavin Koch gavin@cygnus.com
config.sub/config.guess Ben Elliston bje@cygnus.com
Note individuals who maintain parts of the compiler need approval to check
in changes outside of the parts of the compiler they maintain.
Write After Approval
Ken Raeburn raeburn@cygnus.com
Brendan Kehoe brendan@cygnus.com
Benjamin Kosnik bkoz@cygnus.com
Andrew Macleod amacleod@cygnus.com
Dave Love d.love@dl.ac.uk
*Toon Moene toon@moene.indiv.nluug.nl
*HJ Lu hjl@lucon.org
Mark Mitchell mark@codesourcery.com
Kaveh Ghazi ghazi@caip.rutgers.edu
Andreas Schwab schwab@issan.informatik.uni-dortmund.de
Manfred Hollstein manfred.h@gmx.net
*Paul Eggert eggert@twinsun.com
Klaus Kaempf kkaempf@progis.de
Marc Lehmann pcg@goof.com
Alexandre Oliva oliva@dcc.unicamp.br
Catherine Moore clm@cygnus.com
Vladimir Markarov vmakarov@cygnus.com
Martin v. Löwis loewis@informatik.hu-berlin.de
Bernd Schmidt crux@pool.informatik.rwth-aachen.de
Zack Weinberg zack@rabi.columbia.edu
John Wehle john@feith.com
Nathan Sidwell nathan@acm.org
Tom Tromey tromey@cygnus.com
Andrew Haley aph@cygnus.com
Alexandre Petit-Bianco apbianco@cygnus.com
Anthony Green green@cygnus.com
Stu Grossman grossman@cygnus.com
Gabriel Dos Reis dosreis@cmla.ens-cachan.fr
* Indicates folks we need to get Kerberos/ssh accounts ready so they
can write in the source tree

View File

@@ -1,7 +1,6 @@
#
# Makefile for directory with subdirs to build.
# Copyright (C) 1990, 91, 92, 93, 94, 95, 96, 97, 1998
# Free Software Foundation
# Copyright (C) 1990, 91, 92, 93, 94, 95, 96, 1997 Free Software Foundation
#
# This file is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -21,28 +20,16 @@
srcdir = .
prefix = /usr/local
exec_prefix = $(prefix)
bindir=${exec_prefix}/bin
sbindir=${exec_prefix}/sbin
libexecdir=${exec_prefix}/libexec
datadir=${prefix}/share
sysconfdir=${prefix}/etc
sharedstatedir=${prefix}/com
localstatedir=${prefix}/var
libdir=${exec_prefix}/lib
includedir=${prefix}/include
oldincludedir=/usr/include
infodir=${prefix}/info
mandir=${prefix}/man
gxx_include_dir=${includedir}/g++
tooldir = $(exec_prefix)/$(target_alias)
build_tooldir = $(exec_prefix)/$(target_alias)
bindir = $(exec_prefix)/bin
libdir = $(exec_prefix)/lib
tooldir = $(exec_prefix)/$(target)
program_transform_name =
datadir = $(prefix)/share
mandir = $(prefix)/man
man1dir = $(mandir)/man1
man2dir = $(mandir)/man2
man3dir = $(mandir)/man3
@@ -54,8 +41,6 @@ man8dir = $(mandir)/man8
man9dir = $(mandir)/man9
infodir = $(prefix)/info
includedir = $(prefix)/include
# Directory in which the compiler finds executables, libraries, etc.
libsubdir = $(libdir)/gcc-lib/$(target_alias)/$(gcc_version)
GDB_NLM_DEPS =
SHELL = /bin/sh
@@ -93,8 +78,6 @@ LIBCFLAGS_FOR_TARGET = $(CFLAGS_FOR_TARGET)
PICFLAG =
PICFLAG_FOR_TARGET =
CHILLFLAGS = $(CFLAGS)
CHILL_LIB = -lchill
CXX = c++
# Use -O2 to stress test the compiler.
@@ -117,7 +100,6 @@ GZIPPROG = gzip
# These values are substituted by configure.
DEFAULT_YACC = yacc
DEFAULT_LEX = lex
DEFAULT_M4 = m4
BISON = `if [ -f $$r/bison/bison ] ; then \
echo $$r/bison/bison -L $$s/bison/ ; \
@@ -139,7 +121,7 @@ LEX = `if [ -f $$r/flex/flex ] ; \
M4 = `if [ -f $$r/m4/m4 ] ; \
then echo $$r/m4/m4 ; \
else echo ${DEFAULT_M4} ; fi`
else echo m4 ; fi`
MAKEINFO = `if [ -f $$r/texinfo/makeinfo/Makefile ] ; \
then echo $$r/texinfo/makeinfo/makeinfo ; \
@@ -169,7 +151,7 @@ OTHERS =
# This is set by the configure script to the list of directories which
# should be built using the target tools.
TARGET_CONFIGDIRS = libiberty libgloss newlib libio librx libstdc++ libg++ winsup opcodes libstub cygmon libf2c libchill libobjc
TARGET_CONFIGDIRS = libiberty libgloss newlib libio librx libstdc++ libg++ winsup
# Target libraries are put under this directory:
# Changed by configure to $(target_alias) if cross.
@@ -188,38 +170,28 @@ RPATH_ENVVAR = LD_LIBRARY_PATH
# configure.in sets SET_LIB_PATH to this if --enable-shared was used.
REALLY_SET_LIB_PATH = \
if [ x"$$$(RPATH_ENVVAR)" != x ]; then \
$(RPATH_ENVVAR)=$$r/bfd:$$r/opcodes:$$$(RPATH_ENVVAR); \
else \
$(RPATH_ENVVAR)=$$r/bfd:$$r/opcodes; \
fi; \
$(RPATH_ENVVAR)=$$r/bfd:$$r/opcodes:$$$(RPATH_ENVVAR); \
export $(RPATH_ENVVAR);
ALL = all.normal
INSTALL_TARGET = installdirs \
install-gcc \
$(INSTALL_MODULES) \
$(INSTALL_TARGET_MODULES) \
$(INSTALL_X11_MODULES) \
install-gcc \
$(INSTALL_DOSREL)
INSTALL_TARGET_CROSS = installdirs \
install-gcc-cross \
$(INSTALL_MODULES) \
$(INSTALL_TARGET_MODULES) \
$(INSTALL_X11_MODULES) \
$(INSTALL_DOSREL)
CC_FOR_TARGET = ` \
if [ -f $$r/gcc/xgcc ] ; then \
if [ -f $$r/$(TARGET_SUBDIR)/newlib/Makefile ] ; then \
if [ -f $$r/$(TARGET_SUBDIR)/winsup/Makefile ] ; then \
echo $$r/gcc/xgcc -B$$r/gcc/ -B$$r/$(TARGET_SUBDIR)/newlib/ -B$(build_tooldir)/bin/ -L$$r/$(TARGET_SUBDIR)/winsup -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \
echo $$r/gcc/xgcc -B$$r/gcc/ -B$$r/newlib/ -L$$r/$(TARGET_SUBDIR)/winsup -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \
else \
echo $$r/gcc/xgcc -B$$r/gcc/ -B$(build_tooldir)/bin/ -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \
echo $$r/gcc/xgcc -B$$r/gcc/ -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \
fi; \
else \
echo $$r/gcc/xgcc -B$$r/gcc/ -B$(build_tooldir)/bin/; \
echo $$r/gcc/xgcc -B$$r/gcc/; \
fi; \
else \
if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
@@ -233,29 +205,19 @@ CC_FOR_TARGET = ` \
# variable is passed down to the gcc Makefile, where it is used to
# build libgcc2.a. We define it here so that it can itself be
# overridden on the command line.
GCC_FOR_TARGET = $$r/gcc/xgcc -B$$r/gcc/ -B$(build_tooldir)/bin/ -I$(build_tooldir)/include
GCC_FOR_TARGET = $$r/gcc/xgcc -B$$r/gcc/
CHILL_FOR_TARGET = ` \
if [ -f $$r/gcc/xgcc ] ; then \
echo $$r/gcc/xgcc -B$$r/gcc/ -B$(build_tooldir)/bin/ -L$$r/gcc/ch/runtime/; \
else \
if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
echo $(CC); \
else \
t='$(program_transform_name)'; echo gcc | sed -e 's/x/x/' $$t; \
fi; \
fi`
CXX_FOR_TARGET = ` \
if [ -f $$r/gcc/xgcc ] ; then \
if [ -f $$r/$(TARGET_SUBDIR)/newlib/Makefile ] ; then \
if [ -f $$r/$(TARGET_SUBDIR)/winsup/Makefile ] ; then \
echo $$r/gcc/xgcc -B$$r/gcc/ -B$$r/$(TARGET_SUBDIR)/newlib/ -B$(build_tooldir)/bin/ -L$$r/winsup -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \
echo $$r/gcc/xgcc -B$$r/gcc/ -B$$r/newlib/ -L$$r/winsup -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \
else \
echo $$r/gcc/xgcc -B$$r/gcc/ -B$(build_tooldir)/bin/ -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \
echo $$r/gcc/xgcc -B$$r/gcc/ -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \
fi; \
else \
echo $$r/gcc/xgcc -B$$r/gcc/ -B$(build_tooldir)/bin/; \
echo $$r/gcc/xgcc -B$$r/gcc/; \
fi; \
else \
if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \
@@ -342,18 +304,6 @@ NM_FOR_TARGET = ` \
fi; \
fi`
# The first rule in the file had better be this one. Don't put any above it.
# This lives here to allow makefile fragments to contain dependencies.
all: all.normal
.PHONY: all
# These can be overridden by config/mt-*.
# The _TARGET_ is because they're specified in mt-foo.
# The _HOST_ is because they're programs that run on the host.
EXTRA_TARGET_HOST_ALL_MODULES =
EXTRA_TARGET_HOST_INSTALL_MODULES =
EXTRA_TARGET_HOST_CHECK_MODULES =
#### host and target specific makefile fragments come in here.
###
@@ -368,9 +318,6 @@ BASE_FLAGS_TO_PASS = \
"CC_FOR_TARGET=$(CC_FOR_TARGET)" \
"CFLAGS=$(CFLAGS)" \
"CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
"CHILLFLAGS=$(CHILLFLAGS)" \
"CHILL_FOR_TARGET=$(CHILL_FOR_TARGET)" \
"CHILL_LIB=$(CHILL_LIB)" \
"CXX_FOR_BUILD=$(CXX_FOR_BUILD)" \
"CXXFLAGS=$(CXXFLAGS)" \
"CXXFLAGS_FOR_TARGET=$(CXXFLAGS_FOR_TARGET)" \
@@ -391,37 +338,18 @@ BASE_FLAGS_TO_PASS = \
"MAKE=$(MAKE)" \
"MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \
"NM_FOR_TARGET=$(NM_FOR_TARGET)" \
"PICFLAG=$(PICFLAG)" \
"PICFLAG_FOR_TARGET=$(PICFLAG_FOR_TARGET)" \
"RANLIB_FOR_TARGET=$(RANLIB_FOR_TARGET)" \
"RPATH_ENVVAR=$(RPATH_ENVVAR)" \
"SHELL=$(SHELL)" \
"EXPECT=$(EXPECT)" \
"RUNTEST=$(RUNTEST)" \
"RUNTESTFLAGS=$(RUNTESTFLAGS)" \
"TARGET_SUBDIR=$(TARGET_SUBDIR)" \
"WINDRES_FOR_TARGET=$(WINDRES_FOR_TARGET)" \
"YACC=$(YACC)" \
"bindir=$(bindir)" \
"datadir=$(datadir)" \
"exec_prefix=$(exec_prefix)" \
"includedir=$(includedir)" \
"infodir=$(infodir)" \
"libdir=$(libdir)" \
"libexecdir=$(libexecdir)" \
"lispdir=$(lispdir)" \
"localstatedir=$(localstatedir)" \
"mandir=$(mandir)" \
"oldincludedir=$(oldincludedir)" \
"prefix=$(prefix)" \
"sbindir=$(sbindir)" \
"sharedstatedir=$(sharedstatedir)" \
"sysconfdir=$(sysconfdir)" \
"tooldir=$(tooldir)" \
"build_tooldir=$(build_tooldir)" \
"gxx_include_dir=$(gxx_include_dir)" \
"gcc_version=$(gcc_version)" \
"gcc_version_trigger=$(gcc_version_trigger)" \
"target_alias=$(target_alias)" \
"libsubdir=$(libsubdir)"
"tooldir=$(tooldir)"
# Flags to pass down to most sub-makes, in which we're building with
# the host environment.
@@ -467,6 +395,7 @@ EXTRA_TARGET_FLAGS = \
'LIBCFLAGS=$$(LIBCFLAGS_FOR_TARGET)' \
'LIBCXXFLAGS=$$(LIBCXXFLAGS_FOR_TARGET)' \
'NM=$$(NM_FOR_TARGET)' \
'PICFLAG=$$(PICFLAG_FOR_TARGET)' \
'RANLIB=$$(RANLIB_FOR_TARGET)' \
'WINDRES=$$(WINDRES_FOR_TARGET)'
@@ -479,7 +408,7 @@ TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
# The HOST_* variables are a special case, which are used for the gcc
# cross-building scheme.
EXTRA_GCC_FLAGS = \
'AR=$(AR)' \
'AR=$$(AR_FOR_TARGET)' \
'AS=$(AS)' \
'CC=$(CC)' \
'CXX=$(CXX)' \
@@ -488,18 +417,18 @@ EXTRA_GCC_FLAGS = \
'HOST_PREFIX=$(HOST_PREFIX)' \
'HOST_PREFIX_1=$(HOST_PREFIX_1)' \
'NM=$(NM)' \
'RANLIB=$(RANLIB)' \
'RANLIB=$$(RANLIB_FOR_TARGET)' \
'WINDRES=$$(WINDRES_FOR_TARGET)' \
"GCC_FOR_TARGET=$(GCC_FOR_TARGET)" \
"`echo 'LANGUAGES=$(LANGUAGES)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'STMP_FIXPROTO=$(STMP_FIXPROTO)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'LIMITS_H_TEST=$(LIMITS_H_TEST)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'LIBGCC1_TEST=$(LIBGCC1_TEST)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'LIBGCC2_CFLAGS=$(LIBGCC2_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'LIBGCC2_DEBUG_CFLAGS=$(LIBGCC2_DEBUG_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'LIBGCC2_INCLUDES=$(LIBGCC2_INCLUDES)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'ENQUIRE=$(ENQUIRE)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'BOOT_CFLAGS=$(BOOT_CFLAGS)' | sed -e s/.*=$$/XFOO=/`"
"`if test x'$(LANGUAGES)' != x; then echo 'LANGUAGES=$(LANGUAGES)'; else echo 'XFOO=bar'; fi`" \
"`if test x'$(STMP_FIXPROTO)' != x; then echo 'STMP_FIXPROTO=$(STMP_FIXPROTO)'; else echo 'XFOO=bar'; fi`" \
"`if test x'$(LIMITS_H_TEST)' != x; then echo 'LIMITS_H_TEST=$(LIMITS_H_TEST)'; else echo 'XFOO=bar'; fi`" \
"`if test x'$(LIBGCC1_TEST)' != x; then echo 'LIBGCC1_TEST=$(LIBGCC1_TEST)'; else echo 'XFOO=bar'; fi`" \
"`if test x'$(LIBGCC2_CFLAGS)' != x; then echo 'LIBGCC2_CFLAGS=$(LIBGCC2_CFLAGS)'; else echo 'XFOO=bar'; fi`" \
"`if test x'$(LIBGCC2_DEBUG_CFLAGS)' != x; then echo 'LIBGCC2_DEBUG_CFLAGS=$(LIBGCC2_DEBUG_CFLAGS)'; else echo 'XFOO=bar'; fi`" \
"`if test x'$(LIBGCC2_INCLUDES)' != x; then echo 'LIBGCC2_INCLUDES=$(LIBGCC2_INCLUDES)'; else echo 'XFOO=bar'; fi`" \
"`if test x'$(ENQUIRE)' != x; then echo 'ENQUIRE=$(ENQUIRE)'; else echo 'XFOO=bar'; fi`" \
"`if test x'$(BOOT_CFLAGS)' != x; then echo 'BOOT_CFLAGS=$(BOOT_CFLAGS)'; else echo 'XFOO=bar'; fi`"
GCC_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_GCC_FLAGS)
@@ -507,7 +436,6 @@ GCC_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_GCC_FLAGS)
# using $(FLAGS_TO_PASS).
ALL_MODULES = \
all-apache \
all-ash \
all-autoconf \
all-automake \
all-bash \
@@ -515,8 +443,7 @@ ALL_MODULES = \
all-binutils \
all-bison \
all-byacc \
all-bzip2 \
all-cvssrc \
all-cvs \
all-db \
all-dejagnu \
all-diff \
@@ -528,7 +455,6 @@ ALL_MODULES = \
all-flex \
all-gas \
all-gawk \
all-gettext \
all-gnuserv \
all-gprof \
all-grep \
@@ -537,11 +463,9 @@ ALL_MODULES = \
all-hello \
all-indent \
all-inet \
all-intl \
all-ispell \
all-itcl \
all-ld \
all-libgui \
all-libiberty \
all-m4 \
all-make \
@@ -558,7 +482,7 @@ ALL_MODULES = \
all-send-pr \
all-shellutils \
all-sim \
all-snavigator \
all-sn \
all-tar \
all-tcl \
all-texinfo \
@@ -566,9 +490,7 @@ ALL_MODULES = \
all-tgas \
all-time \
all-uudecode \
all-wdiff \
all-zip \
$(EXTRA_TARGET_HOST_ALL_MODULES)
all-wdiff
# This is a list of the check targets for all of the modules which are
# compiled using $(FLAGS_TO_PASS).
@@ -579,19 +501,16 @@ ALL_MODULES = \
NATIVE_CHECK_MODULES = \
check-bison \
check-byacc \
check-flex \
check-zip
check-flex
CROSS_CHECK_MODULES = \
check-apache \
check-ash \
check-autoconf \
check-automake \
check-bash \
check-bfd \
check-binutils \
check-bzip2 \
check-cvssrc \
check-cvs \
check-db \
check-dejagnu \
check-diff \
@@ -601,7 +520,6 @@ CROSS_CHECK_MODULES = \
check-find \
check-gas \
check-gawk \
check-gettext \
check-gnuserv \
check-gprof \
check-grep \
@@ -609,13 +527,10 @@ CROSS_CHECK_MODULES = \
check-hello \
check-indent \
check-inet \
check-intl \
check-ispell \
check-itcl \
check-ld \
check-libgui \
check-libiberty \
check-libtool \
check-m4 \
check-make \
check-mmcheckoc \
@@ -629,7 +544,7 @@ CROSS_CHECK_MODULES = \
check-sed \
check-send-pr \
check-shellutils \
check-snaviagor \
check-sn \
check-sim \
check-tar \
check-tcl \
@@ -638,8 +553,7 @@ CROSS_CHECK_MODULES = \
check-tgas \
check-time \
check-uudecode \
check-wdiff \
$(EXTRA_TARGET_HOST_CHECK_MODULES)
check-wdiff
CHECK_MODULES=$(NATIVE_CHECK_MODULES) $(CROSS_CHECK_MODULES)
@@ -648,21 +562,17 @@ CHECK_MODULES=$(NATIVE_CHECK_MODULES) $(CROSS_CHECK_MODULES)
# We put install-opcodes before install-binutils because the installed
# binutils might be on PATH, and they might need the shared opcodes
# library.
# We put install-tcl before install-itcl because itcl wants to run a
# program on installation which uses the Tcl libraries.
INSTALL_MODULES = \
install-apache \
install-ash \
install-autoconf \
install-automake \
install-bash \
install-bfd \
install-bzip2 \
install-opcodes \
install-binutils \
install-bison \
install-byacc \
install-cvssrc \
install-cvs \
install-db \
install-dejagnu \
install-diff \
@@ -674,7 +584,6 @@ INSTALL_MODULES = \
install-flex \
install-gas \
install-gawk \
install-gettext \
install-gnuserv \
install-gprof \
install-grep \
@@ -683,14 +592,10 @@ INSTALL_MODULES = \
install-hello \
install-indent \
install-inet \
install-intl \
install-ispell \
install-tcl \
install-itcl \
install-ld \
install-libgui \
install-libiberty \
install-libtool \
install-m4 \
install-make \
install-mmalloc \
@@ -704,16 +609,15 @@ INSTALL_MODULES = \
install-send-pr \
install-shellutils \
install-sim \
install-snavigator \
install-sn \
install-tar \
install-tcl \
install-texinfo \
install-textutils \
install-tgas \
install-time \
install-uudecode \
install-wdiff \
install-zip \
$(EXTRA_TARGET_HOST_INSTALL_MODULES)
install-wdiff
# This is a list of the targets for all of the modules which are compiled
# using $(X11_FLAGS_TO_PASS).
@@ -761,20 +665,11 @@ ALL_TARGET_MODULES = \
all-target-librx \
all-target-libg++ \
all-target-newlib \
all-target-libf2c \
all-target-libchill \
all-target-libobjc \
all-target-winsup \
all-target-libgloss \
all-target-libiberty \
all-target-gperf \
all-target-examples \
all-target-libstub \
all-target-libjava \
all-target-zlib \
all-target-boehm-gc \
all-target-qthreads \
all-target-cygmon
all-target-examples
# This is a list of the configure targets for all of the modules which
# are compiled using the target tools.
@@ -784,20 +679,11 @@ CONFIGURE_TARGET_MODULES = \
configure-target-librx \
configure-target-libg++ \
configure-target-newlib \
configure-target-libf2c \
configure-target-libchill \
configure-target-libobjc \
configure-target-winsup \
configure-target-libgloss \
configure-target-libiberty \
configure-target-gperf \
configure-target-examples \
configure-target-libstub \
configure-target-libjava \
configure-target-zlib \
configure-target-boehm-gc \
configure-target-qthreads \
configure-target-cygmon
configure-target-examples
# This is a list of the check targets for all of the modules which are
# compiled using $(TARGET_FLAGS_TO_PASS).
@@ -806,15 +692,8 @@ CHECK_TARGET_MODULES = \
check-target-libstdc++ \
check-target-libg++ \
check-target-newlib \
check-target-libf2c \
check-target-libchill \
check-target-libobjc \
check-target-winsup \
check-target-libiberty \
check-target-libjava \
check-target-zlib \
check-target-boehm-gc \
check-target-qthreads \
check-target-gperf
# This is a list of the install targets for all of the modules which are
@@ -824,23 +703,14 @@ INSTALL_TARGET_MODULES = \
install-target-libstdc++ \
install-target-libg++ \
install-target-newlib \
install-target-libf2c \
install-target-libchill \
install-target-libobjc \
install-target-winsup \
install-target-libgloss \
install-target-libiberty \
install-target-bsp \
install-target-libjava \
install-target-zlib \
install-target-boehm-gc \
install-target-qthreads \
install-target-gperf
# This is a list of the targets for which we can do a clean-{target}.
CLEAN_MODULES = \
clean-apache \
clean-ash \
clean-autoconf \
clean-automake \
clean-bash \
@@ -848,8 +718,7 @@ CLEAN_MODULES = \
clean-binutils \
clean-bison \
clean-byacc \
clean-bzip2 \
clean-cvssrc \
clean-cvs \
clean-db \
clean-dejagnu \
clean-diff \
@@ -861,7 +730,6 @@ CLEAN_MODULES = \
clean-flex \
clean-gas \
clean-gawk \
clean-gettext \
clean-gnuserv \
clean-gprof \
clean-grep \
@@ -870,13 +738,10 @@ CLEAN_MODULES = \
clean-hello \
clean-indent \
clean-inet \
clean-intl \
clean-ispell \
clean-itcl \
clean-ld \
clean-libgui \
clean-libiberty \
clean-libtool \
clean-m4 \
clean-make \
clean-mmalloc \
@@ -892,7 +757,7 @@ CLEAN_MODULES = \
clean-send-pr \
clean-shellutils \
clean-sim \
clean-snavigator \
clean-sn \
clean-tar \
clean-tcl \
clean-texinfo \
@@ -900,9 +765,7 @@ CLEAN_MODULES = \
clean-tgas \
clean-time \
clean-uudecode \
clean-wdiff \
clean-zip
clean-wdiff
# All of the target modules that can be cleaned
CLEAN_TARGET_MODULES = \
@@ -911,20 +774,11 @@ CLEAN_TARGET_MODULES = \
clean-target-librx \
clean-target-libg++ \
clean-target-newlib \
clean-target-libf2c \
clean-target-libchill \
clean-target-libobjc \
clean-target-winsup \
clean-target-libgloss \
clean-target-libiberty \
clean-target-gperf \
clean-target-examples \
clean-target-libstub \
clean-target-libjava \
clean-target-zlib \
clean-target-boehm-gc \
clean-target-qthreads \
clean-target-cygmon
clean-target-examples
# All of the x11 modules that can be cleaned
CLEAN_X11_MODULES = \
@@ -1036,10 +890,10 @@ install-info: do-install-info dir.info
else true ; fi
local-clean:
-rm -f *.a TEMP errs core *.o *~ \#* TAGS *.E *.log
-rm -f *.a TEMP errs core *.o *~ \#* TAGS *.E
local-distclean:
-rm -f Makefile config.status config.cache mh-frag mt-frag
-rm -f Makefile config.status config.cache
-if [ "$(TARGET_SUBDIR)" != "." ]; then \
rm -rf $(TARGET_SUBDIR); \
else true; fi
@@ -1091,32 +945,10 @@ check: $(CHECK_MODULES) \
$(CHECK_X11_MODULES) \
check-gcc
# Automated reporting of test results.
warning.log: build.log
$(srcdir)/contrib/warn_summary build.log > $@
mail-report.log:
if test x'$(BOOT_CFLAGS)' != x''; then \
BOOT_CFLAGS='$(BOOT_CFLAGS)'; export BOOT_CFLAGS; \
fi; \
$(srcdir)/contrib/test_summary -t >$@
chmod +x $@
echo If you really want to send e-mail, run ./$@ now
mail-report-with-warnings.log: warning.log
if test x'$(BOOT_CFLAGS)' != x''; then \
BOOT_CFLAGS='$(BOOT_CFLAGS)'; export BOOT_CFLAGS; \
fi; \
$(srcdir)/contrib/test_summary -t -i warning.log >$@
chmod +x $@
echo If you really want to send e-mail, run ./$@ now
# Installation targets.
.PHONY: install install-cross uninstall source-vault binary-vault vault-install
.PHONY: install uninstall source-vault binary-vault vault-install
install: $(INSTALL_TARGET)
install-cross: $(INSTALL_TARGET_CROSS)
uninstall:
@echo "the uninstall target is not supported in this tree"
@@ -1325,23 +1157,14 @@ $(CONFIGURE_TARGET_MODULES):
libsrcdir="$$s/$${dir}"; \
fi; \
if [ -f $${libsrcdir}/configure ] ; then \
rm -f no-such-file skip-this-dir; \
CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
$(SHELL) $${libsrcdir}/configure \
$(CONFIG_ARGUMENTS) $${srcdiroption} \
--with-target-subdir="$(TARGET_SUBDIR)"; \
else \
rm -f no-such-file skip-this-dir; \
CONFIG_SITE=no-such-file $(SHELL) $$s/configure \
$(SHELL) $$s/configure \
$(CONFIG_ARGUMENTS) $${srcdiroption} \
--with-target-subdir="$(TARGET_SUBDIR)"; \
fi; \
if [ -f skip-this-dir ] ; then \
sh skip-this-dir; \
rm -f skip-this-dir; \
cd ..; rmdir $${dir} || true; \
else \
true; \
fi; \
else \
true; \
fi; \
@@ -1450,57 +1273,16 @@ all-gcc:
true; \
fi
# Building GCC uses some tools for rebuilding "source" files
# like texinfo, bison/byacc, etc. So we must depend on those.
#
# While building GCC, it may be necessary to run various target
# programs like the assembler, linker, etc. So we depend on
# those too.
#
# In theory, on an SMP all those dependencies can be resolved
# in parallel.
#
.PHONY: bootstrap bootstrap-lean bootstrap2 bootstrap2-lean bootstrap3 bootstrap3-lean bootstrap4 bootstrap4-lean
bootstrap bootstrap-lean bootstrap2 bootstrap2-lean bootstrap3 bootstrap3-lean bootstrap4 bootstrap4-lean: all-texinfo all-bison all-byacc all-binutils all-gas all-ld
@r=`pwd`; export r; \
s=`cd $(srcdir); pwd`; export s; \
$(SET_LIB_PATH) \
echo "Bootstrapping the compiler"; \
cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) $@
@r=`pwd`; export r; \
s=`cd $(srcdir); pwd`; export s; \
case "$@" in \
*bootstrap4-lean ) \
msg="Comparing stage3 and stage4 of the compiler"; \
compare=compare3-lean ;; \
*bootstrap4 ) msg="Comparing stage3 and stage4 of the compiler"; \
compare=compare3 ;; \
*-lean ) msg="Comparing stage2 and stage3 of the compiler"; \
compare=compare-lean ;; \
* ) msg="Comparing stage2 and stage3 of the compiler"; \
compare=compare ;; \
esac; \
$(SET_LIB_PATH) \
echo "$$msg"; \
cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) $$compare
@r=`pwd`; export r; \
s=`cd $(srcdir); pwd` ; export s; \
$(SET_LIB_PATH) \
echo "Building runtime libraries"; \
$(MAKE) $(BASE_FLAGS_TO_PASS) all
.PHONY: cross
cross: all-texinfo all-bison all-byacc all-binutils all-gas all-ld
@r=`pwd`; export r; \
s=`cd $(srcdir); pwd`; export s; \
$(SET_LIB_PATH) \
echo "Building the C and C++ compiler"; \
cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) LANGUAGES="c c++"
@r=`pwd`; export r; \
s=`cd $(srcdir); pwd` ; export s; \
$(SET_LIB_PATH) \
echo "Building runtime libraries"; \
$(MAKE) $(BASE_FLAGS_TO_PASS) all LANGUAGES="c c++"
.PHONY: all-bootstrap
all-bootstrap:
@if [ -f ./gcc/Makefile ] ; then \
r=`pwd`; export r; \
s=`cd $(srcdir); pwd`; export s; \
$(SET_LIB_PATH) \
(cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) bootstrap); \
else \
true; \
fi
.PHONY: check-gcc
check-gcc:
@@ -1524,16 +1306,7 @@ install-gcc:
true; \
fi
.PHONY: install-gcc-cross
install-gcc-cross:
@if [ -f ./gcc/Makefile ] ; then \
r=`pwd`; export r; \
s=`cd $(srcdir); pwd`; export s; \
$(SET_LIB_PATH) \
(cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) LANGUAGES="c c++" install); \
else \
true; \
fi
# EXPERIMENTAL STUFF
# This rule is used to install the modules which use FLAGS_TO_PASS.
# To build a target install-X means to cd to X and make install.
@@ -1554,20 +1327,14 @@ install-dosrel-fake:
# This is a list of inter-dependencies among modules.
all-apache:
all-ash:
all-autoconf: all-m4 all-texinfo
all-automake: all-m4 all-texinfo
all-automake:
all-bash:
all-bfd: all-libiberty all-intl
all-binutils: all-libiberty all-opcodes all-bfd all-flex all-bison all-byacc all-intl
all-bfd:
all-binutils: all-libiberty all-opcodes all-bfd all-flex all-bison all-byacc
all-bison: all-texinfo
configure-target-boehm-gc: configure-target-newlib configure-target-qthreads
all-target-boehm-gc: configure-target-boehm-gc
all-byacc:
all-bzip2:
all-cvssrc:
configure-target-cygmon: $(ALL_GCC)
all-target-cygmon: configure-target-cygmon all-gas all-ld all-gcc all-target-libiberty all-target-newlib all-target-libio all-target-libstub
all-cvs:
all-db:
all-dejagnu: all-tcl all-expect all-tk
all-diff: all-libiberty
@@ -1581,19 +1348,18 @@ all-fileutils: all-libiberty
all-findutils:
all-find:
all-flex: all-libiberty all-bison all-byacc
all-gas: all-libiberty all-opcodes all-bfd all-intl
all-gas: all-libiberty all-opcodes all-bfd
all-gash: all-tcl
all-gawk:
ALL_GCC = all-gcc
all-gcc: all-bison all-byacc all-binutils all-gas all-ld
all-bootstrap: all-libiberty all-bison all-byacc all-binutils all-gas all-ld
GDB_TK = all-tk all-tcl all-itcl all-tix all-libgui
GDB_TK = all-tk all-tcl all-itcl all-tix
all-gdb: all-libiberty all-opcodes all-bfd all-mmalloc all-readline all-bison all-byacc all-sim $(gdbnlmrequirements) $(GDB_TK)
all-gettext:
all-gnuserv:
configure-target-gperf: $(ALL_GCC)
all-target-gperf: configure-target-gperf all-target-libiberty all-target-libstdc++
all-gprof: all-libiberty all-bfd all-opcodes all-intl
all-target-gperf: configure-target-gperf all-target-libiberty all-target-libg++
all-gprof: all-libiberty all-bfd all-opcodes
all-grep: all-libiberty
all-grez: all-libiberty all-bfd all-opcodes
all-gui: all-gdb all-libproc all-target-librx
@@ -1602,31 +1368,20 @@ all-gzip: all-libiberty
all-hello: all-libiberty
all-indent:
all-inet: all-tcl all-send-pr all-perl
all-intl:
all-ispell: all-emacs19
all-itcl: all-tcl all-tk
all-ld: all-libiberty all-bfd all-opcodes all-bison all-byacc all-flex all-intl
all-ld: all-libiberty all-bfd all-opcodes all-bison all-byacc all-flex
configure-target-libg++: $(ALL_GCC) configure-target-librx
all-target-libg++: configure-target-libg++ all-gas all-ld all-gcc all-target-libiberty all-target-newlib all-target-libio all-target-librx all-target-libstdc++
configure-target-libgloss: $(ALL_GCC)
all-target-libgloss: configure-target-libgloss configure-target-newlib
configure-target-libio: $(ALL_GCC)
all-target-libio: configure-target-libio all-gas all-ld all-gcc all-target-libiberty all-target-newlib
check-target-libio: all-target-libstdc++
all-libgui: all-tcl all-tk all-itcl
all-libiberty:
configure-target-libjava: $(ALL_GCC) configure-target-zlib configure-target-boehm-gc configure-target-qthreads configure-target-newlib
all-target-libjava: configure-target-libjava all-gcc all-zip all-target-newlib all-target-zlib all-target-boehm-gc all-target-qthreads
configure-target-librx: $(ALL_GCC) configure-target-newlib
all-target-librx: configure-target-librx
configure-target-libstdc++: $(ALL_GCC)
all-target-libstdc++: configure-target-libstdc++ all-gas all-ld all-gcc all-target-libiberty all-target-newlib all-target-libio
configure-target-libstub: $(ALL_GCC)
all-target-libstub: configure-target-libstub
all-libtool:
all-target-libf2c: configure-target-libf2c all-gas all-ld all-gcc all-target-libiberty all-target-newlib
all-target-libchill: configure-target-libchill all-gas all-ld all-gcc all-target-libiberty all-target-newlib
all-target-libobjc: configure-target-libobjc all-gas all-ld all-gcc all-target-libiberty all-target-newlib
all-m4: all-libiberty
all-make: all-libiberty
all-mmalloc:
@@ -1636,16 +1391,14 @@ all-opcodes: all-bfd all-libiberty
all-patch: all-libiberty
all-perl:
all-prms: all-libiberty
configure-target-qthreads: configure-target-newlib
all-target-qthreads: configure-target-qthreads
all-rcs:
all-readline:
all-recode: all-libiberty
all-sed: all-libiberty
all-send-pr: all-prms
all-shellutils:
all-sim: all-libiberty all-bfd all-opcodes all-readline
all-snavigator: all-tcl all-tk all-itcl all-db all-grep all-libgui
all-sim: all-libiberty all-bfd all-opcodes
all-sn: all-tcl all-tk all-itcl all-db all-grep
all-tar: all-libiberty
all-tcl:
all-tclX: all-tcl all-tk
@@ -1656,12 +1409,9 @@ all-tgas: all-libiberty all-bfd all-opcodes
all-time:
all-tix: all-tcl all-tk
all-wdiff:
all-target-winsup: all-target-newlib all-target-libiberty all-target-libio configure-target-winsup
all-target-winsup: all-target-newlib all-target-libiberty all-target-librx all-target-libio configure-target-winsup
configure-target-winsup: configure-target-newlib
all-uudecode: all-libiberty
all-zip:
configure-target-zlib: $(ALL_GCC)
all-target-zlib: configure-target-zlib
configure-target-libiberty: $(ALL_GCC)
all-target-libiberty: configure-target-libiberty all-gcc all-ld all-target-newlib
all-target: $(ALL_TARGET_MODULES)
@@ -1699,7 +1449,7 @@ TAGS: do-TAGS
# with the gnu make, this is done automatically.
Makefile: Makefile.in configure.in $(host_makefile_frag) $(target_makefile_frag) $(gcc_version_trigger)
Makefile: Makefile.in configure.in $(host_makefile_frag) $(target_makefile_frag)
$(SHELL) ./config.status
#
@@ -1709,7 +1459,7 @@ Makefile: Makefile.in configure.in $(host_makefile_frag) $(target_makefile_frag)
# ChangeLog omitted because it may refer to files which are not in this
# distribution (perhaps it would be better to include it anyway).
DEVO_SUPPORT= README Makefile.in configure configure.in \
config.guess config.if config.sub config move-if-change \
config.guess config.sub config move-if-change \
mpw-README mpw-build.in mpw-config.in mpw-configure mpw-install \
COPYING COPYING.LIB install-sh config-ml.in symlink-tree \
mkinstalldirs ltconfig ltmain.sh missing ylwrap
@@ -1728,7 +1478,7 @@ SUPPORT_FILES = list-of-support-files-for-tool-in-question
taz: $(DEVO_SUPPORT) $(SUPPORT_FILES) \
texinfo/texinfo.tex texinfo/gpl.texinfo texinfo/lgpl.texinfo
# Take out texinfo from a few places
# Take out texinfo from a few places; make simple BISON=bison line.
sed -e '/^all\.normal: /s/\all-texinfo //' \
-e '/^ install-texinfo /d' \
<Makefile.in >tmp
@@ -1778,7 +1528,7 @@ taz: $(DEVO_SUPPORT) $(SUPPORT_FILES) \
mkdir proto-toplev/texinfo/util && \
ln -s ../../../texinfo/util/tex3patch proto-toplev/texinfo/util ; \
else true; fi
chmod -R og=u . || chmod og=u `find . -print`
chmod og=u `find . -print`
if grep AM_INIT_AUTOMAKE $(TOOL)/configure.in >/dev/null 2>&1; then \
ver=`sed < $(TOOL)/configure.in -n 's/AM_INIT_AUTOMAKE[^,]*, *\([^)]*\))/\1/p'`; \
else \
@@ -1797,14 +1547,14 @@ TEXINFO_SUPPORT= texinfo/texinfo.tex texinfo/gpl.texinfo texinfo/lgpl.texinfo
DIST_SUPPORT= $(DEVO_SUPPORT) $(TEXINFO_SUPPORT)
.PHONY: gas.tar.gz
GAS_SUPPORT_DIRS= bfd include libiberty opcodes intl setup.com makefile.vms
GAS_SUPPORT_DIRS= bfd include libiberty opcodes setup.com makefile.vms
gas.tar.gz: $(DIST_SUPPORT) $(GAS_SUPPORT_DIRS) gas
$(MAKE) -f Makefile.in taz TOOL=gas \
SUPPORT_FILES="$(GAS_SUPPORT_DIRS)"
# The FSF "binutils" release includes gprof and ld.
.PHONY: binutils.tar.gz
BINUTILS_SUPPORT_DIRS= bfd gas include libiberty opcodes ld gprof intl setup.com makefile.vms
BINUTILS_SUPPORT_DIRS= bfd gas include libiberty opcodes ld gprof setup.com makefile.vms
binutils.tar.gz: $(DIST_SUPPORT) $(BINUTILS_SUPPORT_DIRS) binutils
$(MAKE) -f Makefile.in taz TOOL=binutils \
SUPPORT_FILES="$(BINUTILS_SUPPORT_DIRS) makeall.bat configure.bat"
@@ -1827,7 +1577,7 @@ gnats.tar.gz: $(DIST_SUPPORT) $(GNATS_SUPPORT_DIRS) gnats
SUPPORT_FILES="$(GNATS_SUPPORT_DIRS)"
.PHONY: gdb.tar.gz
GDB_SUPPORT_DIRS= bfd include libiberty mmalloc opcodes readline sim utils intl
GDB_SUPPORT_DIRS= bfd include libiberty mmalloc opcodes readline sim utils
GDBTK_SUPPORT_DIRS= `if [ -d tcl -a -d tk ] ; then echo tcl tk ; fi`
gdb.tar.gz: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb
$(MAKE) -f Makefile.in taz TOOL=gdb \
@@ -1854,4 +1604,5 @@ newlib.tar.gz: $(DIST_SUPPORT) $(NEWLIB_SUPPORT_DIRS) newlib
.NOEXPORT:
MAKEOVERRIDES=
# end of Makefile.in

34
README
View File

@@ -3,10 +3,40 @@
This directory contains various GNU compilers, assemblers, linkers,
debuggers, etc., plus their support routines, definitions, and documentation.
If you are receiving this as part of a GDB release, see the file gdb/README.
If with a binutils release, see binutils/README; if with a libg++ release,
see libg++/README, etc. That'll give you info about this
package -- supported targets, how to use it, how to report bugs, etc.
Check the INSTALL directory for detailed configuration and installation
instructions.
It is now possible to automatically configure and build a variety of
tools with one command. To build all of the tools contained herein,
run the ``configure'' script here, e.g.:
./configure
make
To install them (by default in /usr/local/bin, /usr/local/lib, etc),
then do:
make install
(If the configure script can't determine your type of computer, give it
the name as an argument, for instance ``./configure sun4''. You can
use the script ``config.sub'' to test whether a name is recognized; if
it is, config.sub translates it to a triplet specifying CPU, vendor,
and OS.)
If you have more than one compiler on your system, it is often best to
explicitly set CC in the environment before running configure, and to
also set CC when running make. For example (assuming sh/bash/ksh):
CC=gcc ./configure
make
A similar example using csh:
setenv CC gcc
./configure
make
Much of the code and documentation enclosed is copyright by
the Free Software Foundation, Inc. See the file COPYING or

View File

@@ -99,7 +99,6 @@ fi
# Scan all the arguments and set all the ones we need.
ml_verbose=--verbose
for option in ${ml_arguments}
do
case $option in
@@ -129,9 +128,6 @@ do
--norecursion | --no*)
ml_norecursion=yes
;;
--silent | --sil* | --quiet | --q*)
ml_verbose=--silent
;;
--verbose | --v | --verb*)
ml_verbose=--verbose
;;
@@ -299,28 +295,6 @@ mips*-*-*)
esac
done
fi
case " $multidirs " in
*" mabi=64 "*)
# We will not be able to create libraries with -mabi=64 if
# we cannot even link a trivial program. It usually
# indicates the 64bit libraries are missing.
if echo 'main() {}' > conftest.c &&
${CC-gcc} -mabi=64 conftest.c -o conftest; then
:
else
echo Could not link program with -mabi=64, disabling it.
old_multidirs="${multidirs}"
multidirs=""
for x in ${old_multidirs}; do
case "$x" in
*mabi=64* ) : ;;
*) multidirs="${multidirs} ${x}" ;;
esac
done
fi
rm -f conftest.c conftest
;;
esac
;;
powerpc*-*-* | rs6000*-*-*)
if [ x$enable_softfloat = xno ]
@@ -434,7 +408,6 @@ multi-do:
CXXFLAGS="$(CXXFLAGS) $${flags}" \
LIBCFLAGS="$(LIBCFLAGS) $${flags}" \
LIBCXXFLAGS="$(LIBCXXFLAGS) $${flags}" \
LDFLAGS="$(LDFLAGS) $${flags}" \
$(DO)); then \
true; \
else \
@@ -590,13 +563,6 @@ if [ -n "${multidirs}" ] && [ -z "${ml_norecursion}" ]; then
fi
(cd ${ml_dir}/${ml_libdir};
../${dotdot}${ml_unsubdir}symlink-tree ../${dotdot}${ml_unsubdir}${ml_libdir} "")
if [ -f ${ml_dir}/${ml_libdir}/Makefile ]; then
if [ x"${MAKE}" = x ]; then
(cd ${ml_dir}/${ml_libdir}; make distclean)
else
(cd ${ml_dir}/${ml_libdir}; ${MAKE} distclean)
fi
fi
ml_newsrcdir="."
ml_srcdiroption=
multisrctop=${dotdot}

237
config.guess vendored
View File

@@ -1,6 +1,6 @@
#! /bin/sh
# Attempt to guess a canonical system name.
# Copyright (C) 1992, 93, 94, 95, 96, 97, 1998, 1999 Free Software Foundation, Inc.
# Copyright (C) 1992, 93, 94, 95, 96, 1997 Free Software Foundation, Inc.
#
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@@ -52,9 +52,6 @@ trap 'rm -f dummy.c dummy.o dummy; exit 1' 1 2 15
case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
alpha:OSF1:*:*)
if test $UNAME_RELEASE = "V4.0"; then
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
fi
# A Vn.n version is a released version.
# A Tn.n version is a released field test version.
# A Xn.n version is an unreleased experimental baselevel.
@@ -65,14 +62,9 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
main:
.frame \$30,0,\$26,0
.prologue 0
.long 0x47e03d80 # implver $0
lda \$2,259
.long 0x47e20c21 # amask $2,$1
srl \$1,8,\$2
sll \$2,2,\$2
sll \$0,3,\$0
addl \$1,\$0,\$0
addl \$2,\$0,\$0
.long 0x47e03d84
cmoveq \$4,0,\$3
addl \$3,\$31,\$0
ret \$31,(\$26),1
.end main
EOF
@@ -80,32 +72,17 @@ EOF
if test "$?" = 0 ; then
./dummy
case "$?" in
7)
UNAME_MACHINE="alpha"
;;
15)
1)
UNAME_MACHINE="alphaev5"
;;
14)
2)
UNAME_MACHINE="alphaev56"
;;
10)
UNAME_MACHINE="alphapca56"
;;
16)
UNAME_MACHINE="alphaev6"
;;
esac
fi
rm -f dummy.s dummy
echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//'`
exit 0 ;;
Alpha\ *:Windows_NT*:*)
# How do we know it's Interix rather than generic posix subsystem?
# Should we change UNAME_MACHINE based on the output of uname
# instead of the specific alpha model.
echo alpha-pc-interix
exit 0;;
21064:Windows_NT:50:3)
echo alpha-dec-winnt3.5
exit 0 ;;
@@ -118,9 +95,6 @@ EOF
amiga:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
*:[Aa]miga[Oo][Ss]:*:*)
echo ${UNAME_MACHINE}-unknown-amigaos
exit 0 ;;
arc64:OpenBSD:*:*)
echo mips64el-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
@@ -159,9 +133,6 @@ EOF
NILE:*:*:dcosx)
echo pyramid-pyramid-svr4
exit 0 ;;
sun4H:SunOS:5.*:*)
echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit 0 ;;
sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit 0 ;;
@@ -186,18 +157,6 @@ EOF
sun3*:SunOS:*:*)
echo m68k-sun-sunos${UNAME_RELEASE}
exit 0 ;;
sun*:*:4.2BSD:*)
UNAME_RELEASE=`(head -1 /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3
case "`/bin/arch`" in
sun3)
echo m68k-sun-sunos${UNAME_RELEASE}
;;
sun4)
echo sparc-sun-sunos${UNAME_RELEASE}
;;
esac
exit 0 ;;
aushp:SunOS:*:*)
echo sparc-auspex-sunos${UNAME_RELEASE}
exit 0 ;;
@@ -366,48 +325,12 @@ EOF
hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*)
echo m68k-hp-bsd4.4
exit 0 ;;
*9??*:MPE/iX:*:*)
echo hppa1.0-hp-mpeix
exit 0 ;;
9000/[34678]??:HP-UX:*:*)
9000/[3478]??:HP-UX:*:*)
case "${UNAME_MACHINE}" in
9000/31? ) HP_ARCH=m68000 ;;
9000/[34]?? ) HP_ARCH=m68k ;;
9000/[678][0-9][0-9] )
sed 's/^ //' << EOF >dummy.c
#include <stdlib.h>
#include <unistd.h>
int main ()
{
#if defined(_SC_KERNEL_BITS)
long bits = sysconf(_SC_KERNEL_BITS);
#endif
long cpu = sysconf (_SC_CPU_VERSION);
switch (cpu)
{
case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
case CPU_PA_RISC2_0:
#if defined(_SC_KERNEL_BITS)
switch (bits)
{
case 64: puts ("hppa2.0w"); break;
case 32: puts ("hppa2.0n"); break;
default: puts ("hppa2.0"); break;
} break;
#else /* !defined(_SC_KERNEL_BITS) */
puts ("hppa2.0"); break;
#endif
default: puts ("hppa1.0"); break;
}
exit (0);
}
EOF
(${CC-cc} dummy.c -o dummy 2>/dev/null ) && HP_ARCH=`./dummy`
rm -f dummy.c dummy
9000/7?? | 9000/8?[1679] ) HP_ARCH=hppa1.1 ;;
9000/8?? ) HP_ARCH=hppa1.0 ;;
esac
HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
echo ${HP_ARCH}-hp-hpux${HPUX_REV}
@@ -464,9 +387,6 @@ EOF
parisc*:Lites*:*:*)
echo hppa1.1-hp-lites
exit 0 ;;
hppa*:OpenBSD:*:*)
echo hppa-unknown-openbsd
exit 0 ;;
C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
echo c1-convex-bsd
exit 0 ;;
@@ -503,7 +423,7 @@ EOF
echo cray2-cray-unicos
exit 0 ;;
F300:UNIX_System_V:*:*)
FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
FUJITSU_SYS=`uname -p | tr [A-Z] [a-z] | sed -e 's/\///'`
FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
echo "f300-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
exit 0 ;;
@@ -520,11 +440,7 @@ EOF
echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
exit 0 ;;
*:FreeBSD:*:*)
if test -x /usr/bin/objformat -a "elf" = "`/usr/bin/objformat`"; then
echo ${UNAME_MACHINE}-unknown-freebsdelf
else
echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*//'`
fi
echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
exit 0 ;;
*:NetBSD:*:*)
echo ${UNAME_MACHINE}-unknown-netbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
@@ -533,20 +449,10 @@ EOF
echo ${UNAME_MACHINE}-unknown-openbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
exit 0 ;;
i*:CYGWIN*:*)
echo ${UNAME_MACHINE}-pc-cygwin32
echo i386-pc-cygwin32
exit 0 ;;
i*:MINGW*:*)
echo ${UNAME_MACHINE}-pc-mingw32
exit 0 ;;
i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
# How do we know it's Interix rather than generic posix subsystem?
# It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
# change UNAME_MACHINE based on the output of uname instead of
# i386?
echo i386-pc-interix
exit 0 ;;
i*:UWIN*:*)
echo ${UNAME_MACHINE}-pc-uwin
echo i386-pc-mingw32
exit 0 ;;
p*:CYGWIN*:*)
echo powerpcle-unknown-cygwin32
@@ -558,13 +464,6 @@ EOF
echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
exit 0 ;;
*:Linux:*:*)
# uname on the ARM produces all sorts of strangeness, and we need to
# filter it out.
case "$UNAME_MACHINE" in
armv*) UNAME_MACHINE=$UNAME_MACHINE ;;
arm* | sa110*) UNAME_MACHINE="arm" ;;
esac
# The BFD linker knows what the default object file format is, so
# first see if it will tell us.
ld_help_string=`ld --help 2>&1`
@@ -578,38 +477,8 @@ EOF
i?86linux) echo "${UNAME_MACHINE}-pc-linux-gnuaout" ; exit 0 ;;
i?86coff) echo "${UNAME_MACHINE}-pc-linux-gnucoff" ; exit 0 ;;
sparclinux) echo "${UNAME_MACHINE}-unknown-linux-gnuaout" ; exit 0 ;;
armlinux) echo "${UNAME_MACHINE}-unknown-linux-gnuaout" ; exit 0 ;;
m68klinux) echo "${UNAME_MACHINE}-unknown-linux-gnuaout" ; exit 0 ;;
elf32ppc | elf32ppclinux)
# Determine Lib Version
cat >dummy.c <<EOF
#include <features.h>
#if defined(__GLIBC__)
extern char __libc_version[];
extern char __libc_release[];
#endif
main(argc, argv)
int argc;
char *argv[];
{
#if defined(__GLIBC__)
printf("%s %s\n", __libc_version, __libc_release);
#else
printf("unkown\n");
#endif
return 0;
}
EOF
LIBC=""
${CC-cc} dummy.c -o dummy 2>/dev/null
if test "$?" = 0 ; then
./dummy | grep 1\.99 > /dev/null
if test "$?" = 0 ; then
LIBC="libc1"
fi
fi
rm -f dummy.c dummy
echo powerpc-unknown-linux-gnu${LIBC} ; exit 0 ;;
elf32ppc) echo "powerpc-unknown-linux-gnu" ; exit 0 ;;
esac
if test "${UNAME_MACHINE}" = "alpha" ; then
@@ -619,47 +488,26 @@ EOF
main:
.frame \$30,0,\$26,0
.prologue 0
.long 0x47e03d80 # implver $0
lda \$2,259
.long 0x47e20c21 # amask $2,$1
srl \$1,8,\$2
sll \$2,2,\$2
sll \$0,3,\$0
addl \$1,\$0,\$0
addl \$2,\$0,\$0
.long 0x47e03d84
cmoveq \$4,0,\$3
addl \$3,\$31,\$0
ret \$31,(\$26),1
.end main
EOF
LIBC=""
${CC-cc} dummy.s -o dummy 2>/dev/null
if test "$?" = 0 ; then
./dummy
case "$?" in
7)
UNAME_MACHINE="alpha"
;;
15)
UNAME_MACHINE="alphaev5"
;;
14)
UNAME_MACHINE="alphaev56"
;;
10)
UNAME_MACHINE="alphapca56"
;;
16)
UNAME_MACHINE="alphaev6"
;;
esac
objdump --private-headers dummy | \
grep ld.so.1 > /dev/null
if test "$?" = 0 ; then
LIBC="libc1"
fi
fi
rm -f dummy.s dummy
echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} ; exit 0
1)
UNAME_MACHINE="alphaev5"
;;
2)
UNAME_MACHINE="alphaev56"
;;
esac
fi
rm -f dummy.s dummy
echo ${UNAME_MACHINE}-unknown-linux-gnu ; exit 0
elif test "${UNAME_MACHINE}" = "mips" ; then
cat >dummy.c <<EOF
main(argc, argv)
@@ -740,18 +588,6 @@ EOF
echo ${UNAME_MACHINE}-pc-sysv${UNAME_RELEASE}
fi
exit 0 ;;
i?86:*:5:7*)
UNAME_REL=`(/bin/uname -X|egrep Release|sed -e 's/.*= //')`
(/bin/uname -X|egrep i80486 >/dev/null) && UNAME_MACHINE=i486
(/bin/uname -X|egrep '^Machine.*Pentium' >/dev/null) \
&& UNAME_MACHINE=i586
# 5.0.4c returns "Pent II". 5.0.5 returns PentII
(/bin/uname -X|egrep '^Machine.*Pent.*II' >/dev/null) \
&& UNAME_MACHINE=i686
(/bin/uname -X|egrep '^Machine.*Pentium Pro' >/dev/null) \
&& UNAME_MACHINE=i686
echo ${UNAME_MACHINE}-${UNAME_SYSTEM}${UNAME_VERSION}-sysv${UNAME_RELEASE}
exit 0 ;;
i?86:*:3.2:*)
if test -f /usr/options/cb.name; then
UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
@@ -761,12 +597,6 @@ EOF
(/bin/uname -X|egrep i80486 >/dev/null) && UNAME_MACHINE=i486
(/bin/uname -X|egrep '^Machine.*Pentium' >/dev/null) \
&& UNAME_MACHINE=i586
(/bin/uname -X|egrep '^Machine.*PentII' >/dev/null) \
&& UNAME_MACHINE=i686
(/bin/uname -X|egrep '^Machine.*Pent II' >/dev/null) \
&& UNAME_MACHINE=i686
(/bin/uname -X|egrep '^Machine.*Pentium Pro' >/dev/null) \
&& UNAME_MACHINE=i686
echo ${UNAME_MACHINE}-pc-sco$UNAME_REL
else
echo ${UNAME_MACHINE}-pc-sysv32
@@ -855,22 +685,13 @@ EOF
news*:NEWS-OS:*:6*)
echo mips-sony-newsos6
exit 0 ;;
R3000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R4000:UNIX_SV:*:*)
R3000:*System_V*:*:* | R4000:UNIX_SYSV:*:*)
if [ -d /usr/nec ]; then
echo mips-nec-sysv${UNAME_RELEASE}
else
echo mips-unknown-sysv${UNAME_RELEASE}
fi
exit 0 ;;
BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
echo powerpc-be-beos
exit 0 ;;
BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only.
echo powerpc-apple-beos
exit 0 ;;
BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
echo i586-pc-beos
exit 0 ;;
esac
#echo '(No uname command or uname output not recognized.)' 1>&2

View File

@@ -1,87 +0,0 @@
#! /dev/null
# Don't call it directly. This shell script fragment is called to
# determine:
#
# 1. libstcxx_interface: the interface name for libstdc++.
# 2. cxx_interface: the interface name for c++.
# 3. libc_interface: the interface name for libc.
#
# Get the top level src dir.
if [ -z "${topsrcdir}" -a -z "${top_srcdir}" ]
then
echo "Undefined top level src dir: topsrcdir and top_srcdir are empty" >&2
exit 1
fi
if [ -n "${topsrcdir}" ]
then
if_topsrcdir=${topsrcdir}
else
if_topsrcdir=${top_srcdir}
fi
if [ -f ${if_topsrcdir}/libstdc++/Makefile.in ]; then
# We check libstdc++ for libstdcxx_interface.
libstdcxx_interface=`grep "^INTERFACE" ${if_topsrcdir}/libstdc++/Makefile.in | sed 's/INTERFACE[ ]*=[ ]*\(.*\)/\1/'`
else
libstdcxx_interface=
fi
if [ -f ${if_topsrcdir}/gcc/cp/Makefile.in ]; then
# We check gcc/cp for cxx_interface.
cxx_interface=`grep "^INTERFACE" ${if_topsrcdir}/gcc/cp/Makefile.in | sed 's/INTERFACE[ ]*=[ ]*\(.*\)/\1/'`
else
cxx_interface=
fi
# The trickiest part is libc_interface.
if [ -z "${libc_interface}" ]
then
case ${target_os} in
*linux*libc1*|*linux*libc5*)
case ${target_alias} in
*alpha*|*powerpc*)
libc_interface=-libc5.9-
;;
*)
libc_interface=-libc5-
;;
esac
;;
*linux*gnu*)
# We have to work harder to figure it out.
if [ ${target_alias} = ${build_alias} ]
then
dummy=if$$
cat >$dummy.c <<EOF
#include <features.h>
main(argc, argv)
int argc;
char *argv[];
{
printf("%d\n", __GLIBC_MINOR__);
return 0;
}
EOF
${CC-cc} $dummy.c -o $dummy 2>/dev/null
if [ "$?" = 0 ]
then
libc_interface=-libc6.`./$dummy`-
rm -f $dummy.c $dummy
else
# It should never happen.
echo "Cannot find the GNU C library minor version number." >&2
rm -f $dummy.c $dummy
exit 1
fi
else
# Cross compiling. Assume glibc 2.1.
libc_interface=-libc6.1-
fi
;;
*)
libc_interface=-
;;
esac
fi

277
config.sub vendored
View File

@@ -1,6 +1,6 @@
#! /bin/sh
# Configuration validation subroutine script, version 1.1.
# Copyright (C) 1991, 92-97, 1998, 1999 Free Software Foundation, Inc.
# Copyright (C) 1991, 92, 93, 94, 95, 96, 1997 Free Software Foundation, Inc.
# This file is (in principle) common to ALL GNU software.
# The presence of a machine in this file suggests that SOME GNU software
# can handle that machine. It does not imply ALL GNU software can.
@@ -98,21 +98,21 @@ case $os in
os=
basic_machine=$1
;;
-sim | -cisco | -oki | -wec | -winbond ) # EGCS LOCAL
-sim | -cisco | -oki | -wec | -winbond ) # CYGNUS LOCAL
os=
basic_machine=$1
;;
-scout) # EGCS LOCAL
-scout) # CYGNUS LOCAL
;;
-wrs) # EGCS LOCAL
os=-vxworks
-wrs) # CYGNUS LOCAL
os=vxworks
basic_machine=$1
;;
-hiux*)
os=-hiuxwe2
;;
-sco5)
os=-sco3.2v5
os=sco3.2v5
basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
;;
-sco4)
@@ -131,9 +131,6 @@ case $os in
os=-sco3.2v2
basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
;;
-udk*)
basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
;;
-isc)
os=-isc2.2
basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
@@ -164,41 +161,36 @@ case $basic_machine in
# Some are omitted here because they have special meanings below.
tahoe | i860 | m32r | m68k | m68000 | m88k | ns32k | arc | arm \
| arme[lb] | pyramid | mn10200 | mn10300 \
| tron | a29k | 580 | i960 | h8300 \
| hppa | hppa1.0 | hppa1.1 | hppa2.0 | hppa2.0w | hppa2.0n \
| alpha | alphaev5 | alphaev56 | alphapca56 | alphaev6 \
| we32k | ns16k | clipper | i370 | sh | powerpc | powerpcle \
| 1750a | dsp16xx | pdp11 \
| tron | a29k | 580 | i960 | h8300 | hppa | hppa1.0 | hppa1.1 \
| alpha | alphaev5 | alphaev56 | we32k | ns16k | clipper \
| i370 | sh | powerpc | powerpcle | 1750a | dsp16xx | pdp11 \
| mips64 | mipsel | mips64el | mips64orion | mips64orionel \
| mipstx39 | mipstx39el \
| sparc | sparclet | sparclite | sparc64 | sparcv9 | v850 | c4x)
| sparc | sparclet | sparclite | sparc64)
basic_machine=$basic_machine-unknown
;;
m88110 | m680[012346]0 | m683?2 | m68360 | m5200 | z8k | v70 \
| h8500 | w65) # EGCS LOCAL
;;
thumb)
m88110 | m680[01234]0 | m683?2 | m68360 | z8k | v70 | h8500 | w65) # CYGNUS LOCAL
basic_machine=$basic_machine-unknown
;;
mips64vr4300 | mips64vr4300el) # EGCS LOCAL jsmith/vr4300
mips64vr4300 | mips64vr4300el) # CYGNUS LOCAL jsmith/vr4300
basic_machine=$basic_machine-unknown
;;
mips64vr4100 | mips64vr4100el) # EGCS LOCAL jsmith/vr4100
mips64vr4100 | mips64vr4100el) # CYGNUS LOCAL jsmith/vr4100
basic_machine=$basic_machine-unknown
;;
mips64vr5000 | mips64vr5000el) # EGCS LOCAL ian/vr5000
mips64vr5000 | mips64vr5000el) # CYGNUS LOCAL ian/vr5000
basic_machine=$basic_machine-unknown
;;
mips16)
mips16) # CYGNUS LOCAL krk/mips16
basic_machine=$basic_machine-unknown
;;
d10v)
d10v) # CYGNUS LOCAL meissner/d10v
basic_machine=$basic_machine-unknown
;;
# We use `pc' rather than `unknown'
# because (1) that's what they normally are, and
# (2) the word "unknown" tends to confuse beginning users.
i[34567]86)
i[3456]86)
basic_machine=$basic_machine-pc
;;
# Object if more than one company name word.
@@ -207,44 +199,30 @@ case $basic_machine in
exit 1
;;
# Recognize the basic CPU types with company name.
vax-* | tahoe-* | i[34567]86-* | i860-* | m32r-* | m68k-* | m68000-* \
vax-* | tahoe-* | i[3456]86-* | i860-* | m32r-* | m68k-* | m68000-* \
| m88k-* | sparc-* | ns32k-* | fx80-* | arc-* | arm-* | c[123]* \
| mips-* | pyramid-* | tron-* | a29k-* | romp-* | rs6000-* \
| power-* | none-* | 580-* | cray2-* | h8300-* | i960-* \
| xmp-* | ymp-* \
| hppa-* | hppa1.0-* | hppa1.1-* \
| hppa2.0-* | hppa2.0w-* | hppa2.0n-* \
| alpha-* | alphaev5-* | alphaev56-* | alphapca56-* \
| alphaev6-* | we32k-* | cydra-* | ns16k-* | pn-* | np1-* \
| xps100-* | clipper-* | orion-* \
| xmp-* | ymp-* | hppa-* | hppa1.0-* | hppa1.1-* \
| alpha-* | alphaev5-* | alphaev56-* | we32k-* | cydra-* \
| ns16k-* | pn-* | np1-* | xps100-* | clipper-* | orion-* \
| sparclite-* | pdp11-* | sh-* | powerpc-* | powerpcle-* \
| sparc64-* | sparcv9-* | sparc86x-* | mips64-* | mipsel-* \
| mips64el-* | mips64orion-* | mips64orionel-* \
| sparc64-* | mips64-* | mipsel-* \
| mips64el-* | mips64orion-* | mips64orionel-* \
| mipstx39-* | mipstx39el-* \
| f301-* | arm*-*)
| f301-*)
;;
m88110-* | m680[01234]0-* | m683?2-* | m68360-* | z8k-* | h8500-* | d10v-*) # EGCS LOCAL
m88110-* | m680[01234]0-* | m683?2-* | m68360-* | z8k-* | h8500-* | d10v-*) # CYGNUS LOCAL
;;
thumb-*) # EGCS LOCAL angela/thumb
mips64vr4300-* | mips64vr4300el-*) # CYGNUS LOCAL jsmith/vr4300
;;
v850-*) # EGCS LOCAL
;;
d30v-*) # EGCS LOCAL
;;
mips64vr4300-* | mips64vr4300el-*) # EGCS LOCAL jsmith/vr4300
mips64vr4100-* | mips64vr4100el-*) # CYGNUS LOCAL jsmith/vr4100
;;
mips64vr4100-* | mips64vr4100el-*) # EGCS LOCAL jsmith/vr4100
;;
mips16-*) # EGCS LOCAL krk/mips16
;;
tic30-*) # EGCS LOCAL ian/tic30
;;
c30-*) # EGCS LOCAL ian/tic30
basic_machine=tic30-unknown
mips16-*) # CYGNUS LOCAL krk/mips16
;;
# Recognize the various machine names and aliases which stand
# for a CPU type and a company and sometimes even an OS.
386bsd) # EGCS LOCAL
386bsd) # CYGNUS LOCAL
basic_machine=i386-unknown
os=-bsd
;;
@@ -254,11 +232,11 @@ case $basic_machine in
3b*)
basic_machine=we32k-att
;;
a29khif) # EGCS LOCAL
a29khif) # CYGNUS LOCAL
basic_machine=a29k-amd
os=-udi
;;
adobe68k) # EGCS LOCAL
adobe68k) # CYGNUS LOCAL
basic_machine=m68010-adobe
os=-scout
;;
@@ -279,9 +257,9 @@ case $basic_machine in
amiga | amiga-*)
basic_machine=m68k-cbm
;;
amigaos | amigados)
amigados)
basic_machine=m68k-cbm
os=-amigaos
os=-amigados
;;
amigaunix | amix)
basic_machine=m68k-cbm
@@ -291,7 +269,7 @@ case $basic_machine in
basic_machine=m68k-apollo
os=-sysv
;;
apollo68bsd) # EGCS LOCAL
apollo68bsd) # CYGNUS LOCAL
basic_machine=m68k-apollo
os=-bsd
;;
@@ -371,7 +349,7 @@ case $basic_machine in
encore | umax | mmax)
basic_machine=ns32k-encore
;;
es1800 | OSE68k | ose68k | ose | OSE) # EGCS LOCAL
es1800 | OSE68k | ose68k | ose | OSE) # CYGNUS LOCAL
basic_machine=m68k-ericsson
os=-ose
;;
@@ -393,11 +371,11 @@ case $basic_machine in
basic_machine=h8300-hitachi
os=-hms
;;
h8300xray) # EGCS LOCAL
h8300xray) # CYGNUS LOCAL
basic_machine=h8300-hitachi
os=-xray
;;
h8500hms) # EGCS LOCAL
h8500hms) # CYGNUS LOCAL
basic_machine=h8500-hitachi
os=-hms
;;
@@ -416,47 +394,29 @@ case $basic_machine in
basic_machine=m68k-hp
os=-hpux
;;
w89k-*) # EGCS LOCAL
w89k-*) # CYGNUS LOCAL
basic_machine=hppa1.1-winbond
os=-proelf
;;
op50n-*) # EGCS LOCAL
op50n-*) # CYGNUS LOCAL
basic_machine=hppa1.1-oki
os=-proelf
;;
op60c-*) # EGCS LOCAL
op60c-*) # CYGNUS LOCAL
basic_machine=hppa1.1-oki
os=-proelf
;;
hppro) # EGCS LOCAL
hppro) # CYGNUS LOCAL
basic_machine=hppa1.1-hp
os=-proelf
;;
hp3k9[0-9][0-9] | hp9[0-9][0-9])
basic_machine=hppa1.0-hp
;;
hp9k2[0-9][0-9] | hp9k31[0-9])
basic_machine=m68000-hp
;;
hp9k3[2-9][0-9])
basic_machine=m68k-hp
;;
hp9k6[0-9][0-9] | hp6[0-9][0-9] )
basic_machine=hppa1.0-hp
;;
hp9k7[0-79][0-9] | hp7[0-79][0-9] )
basic_machine=hppa1.1-hp
;;
hp9k78[0-9] | hp78[0-9] )
# FIXME: really hppa2.0-hp
basic_machine=hppa1.1-hp
;;
hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | \
hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893 )
# FIXME: really hppa2.0-hp
basic_machine=hppa1.1-hp
;;
hp9k8[0-9][13679] | hp8[0-9][13679] )
hp9k7[0-9][0-9] | hp7[0-9][0-9] | hp9k8[0-9]7 | hp8[0-9]7)
basic_machine=hppa1.1-hp
;;
hp9k8[0-9][0-9] | hp8[0-9][0-9])
@@ -465,7 +425,7 @@ case $basic_machine in
hppa-next)
os=-nextstep3
;;
hppaosf) # EGCS LOCAL
hppaosf) # CYGNUS LOCAL
basic_machine=hppa1.1-hp
os=-osf
;;
@@ -474,38 +434,34 @@ case $basic_machine in
os=-mvs
;;
# I'm not sure what "Sysv32" means. Should this be sysv3.2?
i[34567]86v32)
i[3456]86v32)
basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
os=-sysv32
;;
i[34567]86v4*)
i[3456]86v4*)
basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
os=-sysv4
;;
i[34567]86v)
i[3456]86v)
basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
os=-sysv
;;
i[34567]86sol2)
i[3456]86sol2)
basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
os=-solaris2
;;
i386mach) # EGCS LOCAL
i386mach) # CYGNUS LOCAL
basic_machine=i386-mach
os=-mach
;;
i386-vsta | vsta) # EGCS LOCAL
i386-vsta | vsta) # CYGNUS LOCAL
basic_machine=i386-unknown
os=-vsta
;;
i386-go32 | go32) # EGCS LOCAL
i386-go32 | go32) # CYGNUS LOCAL
basic_machine=i386-unknown
os=-go32
;;
i386-mingw32 | mingw32)
basic_machine=i386-unknown
os=-mingw32
;;
iris | iris4d)
basic_machine=mips-sgi
case $os in
@@ -548,11 +504,11 @@ case $basic_machine in
mips3*)
basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown
;;
monitor) # EGCS LOCAL
monitor) # CYGNUS LOCAL
basic_machine=m68k-rom68k
os=-coff
;;
msdos) # EGCS LOCAL
msdos) # CYGNUS LOCAL
basic_machine=i386-unknown
os=-msdos
;;
@@ -561,13 +517,9 @@ case $basic_machine in
os=-sysv4
;;
netbsd386)
basic_machine=i386-unknown # EGCS LOCAL
basic_machine=i386-unknown # CYGNUS LOCAL
os=-netbsd
;;
netwinder)
basic_machine=armv4l-corel
os=-linux
;;
news | news700 | news800 | news900)
basic_machine=m68k-sony
os=-newsos
@@ -580,7 +532,7 @@ case $basic_machine in
basic_machine=mips-sony
os=-newsos
;;
necv70) # EGCS LOCAL
necv70) # CYGNUS LOCAL
basic_machine=v70-nec
os=-sysv
;;
@@ -609,18 +561,18 @@ case $basic_machine in
basic_machine=i960-intel
os=-nindy
;;
mon960) # EGCS LOCAL
mon960) # CYGNUS LOCAL
basic_machine=i960-intel
os=-mon960
;;
np1)
basic_machine=np1-gould
;;
OSE68000 | ose68000) # EGCS LOCAL
OSE68000 | ose68000) # CYGNUS LOCAL
basic_machine=m68000-ericsson
os=-ose
;;
os68k) # EGCS LOCAL
os68k) # CYGNUS LOCAL
basic_machine=m68k-none
os=-os68k
;;
@@ -641,23 +593,25 @@ case $basic_machine in
pc532 | pc532-*)
basic_machine=ns32k-pc532
;;
pentium | p5 | k5 | k6 | nexen)
basic_machine=i586-pc
pentium | p5)
basic_machine=i586-intel
;;
pentiumpro | p6 | 6x86)
basic_machine=i686-pc
pentiumpro | p6)
basic_machine=i686-intel
;;
pentiumii | pentium2)
basic_machine=i786-pc
;;
pentium-* | p5-* | k5-* | k6-* | nexen-*)
pentium-* | p5-*)
basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
pentiumpro-* | p6-* | 6x86-*)
pentiumpro-* | p6-*)
basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
pentiumii-* | pentium2-*)
basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'`
k5)
# We don't have specific support for AMD's K5 yet, so just call it a Pentium
basic_machine=i586-amd
;;
nexen)
# We don't have specific support for Nexgen yet, so just call it a Pentium
basic_machine=i586-nexgen
;;
pn)
basic_machine=pn-gould
@@ -677,7 +631,7 @@ case $basic_machine in
ps2)
basic_machine=i386-ibm
;;
rom68k) # EGCS LOCAL
rom68k) # CYGNUS LOCAL
basic_machine=m68k-rom68k
os=-coff
;;
@@ -687,7 +641,7 @@ case $basic_machine in
rtpc | rtpc-*)
basic_machine=romp-ibm
;;
sa29200) # EGCS LOCAL
sa29200) # CYGNUS LOCAL
basic_machine=a29k-amd
os=-udi
;;
@@ -698,7 +652,7 @@ case $basic_machine in
basic_machine=sh-hitachi
os=-hms
;;
sparclite-wrs) # EGCS LOCAL
sparclite-wrs) # CYGNUS LOCAL
basic_machine=sparclite-wrs
os=-vxworks
;;
@@ -709,10 +663,10 @@ case $basic_machine in
spur)
basic_machine=spur-unknown
;;
st2000) # EGCS LOCAL
st2000) # CYGNUS LOCAL
basic_machine=m68k-tandem
;;
stratus) # EGCS LOCAL
stratus) # CYGNUS LOCAL
basic_machine=i860-stratus
os=-sysv4
;;
@@ -777,7 +731,7 @@ case $basic_machine in
basic_machine=a29k-nyu
os=-sym1
;;
v810 | necv810) # EGCS LOCAL
v810 | necv810) # CYGNUS LOCAL
basic_machine=v810-nec
os=-none
;;
@@ -804,7 +758,7 @@ case $basic_machine in
basic_machine=a29k-wrs
os=-vxworks
;;
w65*) # EGCS LOCAL
w65*) # CYGNUS LOCAL
basic_machine=w65-wdc
os=-none
;;
@@ -815,7 +769,7 @@ case $basic_machine in
xps | xps100)
basic_machine=xps100-honeywell
;;
z8k-*-coff) # EGCS LOCAL
z8k-*-coff) # CYGNUS LOCAL
basic_machine=z8k-unknown
os=-sim
;;
@@ -826,13 +780,13 @@ case $basic_machine in
# Here we handle the default manufacturer of certain CPU types. It is in
# some cases the only manufacturer, in others, it is the most popular.
w89k) # EGCS LOCAL
w89k) # CYGNUS LOCAL
basic_machine=hppa1.1-winbond
;;
op50n) # EGCS LOCAL
op50n) # CYGNUS LOCAL
basic_machine=hppa1.1-oki
;;
op60c) # EGCS LOCAL
op60c) # CYGNUS LOCAL
basic_machine=hppa1.1-oki
;;
mips)
@@ -857,7 +811,7 @@ case $basic_machine in
we32k)
basic_machine=we32k-att
;;
sparc | sparcv9)
sparc)
basic_machine=sparc-sun
;;
cydra)
@@ -869,16 +823,12 @@ case $basic_machine in
orion105)
basic_machine=clipper-highlevel
;;
mac | mpw | mac-mpw) # EGCS LOCAL
mac | mpw | mac-mpw) # CYGNUS LOCAL
basic_machine=m68k-apple
;;
pmac | pmac-mpw) # EGCS LOCAL
pmac | pmac-mpw) # CYGNUS LOCAL
basic_machine=powerpc-apple
;;
c4x*)
basic_machine=c4x-none
os=-coff
;;
*)
echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
exit 1
@@ -911,12 +861,9 @@ case $os in
-solaris)
os=-solaris2
;;
-svr4*)
-unixware* | svr4*)
os=-sysv4
;;
-unixware*)
os=-sysv4.2uw
;;
-gnu/linux*)
os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'`
;;
@@ -927,20 +874,18 @@ case $os in
-gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
| -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\
| -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \
| -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \
| -aos* \
| -amigados* | -msdos* | -newsos* | -unicos* | -aof* | -aos* \
| -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
| -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
| -hiux* | -386bsd* | -netbsd* | -openbsd* | -freebsd* | -riscix* \
| -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
| -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* \
| -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
| -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
| -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
| -mingw32* | -linux-gnu* | -uxpv* | -beos* | -mpeix* | -udk* \
| -interix* | -uwin* )
| -cygwin32* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
| -mingw32* | -linux-gnu* | -uxpv*)
# Remember, each alternative MUST END IN *, to match a version number.
;;
# EGCS LOCAL
# CYGNUS LOCAL
-sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \
| -windows* | -osx | -abug | -netware* | -os9* | -beos* \
| -macos* | -mpw* | -magic* | -mon960* | -lnews* )
@@ -948,7 +893,7 @@ case $os in
-mac*)
os=`echo $os | sed -e 's|mac|macos|'`
;;
# END EGCS LOCAL
# END CYGNUS LOCAL
-linux*)
os=`echo $os | sed -e 's|linux|linux-gnu|'`
;;
@@ -973,7 +918,7 @@ case $os in
-acis*)
os=-aos
;;
-386bsd) # EGCS LOCAL
-386bsd) # CYGNUS LOCAL
os=-bsd
;;
-ctix* | -uts*)
@@ -1007,10 +952,10 @@ case $os in
# This must come after -sysvr4.
-sysv*)
;;
-ose*) # EGCS LOCAL
-ose*) # CYGNUS LOCAL
os=-ose
;;
-es1800*) # EGCS LOCAL
-es1800*) # CYGNUS LOCAL
os=-ose
;;
-xenix)
@@ -1041,9 +986,6 @@ case $basic_machine in
*-acorn)
os=-riscix1.2
;;
arm*-corel)
os=-linux
;;
arm*-semi)
os=-aout
;;
@@ -1065,13 +1007,13 @@ case $basic_machine in
# default.
# os=-sunos4
;;
m68*-cisco) # EGCS LOCAL
m68*-cisco) # CYGNUS LOCAL
os=-aout
;;
mips*-cisco) # EGCS LOCAL
mips*-cisco) # CYGNUS LOCAL
os=-elf
;;
mips*-*) # EGCS LOCAL
mips*-*) # CYGNUS LOCAL
os=-elf
;;
*-tti) # must be before sparc entry or we get the wrong os.
@@ -1080,19 +1022,19 @@ case $basic_machine in
sparc-* | *-sun)
os=-sunos4.1.1
;;
*-be)
*-be) # CYGNUS LOCAL
os=-beos
;;
*-ibm)
os=-aix
;;
*-wec) # EGCS LOCAL
*-wec) # CYGNUS LOCAL
os=-proelf
;;
*-winbond) # EGCS LOCAL
*-winbond) # CYGNUS LOCAL
os=-proelf
;;
*-oki) # EGCS LOCAL
*-oki) # CYGNUS LOCAL
os=-proelf
;;
*-hp)
@@ -1105,7 +1047,7 @@ case $basic_machine in
os=-sysv
;;
*-cbm)
os=-amigaos
os=-amigados
;;
*-dg)
os=-dgux
@@ -1158,13 +1100,13 @@ case $basic_machine in
f301-fujitsu)
os=-uxpv
;;
*-rom68k) # EGCS LOCAL
*-rom68k) # CYGNUS LOCAL
os=-coff
;;
*-*bug) # EGCS LOCAL
*-*bug) # CYGNUS LOCAL
os=-coff
;;
*-apple) # EGCS LOCAL
*-apple) # CYGNUS LOCAL
os=-macos
;;
*)
@@ -1188,15 +1130,12 @@ case $basic_machine in
-aix*)
vendor=ibm
;;
-beos*)
-beos*) # CYGNUS LOCAL
vendor=be
;;
-hpux*)
vendor=hp
;;
-mpeix*)
vendor=hp
;;
-hiux*)
vendor=hitachi
;;
@@ -1224,10 +1163,10 @@ case $basic_machine in
-aux*)
vendor=apple
;;
-hms*) # EGCS LOCAL
-hms*) # CYGNUS LOCAL
vendor=hitachi
;;
-mpw* | -macos*) # EGCS LOCAL
-mpw* | -macos*) # CYGNUS LOCAL
vendor=apple
;;
esac

View File

@@ -1,73 +1,3 @@
Sun Oct 24 23:54:10 PDT 1999 Jeff Law (law@cygnus.com)
* gcc-2.95.2 Released.
Mon Aug 16 01:29:24 PDT 1999 Jeff Law (law@cygnus.com)
* gcc-2.95.1 Released.
Wed Jul 28 21:39:31 PDT 1999 Jeff Law (law@cygnus.com)
* gcc-2.95 Released.
Sun Jul 25 23:40:51 PDT 1999 Jeff Law (law@cygnus.com)
* gcc-2.95 Released.
Tue Feb 2 22:51:21 1999 Philip Blundell <philb@gnu.org>
* mh-armpic: New file. Patch from Jim Pick <jim@jimpick.com>.
* mt-armpic: Likewise.
Mon Jan 18 19:41:08 1999 Christopher Faylor <cgf@cygnus.com>
* cygwin.mh: Activate commented out dependencies for
gdb: libtermcap.
Wed Nov 18 20:29:46 1998 Christopher Faylor <cgf@cygnus.com>
* cygwin.mh: Add extra libtermcap target information.
Add commented out dependency for gdb to libtermcap for
future readline requirement.
Mon Nov 2 15:15:33 1998 Geoffrey Noer <noer@cygnus.com>
* mh-cygwin32: delete
* mh-cygwin: was mh-cygwin32
Mon Aug 31 17:50:53 1998 David Edelsohn <edelsohn@mhpcc.edu>
* mh-aix43 (NM_FOR_TARGET): Add -X32_64 as well.
Sat Aug 29 14:32:55 1998 David Edelsohn <edelsohn@mhpcc.edu>
* mh-aix43: New file.
Mon Aug 10 00:15:47 1998 HJ Lu (hjl@gnu.org)
* mt-linux (CXXFLAGS_FOR_TARGET): Add -D_GNU_SOURCE.
Wed Apr 22 12:24:28 1998 Michael Meissner <meissner@cygnus.com>
* mt-ospace: New file, support using -Os instead of -O2 to compile
the libraries.
Wed Apr 22 10:53:14 1998 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* mt-linux (CXXFLAGS_FOR_TARGET): Set this instead of CXXFLAGS.
Sat Apr 11 22:43:17 1998 J. Kean Johnston <jkj@sco.com>
* mh-svsv5: New file - support for SCO UnixWare 7 / SVR5.
Thu Mar 26 01:54:25 1998 Geoffrey Noer <noer@cygnus.com>
* mh-cygwin32: stop configuring and building dosrel.
Thu Sep 11 16:43:27 1997 Jim Wilson <wilson@cygnus.com>
* mh-elfalphapic, mt-elfalphapic: New files.
Wed Jul 23 12:32:18 1997 Robert Hoehne <robert.hoehne@Mathematik.TU-Chemnitz.DE>
* mh-go32 (CFLAGS): Don't set -fno-omit-frame-pointer.

View File

@@ -1,4 +0,0 @@
# AIX 4.3 and above requires -X32_64 flag to all ar and nm commands
# to handle both 32-bit and 64-bit objects.
AR_FOR_TARGET=ar -X32_64
NM_FOR_TARGET=nm -X32_64

View File

@@ -1 +0,0 @@
PICFLAG=-fPIC

View File

@@ -1,6 +0,0 @@
EXTRA_TARGET_HOST_ALL_MODULES=all-libtermcap
EXTRA_TARGET_HOST_INSTALL_MODULES=install-libtermcap
all-gdb: all-libtermcap
install-gdb: all-libtermcap

16
config/mh-cygwin32 Normal file
View File

@@ -0,0 +1,16 @@
# We don't want debugging info in Win32-hosted toolchains.
# Accomplish this by overriding CFLAGS.
CFLAGS=-O2
CXXFLAGS=-O2
# We also need to override LIBGCC2_DEBUG_CFLAGS so libgcc2 will be
# build without debugging information
LIBGCC2_DEBUG_CFLAGS=
# We set MAKEINFOFLAGS to not split .info files, because the resulting
# file names don't work on DOS.
MAKEINFOFLAGS=--no-split
# custom installation rules for cygwin32 (append .exe to binaries, etc.)
INSTALL_DOSREL=install-dosrel

View File

@@ -1 +0,0 @@
PICFLAG=-fPIC

View File

@@ -1,14 +0,0 @@
# The shell may not be in /bin.
SHELL = sh
RANLIB = true
# We don't want debugging info in Interix-hosted toolchains.
# Accomplish this by overriding CFLAGS. This is also a workaround
# for LD crash when building shared libstdc++.
CFLAGS=-O2
CXXFLAGS=-O2
# We also need to override LIBGCC2_DEBUG_CFLAGS so libgcc2 will be
# built without debugging information
LIBGCC2_DEBUG_CFLAGS=

View File

@@ -1,12 +0,0 @@
# We don't want debugging info in Win32-hosted toolchains.
# Accomplish this by overriding CFLAGS.
CFLAGS=-O2
CXXFLAGS=-O2
# We also need to override LIBGCC2_DEBUG_CFLAGS so libgcc2 will be
# built without debugging information
LIBGCC2_DEBUG_CFLAGS=
# custom installation rules for mingw32 (append .exe to binaries, etc.)
# INSTALL_DOSREL=install-dosrel

View File

@@ -1 +1 @@
PICFLAG=`case "${LIBCFLAGS} ${LIBCXXFLAGS}" in *-fpic* ) echo -fpic ;; * ) echo -fPIC ;; esac`
PICFLAG=-fPIC

View File

@@ -1,8 +0,0 @@
# Define SYSV as -DSYSV if you are using a System V operating system.
SYSV = -DSYSV -DSVR4 -DSVR5
RANLIB = true
# The l flag generates a warning from the SVR4 archiver, remove it.
AR_FLAGS = cr
X11_EXTRA_LIBS = -lnsl

16
config/mh-windows Normal file
View File

@@ -0,0 +1,16 @@
CC=cc
CFLAGS=
RANLIB=true
AR_FLAGS=
.PHONY: windows
windows: nmake.mak
@echo "Don't forget to setup setvars.mak!"
nmake.mak: to-be-built
@echo Building nmake files
@$(srcdir)/gdb/mswin/genmakes
to-be-built:
@echo Recording commands
@$(srcdir)/gdb/mswin/recordit

View File

@@ -1,16 +1,53 @@
Sun Oct 24 23:54:10 PDT 1999 Jeff Law (law@cygnus.com)
Tue Nov 26 12:34:12 1996 Stan Shebs <shebs@andros.cygnus.com>
* gcc-2.95.2 Released.
* g-mpw-make.sed: Fix some comments.
Mon Aug 16 01:29:24 PDT 1999 Jeff Law (law@cygnus.com)
Mon Sep 16 14:42:52 1996 Stan Shebs <shebs@andros.cygnus.com>
* gcc-2.95.1 Released.
* g-mpw-make.sed (HLDENV): Edit out all references.
Wed Jul 28 21:39:31 PDT 1999 Jeff Law (law@cygnus.com)
Thu Aug 15 19:49:23 1996 Stan Shebs <shebs@andros.cygnus.com>
* gcc-2.95 Released.
* true: New script, identical to mpw-true.
* g-mpw-make.sed: Add @DASH_C_FLAG@ and @SEGMENT_FLAG()@
to the editors for compile commands.
Sun Jul 25 23:40:51 PDT 1999 Jeff Law (law@cygnus.com)
Thu Aug 1 15:01:42 1996 Stan Shebs <shebs@andros.cygnus.com>
* gcc-2.95 Released.
* mpw-true, mpw-touch, null-command: New scripts.
* README: Describe usage in more detail.
Tue Dec 12 14:51:51 1995 Stan Shebs <shebs@andros.cygnus.com>
* g-mpw-make.sed: Don't edit out "version=" occurrences.
Fri Dec 1 11:46:18 1995 Stan Shebs <shebs@andros.cygnus.com>
* g-mpw-make.sed (bindir, libdir): Edit the positions of
pathname separators to work with other pathnames better.
Tue Nov 7 15:08:07 1995 Stan Shebs <shebs@andros.cygnus.com>
* g-mpw-make.sed: Add comment about Duplicate vs Catenate,
add additional pattern for editing link-compile commands.
Tue Oct 24 14:28:51 1995 Stan Shebs <shebs@andros.cygnus.com>
* g-mpw-make.sed: Add handling for *.tab.[hc] files.
(CHILL_FOR_TARGET, CHILL_LIB): Edit out tricky definitions
of these.
Thu Sep 28 21:05:10 1995 Stan Shebs <shebs@andros.cygnus.com>
* g-mpw-make.sed: New file, generic sed commands to translate
Unix makefiles into MPW makefile syntax.
Fri Mar 17 11:51:20 1995 Stan Shebs <shebs@andros.cygnus.com>
* README: Clarify instructions.
* fi: Remove.
Wed Dec 21 15:45:53 1994 Stan Shebs <shebs@andros.cygnus.com>
* MoveIfChange, README, fi, forward-include, open-brace,
tr-7to8-src: New files.

View File

@@ -1 +0,0 @@
PICFLAG_FOR_TARGET=-fPIC

View File

@@ -1 +0,0 @@
PICFLAG_FOR_TARGET=-fPIC

View File

@@ -1,2 +0,0 @@
# When using glibc 2 on Linux we must always use vtable thunks.
CXXFLAGS_FOR_TARGET = $(CXXFLAGS) -fvtable-thunks -D_GNU_SOURCE

View File

@@ -1,3 +0,0 @@
# Build libraries optimizing for space, not speed.
CFLAGS_FOR_TARGET = -g -Os
CXXFLAGS_FOR_TARGET = -g -Os

View File

@@ -1 +1 @@
PICFLAG_FOR_TARGET=`case "${LIBCFLAGS} ${LIBCXXFLAGS}" in *-fpic* ) echo -fpic ;; * ) echo -fPIC ;; esac`
PICFLAG_FOR_TARGET=-fPIC

328
configure vendored
View File

@@ -51,22 +51,17 @@ build_alias=
cache_file=config.cache
cache_file_option=
configdirs=
extraconfigdirs=
diroptions=
exec_prefix=
exec_prefixoption=
fatal=
floating_point=default
gas=default
gcc_version=
gcc_version_trigger=
host_alias=NOHOST
host_makefile_frag=
moveifchange=
norecursion=
other_options=
package_makefile_frag=
package_makefile_rules_frag=
prefix=/usr/local
progname=
program_prefix=
@@ -75,7 +70,7 @@ program_suffix=
program_suffixoption=
program_transform_name=
program_transform_nameoption=
redirect=
redirect=">/dev/null"
removing=
site=
site_makefile_frag=
@@ -86,20 +81,8 @@ subdirs=
target_alias=NOTARGET
target_makefile_frag=
undefs=NOUNDEFS
version="$Revision: 1.22 $"
version="$Revision: 1.244 $"
x11=default
bindir='${exec_prefix}/bin'
sbindir='${exec_prefix}/sbin'
libexecdir='${exec_prefix}/libexec'
datadir='${prefix}/share'
sysconfdir='${prefix}/etc'
sharedstatedir='${prefix}/com'
localstatedir='${prefix}/var'
libdir='${exec_prefix}/lib'
includedir='${prefix}/include'
oldincludedir='/usr/include'
infodir='${prefix}/info'
mandir='${prefix}/man'
### we might need to use some other shell than /bin/sh for running subshells
@@ -206,10 +189,6 @@ do
# Now, process the options
case $option in
--bi*)
bindir=$optarg
diroptions="$diroptions --bindir=$optarg"
;;
--build* | --bu*)
case "$build_alias" in
"") build_alias=$optarg ;;
@@ -221,10 +200,6 @@ do
--cache*)
cache_file=$optarg
;;
--da*)
datadir=$optarg
diroptions="$diroptions --datadir=$optarg"
;;
--disable-*)
enableopt=`echo ${option} | sed 's:^--disable-:enable_:;s:-:_:g'`
eval $enableopt=no
@@ -258,30 +233,6 @@ do
;;
esac
;;
--inc*)
includedir=$optarg
diroptions="$diroptions --includedir=$optarg"
;;
--inf*)
infodir=$optarg
diroptions="$diroptions --infodir=$optarg"
;;
--libd*)
libdir=$optarg
diroptions="$diroptions --libdir=$optarg"
;;
--libe*)
libexecdir=$optarg
diroptions="$diroptions --libexecdir=$optarg"
;;
--lo*)
localstatedir=$optarg
diroptions="$diroptions --localstatedir=$optarg"
;;
--ma*)
mandir=$optarg
diroptions="$diroptions --mandir=$optarg"
;;
--nfp | --nf*)
floating_point=no
floating_pointoption="--nfp"
@@ -289,10 +240,6 @@ do
--norecursion | --no*)
norecursion=yes
;;
--ol*)
oldincludedir=$optarg
diroptions="$diroptions --oldincludedir=$optarg"
;;
--prefix* | --pre*)
prefix=$optarg
prefixoption="--prefix=$optarg"
@@ -313,14 +260,6 @@ do
--rm)
removing=--rm
;;
--sb*)
sbindir=$optarg
diroptions="$diroptions --sbindir=$optarg"
;;
--sh*)
sharedstatedir=$optarg
diroptions="$diroptions --sharedstatedir=$optarg"
;;
--silent | --sil* | --quiet | --q*)
redirect=">/dev/null"
verbose=--silent
@@ -339,10 +278,6 @@ do
--srcdir* | --sr*)
srcdir=$optarg
;;
--sy*)
sysconfdir=$optarg
diroptions="$diroptions --sysconfdir=$optarg"
;;
--target* | --ta*)
case $target_alias in
NOTARGET) target_alias=$optarg ;;
@@ -383,6 +318,9 @@ do
;;
--x-i* | --x-l*) other_options="$other_options $orig_option"
;;
--bi* | --sb* | --li* | --da* | --sy* | --sh* | --lo* | --in* | --ol* | --ma*)
# These options were added to autoconf for emacs.
;;
--*)
echo "configure: Unrecognized option: \"$orig_option\"; use --help for usage." >&2
exit 1
@@ -518,8 +456,6 @@ fi
configsub=`echo ${progname} | sed 's/configure$/config.sub/'`
moveifchange=`echo ${progname} | sed 's/configure$/move-if-change/'`
topsrcdir=`cd \`dirname ${progname}\`; pwd`
# this is a hack. sun4 must always be a valid host alias or this will fail.
if ${config_shell} ${configsub} sun4 >/dev/null 2>&1 ; then
@@ -582,28 +518,6 @@ case "${exec_prefixoption}" in
*) ;;
esac
# Define the trigger file to make sure configure will re-run whenever
# the gcc version number changes.
if [ "${with_gcc_version_trigger+set}" = set ]; then
gcc_version_trigger="$with_gcc_version_trigger"
gcc_version=`sed -e 's/.*\"\([^ \"]*\)[ \"].*/\1/' < ${with_gcc_version_trigger}`
else
# If gcc's sources are available, define the trigger file.
if [ -f ${topsrcdir}/gcc/version.c ] ; then
gcc_version_trigger=${topsrcdir}/gcc/version.c
gcc_version=`sed -e 's/.*\"\([^ \"]*\)[ \"].*/\1/' < ${gcc_version_trigger}`
case "$arguments" in
*--with-gcc-version-trigger=$gcc_version_trigger* )
;;
* )
# Make sure configure.in knows about this.
arguments="--with-gcc-version-trigger=$gcc_version_trigger $arguments"
;;
esac
withoptions="--with-gcc-version-trigger=$gcc_version_trigger $withoptions"
fi
fi
### break up ${srcdir}/configure.in.
case "`grep '^# per\-host:' ${srcdir}/configure.in`" in
"")
@@ -626,7 +540,7 @@ case "`grep '^# per\-host:' ${srcdir}/configure.in`" in
eval exec ${config_shell} ${srcdir}/configure ${verbose} \
${buildopt} --host=${host_alias} --target=${target_alias} \
${prefixoption} ${tmpdiroption} ${exec_prefixoption} \
${srcdiroption} ${diroptions} \
${srcdiroption} \
${program_prefixoption} ${program_suffixoption} \
${program_transform_nameoption} ${site_option} \
${withoptions} ${withoutoptions} \
@@ -677,24 +591,8 @@ fi
### do common part of configure.in
# If the language specific compiler does not exist, but the "gcc" directory does,
# we will skip this directory; in this case the sub-directory's common part
# of configure.in will create a small shell script "skip-this-dir" containing
# commands to completely clean up any temporary or created files.
. ${tmpfile}.com
if test -f skip-this-dir; then
# Perform the same cleanup as the trap handler, minus the "exit 1" of course,
# and reset the trap handler.
trap 0
rm -f Makefile* ${tmpfile}.com ${tmpfile}.tgt ${tmpfile}.hst ${tmpfile}.pos
# Execute the final clean-up actions
${config_shell} skip-this-dir
# and stop configuring this directory.
exit 0
fi
# some sanity checks on configure.in
case "${srctrigger}" in
"")
@@ -804,7 +702,7 @@ fi
# If CC and CXX are not set in the environment, and the Makefile
# exists, try to extract them from it. This is to handle running
# ./config.status by hand.
if [ -z "${CC}" ] && [ -r Makefile ]; then
if [ -z "${CC}" -a -r Makefile ]; then
sed -n -e ':loop
/\\$/ N
s/\\\n//g
@@ -814,7 +712,7 @@ t loop
rm -f Makefile.cc
fi
if [ -z "${CFLAGS}" ] && [ -r Makefile ]; then
if [ -z "${CFLAGS}" -a -r Makefile ]; then
sed -n -e ':loop
/\\$/ N
s/\\\n//g
@@ -824,7 +722,7 @@ t loop
rm -f Makefile.cc
fi
if [ -z "${CXX}" ] && [ -r Makefile ]; then
if [ -z "${CXX}" -a -r Makefile ]; then
sed -n -e ':loop
/\\$/ N
s/\\\n//g
@@ -834,7 +732,7 @@ t loop
rm -f Makefile.cc
fi
if [ -z "${CXXFLAGS}" ] && [ -r Makefile ]; then
if [ -z "${CXXFLAGS}" -a -r Makefile ]; then
sed -n -e ':loop
/\\$/ N
s/\\\n//g
@@ -863,25 +761,6 @@ do
test -n "$DEFAULT_YACC" && break
done
# Generate a default definition for M4. This is used if the makefile can't
# locate m4 in objdir.
for prog in gm4 gnum4 m4
do
set dummy $prog; tmp=$2
IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
for dir in $PATH; do
test -z "$dir" && dir=.
if test -f $dir/$tmp; then
DEFAULT_M4="$prog"
break
fi
done
IFS="$save_ifs"
test -n "$DEFAULT_M4" && break
done
# Generate a default definition for LEX. This is used if the makefile can't
# locate flex in objdir.
@@ -913,7 +792,7 @@ if [ "${build}" != "${host}" ]; then
tools="${tools} WINDRES WINDRES_FOR_TARGET YACC"
for var in ${tools}; do
if [ -z "`eval 'echo $'"${var}"`" ] && [ -r Makefile ]; then
if [ -z "`eval 'echo $'"${var}"`" -a -r Makefile ]; then
sed -n -e ':loop
/\\$/ N
s/\\\n//g
@@ -1015,10 +894,10 @@ else
echo 'void f(){}' > conftest.c
if test -z "`${CC} -g -c conftest.c 2>&1`"; then
CFLAGS=${CFLAGS-"-g -O2"}
CXXFLAGS=${CXXFLAGS-"-g -O2"}
CXXFLAGS=${CFLAGS-"-g -O2"}
else
CFLAGS=${CFLAGS-"-O2"}
CXXFLAGS=${CXXFLAGS-"-O2"}
CXXFLAGS=${CFLAGS-"-O2"}
fi
rm -f conftest*
break
@@ -1026,24 +905,6 @@ else
done
IFS="$save_ifs"
CC=${CC-cc}
else
if test -z "${CFLAGS}"; then
# Here CC is set but CFLAGS is not. Use a quick hack to use -O2 if CC
# is set to a version of gcc.
case "${CC}" in
*gcc)
echo 'void f(){}' > conftest.c
if test -z "`${CC} -g -c conftest.c 2>&1`"; then
CFLAGS=${CFLAGS-"-g -O2"}
CXXFLAGS=${CXXFLAGS-"-g -O2"}
else
CFLAGS=${CFLAGS-"-O2"}
CXXFLAGS=${CXXFLAGS-"-O2"}
fi
rm -f conftest*
;;
esac
fi
fi
CXX=${CXX-"c++"}
@@ -1131,34 +992,27 @@ for subdir in . ${subdirs} ; do
set ${links}; link=$1; shift; links=$*
if [ ! -r ${srcdir}/${file} ] ; then
if [ ! -r ${file} ] ; then
echo '***' "${progname}: cannot create a link \"${link}\"," 1>&2
echo '***' "since the file \"${srcdir}/${file}\" does not exist." 1>&2
exit 1
else
srcfile=${file}
fi
else
srcfile=${srcdir}/${file}
fi
${remove} -f ${link}
# Make a symlink if possible, otherwise try a hard link
if ${symbolic_link} ${srcfile} ${link} >/dev/null 2>&1 ; then
if ${symbolic_link} ${srcdir}/${file} ${link} >/dev/null 2>&1 ; then
true
else
# We need to re-remove the file because Lynx leaves a
# very strange directory there when it fails an NFS symlink.
${remove} -r -f ${link}
${hard_link} ${srcfile} ${link}
${hard_link} ${srcdir}/${file} ${link}
fi
if [ ! -r ${link} ] ; then
echo '***' "${progname}: unable to link \"${link}\" to \"${srcfile}\"." 1>&2
echo '***' "${progname}: unable to link \"${link}\" to \"${srcdir}/${file}\"." 1>&2
exit 1
fi
echo "Linked \"${link}\" to \"${srcfile}\"."
echo "Linked \"${link}\" to \"${srcdir}/${file}\"."
done
# Create a .gdbinit file which runs the one in srcdir
@@ -1184,101 +1038,88 @@ EOF
# been somewhat optimized and is perhaps a bit twisty.
# code is order so as to try to sed the smallest input files we know.
# so do these separately because I don't trust the order of sed -e expressions.
# the five makefile fragments MUST end up in the resulting Makefile in this order:
# package macros, target, host, site, and package rules.
# the four makefile fragments MUST end up in the resulting Makefile in this order:
# package, target, host, and site. so do these separately because I don't trust the
# order of sed -e expressions.
if [ -f ${srcdir}/${subdir}/${Makefile_in} ] ; then
# Conditionalize the makefile for this package from "Makefile.in" (or whatever it's called) into Makefile.tem.
rm -f ${subdir}/${Makefile}.tem
case "${package_makefile_rules_frag}" in
"") cp ${srcdir}/${subdir}/${Makefile_in} ${subdir}/Makefile.tem ;;
*)
if [ ! -f ${package_makefile_rules_frag} ] ; then
package_makefile_rules_frag=${srcdir}/${package_makefile_rules_frag}
fi
if [ -f ${package_makefile_rules_frag} ] ; then
sed -e "/^####/ r ${package_makefile_rules_frag}" ${srcdir}/${subdir}/${Makefile_in} > ${Makefile}.tem
else
echo '***' Expected package makefile rules fragment \"${package_makefile_rules_frag}\" 1>&2
echo '***' is missing in ${PWD=`pwd`}. 1>&2
cp ${srcdir}/${subdir}/${Makefile_in} ${subdir}/Makefile.tem
fi
esac
# working copy now in ${Makefile}.tem
# Conditionalize for this site.
rm -f ${Makefile}
# Conditionalize for this site from "Makefile.in" (or whatever it's called) into Makefile.tem
rm -f ${subdir}/Makefile.tem
case "${site}" in
"") mv ${subdir}/Makefile.tem ${Makefile} ;;
"") cp ${srcdir}/${subdir}/${Makefile_in} ${subdir}/Makefile.tem ;;
*)
site_makefile_frag=${srcdir}/config/ms-${site}
if [ -f ${site_makefile_frag} ] ; then
sed -e "/^####/ r ${site_makefile_frag}" ${subdir}/Makefile.tem \
> ${Makefile}
sed -e "/^####/ r ${site_makefile_frag}" ${srcdir}/${subdir}/${Makefile_in} \
> ${subdir}/Makefile.tem
else
mv ${subdir}/Makefile.tem ${Makefile}
cp ${srcdir}/${subdir}/${Makefile_in} ${subdir}/Makefile.tem
site_makefile_frag=
fi
;;
esac
# working copy now in ${Makefile}
# working copy now in ${subdir}/Makefile.tem
# Conditionalize the makefile for this host.
rm -f ${subdir}/Makefile.tem
rm -f ${Makefile}
case "${host_makefile_frag}" in
"") mv ${Makefile} ${subdir}/Makefile.tem ;;
"") mv ${subdir}/Makefile.tem ${Makefile} ;;
*)
if [ ! -f ${host_makefile_frag} ] ; then
host_makefile_frag=${srcdir}/${host_makefile_frag}
fi
if [ -f ${host_makefile_frag} ] ; then
sed -e "/^####/ r ${host_makefile_frag}" ${Makefile} > ${subdir}/Makefile.tem
sed -e "/^####/ r ${host_makefile_frag}" ${subdir}/Makefile.tem > ${Makefile}
else
echo '***' Expected host makefile fragment \"${host_makefile_frag}\" 1>&2
echo '***' is missing in ${PWD=`pwd`}. 1>&2
mv ${Makefile} ${subdir}/Makefile.tem
mv ${subdir}/Makefile.tem ${Makefile}
fi
esac
# working copy now in ${subdir)/Makefile.tem
# working copy now in ${Makefile}
# Conditionalize the makefile for this target.
rm -f ${Makefile}
rm -f ${subdir}/Makefile.tem
case "${target_makefile_frag}" in
"") mv ${subdir}/Makefile.tem ${Makefile} ;;
"") mv ${Makefile} ${subdir}/Makefile.tem ;;
*)
if [ ! -f ${target_makefile_frag} ] ; then
target_makefile_frag=${srcdir}/${target_makefile_frag}
fi
if [ -f ${target_makefile_frag} ] ; then
sed -e "/^####/ r ${target_makefile_frag}" ${subdir}/Makefile.tem > ${Makefile}
sed -e "/^####/ r ${target_makefile_frag}" ${Makefile} > ${subdir}/Makefile.tem
else
mv ${subdir}/Makefile.tem ${Makefile}
mv ${Makefile} ${subdir}/Makefile.tem
target_makefile_frag=
fi
;;
esac
# working copy now in ${Makefile}
# real copy now in ${subdir}/Makefile.tem
# Emit the default values of this package's macros.
rm -f ${subdir}/Makefile.tem
# Conditionalize the makefile for this package.
rm -f ${Makefile}
case "${package_makefile_frag}" in
"") mv ${Makefile} ${subdir}/Makefile.tem ;;
"") mv ${subdir}/Makefile.tem ${Makefile} ;;
*)
if [ ! -f ${package_makefile_frag} ] ; then
package_makefile_frag=${srcdir}/${package_makefile_frag}
fi
if [ -f ${package_makefile_frag} ] ; then
sed -e "/^####/ r ${package_makefile_frag}" ${Makefile} > ${subdir}/Makefile.tem
sed -e "/^####/ r ${package_makefile_frag}" ${subdir}/Makefile.tem > ${Makefile}
rm -f ${subdir}/Makefile.tem
else
echo '***' Expected package makefile fragment \"${package_makefile_rules_frag}\" 1>&2
echo '***' Expected package makefile fragment \"${package_makefile_frag}\" 1>&2
echo '***' is missing in ${PWD=`pwd`}. 1>&2
mv ${Makefile} ${subdir}/Makefile.tem
mv ${subdir}/Makefile.tem ${Makefile}
fi
esac
# working copy now in ${Makefile}
mv ${Makefile} ${subdir}/Makefile.tem
# real copy now in ${subdir}/Makefile.tem
# prepend warning about editting, and a bunch of variables.
@@ -1331,25 +1172,6 @@ EOF
echo site_makefile_frag = ${invsubdir}${site_makefile_frag} >>${Makefile}
fi
# record if we want to build shared libs.
if test -z "${enable_shared}"; then
echo enable_shared = no >> ${Makefile}
else
echo enable_shared = ${enable_shared} >> ${Makefile}
fi
# record if we want to rumtime library stuff installed in libsubdir.
if test -z "${enable_version_specific_runtime_libs}"; then
echo enable_version_specific_runtime_libs = no >> ${Makefile}
else
echo enable_version_specific_runtime_libs = ${enable_version_specific_runtime_libs} >> ${Makefile}
fi
# Emit a macro which describes the file containing gcc's
# version number.
echo gcc_version_trigger = ${gcc_version_trigger} >> ${Makefile}
# And emit a macro defining gcc's version number.
echo gcc_version = ${gcc_version} >> ${Makefile}
# reset prefix, exec_prefix, srcdir, SUBDIRS, NONSUBDIRS,
# remove any form feeds.
if [ -z "${subdirs}" ]; then
@@ -1362,18 +1184,6 @@ EOF
fi
sed -e "s|^prefix[ ]*=.*$|prefix = ${prefix}|" \
-e "s|^exec_prefix[ ]*=.*$|exec_prefix = ${exec_prefix}|" \
-e "s|^bindir[ ]*=.*$|bindir = ${bindir}|" \
-e "s|^sbindir[ ]*=.*$|sbindir = ${sbindir}|" \
-e "s|^libexecdir[ ]*=.*$|libexecdir = ${libexecdir}|" \
-e "s|^datadir[ ]*=.*$|datadir = ${datadir}|" \
-e "s|^sysconfdir[ ]*=.*$|sysconfdir = ${sysconfdir}|" \
-e "s|^sharedstatedir[ ]*=.*$|sharedstatedir = ${sharedstatedir}|" \
-e "s|^localstatedir[ ]*=.*$|localstatedir = ${localstatedir}|" \
-e "s|^libdir[ ]*=.*$|libdir = ${libdir}|" \
-e "s|^includedir[ ]*=.*$|includedir = ${includedir}|" \
-e "s|^oldincludedir[ ]*=.*$|oldincludedir = ${oldincludedir}|" \
-e "s|^infodir[ ]*=.*$|infodir = ${infodir}|" \
-e "s|^mandir[ ]*=.*$|mandir = ${mandir}|" \
-e "/^CC[ ]*=/{
:loop1
/\\\\$/ N
@@ -1410,10 +1220,8 @@ EOF
-e "s:^program_suffix[ ]*=.*$:program_suffix = ${program_suffix}:" \
-e "s:^program_transform_name[ ]*=.*$:program_transform_name = ${program_transform_name}:" \
-e "s|^tooldir[ ]*=.*$|tooldir = ${tooldir}|" \
-e "s|^build_tooldir[ ]*=.*$|build_tooldir = ${tooldir}|" \
-e "s:^DEFAULT_YACC[ ]*=.*$:DEFAULT_YACC = ${DEFAULT_YACC}:" \
-e "s:^DEFAULT_LEX[ ]*=.*$:DEFAULT_LEX = ${DEFAULT_LEX}:" \
-e "s:^DEFAULT_M4[ ]*=.*$:DEFAULT_M4 = ${DEFAULT_M4}:" \
${subdir}/Makefile.tem >> ${Makefile}
# If this is a Canadian Cross, preset the values of many more
@@ -1497,33 +1305,19 @@ ${progname}" ${arguments} "
done
# If there are subdirectories, then recur.
if [ -z "${norecursion}" ] && [ -n "${configdirs}" ] ; then
for configdir in ${configdirs} ${extraconfigdirs} ; do
if [ -z "${norecursion}" -a -n "${configdirs}" ] ; then
for configdir in ${configdirs} ; do
# If configdir contains ',' it is
# srcdir,builddir,target_alias
# These come from extraconfigdirs.
case ${configdir} in
*,*)
eval `echo ${configdir} | sed -e 's/\([^,]*\),\([^,]*\),\(.*\)/cfg_dir=\1 bld_dir=\2 tgt_alias=\3/'`
;;
*)
cfg_dir=${configdir}
bld_dir=${configdir}
tgt_alias=${target_alias}
;;
esac
if [ -d ${srcdir}/${cfg_dir} ] ; then
if [ -d ${srcdir}/${configdir} ] ; then
eval echo Configuring ${configdir}... ${redirect}
case "${srcdir}" in
".") ;;
*)
if [ ! -d ./${bld_dir} ] ; then
if mkdir ./${bld_dir} ; then
if [ ! -d ./${configdir} ] ; then
if mkdir ./${configdir} ; then
true
else
echo '***' "${progname}: could not make ${PWD=`pwd`}/${bld_dir}" 1>&2
echo '***' "${progname}: could not make ${PWD=`pwd`}/${configdir}" 1>&2
exit 1
fi
fi
@@ -1531,21 +1325,21 @@ if [ -z "${norecursion}" ] && [ -n "${configdirs}" ] ; then
esac
POPDIR=${PWD=`pwd`}
cd ${bld_dir}
cd ${configdir}
### figure out what to do with srcdir
case "${srcdir}" in
".") newsrcdir=${srcdir} ;; # no -srcdir option. We're building in place.
/*) # absolute path
newsrcdir=${srcdir}/${cfg_dir}
newsrcdir=${srcdir}/${configdir}
srcdiroption="--srcdir=${newsrcdir}"
;;
?:*) # absolute path on win32
newsrcdir=${srcdir}/${cfg_dir}
newsrcdir=${srcdir}/${configdir}
srcdiroption="--srcdir=${newsrcdir}"
;;
*) # otherwise relative
newsrcdir=../${srcdir}/${cfg_dir}
newsrcdir=../${srcdir}/${configdir}
srcdiroption="--srcdir=${newsrcdir}"
;;
esac
@@ -1575,15 +1369,15 @@ if [ -z "${norecursion}" ] && [ -n "${configdirs}" ] ; then
*) recprog=../${progname} ;;
esac
else
eval echo No configuration information in ${cfg_dir} ${redirect}
eval echo No configuration information in ${configdir} ${redirect}
recprog=
fi
### The recursion line is here.
if [ ! -z "${recprog}" ] ; then
if eval ${config_shell} ${recprog} ${verbose} ${buildopt} --host=${host_alias} --target=${tgt_alias} \
if eval ${config_shell} ${recprog} ${verbose} ${buildopt} --host=${host_alias} --target=${target_alias} \
${prefixoption} ${tmpdiroption} ${exec_prefixoption} \
${srcdiroption} ${diroptions} ${program_prefixoption} ${program_suffixoption} ${program_transform_nameoption} ${site_option} ${withoptions} ${withoutoptions} ${enableoptions} ${disableoptions} ${floating_pointoption} ${cache_file_option} ${removing} ${other_options} ${redirect} ; then
${srcdiroption} ${program_prefixoption} ${program_suffixoption} ${program_transform_nameoption} ${site_option} ${withoptions} ${withoutoptions} ${enableoptions} ${disableoptions} ${floating_pointoption} ${cache_file_option} ${removing} ${other_options} ${redirect} ; then
true
else
echo Configure in `pwd` failed, exiting. 1>&2

View File

@@ -14,7 +14,7 @@
## For more information on these two systems, check out the documentation
## for 'Autoconf' (autoconf.texi) and 'Configure' (configure.texi).
# Copyright (C) 1992, 93, 94, 95, 96, 97, 1998, 1999 Free Software Foundation, Inc.
# Copyright (C) 1992, 93, 94, 95, 96, 1997 Free Software Foundation, Inc.
#
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@@ -41,7 +41,7 @@
# these libraries are used by various programs built for the host environment
#
host_libs="intl mmalloc libiberty opcodes bfd readline gash db tcl tk tclX itcl tix libgui"
host_libs="mmalloc libiberty opcodes bfd readline gash db tcl tk tclX itcl tix"
if [ "${enable_gdbgui}" = "yes" ] ; then
host_libs="${host_libs} libgui"
@@ -50,26 +50,13 @@ fi
# these tools are built for the host environment
# Note, the powerpc-eabi build depends on sim occurring before gdb in order to
# know that we are building the simulator.
host_tools="texinfo byacc flex bison binutils ld gas gcc sim gdb make patch prms send-pr gprof gdbtest tgas etc expect dejagnu ash bash bzip2 m4 autoconf automake libtool ispell grep diff rcs cvssrc fileutils shellutils time textutils wdiff find emacs emacs19 uudecode hello tar gzip indent recode release sed utils guile perl apache inet gawk findutils snavigator libtool gettext zip"
host_tools="texinfo byacc flex bison binutils ld gas gcc sim gdb make patch prms send-pr gprof gdbtest tgas etc expect dejagnu bash m4 autoconf automake ispell grep diff rcs cvs fileutils shellutils time textutils wdiff find emacs emacs19 uudecode hello tar gzip indent recode release sed utils guile perl apache inet gawk findutils sn"
# these libraries are built for the target environment, and are built after
# the host libraries and the host tools (which may be a cross compiler)
#
target_libs="target-libiberty \
target-libgloss \
target-newlib \
target-libio \
target-librx \
target-libstdc++ \
target-libg++ \
target-libf2c \
target-libchill \
target-libjava \
target-zlib \
target-boehm-gc \
target-qthreads \
target-libobjc"
target_libs="target-libiberty target-libgloss target-newlib target-libio target-librx target-libstdc++ target-libg++"
# these tools are built using the target libs, and are intended to run only
# in the target environment
@@ -92,11 +79,11 @@ target_tools="target-examples target-groff target-gperf"
#
# This must be a single line because of the way it is searched by grep in
# the code below.
native_only="autoconf automake libtool cvssrc emacs emacs19 fileutils find gawk gettext grep gzip hello indent ispell m4 rcs recode sed shellutils tar textutils gash uudecode wdiff gprof target-groff guile perl apache inet time ash bash bzip2 prms snavigator gnuserv target-gperf"
native_only="autoconf automake cvs emacs emacs19 fileutils find gawk grep gzip hello indent ispell m4 rcs recode sed shellutils tar textutils gash uudecode wdiff gprof target-groff guile perl apache inet time bash prms sn gnuserv target-gperf"
# directories to be built in a cross environment only
#
cross_only="target-libgloss target-newlib target-cygmon target-opcodes target-libstub"
cross_only="target-libgloss target-newlib"
## All tools belong in one of the four categories, and are assigned above
## We assign ${configdirs} this way to remove all embedded newlines. This
@@ -120,132 +107,48 @@ appdirs=""
# Work in distributions that contain no compiler tools, like Autoconf.
if [ -d ${srcdir}/config ]; then
case "${host}" in
m68k-hp-hpux*)
host_makefile_frag="${host_makefile_frag} config/mh-hp300"
;;
m68k-apollo-sysv*)
host_makefile_frag="${host_makefile_frag} config/mh-apollo68"
;;
m68k-apollo-bsd*)
host_makefile_frag="${host_makefile_frag} config/mh-a68bsd"
;;
m88k-dg-dgux*)
host_makefile_frag="${host_makefile_frag} config/mh-dgux"
;;
m88k-harris-cxux*)
host_makefile_frag="${host_makefile_frag} config/mh-cxux"
;;
m88k-motorola-sysv*)
host_makefile_frag="${host_makefile_frag} config/mh-delta88"
;;
mips*-dec-ultrix*)
host_makefile_frag="${host_makefile_frag} config/mh-decstation"
;;
mips*-nec-sysv4*)
host_makefile_frag="${host_makefile_frag} config/mh-necv4"
;;
mips*-sgi-irix6*)
host_makefile_frag="${host_makefile_frag} config/mh-irix6"
;;
mips*-sgi-irix5*)
host_makefile_frag="${host_makefile_frag} config/mh-irix5"
;;
mips*-sgi-irix4*)
host_makefile_frag="${host_makefile_frag} config/mh-irix4"
;;
mips*-sgi-irix3*)
host_makefile_frag="${host_makefile_frag} config/mh-sysv"
;;
mips*-*-sysv4*)
host_makefile_frag="${host_makefile_frag} config/mh-sysv4"
;;
mips*-*-sysv*)
host_makefile_frag="${host_makefile_frag} config/mh-riscos"
;;
i[3456]86-*-sysv5*)
host_makefile_frag="${host_makefile_frag} config/mh-sysv5"
;;
i[3456]86-*-dgux*)
host_makefile_frag="${host_makefile_frag} config/mh-dgux386"
;;
i[3456]86-ncr-sysv4.3*)
host_makefile_frag="${host_makefile_frag} config/mh-ncrsvr43"
;;
i[3456]86-ncr-sysv4*)
host_makefile_frag="${host_makefile_frag} config/mh-ncr3000"
;;
i[3456]86-*-sco3.2v5*)
host_makefile_frag="${host_makefile_frag} config/mh-sysv"
;;
i[3456]86-*-sco*)
host_makefile_frag="${host_makefile_frag} config/mh-sco"
;;
i[3456]86-*-udk*)
host_makefile_frag="${host_makefile_frag} config/mh-sysv5"
;;
i[3456]86-*-isc*)
host_makefile_frag="${host_makefile_frag} config/mh-sysv"
;;
i[3456]86-*-solaris2*)
host_makefile_frag="${host_makefile_frag} config/mh-sysv4"
;;
i[3456]86-*-aix*)
host_makefile_frag="${host_makefile_frag} config/mh-aix386"
;;
i[3456]86-*-msdosdjgpp*)
host_makefile_frag="${host_makefile_frag} config/mh-djgpp"
;;
*-cygwin32*)
host_makefile_frag="${host_makefile_frag} config/mh-cygwin"
;;
*-mingw32*)
host_makefile_frag="${host_makefile_frag} config/mh-mingw32"
;;
*-interix*)
host_makefile_frag="${host_makefile_frag} config/mh-interix"
;;
*-windows*)
host_makefile_frag="${host_makefile_frag} config/mh-windows"
;;
vax-*-ultrix2*)
host_makefile_frag="${host_makefile_frag} config/mh-vaxult2"
;;
*-*-solaris2*)
host_makefile_frag="${host_makefile_frag} config/mh-solaris"
;;
m68k-sun-sunos*)
host_makefile_frag="${host_makefile_frag} config/mh-sun3"
;;
*-hp-hpux[78]*)
host_makefile_frag="${host_makefile_frag} config/mh-hpux8"
;;
*-hp-hpux*)
host_makefile_frag="${host_makefile_frag} config/mh-hpux"
;;
*-*-hiux*)
host_makefile_frag="${host_makefile_frag} config/mh-hpux"
;;
rs6000-*-lynxos*)
host_makefile_frag="${host_makefile_frag} config/mh-lynxrs6k"
;;
*-*-lynxos*)
host_makefile_frag="${host_makefile_frag} config/mh-lynxos"
;;
*-*-aix4.[3456789]* | *-*-aix[56789].*)
host_makefile_frag="${host_makefile_frag} config/mh-aix43"
;;
*-*-sysv4*)
host_makefile_frag="${host_makefile_frag} config/mh-sysv4"
;;
*-*-sysv*)
host_makefile_frag="${host_makefile_frag} config/mh-sysv"
;;
m68k-hp-hpux*) host_makefile_frag=config/mh-hp300 ;;
m68k-apollo-sysv*) host_makefile_frag=config/mh-apollo68 ;;
m68k-apollo-bsd*) host_makefile_frag=config/mh-a68bsd ;;
m88k-dg-dgux*) host_makefile_frag=config/mh-dgux ;;
m88k-harris-cxux*) host_makefile_frag=config/mh-cxux ;;
m88k-motorola-sysv*) host_makefile_frag=config/mh-delta88;;
mips*-dec-ultrix*) host_makefile_frag=config/mh-decstation ;;
mips*-nec-sysv4*) host_makefile_frag=config/mh-necv4 ;;
mips*-sgi-irix6*) host_makefile_frag=config/mh-irix6 ;;
mips*-sgi-irix5*) host_makefile_frag=config/mh-irix5 ;;
mips*-sgi-irix4*) host_makefile_frag=config/mh-irix4 ;;
mips*-sgi-irix3*) host_makefile_frag=config/mh-sysv ;;
mips*-*-sysv4*) host_makefile_frag=config/mh-sysv4 ;;
mips*-*-sysv*) host_makefile_frag=config/mh-riscos ;;
i[3456]86-*-dgux*) host_makefile_frag=config/mh-dgux386 ;;
i[3456]86-ncr-sysv4.3) host_makefile_frag=config/mh-ncrsvr43 ;;
i[3456]86-ncr-sysv4*) host_makefile_frag=config/mh-ncr3000 ;;
i[3456]86-*-sco3.2v5*) host_makefile_frag=config/mh-sysv ;;
i[3456]86-*-sco*) host_makefile_frag=config/mh-sco ;;
i[3456]86-*-isc*) host_makefile_frag=config/mh-sysv ;;
i[3456]86-*-solaris2*) host_makefile_frag=config/mh-sysv4 ;;
i[3456]86-*-aix*) host_makefile_frag=config/mh-aix386 ;;
i[3456]86-*-go32*) host_makefile_frag=config/mh-go32 ;;
i[3456]86-*-msdosdjgpp*) host_makefile_frag=config/mh-go32 ;;
*-cygwin32*) host_makefile_frag=config/mh-cygwin32 ;;
*-windows*) host_makefile_frag=config/mh-windows ;;
vax-*-ultrix2*) host_makefile_frag=config/mh-vaxult2 ;;
*-*-solaris2*) host_makefile_frag=config/mh-solaris ;;
m68k-sun-sunos*) host_makefile_frag=config/mh-sun3 ;;
*-hp-hpux[78]*) host_makefile_frag=config/mh-hpux8 ;;
*-hp-hpux*) host_makefile_frag=config/mh-hpux ;;
*-*-hiux*) host_makefile_frag=config/mh-hpux ;;
rs6000-*-lynxos*) host_makefile_frag=config/mh-lynxrs6k ;;
*-*-lynxos*) host_makefile_frag=config/mh-lynxos ;;
*-*-sysv4*) host_makefile_frag=config/mh-sysv4 ;;
*-*-sysv*) host_makefile_frag=config/mh-sysv ;;
esac
fi
# If we aren't going to be using gcc, see if we can extract a definition
# of CC from the fragment.
if [ -z "${CC}" ] && [ "${build}" = "${host}" ]; then
if [ -z "${CC}" -a "${build}" = "${host}" ]; then
IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
found=
for dir in $PATH; do
@@ -256,7 +159,7 @@ if [ -z "${CC}" ] && [ "${build}" = "${host}" ]; then
fi
done
IFS="$save_ifs"
if [ -z "${found}" ] && [ -n "${host_makefile_frag}" ] && [ -f "${srcdir}/${host_makefile_frag}" ]; then
if [ -z "${found}" -a -n "${host_makefile_frag}" -a -f "${srcdir}/${host_makefile_frag}" ]; then
xx=`sed -n -e 's/^[ ]*CC[ ]*=[ ]*\(.*\)$/\1/p' < ${srcdir}/${host_makefile_frag}`
if [ -n "${xx}" ] ; then
CC=$xx
@@ -268,8 +171,8 @@ fi
# Well, we don't yet, but we will.
if false && [ "${host}" = "${target}" ] && [ x${enable_shared} = x ]; then
case "${target}" in
alpha*-dec-osf*) enable_shared=yes ;;
alpha*-*-linux*) enable_shared=yes ;;
alpha-dec-osf*) enable_shared=yes ;;
alpha-*-linux*) enable_shared=yes ;;
mips-sgi-irix5*) enable_shared=yes ;;
*) enable_shared=no ;;
esac
@@ -283,80 +186,31 @@ case "${enable_shared}" in
esac
if [ x${shared} = xyes ]; then
waugh=
case "${host}" in
alpha*-*-linux*)
host_makefile_frag="${host_makefile_frag} config/mh-elfalphapic"
;;
arm*-*-*)
host_makefile_frag="${host_makefile_frag} config/mh-armpic"
;;
hppa*-*-*)
host_makefile_frag="${host_makefile_frag} config/mh-papic"
;;
i[3456]86-*-cygwin32*)
# We don't want -fPIC on cygwin32.
;;
i[3456]86-*-*)
host_makefile_frag="${host_makefile_frag} config/mh-x86pic"
;;
sparc64-*-*)
host_makefile_frag="${host_makefile_frag} config/mh-sparcpic"
;;
powerpc*-*-aix*)
# We don't want -fPIC on AIX.
;;
powerpc*-*-*)
host_makefile_frag="${host_makefile_frag} config/mh-ppcpic"
;;
*-*-*)
if test -f ${srcdir}/config/mh-${host_cpu}pic; then
host_makefile_frag="${host_makefile_frag} config/mh-${host_cpu}pic"
fi
;;
hppa*) waugh=config/mh-papic ;;
i[3456]86-*) waugh=config/mh-x86pic ;;
sparc64-*) waugh=config/mh-sparcpic ;;
powerpc*-*) waugh=config/mh-ppcpic ;;
*) waugh=config/mh-${host_cpu}pic ;;
esac
fi
rm -f mh-frag
if [ -n "${host_makefile_frag}" ] ; then
for f in ${host_makefile_frag}
do
cat ${srcdir}/$f >> mh-frag
done
host_makefile_frag=mh-frag
if [ -f ${srcdir}/${waugh} ]; then
if [ -n "${host_makefile_frag}" ] ; then
cat ${srcdir}/${host_makefile_frag} > mh-frag
cat ${srcdir}/${waugh} >> mh-frag
host_makefile_frag=mh-frag
else
host_makefile_frag=${waugh}
fi
fi
fi
# per-target:
case "${target}" in
v810*)
target_makefile_frag="${target_makefile_frag} config/mt-v810"
;;
i[3456]86-*-netware*)
target_makefile_frag="${target_makefile_frag} config/mt-netware"
;;
powerpc-*-netware*)
target_makefile_frag="${target_makefile_frag} config/mt-netware"
;;
*-*-linux-gnu)
target_makefile_frag="${target_makefile_frag} config/mt-linux"
;;
esac
# If --enable-target-optspace always use -Os instead of -O2 to build
# the target libraries, similarly if it is not specified, use -Os
# on selected platforms.
case "${enable_target_optspace}:${target}" in
yes:*)
target_makefile_frag="${target_makefile_frag} config/mt-ospace"
;;
:m32r-*)
target_makefile_frag="${target_makefile_frag} config/mt-ospace"
;;
no:* | :*)
;;
*)
echo "*** bad value \"${enable_target_optspace}\" for --enable-target-optspace flag; ignored" 1>&2
;;
v810*) target_makefile_frag=config/mt-v810 ;;
i[3456]86-*-netware*) target_makefile_frag=config/mt-netware ;;
powerpc-*-netware*) target_makefile_frag=config/mt-netware ;;
esac
skipdirs=
@@ -371,7 +225,7 @@ case ${with_x} in
yes | "") # the default value for this tree is that X11 is available
;;
no)
skipdirs="${skipdirs} tk libgui gash"
skipdirs="${skipdirs} tk gash"
;;
*)
echo "*** bad value \"${with_x}\" for -with-x flag; ignored" 1>&2
@@ -390,17 +244,20 @@ if [ x"${host}" = x"${target}" ] ; then
# that are in the 'cross only' list
skipdirs="${skipdirs} ${cross_only}"
is_cross_compiler=no
target_subdir=.
case "${host}" in
# We need multilib support for irix6, to get libiberty built
# properly for o32 and n32.
mips-sgi-irix6*) target_subdir=${host} ;;
esac
else
# similarly, don't build the targets in the 'native only'
# list when building a cross compiler
skipdirs="${skipdirs} ${native_only}"
is_cross_compiler=yes
target_subdir=${target_alias}
fi
# We always want to use the same name for this directory, so that dejagnu
# can reliably find it.
target_subdir=${target_alias}
if [ ! -d ${target_subdir} ] ; then
if mkdir ${target_subdir} ; then true
else
@@ -463,7 +320,7 @@ if [ x${with_stabs} = x ]; then
case "${target}" in
mips*-*-irix6*)
;;
mips*-*-* | alpha*-*-osf*)
mips*-*-* | alpha*-*-osf* | i[3456]86*-*-sysv4* | i[3456]86*-*-unixware*)
with_stabs=yes;
withoptions="${withoptions} --with-stabs"
;;
@@ -506,8 +363,6 @@ done
case "${host}" in
i[3456]86-*-go32*)
configdirs="$configdirs dosrel" ;;
i[3456]86-*-mingw32*)
configdirs="$configdirs dosrel" ;;
*-cygwin32*)
configdirs="$configdirs dosrel" ;;
esac
@@ -520,17 +375,13 @@ noconfigdirs=""
case "${host}" in
i[3456]86-*-vsta)
noconfigdirs="tcl expect dejagnu make texinfo bison patch flex byacc send-pr gprof uudecode dejagnu diff guile perl apache inet itcl tix db snavigator gnuserv gettext"
noconfigdirs="tcl expect dejagnu make texinfo bison patch flex byacc send-pr gprof uudecode dejagnu diff guile perl apache inet itcl tix db sn gnuserv"
;;
i[3456]86-*-go32* | i[3456]86-*-msdosdjgpp*)
noconfigdirs="tcl tk expect dejagnu make texinfo bison patch flex byacc send-pr uudecode dejagnu diff guile perl apache inet itcl tix db snavigator gnuserv gettext"
;;
i[3456]86-*-mingw32*)
# noconfigdirs="tcl tk expect dejagnu make texinfo bison patch flex byacc send-pr uudecode dejagnu diff guile perl apache inet itcl tix db snavigator gnuserv"
noconfigdirs="expect dejagnu cvs autoconf automake send-pr gprof rcs guile perl texinfo apache inet libtool"
noconfigdirs="tcl tk expect dejagnu make texinfo bison patch flex byacc send-pr uudecode dejagnu diff guile perl apache inet itcl tix db sn gnuserv"
;;
*-*-cygwin32)
noconfigdirs="autoconf automake send-pr gprof rcs guile perl apache inet"
noconfigdirs="expect dejagnu cvs autoconf automake bison send-pr gprof rcs guile perl texinfo apache inet"
;;
*-*-windows*)
# This is only used to build WinGDB...
@@ -538,11 +389,8 @@ case "${host}" in
configdirs="bfd libiberty opcodes readline sim gdb"
target_configdirs=
;;
*-*-netbsd*)
noconfigdirs="rcs"
;;
ppc*-*-pe)
noconfigdirs="patch diff make tk tcl expect dejagnu cvssrc autoconf automake texinfo bison send-pr gprof rcs guile perl apache inet itcl tix db snavigator gnuserv"
noconfigdirs="patch diff make tk tcl expect dejagnu cvs autoconf automake texinfo bison send-pr gprof rcs guile perl apache inet itcl tix db sn gnuserv"
;;
esac
@@ -551,13 +399,10 @@ case "${target}" in
*-*-netware)
noconfigdirs="$noconfigdirs target-libg++ target-libstdc++ target-librx target-newlib target-libiberty target-libgloss"
;;
*-*-rtems*)
noconfigdirs="$noconfigdirs target-libgloss"
;;
*-*-vxworks*)
noconfigdirs="$noconfigdirs target-newlib target-libgloss"
;;
alpha*-dec-osf*)
alpha-dec-osf*)
# ld works, but does not support shared libraries. emacs doesn't
# work. newlib is not 64 bit ready. I'm not sure about fileutils.
# gas doesn't generate exception information.
@@ -566,12 +411,6 @@ case "${target}" in
alpha*-*-*vms*)
noconfigdirs="$noconfigdirs gdb ld target-newlib target-libgloss"
;;
alpha*-*-linux*)
# newlib is not 64 bit ready
noconfigdirs="$noconfigdirs target-newlib target-libgloss"
# linux has rx in libc
skipdirs="$skipdirs target-librx"
;;
alpha*-*-*)
# newlib is not 64 bit ready
noconfigdirs="$noconfigdirs target-newlib target-libgloss"
@@ -585,24 +424,6 @@ case "${target}" in
arm-*-coff*)
noconfigdirs="$noconfigdirs target-libgloss"
;;
arm-*-elf*)
noconfigdirs="$noconfigdirs target-libgloss"
if [ x${is_cross_compiler} != xno ] ; then
target_configdirs="${target_configdirs} target-bsp target-libstub target-cygmon"
fi
;;
arm-*-oabi*)
noconfigdirs="$noconfigdirs target-libgloss"
if [ x${is_cross_compiler} != xno ] ; then
target_configdirs="${target_configdirs} target-bsp target-libstub target-cygmon"
fi
;;
c4x-*-*)
noconfigdirs="$noconfigdirs target-libg++ target-libstdc++ target-libio target-librx target-libgloss"
;;
thumb-*-coff)
noconfigdirs="$noconfigdirs target-libgloss"
;;
arm-*-riscix*)
noconfigdirs="$noconfigdirs ld target-libgloss"
;;
@@ -614,7 +435,8 @@ case "${target}" in
noconfigdirs="$noconfigdirs target-libg++ target-libstdc++ target-libio target-librx target-libgloss"
;;
hppa*-*-*elf* | \
hppa*-*-lites*)
hppa*-*-lites* | \
hppa*-*-rtems* )
# Do configure ld/binutils/gas for this case.
;;
hppa*-*-*)
@@ -631,31 +453,16 @@ case "${target}" in
# but don't build gdb
noconfigdirs="$noconfigdirs gdb target-libg++ target-libstdc++ target-libio target-librx"
;;
*-*-linux*)
# linux has rx in libc
skipdirs="$skipdirs target-librx"
;;
i[3456]86-*-mingw32*)
target_configdirs="$target_configdirs target-mingw"
noconfigdirs="$noconfigdirs expect target-libgloss"
# Can't build gdb for mingw32 if not native.
case "${host}" in
i[3456]86-*-mingw32) ;; # keep gdb tcl tk expect etc.
*) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix db snavigator gnuserv"
;;
esac
;;
*-*-cygwin32*)
*-*-cygwin32)
target_configdirs="$target_configdirs target-winsup"
noconfigdirs="$noconfigdirs target-gperf target-libgloss"
noconfigdirs="$noconfigdirs expect target-libgloss"
# always build newlib.
skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
# Can't build gdb for cygwin32 if not native.
case "${host}" in
*-*-cygwin32*) ;; # keep gdb tcl tk expect etc.
*) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix libgui db snavigator gnuserv"
*-*-cygwin32) ;; # keep gdb tcl tk expect etc.
*) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix db sn gnuserv"
;;
esac
;;
@@ -665,7 +472,7 @@ case "${target}" in
i[3456]86-*-sco3.2v5*)
# The linker does not yet know about weak symbols in COFF,
# and is not configured to handle mixed ELF and COFF.
noconfigdirs="$noconfigdirs ld target-libgloss"
noconfigdirs="$noconfigdirs gprof ld target-libgloss"
;;
i[3456]86-*-sco*)
noconfigdirs="$noconfigdirs gprof target-libgloss"
@@ -686,37 +493,31 @@ case "${target}" in
noconfigdirs="$noconfigdirs emacs emacs19 target-libgloss"
;;
mn10200-*-*)
noconfigdirs="$noconfigdirs"
if [ x${is_cross_compiler} != xno ] ; then
target_configdirs="${target_configdirs} target-libstub target-cygmon"
fi
noconfigdirs="$noconfigdirs target-libgloss"
;;
mn10300-*-*)
noconfigdirs="$noconfigdirs"
if [ x${is_cross_compiler} != xno ] ; then
target_configdirs="${target_configdirs} target-libstub target-cygmon"
fi
noconfigdirs="$noconfigdirs target-libgloss"
;;
powerpc-*-aix*)
# copied from rs6000-*-* entry
noconfigdirs="$noconfigdirs gprof cvssrc target-libgloss"
noconfigdirs="$noconfigdirs gprof cvs target-libgloss"
# This is needed until gcc and ld are fixed to work together.
use_gnu_ld=no
;;
powerpc*-*-winnt* | powerpc*-*-pe* | ppc*-*-pe)
target_configdirs="$target_configdirs target-winsup"
noconfigdirs="$noconfigdirs gdb tcl tk make expect target-libgloss itcl tix db snavigator gnuserv"
noconfigdirs="$noconfigdirs gdb tcl tk make expect target-libgloss itcl tix db sn gnuserv"
# always build newlib.
skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
;;
# This is temporary until we can link against shared libraries
powerpcle-*-solaris*)
noconfigdirs="$noconfigdirs gdb sim make tcl tk expect itcl tix db snavigator gnuserv"
noconfigdirs="$noconfigdirs gdb sim make tcl tk expect itcl tix db sn gnuserv"
;;
rs6000-*-lynxos*)
# The CVS server code doesn't work on the RS/6000
# Newlib makes problems for libg++ in crosses.
noconfigdirs="$noconfigdirs target-newlib gprof cvssrc"
noconfigdirs="$noconfigdirs target-newlib gprof cvs"
;;
rs6000-*-aix*)
noconfigdirs="$noconfigdirs gprof"
@@ -745,10 +546,6 @@ case "${target}" in
mips*-*-bsd*)
noconfigdirs="$noconfigdirs gprof target-libgloss"
;;
mipstx39-*-*)
noconfigdirs="$noconfigdirs gprof" # same as generic mips
target_configdirs="${target_configdirs} target-libstub target-cygmon"
;;
mips*-*-*)
noconfigdirs="$noconfigdirs gprof"
;;
@@ -764,21 +561,6 @@ case "${target}" in
esac
noconfigdirs="$noconfigdirs target-libgloss"
;;
sparc-*-elf*)
if [ x${is_cross_compiler} != xno ] ; then
target_configdirs="${target_configdirs} target-libstub target-cygmon"
fi
;;
sparc64-*-elf*)
if [ x${is_cross_compiler} != xno ] ; then
target_configdirs="${target_configdirs} target-libstub target-cygmon"
fi
;;
sparclite-*-aout*)
if [ x${is_cross_compiler} != xno ] ; then
target_configdirs="${target_configdirs} target-libstub target-cygmon"
fi
;;
sparc-*-sunos4*)
if [ x${is_cross_compiler} != xno ] ; then
noconfigdirs="$noconfigdirs gdb gdbtest target-newlib target-libgloss"
@@ -789,9 +571,6 @@ case "${target}" in
v810-*-*)
noconfigdirs="$noconfigdirs bfd binutils gas gcc gdb ld target-libio target-libg++ target-libstdc++ opcodes target-libgloss"
;;
v850-*-*)
noconfigdirs="$noconfigdirs target-libgloss"
;;
vax-*-vms)
noconfigdirs="$noconfigdirs bfd binutils gdb ld target-newlib opcodes target-libgloss"
;;
@@ -809,6 +588,13 @@ case "${target}" in
;;
esac
# targets that need a second pass
case "${target}" in
*-gm-magic*)
noconfigdirs="$noconfigdirs target-libgloss"
;;
esac
# If we aren't building newlib, then don't build libgloss, since libgloss
# depends upon some newlib header files.
case "${noconfigdirs}" in
@@ -816,6 +602,12 @@ case "${noconfigdirs}" in
*target-newlib*) noconfigdirs="$noconfigdirs target-libgloss" ;;
esac
# If we are building a Canadian Cross, discard tools that can not be built
# using a cross compiler. FIXME: These tools should be fixed.
if [ "${build}" != "${host}" ]; then
noconfigdirs="$noconfigdirs expect dejagnu"
fi
# Make sure we don't let GNU ld be added if we didn't want it.
if [ x$with_gnu_ld = xno ]; then
use_gnu_ld=no
@@ -879,12 +671,12 @@ fi
# Deconfigure all subdirectories, in case we are changing the
# configuration from one where a subdirectory is supported to one where it
# is not.
if [ -z "${norecursion}" ] && [ -n "${configdirs}" ]; then
if [ -z "${norecursion}" -a -n "${configdirs}" ]; then
for i in `echo ${configdirs} | sed -e s/target-//g` ; do
rm -f $i/Makefile
done
fi
if [ -z "${norecursion}" ] && [ -n "${target_configdirs}" ]; then
if [ -z "${norecursion}" -a -n "${target_configdirs}" ]; then
for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
rm -f ${target_subdir}/$i/Makefile
done
@@ -962,35 +754,13 @@ fi
if [ x${shared} = xyes ]; then
case "${target}" in
hppa*)
target_makefile_frag="${target_makefile_frag} config/mt-papic"
;;
i[3456]86-*)
target_makefile_frag="${target_makefile_frag} config/mt-x86pic"
;;
powerpc*-*)
target_makefile_frag="${target_makefile_frag} config/mt-ppcpic"
;;
alpha*-*-linux*)
target_makefile_frag="${target_makefile_frag} config/mt-elfalphapic"
;;
*)
if test -f ${srcdir}/config/mt-${target_cpu}pic; then
target_makefile_frag="${target_makefile_frag} config/mt-${target_cpu}pic"
fi
;;
hppa*) target_makefile_frag=config/mt-papic ;;
i[3456]86-*) target_makefile_frag=config/mt-x86pic ;;
powerpc*-*) target_makefile_frag=config/mt-ppcpic ;;
*) target_makefile_frag=config/mt-${target_cpu}pic ;;
esac
fi
rm -f mt-frag
if [ -n "${target_makefile_frag}" ] ; then
for f in ${target_makefile_frag}
do
cat ${srcdir}/$f >> mt-frag
done
target_makefile_frag=mt-frag
fi
# post-target:
# Make sure that the compiler is able to generate an executable. If it
@@ -999,7 +769,7 @@ fi
# can be created. At this point the main configure script has set CC.
echo "int main () { return 0; }" > conftest.c
${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
if [ $? = 0 ] && [ -s conftest -o -s conftest.exe ]; then
if [ $? = 0 ] && [ -s conftest ]; then
:
else
echo 1>&2 "*** The command '${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c' failed."
@@ -1047,7 +817,7 @@ if [ "${shared}" = "yes" ]; then
case "${host}" in
*-*-hpux*)
sed -e 's/^RPATH_ENVVAR[ ]*=.*$/RPATH_ENVVAR = SHLIB_PATH/' \
sed -e 's/RPATH_ENVVAR[ ]*=.*$/RPATH_ENVVAR = SHLIB_PATH/' \
Makefile > Makefile.tem
rm -f Makefile
mv -f Makefile.tem Makefile
@@ -1055,10 +825,21 @@ if [ "${shared}" = "yes" ]; then
esac
fi
# If we are building for a cygwin32 host, then set INSTALL_PROGRAM_ARGS to
# -x. This will cause programs to be installed with .exe extensions.
case "${host}" in
*-*-cygwin32*)
sed -e 's/^INSTALL_PROGRAM_ARGS[ ]*=.*$/INSTALL_PROGRAM_ARGS = -x/' \
Makefile > Makefile.tem
rm -f Makefile
mv -f Makefile.tem Makefile
;;
esac
# Record target_configdirs and the configure arguments in Makefile.
target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
targargs=`echo "${arguments}" | \
sed -e 's/--no[^ ]*//' \
sed -e 's/--norecursion//' \
-e 's/--cache[a-z-]*=[^ ]*//' \
-e 's/--ho[a-z-]*=[^ ]*//' \
-e 's/--bu[a-z-]*=[^ ]*//' \
@@ -1078,46 +859,10 @@ if [ x${enable_multilib} = x ]; then
targargs="--enable-multilib ${targargs}"
fi
# Pass --with-newlib if appropriate. Note that target_configdirs has
# changed from the earlier setting of with_newlib.
if [ x${with_newlib} != xno ] && echo " ${target_configdirs} " | grep " newlib " > /dev/null 2>&1 && [ -d ${srcdir}/newlib ] ; then
targargs="--with-newlib ${targargs}"
fi
# provide a proper gxx_include_dir.
# Note, if you change the default, make sure to fix both here and in
# the gcc, libio, libstdc++ and libg++ subdirectories.
# Check whether --with-gxx-include-dir or --without-gxx-include-dir was given.
gxx_include_dir=
if test -n "${with_gxx_include_dir}"; then
case "${with_gxx_include_dir}" in
yes )
echo "configure.in: error: bad value ${withval} given for g++ include directory" 1>&2
exit 1
;;
no )
;;
* )
gxx_include_dir=${with_gxx_include_dir}
;;
esac
fi
if test x${gxx_include_dir} = x; then
if test x${enable_version_specific_runtime_libs} = xyes; then
gxx_include_dir='${libsubdir}/include/g++'
else
. ${topsrcdir}/config.if
gxx_include_dir='${prefix}/include/g++'-${libstdcxx_interface}
fi
else
gxx_include_dir=${gxx_include_dir}
fi
targargs="--host=${target_alias} --build=${build_alias} ${targargs}"
sed -e "s:^TARGET_CONFIGDIRS[ ]*=.*$:TARGET_CONFIGDIRS = ${target_configdirs}:" \
-e "s%^CONFIG_ARGUMENTS[ ]*=.*$%CONFIG_ARGUMENTS = ${targargs}%" \
-e "s%^TARGET_SUBDIR[ ]*=.*$%TARGET_SUBDIR = ${target_subdir}%" \
-e "s%^gxx_include_dir[ ]*=.*$%gxx_include_dir=${gxx_include_dir}%" \
Makefile > Makefile.tem
rm -f Makefile
mv -f Makefile.tem Makefile

View File

@@ -1,248 +0,0 @@
Sun Oct 24 23:54:10 PDT 1999 Jeff Law (law@cygnus.com)
* gcc-2.95.2 Released.
Mon Aug 16 01:29:24 PDT 1999 Jeff Law (law@cygnus.com)
* gcc-2.95.1 Released.
Wed Jul 28 21:39:31 PDT 1999 Jeff Law (law@cygnus.com)
* gcc-2.95 Released.
Sun Jul 25 23:40:51 PDT 1999 Jeff Law (law@cygnus.com)
* gcc-2.95 Released.
1999-07-17 Alexandre Oliva <oliva@dcc.unicamp.br>
* test_summary: Replace egcs with gcc. Update e-mail address.
1999-06-12 Alexandre Oliva <oliva@dcc.unicamp.br>
* test_summary: Set default mail-address and version for egcs
instead of relying on unpredictable pathnames.
Reported by Andreas Jaeger <aj@arthur.rhein-neckar.de>
1999-06-12 Alexandre Oliva <oliva@dcc.unicamp.br>
* test_summary: Set default mail-address and version for egcs
instead of relying on unpredictable pathnames.
Reported by Andreas Jaeger <aj@arthur.rhein-neckar.de>
Fri Apr 2 16:09:02 1999 Jeffrey A Law (law@cygnus.com)
* fixinc/*: Delete obsolete files.
1999-02-04 Robert Lipe <robertlipe@usa.net>
* egcs_update: Test return values of 'cvs update'. Propogate
to caller as exit values.
1999-01-25 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
* egcs_update: Use "if" instead of "&&". Touch generated files
only after the corresponding *.y files.
1999-01-19 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
* egcs_update: Do not use xargs, but a backquote construct.
1999-01-07 Alexandre Oliva <oliva@dcc.unicamp.br>
* test_summary (version): Remove carriage return that gawk inserts
in the version string for some reason.
1998-11-30 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
* egcs_update: Only touch files that already exist.
1998-11-29 Alexandre Oliva <oliva@dcc.unicamp.br>
* test_summary (EOF): Remove double backslash.
Reported by Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
1998-11-28 Alexandre Oliva <oliva@dcc.unicamp.br>
* test_summary (address): Set to egcs-testresults mailing list.
1998-11-27 Alexandre Oliva <oliva@dcc.unicamp.br>
* test_summary (address): Added Marc Lehmann's testsuite-results
to the default e-mail address.
1998-11-25 Alexandre Oliva <oliva@dcc.unicamp.br>
* test_summary (-p, prepend_logs): Add these before the summary.
(Compiler, Platform): Print these just before configflags.
Sat Oct 31 10:53:40 1998 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* warn_summary (longLineFilter): New shell function to encapsulate
this functionality. It is off by default, only active if -llf
flag is specified.
(subdirectoryFilter): Fix bug in filtering which made some
subdirectory warnings erroneously appear in the toplevel set.
(stageNfilter): Renamed from `stageNwarns'. Updated to collect
warnings from stage1 as well as stage0, which means warnings from
outside the bootstrap directory. Eg, the libraries, etc.
(warningFilter): New shell function to encapsulate this
functionality.
(keywordFilter): New shell function to encapsulate this
functionality.
Store data in a temp file rather than calculating it 3x. Arrange
to remove it on exit and signals.
Add -pass/-wpass flags to do "pass through" (i.e. manual
inspection) of bootstrap output from a particular stageN as well
as language subdirs.
Add better comments/documentation.
Sat Oct 31 16:39:31 1998 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
* egcs_update: Add comment about keeping the FAQ synchronized.
Fri Oct 30 00:39:27 1998 Jeffrey A Law (law@cygnus.com)
* egcs_update: Do touch java/parse.c and java/parse-scan.c. They're
in the repo again.
Fri Oct 16 07:35:00 1998 Bruce Korb <korb@datadesign.com>
* egcs_update: Added gcc/fixinc/* generated files to touch list.
Tue Oct 13 23:28:33 1998 Jeffrey A Law (law@cygnus.com)
* egcs_update: Remove gcc/java/parse.c from list of files to
touch.
Wed Oct 7 13:00:40 1998 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* gperf-2.7-19981006.pat: New file, patch for egcs-local gperf.
Mon Oct 5 14:19:48 1998 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* warn_summary (subdirectoryFilter): New shell function to
optionally filter in/out gcc subdirectories when summarizing
warnings. Add new flags to support subdirectory filtering.
Also, ensure the bootstrap stage is a number. Add some more C
keywords that are preserved in the "warning type" summary and
tighten up the "arg ???" regexp.
Tue Sep 22 07:30 Bruce Korb <korb@datadesign.com>
* fixinc/inclhack.def: Not all C++ comments in C headers
were treated alike. They are now. Also fixed syntax
of sed expression in "systypes" fix.
* fixinc/inclhack.def: Removed SVR4.2-ism from shell invocation
* egcs_update: Added fixinc/* generated files to touch list.
Wed Sep 16 16:06:51 1998 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* egcs_update: Additionally touch gcc/java/parse.[ch].
Thu Sep 9 16:48 Bruce Korb <korb@datadesign.com>
* fixinc/inclhack.def: Added two files required by
SCO's Open Server 5's avoid_bool fix.
Regenerated fixinc.x and inclhack.sh to incorporate
the update.
Thu Sep 3 10:11:32 1998 Robert Lipe <robertl@dgii.com>
* egcs_update: Do the pass 1 CVS update only for files that
may reasonably be under CVS control.
1998-08-14 Alexandre Oliva <oliva@dcc.unicamp.br>
* test_installed: New script for testing already-installed
gcc/g++/g77.
Wed Aug 12 19:59:36 1998 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
* egcs_update: Assigned copyright to FSF.
Tue Aug 11 17:55:53 1998 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
Alexandre Oliva <oliva@dcc.unicamp.br>
* egcs_update: New switch --nostdflags and documentation
enhancements.
Tue Aug 11 17:33:19 1998 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
* egcs_update: New script.
1998-08-05 Bruce Korb <korbb@datadesign.com>
* fixinc/Makefile
Added define for target machine so machine-specific tests
can be selected for or against.
* fixinc/fixincl.c
Added an array of string pointers to machines to select
or avoid, depending on a FD_MACH_IFNOT bit flag.
Used a shell script to match the defined TARGET_MACHINE
with any of the given match patterns.
* fixinc/fixincl.tpl
Generate the array of strings and bit flag, as needed,
depending on "mach" and "not_machine" attributes for a fix.
* fixinc/mkfixinc.sh
Invoke the make with TARGET assigned the value of the
machine name argument.
Mon Jul 27 22:08:12 1998 Mike Stump (mrs@wrs.com)
* compare_tests: New script.
1998-07-28 Alexandre Oliva <oliva@dcc.unicamp.br>
* test_summary: Assigned copyright to FSF.
Mon Jul 27 20:33:02 1998 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
* test_summary: Corrected script name in comments providing
documentation. Added linebreaks for lines with > 80 characters.
Fri Jun 19 02:36:59 1998 Alexandre Oliva <oliva@dcc.unicamp.br>
* test_summary: New switch, -i, and environment variable,
append_logs, for including files in the report.
1998-06-01 Manfred Hollstein <manfred@s-direktnet.de>
* warn_summary: Update to Kaveh's latest version allowing to
specify the last stage built.
1998-05-29 Bruce Korb <korbb@datadesign.com>
* fixinc/mkfixinc.sh
Changes to make it easier to invoke on platforms that
normally do not invoke fixincludes.
* fixinc/inclhack.def
Applied fixes from egcs/gcc/fixincludes from the past several
months.
1998-05-28 Bruce Korb <korbb@datadesign.com>
* fixinc/*: Updated most everything for a first real
try at getting "fast_fixincludes" working.
1998-05-28 Jason Merrill <jason@yorick.cygnus.com>
* index-prop: New file.
Sat May 23 23:38:49 1998 Matthias Klose <doko@cs.tu-berlin.de>
* test_summary: find good awk (copied from warn_summary).
Sat May 23 23:38:33 1998 Jeffrey A Law (law@cygnus.com)
* test_summary, warn_summary: New files

View File

@@ -1,98 +0,0 @@
#!/bin/sh
# This script automatically test the given tool with the tool's test cases,
# reporting anything of interest.
# exits with 1 if there is nothing of interest
# exits with 0 if there is something interesting
# exits with 2 if an error occurred
# Give two .sum files to compare them
# Written by Mike Stump <mrs@cygnus.com>
tmp1=/tmp/$tool-testing.$$a
tmp2=/tmp/$tool-testing.$$b
now_s=/tmp/$tool-testing.$$d
before_s=/tmp/$tool-testing.$$e
if [ "$2" = "" ]; then
echo "Usage: $0 previous current" >&2
exit 2
fi
sed 's/^XFAIL/FAIL/; s/^XPASS/PASS/' < "$1" >$tmp1
sed 's/^XFAIL/FAIL/; s/^XPASS/PASS/' < "$2" >$tmp2
before=$tmp1
now=$tmp2
trap "rm -f $tmp1 $tmp2 $now_s $before_s" 0 1 2 3 5 9 13 15
sort +0.4 "$now" > "$now_s"
sort +0.4 "$before" > "$before_s"
grep '^FAIL' "$now_s" | sed 's/^....: //' >$tmp1
grep '^PASS' "$before_s" | sed 's/^....: //' | comm -12 $tmp1 - >$tmp2
grep -s . $tmp2 >/dev/null
if [ $? = 0 ]; then
echo "Tests that now fail, but worked before:"
echo
cat $tmp2
echo
fi
grep '^PASS' "$now_s" | sed 's/^....: //' >$tmp1
grep '^FAIL' "$before_s" | sed 's/^....: //' | comm -12 $tmp1 - >$tmp2
grep -s . $tmp2 >/dev/null
if [ $? = 0 ]; then
echo "Tests that now work, but didn't before:"
echo
cat $tmp2
echo
fi
grep '^FAIL' "$now_s" | sed 's/^....: //' >$tmp1
grep '^[PF]A[SI][SL]' "$before_s" | sed 's/^....: //' | comm -23 $tmp1 - >$tmp2
grep -s . $tmp2 >/dev/null
if [ $? = 0 ]; then
echo "New tests that FAIL:"
echo
cat $tmp2
echo
fi
grep '^PASS' "$now_s" | sed 's/^....: //' >$tmp1
grep '^[PF]A[SI][SL]' "$before_s" | sed 's/^....: //' | comm -23 $tmp1 - >$tmp2
grep -s . $tmp2 >/dev/null
if [ $? = 0 ]; then
echo "New tests that PASS:"
echo
cat $tmp2
echo
fi
grep '^[PF]A[SI][SL]' "$now_s" | sed 's/^....: //' >$tmp1
grep '^PASS' "$before_s" | sed 's/^....: //' | comm -13 $tmp1 - >$tmp2
grep -s . $tmp2 >/dev/null
if [ $? = 0 ]; then
echo "Old tests that passed, that have disappeared: (Eeek!)"
echo
cat $tmp2
echo
fi
grep '^[PF]A[SI][SL]' "$now_s" | sed 's/^....: //' >$tmp1
grep '^FAIL' "$before_s" | sed 's/^....: //' | comm -13 $tmp1 - >$tmp2
grep -s . $tmp2 >/dev/null
if [ $? = 0 ]; then
echo "Old tests that failed, that have disappeared: (Eeek!)"
echo
cat $tmp2
echo
fi

View File

@@ -1,202 +0,0 @@
#! /bin/sh
#
# Update a local CVS tree from the egcs repository, with an emphasis
# on treating generated files correctly, so that autoconf, bison et
# al are not required for the ``end'' user.
#
# By default all command-line options are passed to `cvs update` in
# addition to $UPDATE_OPTIONS (defined below). If the first parameter
# reads --nostdflags, $UPDATE_OPTIONS as well as this parameter itself
# are omitted.
#
# If the first parameter reads --patch, the second parameter is considered
# a patch file.
#
# If the first parameter is --touch, no cvs operation will be performed,
# only generated files that appear to be out of date in the local tree
# will be touched.
#
# If the first parameter is --list, a list of the generated files and
# their dependencies will be printed; --help prints this message.
#
# Examples:
#
# contrib/egcs_update -r egcs_latest_snapshot
# contrib/egcs_update -A
# contrib/egcs_update --nostdflags -P -r egcs_1_1_branch gcc/testsuite
# contrib/egcs_update --patch some-patch
# contrib/egcs_update --touch
# contrib/egcs_update --list
#
#
# (C) 1998-1999 Free Software Foundation
# Originally by Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>, August 1998.
#
# This script is Free Software, and it can be copied, distributed and
# modified as defined in the GNU General Public License. A copy of
# its license can be downloaded from http://www.gnu.org/copyleft/gpl.html
# Default options used when updating via CVS.
UPDATE_OPTIONS=-P
# Add -d to create any directories that exist in the repository but not
# locally.
# Add -A to reset any sticky tags, dates, or `-k' options.
# This function prints a list of all generated files, along with their
# dependencies. Note that only one target is supported per line: the
# colon is stripped from the output.
files_and_dependencies () {
sed -e 's/ *#.*//' -e '/^$/d' -e 's/://' <<\EOF
# All automake dependencies within texinfo
# In fact, not all, since we do not care about sub-directories that
# we do not build. In particular, *.po and *.gmo are not touched.
texinfo/aclocal.m4: texinfo/configure.in texinfo/acinclude.m4
texinfo/Makefile.in: texinfo/Makefile.am texinfo/configure.in texinfo/aclocal.m4
texinfo/configure: texinfo/configure.in texinfo/aclocal.m4
texinfo/stamp-h.in: texinfo/configure.in texinfo/aclocal.m4 texinfo/acconfig.h
texinfo/lib/Makefile.in: texinfo/lib/Makefile.am texinfo/configure.in texinfo/aclocal.m4
texinfo/makeinfo/Makefile.in: texinfo/makeinfo/Makefile.am texinfo/configure.in texinfo/aclocal.m4
texinfo/util/Makefile.in: texinfo/util/Makefile.am texinfo/configure.in texinfo/aclocal.m4
# Now, proceed to gcc automatically generated files
gcc/configure: gcc/configure.in
gcc/cstamp-h.in: gcc/configure.in gcc/acconfig.h
gcc/config.in: gcc/cstamp-h.in
gcc/c-parse.y: gcc/c-parse.in
gcc/c-parse.c: gcc/c-parse.y
gcc/c-parse.h: gcc/c-parse.c
gcc/c-gperf.h: gcc/c-parse.gperf
gcc/cexp.c: gcc/cexp.y
gcc/fixinc/fixincl.x: gcc/fixinc/fixincl.tpl gcc/fixinc/inclhack.def
gcc/fixinc/inclhack.sh: gcc/fixinc/inclhack.def gcc/fixinc/inclhack.tpl gcc/fixinc/hackshell.tpl
gcc/fixinc/fixincl.sh: gcc/fixinc/inclhack.def gcc/fixinc/inclhack.tpl
# And then, language-specific files
gcc/cp/parse.c: gcc/cp/parse.y
gcc/cp/parse.h: gcc/cp/parse.c
gcc/objc/objc-parse.y: gcc/c-parse.in
gcc/objc/objc-parse.c: gcc/objc/objc-parse.y
gcc/java/parse.h: gcc/java/parse.y
gcc/java/parse.c: gcc/java/parse.y gcc/java/lex.c gcc/java/parse.h gcc/java/lex.h
gcc/java/parse-scan.c: gcc/java/parse-scan.y gcc/java/lex.c gcc/java/parse.h gcc/java/lex.h
# And libraries, at last
libchill/configure: libchill/configure.in
libf2c/configure: libf2c/configure.in
libf2c/libF77/configure: libf2c/libF77/configure.in
libf2c/libI77/configure: libf2c/libI77/configure.in
libf2c/libU77/configure: libf2c/libU77/configure.in
libf2c/libU77/stamp-h.in: libf2c/libU77/configure.in libf2c/libU77/acconfig.h
libobjc/configure: libobjc/configure.in
EOF
}
# This function checks whether its first argument is newer than all
# the other arguments. It returns success (0) otherwise.
is_out_of_date () {
test `ls -1dt ${1+"$@"} | sed 1q` != "$1"
}
# This function touches generated files such that the ``end'' user does
# not have to rebuild them.
touch_files () {
files_and_dependencies | while read f deps; do
if test -f $f && is_out_of_date "$f" $deps; then
echo Touching "$f"...
touch $f
if is_out_of_date "$f" $deps; then
# Hmm, it may have got the same timestamp as one of
# its touched dependencies. Wait a second and retry
sleep 1
touch $f
fi
fi
done
}
# This functions applies a patch to an existing tree.
apply_patch () {
if [ -f $1 ]; then
echo "Applying patch file $1"
case "$1" in
*gz)
gzip -d -c $1 | patch -p1 ;;
*)
cat $1 | patch -p1 ;;
esac
fi
echo "Adjusting file timestamps"
touch_files
}
# Check whether this indeed looks like a local tree.
if [ ! -f gcc/version.c ]; then
echo "This does not seem to be an egcs tree!"
exit
fi
case "$1" in
# First of all, check whether we are going to process a patch.
--patch)
if test "$#" != 2; then
echo "$1" expects only one argument >&2
exit 1
fi
apply_patch "${2}"
exit $?
;;
--touch)
if test "$#" != 1; then
echo "$1" does not expect any argument >&2
exit 1
fi
touch_files
exit $?
;;
--list)
if test "$#" != 1; then
echo "$1" does not expect any argument >&2
exit 1
fi
files_and_dependencies | sed 's/ /: /'
exit $?
;;
--help)
sed -e '1,2d' -e '/^UPDATE_OPTIONS=/{i\
\
p
}' \
-e '/^$/,$d' -e 's/#//' -e 's/^ //' < $0
exit $?
;;
esac
# Check whether this indeed looks like a local CVS tree.
if [ ! -d CVS ]; then
echo "This does not seem to be an egcs CVS tree!"
exit
fi
# Check command-line options
if [ x"${1}"x = x"--nostdflags"x ]; then
shift
else
set -- $UPDATE_OPTIONS ${1+"$@"}
fi
echo "Updating CVS tree"
cvs -q update ${1+"$@"}
if [ $? -ne 0 ]; then
echo "CVS update of full tree failed." >&2
exit 1
fi
echo "Adjusting file timestamps"
touch_files

View File

@@ -1,148 +0,0 @@
Tue Oct 6 16:18:10 1998 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* key-list.cc (output_keyword_blank_entries): Output
get_fill_default() in the blank entries of keywords as a trailing
list of initializers.
* options.cc: Add support for fill_default.
* options.h: Likewise.
* options.icc: Likewise.
* version.cc: Update to indicate forked version.
diff -rup orig/gperf-2.7/src/key-list.cc gperf-2.7/src/key-list.cc
--- orig/gperf-2.7/src/key-list.cc Wed Apr 15 18:02:51 1998
+++ gperf-2.7/src/key-list.cc Tue Oct 6 15:38:54 1998
@@ -1069,7 +1069,7 @@ output_keyword_blank_entries (int count,
printf (", ");
}
if (option[TYPE])
- printf ("{\"\"}");
+ printf ("{\"\"%s}", option.get_fill_default());
else
printf ("\"\"");
column++;
diff -rup orig/gperf-2.7/src/options.cc gperf-2.7/src/options.cc
--- orig/gperf-2.7/src/options.cc Sat May 2 06:35:16 1998
+++ gperf-2.7/src/options.cc Tue Oct 6 15:20:03 1998
@@ -40,6 +40,9 @@ static const int DEFAULT_JUMP_VALUE = 5;
/* Default name for generated lookup function. */
static const char *const DEFAULT_NAME = "in_word_set";
+/* Default filler for keyword table. */
+static const char *const DEFAULT_FILL = "";
+
/* Default name for the key component. */
static const char *const DEFAULT_KEY = "name";
@@ -66,6 +69,7 @@ int Options::argument_count;
int Options::iterations;
char **Options::argument_vector;
const char *Options::function_name;
+const char *Options::fill_default;
const char *Options::key_name;
const char *Options::class_name;
const char *Options::hash_name;
@@ -265,6 +269,7 @@ Options::Options (void)
jump = DEFAULT_JUMP_VALUE;
option_word = DEFAULTCHARS | C;
function_name = DEFAULT_NAME;
+ fill_default = DEFAULT_FILL;
key_name = DEFAULT_KEY;
hash_name = DEFAULT_HASH_NAME;
wordlist_name = DEFAULT_WORDLIST_NAME;
@@ -306,6 +311,7 @@ Options::~Options (void)
"\nSEVENBIT is....: %s"
"\niterations = %d"
"\nlookup function name = %s"
+ "\nfill default = %s"
"\nhash function name = %s"
"\nword list name = %s"
"\nkey name = %s"
@@ -336,7 +342,7 @@ Options::~Options (void)
option_word & INCLUDE ? "enabled" : "disabled",
option_word & SEVENBIT ? "enabled" : "disabled",
iterations,
- function_name, hash_name, wordlist_name, key_name,
+ function_name, fill_default, hash_name, wordlist_name, key_name,
jump, size - 1, initial_asso_value, delimiters, total_switches);
if (option_word & ALLCHARS)
fprintf (stderr, "all characters are used in the hash function\n");
@@ -379,6 +385,7 @@ static const struct option long_options[
{ "compare-strlen", no_argument, 0, 'l' },
{ "duplicates", no_argument, 0, 'D' },
{ "fast", required_argument, 0, 'f' },
+ { "fill-default", required_argument, 0, 'F' },
{ "initial-asso", required_argument, 0, 'i' },
{ "jump", required_argument, 0, 'j' },
{ "no-strlen", no_argument, 0, 'n' },
@@ -403,7 +410,7 @@ Options::operator() (int argc, char *arg
while ((option_char =
getopt_long (argument_count, argument_vector,
- "adcCDe:Ef:gGhH:i:Ij:k:K:lL:nN:oprs:S:tTvW:Z:7",
+ "adcCDe:Ef:F:gGhH:i:Ij:k:K:lL:nN:oprs:S:tTvW:Z:7",
long_options, (int *)0))
!= -1)
{
@@ -575,6 +582,11 @@ Options::operator() (int argc, char *arg
case 'N': /* Make generated lookup function name be optarg */
{
function_name = /*getopt*/optarg;
+ break;
+ }
+ case 'F': /* Make fill_default be optarg */
+ {
+ fill_default = /*getopt*/optarg;
break;
}
case 'o': /* Order input by frequency of key set occurrence. */
diff -rup orig/gperf-2.7/src/options.h gperf-2.7/src/options.h
--- orig/gperf-2.7/src/options.h Tue Apr 14 06:55:28 1998
+++ gperf-2.7/src/options.h Tue Oct 6 15:12:46 1998
@@ -97,6 +97,7 @@ public:
static int initial_value (void);
static int get_total_switches (void);
static const char *get_function_name (void);
+ static const char *get_fill_default (void);
static const char *get_key_name (void);
static const char *get_class_name (void);
static const char *get_hash_name (void);
@@ -115,6 +116,7 @@ private:
static int iterations; /* Amount to iterate when a collision occurs. */
static char **argument_vector; /* Stores a pointer to command-line vector. */
static const char *function_name; /* Names used for generated lookup function. */
+ static const char *fill_default; /* Expression used to assign default values in keyword table. */
static const char *key_name; /* Name used for keyword key. */
static const char *class_name; /* Name used for generated C++ class. */
static const char *hash_name; /* Name used for generated hash function. */
diff -rup orig/gperf-2.7/src/options.icc gperf-2.7/src/options.icc
--- orig/gperf-2.7/src/options.icc Sat Mar 21 07:51:17 1998
+++ gperf-2.7/src/options.icc Tue Oct 6 15:27:36 1998
@@ -110,6 +110,14 @@ Options::get_function_name (void)
return function_name;
}
+/* Returns the fill default. */
+INLINE const char *
+Options::get_fill_default (void)
+{
+ T (Trace t ("Options::get_fill_default");)
+ return fill_default;
+}
+
/* Returns the keyword key name. */
INLINE const char *
Options::get_key_name (void)
diff -rup orig/gperf-2.7/src/version.cc gperf-2.7/src/version.cc
--- orig/gperf-2.7/src/version.cc Sat May 2 06:29:43 1998
+++ gperf-2.7/src/version.cc Tue Oct 6 16:04:56 1998
@@ -19,4 +19,4 @@ You should have received a copy of the G
along with GNU GPERF; see the file COPYING. If not, write to the Free
Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111, USA. */
-const char *version_string = "2.7";
+const char *version_string = "2.7.1 (19981006 egcs)";

View File

@@ -1,25 +0,0 @@
#! /usr/bin/perl -wi
# Fix up the output of cvs diff -c so that it works with patch.
# We do this by propagating the full pathname from the Index: line
# into the diff itself.
#
# Thrown together by Jason Merrill <jason@cygnus.com>
while (<>)
{
if (/^Index: (.*)/)
{
$full = $1;
print;
for (1..7)
{
$_ = <>;
s/ [^\t]+\t/ $full\t/;
print;
}
}
else
{
print;
}
}

View File

@@ -1,114 +0,0 @@
#! /bin/sh
# (C) 1998 Free Software Foundation
# Originally by Alexandre Oliva <oliva@dcc.unicamp.br>
# This script is Free Software, and it can be copied, distributed and
# modified as defined in the GNU General Public License. A copy of
# its license can be downloaded from http://www.gnu.org/copyleft/gpl.html
# This scripts assumes it lives in the contrib directory of the egcs
# source tree, so it will find the testsuite tree from its location.
# If you move it elsewhere, or want to use another testsuite tree, you
# can override the defaults with --srcdir=/some/dir/egcs or
# --testsuite=/some/dir/egcs/gcc/testsuite. If you specify
# --testsuite, --srcdir will be ignored; otherwise, `/gcc/testsuite'
# will be appended to the srcdir.
# You may specify where the binaries to be tested should be picked up
# from. If you specify --prefix=/some/dir, gcc, g++ and g77 will be
# looked for at /some/dir/bin. Each one may be overridden by
# specifying --with-gcc=/pathname/to/gcc, --with-g++=/pathname/to/g++
# and --with-g77=/pathname/to/g77. If you specify --without-gcc,
# --without-g++ or --without-g77, the test for the specified program
# will be skipped. By default, gcc, g++ and g77 will be searched in
# the PATH.
# An additional argument may specify --tmpdir=/some/dir; by default,
# temporaries will be stored in the current directory, where the log
# files will be stored.
# The script will interpret arguments until it finds one it does not
# understand. The remaining ones will be passed to `runtest'. A
# double-dash can be used to explicitly separate the arguments to
# `test_installed' from the ones to `runtest'.
# This script should be run in an empty directory; it will refuse to
# run if it finds a file named site.exp in the current directory.
if test -f site.exp; then
echo site.exp already exists >&2
exit 1
fi
while true; do
case "$1" in
--with-testsuite=*) testsuite=`echo "$1" | sed 's/[^=]*=//'`; shift;;
--srcdir=*) srcdir=`echo "$1" | sed 's/[^=]*=//'`; shift;;
--prefix=*) prefix=`echo "$1" | sed 's/[^=]*=//'`; shift;;
--with-gcc=*) GCC_UNDER_TEST=`echo "$1" | sed 's/[^=]*=//'`; shift;;
--with-g++=*) GXX_UNDER_TEST=`echo "$1" | sed 's/[^=]*=//'`; shift;;
--with-g77=*) G77_UNDER_TEST=`echo "$1" | sed 's/[^=]*=//'`; shift;;
--without-gcc) GCC_UNDER_TEST=no; shift;;
--without-g++) GXX_UNDER_TEST=no; shift;;
--without-g77) G77_UNDER_TEST=no; shift;;
--tmpdir=*) tmpdir=`echo "$1" | sed 's/[^=]*=//'`; shift;;
--help) cat <<\EOF
Runs the testsuite for an installed version of gcc/g++/g77
Copyright (C) 1998 Free Software Foundation
by Alexandre Oliva <oliva@dcc.unicamp.br>
Supported arguments:
--help prints this page
--with-testsuite=/some/dir/gcc/testsuite specify the testsuite directory
--srcdir=/some/dir same as --with-testsuite=/some/dir/gcc/testsuite
[deduced from shell-script pathname]
--prefix=/some/dir use gcc, g++ and g77 from /some/dir/bin [PATH]
--with-gcc=/some/dir/bin/gcc use specified gcc program [gcc]
--with-g++=/some/dir/bin/g++ use specified g++ program [g++]
--with-g77=/some/dir/bin/g77 use specified g77 program [g77]
--without-gcc do not run gcc testsuite
--without-g++ do not run g++ testsuite
--without-g77 do not run g77 testsuite
--tmpdir=/some/dir create temporaries and leave failed programs
at specified directory [.]
-- end of argument list; following arguments are passed to runtest
EOF
exit
;;
--) shift; break;;
*) break;;
esac
done
if test x"${testsuite+set}" != x"set" && test x"${srcdir+set}" != x"set"; then
file=$0
while [ -h $file ]; do
file=`ls -l $file | sed s/'.* -> '//`
done
srcdir=`CDPATH=. && cd \`echo "$file" | sed 's,/*[^/]*$,,;s,^$,.,'\`/.. >/dev/null && pwd`
fi
cat >site.exp <<EOF
set tmpdir "${tmpdir-`pwd`}"
set srcdir "${testsuite-${srcdir}/gcc/testsuite}"
set GCC_UNDER_TEST "${GCC_UNDER_TEST-${prefix}${prefix+/bin/}gcc}"
set GXX_UNDER_TEST "${GXX_UNDER_TEST-${prefix}${prefix+/bin/}g++}"
set G77_UNDER_TEST "${G77_UNDER_TEST-${prefix}${prefix+/bin/}g77}"
EOF
test x"${GCC_UNDER_TEST}" = x"no" || runtest --tool gcc ${1+"$@"}
test x"${GXX_UNDER_TEST}" = x"no" || runtest --tool g++ ${1+"$@"}
test x"${G77_UNDER_TEST}" = x"no" || runtest --tool g77 ${1+"$@"}
exit 0

View File

@@ -1,129 +0,0 @@
#! /bin/sh
# (C) 1998-1999 Free Software Foundation
# Originally by Alexandre Oliva <oliva@dcc.unicamp.br>
# This script is Free Software, and it can be copied, distributed and
# modified as defined in the GNU General Public License. A copy of
# its license can be downloaded from http://www.gnu.org/copyleft/gpl.html
# This script processes *.{sum,log} files, producing a shell-script
# that sends e-mail to the appropriate lists and renames files to
# *.sent. It currently handles only gcc, but it should be quite easy
# to modify it to handle other packages and its mailing lists.
# The scripts assumes it is run in the root directory of the build
# tree, and it will include all .sum files it finds in the mail
# report.
# configure flags are extracted from ./config.status
# if the BOOT_CFLAGS environment variable is set, it will be included
# in the mail report too.
# The usage pattern of this script is as follows:
# test_summary | more # so as to observe what should be done
# test_summary | sh # so as to actually send e-mail and move log files
# It accepts a few command line arguments. For example:
# -o: re-reads logs that have been mailed already (.sum.sent)
# -t: prevents logs from being renamed
# -p: prepend specified file (or list of files: -p "a b") to the report
# -i: append specified file (or list of files: -i "a b") to the report
# -m: specify the e-mail address to send notes to. An appropriate default
# should be selected from the log files.
# -f: force reports to be mailed; if omitted, only reports that differ
# from the sent.* version are sent.
# Find a good awk.
if test -z "$AWK" ; then
for AWK in gawk nawk awk ; do
if type $AWK 2>&1 | grep 'not found' > /dev/null 2>&1 ; then
:
else
break
fi
done
fi
: ${filesuffix=}; export fileprefix
: ${move=true}; export move
: ${forcemail=false}; export forcemail
while true; do
case "$1" in
-o) filesuffix=.sent; move=false; : ${mailto=nobody}; shift;;
-t) move=false; shift;;
-p) prepend_logs=${prepend_logs+"$prepend_logs "}"$2"; shift 2;;
-i) append_logs=${append_logs+"$append_logs "}"$2"; shift 2;;
-m) mailto=$2; forcemail=true; shift 2;;
-f) unset mailto; forcemail=true; shift;;
*) break;;
esac
done
: ${mailto="\" address \""}; export mailto
files=`find . -name \*.sum$filesuffix -print`
anyfile=false anychange=$forcemail &&
for file in $files; do
[ -f $file ] &&
anyfile=true &&
{ $anychange ||
anychange=`diff -u $file.sent $file 2>/dev/null |
if test ! -f $file.sent ||
egrep '^[-+](XPASS|FAIL)' >/dev/null; then
echo true
else
echo false
fi
`
}
true
done &&
$anyfile &&
if $forcemail || $anychange; then :; else mailto=nobody; fi &&
$AWK '
BEGIN {
lang="";
address="gcc-testresults@gcc.gnu.org";
version="gcc";
print "cat <<\EOF |";
'${prepend_logs+" system(\"cat $prepend_logs\"); "}'
}
$1 ~ /\/configure$/ { $1 = "configure flags:"; configflags = $0 }
/^Running target / { print ""; print; }
/^Target / { if (host != "") next; else host = $3; }
/^Native / { if (host != "") next; else host = $4; }
/^[ ]*=== [^ ]+ tests ===/ {
if (lang == "") lang = " "$2" "; else lang = " ";
}
/--disable-haifa/ { prefix="haifa-disabled "; }
/--enable-haifa/ { prefix="haifa-enabled "; }
$2 == "version" { save = $0; $1 = ""; $2 = ""; version = $0; gsub(/^ */, "", version); gsub(/\r$/, "", version); $0 = save; }
/\===.*Summary/ { print ""; print; blanks=1; }
/tests ===/ || /^(Target|Host|Native)/ || $2 == "version" { print; blanks=1; }
/^(XPASS|FAIL|# of )/ { print; }
# dumpall != 0 && /^X?(PASS|FAIL|UNTESTED)|^testcase/ { dumpall=0; }
# dumpall != 0 { print; }
# /^FAIL/ { dumpall=1; }
/^$/ && blanks>0 { print; --blanks; }
END { if (lang != "") {
print "";
print "Compiler version: " prefix version lang;
print "Platform: " host;
print configflags;
'${BOOT_CFLAGS+'print "BOOT_CFLAGS='"${BOOT_CFLAGS}"'";'}'
if (boot_cflags != 0) print boot_cflags;
'${append_logs+" system(\"cat $append_logs\"); "}'
print "EOF";
print "Mail -s \"Results for " prefix version lang "testsuite on " host "\" '"${mailto}"' &&";
}}
{ next; }
' ./config.status $files | sed "s/\([\`\$\\\\]\)/\\\\\\1/g" &&
if $move; then
for file in $files `ls -1 $files | sed s/sum$/log/`; do
[ -f $file ] && echo "mv `pwd`/$file `pwd`/$file.sent &&"
done
fi &&
echo true
exit 0

View File

@@ -1,193 +0,0 @@
#!/bin/sh
#
# This script parses the output of a gcc bootstrap when using warning
# flags and determines various statistics.
#
# usage: warn_summary [-llf] [-s stage] [-nosub|-ch|-cp|-f|-java]
# [-pass|-wpass] [file(s)]
#
# -llf
# Filter out long lines from the bootstap output before any other
# action. This is useful for systems with broken awks/greps which choke
# on long lines. It is not done by default as it sometimes slows things
# down.
#
# -s number
# Take warnings from stage "Number". Stage 0 means show warnings from
# before and after the gcc bootstrap directory. E.g. libraries, etc.
# This presupposes using "gcc -W*" for the stage1 compiler.
#
# -nosub
# Only show warnings from the gcc top level directory.
# -ch|-cp|-f|-java
# Only show warnings from the specified language subdirectory.
# These flags assume the output contains "Entering/Leaving" messages from
# gnu make. They override each other so only the last one takes effect.
#
# -pass
# Pass through the bootstrap output after filtering stage and subdir
# (useful for manual inspection.) This is all lines, not just warnings.
# -wpass
# Pass through only warnings from the bootstrap output after filtering
# stage and subdir.
#
# By Kaveh Ghazi (ghazi@caip.rutgers.edu) 12/13/97.
# Some awks choke on long lines, sed seems to do a better job.
# Truncate lines > 255 characters. RE '.\{255,\}' doesn't seem to work. :-(
# Only do this if -llf was specified, because it can really slow things down.
longLineFilter()
{
if test -z "$llf" ; then
cat $1
else
sed 's/^\(...............................................................................................................................................................................................................................................................\).*/\1/' $1
fi
}
# This function does one of three things. It either passes through
# all warning data, or passes through gcc toplevel warnings, or passes
# through a particular subdirectory set of warnings.
subdirectoryFilter()
{
longLineFilter $1 | (
if test -z "$filter" ; then
# Pass through all lines.
cat
else
if test "$filter" = nosub ; then
# Omit all subdirectories.
$AWK 'BEGIN{t=1} ; /Entering directory.*\/gcc\/[a-z]/{t--} ; /Leaving directory.*\/gcc\/[a-z]/{t++} ; {if(t==1)print}'
else
# Pass through only subdir $filter.
$AWK "BEGIN {t=-1} ; /^cd $filter; make/{t=0} ; /Entering directory .*\/gcc\/$filter/{t++} ; /Leaving directory .*\/gcc\/$filter/{t--} ; {if(t==1)print}"
fi
fi )
}
# This function displays all lines from stageN of the bootstrap. If
# stage==0, then show lines prior to stage1 and lines from after the last
# stage. I.e. utilities, libraries, etc.
stageNfilter()
{
if test "$stageN" -lt 1 ; then
# stage "0" means check everything *but* gcc.
$AWK "BEGIN{t=1} ; /^Bootstrapping the compiler/{t=0} ; /^Building runtime libraries/{t=1} ; {if(t==1)print}"
else
if test "$stageN" -eq 1 ; then
$AWK "/^Bootstrapping the compiler|^Building the C and C\+\+ compiler/{t=1} ; /stage$stageN/{t=0} ; {if(t==1)print}"
else
stageNminus1=`expr $stageN - 1`
$AWK "/stage$stageNminus1/{t=1} ; /stage$stageN/{t=0} ; {if(t==1)print}"
fi
fi
}
# This function displays lines containing warnings.
warningFilter()
{
grep ' warning: ' $1
}
# This function replaces `xxx' with `???', where xxx is usually some
# variable or function name. This allows similar warnings to be
# counted together when summarizing. However it avoids replacing
# certain C keywords which are known appear in various messages.
keywordFilter() {
sed 's/.*warning: //;
s/`\(int\)'"'"'/"\1"/g;
s/`\(long\)'"'"'/"\1"/g;
s/`\(char\)'"'"'/"\1"/g;
s/`\(inline\)'"'"'/"\1"/g;
s/`\(else\)'"'"'/"\1"/g;
s/`\(return\)'"'"'/"\1"/g;
s/`\(static\)'"'"'/"\1"/g;
s/`\(extern\)'"'"'/"\1"/g;
s/`\(const\)'"'"'/"\1"/g;
s/`\(noreturn\)'"'"'/"\1"/g;
s/`\(longjmp\)'"'"' or `\(vfork\)'"'"'/"\1" or "\2"/g;
s/`'"[^']*'/"'`???'"'/g;"'
s/.*format, .* arg (arg [0-9][0-9]*)/??? format, ??? arg (arg ???)/;
s/\([( ]\)arg [0-9][0-9]*\([) ]\)/\1arg ???\2/;
s/"\([^"]*\)"/`\1'"'"'/g'
}
# Start the main section.
usage="usage: `basename $0` [-llf] [-s stage] [-nosub|-ch|-cp|-f|-java] [-pass|-wpass] [file(s)]"
stageN=3
tmpfile=/tmp/tmp-warn.$$
# Remove $tmpfile on exit and various signals.
trap "rm -f $tmpfile" 0
trap "rm -f $tmpfile ; exit 1" 1 2 3 5 9 13 15
# Find a good awk.
if test -z "$AWK" ; then
for AWK in gawk nawk awk ; do
if type $AWK 2>&1 | grep 'not found' > /dev/null 2>&1 ; then
:
else
break
fi
done
fi
# Parse command line arguments.
while test -n "$1" ; do
case "$1" in
-llf) llf=1 ; shift ;;
-s) if test -z "$2"; then echo $usage; exit 1; fi; stageN="$2"; shift 2 ;;
-s*) stageN="`expr $1 : '-s\(.*\)'`" ; shift ;;
-nosub|-ch|-cp|-f|-java) filter="`expr $1 : '-\(.*\)'`" ; shift ;;
-pass) pass=1 ; shift ;;
-wpass) pass=w ; shift ;;
-*) echo $usage ; exit 1 ;;
*) break ;;
esac
done
# Check for a valid value of $stageN.
case "$stageN" in
[0-9]) ;;
*) echo "Stage <$stageN> must be in the range [0..9]." ; exit 1 ;;
esac
for file in "$@" ; do
subdirectoryFilter $file | stageNfilter > $tmpfile
# (Just) show me the warnings.
if test "$pass" != '' ; then
if test "$pass" = w ; then
warningFilter $tmpfile
else
cat $tmpfile
fi
continue
fi
if test -z "$filter" ; then
echo "Counting all warnings,"
else
if test "$filter" = nosub ; then
echo "Counting non-subdirectory warnings,"
else
echo "Counting warnings in the gcc/$filter subdirectory,"
fi
fi
count=`warningFilter $tmpfile | wc -l`
echo there are $count warnings in stage$stageN of this bootstrap.
echo
echo Number of warnings per file:
warningFilter $tmpfile | $AWK -F: '{print$1}' | sort | uniq -c | sort -nr
echo
echo Number of warning types:
warningFilter $tmpfile | keywordFilter | sort | uniq -c | sort -nr
done

View File

@@ -1,85 +1,3 @@
Sun Oct 24 23:54:10 PDT 1999 Jeff Law (law@cygnus.com)
* gcc-2.95.2 Released.
Mon Aug 16 01:29:24 PDT 1999 Jeff Law (law@cygnus.com)
* gcc-2.95.1 Released.
Wed Jul 28 21:39:31 PDT 1999 Jeff Law (law@cygnus.com)
* gcc-2.95 Released.
Sun Jul 25 23:40:51 PDT 1999 Jeff Law (law@cygnus.com)
* gcc-2.95 Released.
Mon Nov 23 16:46:10 1998 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* configure.in: Use AC_PREREQ(2.12.1).
Thu May 14 14:43:10 1998 Nick Clifton <nickc@cygnus.com>
* targetdoc/arm-interwork.texi: Document dlltool support of
interworking.
Thu May 7 16:49:38 1998 Jason Molenda (crash@bugshack.cygnus.com)
* Install.in: Remove references to TCL_LIBRARY, TK_LIBRARY,
and GDBTK_FILENAME.
Wed Apr 1 17:11:44 1998 Nick Clifton <nickc@cygnus.com>
* targetdoc/arm-interwork.texi: Document ARM/thumb interworking.
Tue Mar 31 15:28:20 1998 Ian Lance Taylor <ian@cygnus.com>
* standards.texi, make-stds.texi: Update to current FSF versions.
* Makefile.in (standards.info): Depend upon make-std.texi.
Tue Mar 24 16:13:26 1998 Stu Grossman <grossman@bhuna.cygnus.co.uk>
* configure: Regenerate with autoconf 2.12.1 to fix shell issues
for NT native builds.
Mon Mar 9 16:41:04 1998 Doug Evans <devans@canuck.cygnus.com>
* make-rel-sym-tree (binprogs): Add objcopy.
Tue Feb 24 18:11:58 1998 Doug Evans <devans@canuck.cygnus.com>
* make-rel-sym-tree: as.new -> as-new, ld.new -> ld-new
nm.new -> nm-new. Make symlinks to crt*.o.
Fri Nov 21 12:54:58 1997 Manfred Hollstein <manfred@s-direktnet.de>
* Makefile.in: Add --no-split argument to avoid creating files
with names longer than 14 characters.
Tue Oct 7 16:27:34 1997 Manfred Hollstein <manfred@s-direktnet.de>
* aclocal.m4: Substitute INSTALL.
* configure: Re-built.
Thu Sep 25 13:13:11 1997 Jason Molenda (crash@pern.cygnus.com)
* intro.texi: Add closing ifset.
Mon Sep 15 22:53:01 1997 Jeffrey A Law (law@cygnus.com)
* aclocal.m4: New file with replacement for AC_PROG_INSTALL.
* configure.in: Use EGCS_PROG_INSTALL.
Mon Sep 1 10:31:32 1997 Angela Marie Thomas (angela@cygnus.com)
* Install.in: Move setting HOST and TARGET to the beginning
of the file for editing convenience.
Mon Sep 1 10:28:37 1997 Angela Marie Thomas (angela@cygnus.com)
* Install.in.: More friendly options/messages when extracting
from a file instead of a tape device.
Tue Jun 17 15:50:23 1997 Angela Marie Thomas (angela@cygnus.com)
* Install.in: Add /usr/bsd to PATH for Irix (home of compress)

View File

@@ -59,8 +59,8 @@ install-info: info
dvi: $(DVIFILES)
standards.info: $(srcdir)/standards.texi $(srcdir)/make-stds.texi
$(MAKEINFO) --no-split -I$(srcdir) -o standards.info $(srcdir)/standards.texi
standards.info: $(srcdir)/standards.texi
$(MAKEINFO) -I$(srcdir) -o standards.info $(srcdir)/standards.texi
standards.dvi: $(srcdir)/standards.texi
TEXINPUTS=$(TEXIDIR):$$TEXINPUTS $(TEXI2DVI) $(srcdir)/standards.texi

63
etc/aclocal.m4 vendored
View File

@@ -1,63 +0,0 @@
AC_DEFUN(EGCS_PROG_INSTALL,
[AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
# Find a good install program. We prefer a C program (faster),
# so one script is as good as another. But avoid the broken or
# incompatible versions:
# SysV /etc/install, /usr/sbin/install
# SunOS /usr/etc/install
# IRIX /sbin/install
# AIX /bin/install
# AFS /usr/afsws/bin/install, which mishandles nonexistent args
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
AC_MSG_CHECKING(for a BSD compatible install)
if test -z "$INSTALL"; then
AC_CACHE_VAL(ac_cv_path_install,
[ IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
for ac_dir in $PATH; do
# Account for people who put trailing slashes in PATH elements.
case "$ac_dir/" in
/|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
*)
# OSF1 and SCO ODT 3.0 have their own names for install.
for ac_prog in ginstall scoinst install; do
if test -f $ac_dir/$ac_prog; then
if test $ac_prog = install &&
grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
# AIX install. It has an incompatible calling convention.
# OSF/1 installbsd also uses dspmsg, but is usable.
:
else
ac_cv_path_install="$ac_dir/$ac_prog -c"
break 2
fi
fi
done
;;
esac
done
IFS="$ac_save_IFS"
])dnl
if test "${ac_cv_path_install+set}" = set; then
INSTALL="$ac_cv_path_install"
else
# As a last resort, use the slow shell script. We don't cache a
# path for INSTALL within a source directory, because that will
# break other packages using the cache if that directory is
# removed, or if the path is relative.
INSTALL="$ac_install_sh"
fi
fi
dnl We do special magic for INSTALL instead of AC_SUBST, to get
dnl relative paths right.
AC_MSG_RESULT($INSTALL)
AC_SUBST(INSTALL)dnl
# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
# It thinks the first close brace ends the variable substitution.
test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
AC_SUBST(INSTALL_PROGRAM)dnl
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
AC_SUBST(INSTALL_DATA)dnl
])

21
etc/configure vendored
View File

@@ -1,7 +1,7 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated automatically using autoconf version 2.12.1
# Generated automatically using autoconf version 2.12
# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
#
# This configure script is free software; the Free Software Foundation
@@ -49,7 +49,6 @@ mandir='${prefix}/man'
# Initialize some other variables.
subdirs=
MFLAGS= MAKEFLAGS=
SHELL=${CONFIG_SHELL-/bin/sh}
# Maximum number of lines to put in a shell here document.
ac_max_here_lines=12
@@ -333,7 +332,7 @@ EOF
verbose=yes ;;
-version | --version | --versio | --versi | --vers)
echo "configure generated by autoconf version 2.12.1"
echo "configure generated by autoconf version 2.12"
exit 0 ;;
-with-* | --with-*)
@@ -550,7 +549,7 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
echo "configure:554: checking for a BSD compatible install" >&5
echo "configure:553: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -562,7 +561,7 @@ else
/|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
*)
# OSF1 and SCO ODT 3.0 have their own names for install.
for ac_prog in ginstall scoinst install; do
for ac_prog in ginstall installbsd scoinst install; do
if test -f $ac_dir/$ac_prog; then
if test $ac_prog = install &&
grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
@@ -623,7 +622,7 @@ EOF
# Ultrix sh set writes to stderr and can't be redirected directly,
# and sets the high bit in the cache file unless we assign to the vars.
(set) 2>&1 |
case `(ac_space=' '; set) 2>&1 | grep ac_space` in
case `(ac_space=' '; set) 2>&1` in
*ac_space=\ *)
# `set' does not quote correctly, so add quotes (double-quote substitution
# turns \\\\ into \\, and sed turns \\ into \).
@@ -702,7 +701,7 @@ do
echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
-version | --version | --versio | --versi | --vers | --ver | --ve | --v)
echo "$CONFIG_STATUS generated by autoconf version 2.12.1"
echo "$CONFIG_STATUS generated by autoconf version 2.12"
exit 0 ;;
-help | --help | --hel | --he | --h)
echo "\$ac_cs_usage"; exit 0 ;;
@@ -711,6 +710,7 @@ do
done
ac_given_srcdir=$srcdir
ac_given_INSTALL="$INSTALL"
trap 'rm -fr `echo "Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
EOF
@@ -721,7 +721,6 @@ sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
$ac_vpsub
$extrasub
s%@SHELL@%$SHELL%g
s%@CFLAGS@%$CFLAGS%g
s%@CPPFLAGS@%$CPPFLAGS%g
s%@CXXFLAGS@%$CXXFLAGS%g
@@ -743,7 +742,6 @@ s%@includedir@%$includedir%g
s%@oldincludedir@%$oldincludedir%g
s%@infodir@%$infodir%g
s%@mandir@%$mandir%g
s%@INSTALL@%$INSTALL%g
s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
s%@INSTALL_DATA@%$INSTALL_DATA%g
@@ -822,6 +820,10 @@ for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
top_srcdir="$ac_dots$ac_given_srcdir" ;;
esac
case "$ac_given_INSTALL" in
[/$]*) INSTALL="$ac_given_INSTALL" ;;
*) INSTALL="$ac_dots$ac_given_INSTALL" ;;
esac
echo creating "$ac_file"
rm -f "$ac_file"
@@ -837,6 +839,7 @@ for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
s%@configure_input@%$configure_input%g
s%@srcdir@%$srcdir%g
s%@top_srcdir@%$top_srcdir%g
s%@INSTALL@%$INSTALL%g
" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
fi; done
rm -f conftest.s*

View File

@@ -1,7 +1,7 @@
dnl Process this file with autoconf to produce a configure script.
AC_PREREQ(2.12.1)
AC_PREREQ(2.5)
AC_INIT(Makefile.in)
EGCS_PROG_INSTALL
AC_PROG_INSTALL
AC_OUTPUT(Makefile)

View File

@@ -79,7 +79,7 @@ foo.1 : foo.man sedscript
@noindent
will fail when the build directory is not the source directory, because
@file{foo.man} and @file{sedscript} are in the source directory.
@file{foo.man} and @file{sedscript} are in the the source directory.
When using GNU @code{make}, relying on @samp{VPATH} to find the source
file will work in the case where there is a single dependency file,
@@ -209,12 +209,11 @@ don't need to replace them with other programs.
Each program-name variable should come with an options variable that is
used to supply options to the program. Append @samp{FLAGS} to the
program-name variable name to get the options variable name---for
example, @code{BISONFLAGS}. (The names @code{CFLAGS} for the C
compiler, @code{YFLAGS} for yacc, and @code{LFLAGS} for lex, are
exceptions to this rule, but we keep them because they are standard.)
Use @code{CPPFLAGS} in any compilation command that runs the
preprocessor, and use @code{LDFLAGS} in any compilation command that
does linking as well as in any direct use of @code{ld}.
example, @code{BISONFLAGS}. (The name @code{CFLAGS} is an exception to
this rule, but we keep it because it is standard.) Use @code{CPPFLAGS}
in any compilation command that runs the preprocessor, and use
@code{LDFLAGS} in any compilation command that does linking as well as
in any direct use of @code{ld}.
If there are C compiler options that @emph{must} be used for proper
compilation of certain files, do not include them in @code{CFLAGS}.
@@ -240,9 +239,6 @@ Put @code{CFLAGS} last in the compilation command, after other variables
containing compiler options, so the user can use @code{CFLAGS} to
override the others.
@code{CFLAGS} should be used in every invocation of the C compiler,
both those which do compilation and those which do linking.
Every Makefile should define the variable @code{INSTALL}, which is the
basic command for installing a file into the system.
@@ -257,18 +253,6 @@ $(INSTALL_PROGRAM) foo $(bindir)/foo
$(INSTALL_DATA) libfoo.a $(libdir)/libfoo.a
@end example
Optionally, you may prepend the value of @code{DESTDIR} to the target
filename. Doing this allows the installer to create a snapshot of the
installation to be copied onto the real target filesystem later. Do not
set the value of @code{DESTDIR} in your Makefile, and do not include it
in any installed files. With support for @code{DESTDIR}, the above
examples become:
@example
$(INSTALL_PROGRAM) foo $(DESTDIR)$(bindir)/foo
$(INSTALL_DATA) libfoo.a $(DESTDIR)$(libdir)/libfoo.a
@end example
@noindent
Always use a file name, not a directory name, as the second argument of
the installation commands. Use a separate command for each file to be
@@ -295,10 +279,6 @@ When building the complete GNU system, the prefix will be empty and
@file{/usr} will be a symbolic link to @file{/}.
(If you are using Autoconf, write it as @samp{@@prefix@@}.)
Running @samp{make install} with a different value of @code{prefix}
from the one used to build the program should @var{not} recompile
the program.
@item exec_prefix
A prefix used in constructing the default values of some of the
variables listed below. The default value of @code{exec_prefix} should
@@ -308,10 +288,6 @@ be @code{$(prefix)}.
Generally, @code{$(exec_prefix)} is used for directories that contain
machine-specific files (such as executables and subroutine libraries),
while @code{$(prefix)} is used directly for other directories.
Running @samp{make install} with a different value of @code{exec_prefix}
from the one used to build the program should @var{not} recompile the
program.
@end table
Executable programs are installed in one of the following directories.
@@ -379,11 +355,14 @@ files. This directory should normally be @file{/usr/local/etc}, but
write it as @file{$(prefix)/etc}.
(If you are using Autoconf, write it as @samp{@@sysconfdir@@}.)
Do not install executables here in this directory (they probably belong
in @file{$(libexecdir)} or @file{$(sbindir)}). Also do not install
files that are modified in the normal course of their use (programs
whose purpose is to change the configuration of the system excluded).
Those probably belong in @file{$(localstatedir)}.
@c rewritten to avoid overfull hbox --tower
Do not install executables
@c here
in this directory (they probably
belong in @file{$(libexecdir)} or @file{$(sbindir)}). Also do not
install files that are modified in the normal course of their use
(programs whose purpose is to change the configuration of the system
excluded). Those probably belong in @file{$(localstatedir)}.
@item sharedstatedir
The directory for installing architecture-independent data files which
@@ -436,7 +415,7 @@ should normally be @file{/usr/local/include}, but write it as
@file{$(prefix)/include}.
(If you are using Autoconf, write it as @samp{@@includedir@@}.)
Most compilers other than GCC do not look for header files in directory
Most compilers other than GCC do not look for header files in
@file{/usr/local/include}. So installing the header files this way is
only useful with GCC. Sometimes this is not a problem because some
libraries are only really intended to work with GCC. But some libraries
@@ -588,12 +567,12 @@ Here is a sample rule to install an Info file:
@comment This example has been carefully formatted for the Make manual.
@comment Please do not reformat it without talking to roland@gnu.ai.mit.edu.
@smallexample
$(DESTDIR)$(infodir)/foo.info: foo.info
$(infodir)/foo.info: foo.info
$(POST_INSTALL)
# There may be a newer info file in . than in srcdir.
-if test -f foo.info; then d=.; \
else d=$(srcdir); fi; \
$(INSTALL_DATA) $$d/foo.info $(DESTDIR)$@@; \
$(INSTALL_DATA) $$d/foo.info $@@; \
# Run install-info only if it exists.
# Use `if' instead of just prepending `-' to the
# line so we notice real errors from install-info.
@@ -601,8 +580,8 @@ $(DESTDIR)$(infodir)/foo.info: foo.info
# fail gracefully when there is an unknown command.
if $(SHELL) -c 'install-info --version' \
>/dev/null 2>&1; then \
install-info --dir-file=$(DESTDIR)$(infodir)/dir \
$(DESTDIR)$(infodir)/foo.info; \
install-info --dir-file=$(infodir)/dir \
$(infodir)/foo.info; \
else true; fi
@end smallexample
@@ -745,7 +724,7 @@ The easiest way to do this is to create a subdirectory appropriately
named, use @code{ln} or @code{cp} to install the proper files in it, and
then @code{tar} that subdirectory.
Compress the tar file with @code{gzip}. For example, the actual
Compress the tar file file with @code{gzip}. For example, the actual
distribution file for GCC version 1.40 is called @file{gcc-1.40.tar.gz}.
The @code{dist} target should explicitly depend on all non-source files

View File

@@ -2,8 +2,8 @@
@c %**start of header
@setfilename standards.info
@settitle GNU Coding Standards
@c This date is automagically updated when you save this file:
@set lastupdate March 13, 1998
@c UPDATE THIS DATE WHENEVER YOU MAKE CHANGES!
@set lastupdate 16 January 1997
@c %**end of header
@ifinfo
@@ -28,7 +28,7 @@ END-INFO-DIR-ENTRY
@ifinfo
GNU Coding Standards
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
Copyright (C) 1992, 1993, 1994, 1995, 1996 Free Software Foundation, Inc.
Permission is granted to make and distribute verbatim copies of
this manual provided the copyright notice and this permission notice
@@ -59,7 +59,7 @@ by the Free Software Foundation.
@page
@vskip 0pt plus 1filll
Copyright @copyright{} 1992, 1993, 1994, 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
Copyright @copyright{} 1992, 1993, 1994, 1995, 1996 Free Software Foundation, Inc.
Permission is granted to make and distribute verbatim copies of
this manual provided the copyright notice and this permission notice
@@ -104,8 +104,8 @@ programs written in C, but many of the rules and principles are useful
even if you write in another programming language. The rules often
state reasons for writing in a certain way.
Corrections or suggestions for this document should be sent to
@email{gnu@@gnu.org}. If you make a suggestion, please include a
Corrections or suggestions regarding this document should be sent to
@code{gnu@@prep.ai.mit.edu}. If you make a suggestion, please include a
suggested new wording for it; our time is limited. We prefer a context
diff to the @file{standards.texi} or @file{make-stds.texi} files, but if
you don't have those files, please mail your suggestion anyway.
@@ -168,18 +168,14 @@ contributor to a program must sign some sort of legal papers in order
for us to have clear title to the program. The main author alone is not
enough.
So, before adding in any contributions from other people, please tell
us, so we can arrange to get the papers. Then wait until we tell you
So, before adding in any contributions from other people, tell us
so we can arrange to get the papers. Then wait until we tell you
that we have received the signed papers, before you actually use the
contribution.
This applies both before you release the program and afterward. If
you receive diffs to fix a bug, and they make significant changes, we
need legal papers for that change.
This also applies to comments and documentation files. For copyright
law, comments and code are just text. Copyright applies to all kinds of
text, so we need legal papers for all kinds.
need legal papers for it.
You don't need papers for changes of a few lines here or there, since
they are not significant for copyright purposes. Also, you don't need
@@ -196,10 +192,6 @@ The very worst thing is if you forget to tell us about the other
contributor. We could be very embarrassed in court some day as a
result.
We have more detailed advice for maintainers of programs; if you have
reached the stage of actually maintaining a program for GNU (whether
released or not), please ask us for a copy.
@node Design Advice
@chapter General Program Design
@@ -244,6 +236,9 @@ completely with something totally different and better. (For example,
feature as well. (There is a free @code{vi} clone, so we offer it.)
Additional useful features not in Berkeley Unix are welcome.
Additional programs with no counterpart in Unix may be useful,
but our first priority is usually to duplicate what Unix already
has.
@node Using Extensions
@section Using Non-standard Features
@@ -328,16 +323,13 @@ write in @sc{ansi} C.
Using a language other than C is like using a non-standard feature: it
will cause trouble for users. Even if GCC supports the other language,
users may find it inconvenient to have to install the compiler for that
other language in order to build your program. For example, if you
write your program in C++, people will have to install the C++ compiler
in order to compile your program. Thus, it is better if you write in C.
other language in order to build your program. So please write in C.
But there are three situations when there is no disadvantage in using
some other language:
There are three exceptions for this rule:
@itemize @bullet
@item
It is okay to use another language if your program contains an
It is okay to use a special language if the same program contains an
interpreter for that language.
For example, if your program links with GUILE, it is ok to write part of
@@ -351,14 +343,10 @@ This is okay because the only people who want to build the tool will be
those who have installed the other language anyway.
@item
If an application is of interest to a narrow community, then perhaps
If an application is not of extremely widespread interest, then perhaps
it's not important if the application is inconvenient to install.
@end itemize
C has one other advantage over C++ and other compiled languages: more
people know C, so more people will find it easy to read and modify the
program if it is written in C.
@node Program Behavior
@chapter Program Behavior for All Programs
@@ -618,10 +606,10 @@ you can do so by printing an additional line of version info for each
library you want to mention. Use the same format for these lines as for
the first line.
Please do not mention all of the libraries that the program uses ``just
for completeness''---that would produce a lot of unhelpful clutter.
Please mention library version numbers only if you find in practice that
they are very important to you in debugging.
Please don't mention all the libraries that the program uses ``just for
completeness''---that would produce a lot of unhelpful clutter. Please
mention library version numbers only if you find in practice that they
are very important to you in debugging.
The following line, after the version number line or lines, should be a
copyright notice. If more than one copyright notice is called for, put
@@ -640,12 +628,10 @@ Here's an example of output that follows these rules:
@smallexample
GNU Emacs 19.34.5
Copyright (C) 1996 Free Software Foundation, Inc.
GNU Emacs comes with NO WARRANTY,
to the extent permitted by law.
GNU Emacs comes with NO WARRANTY, to the extent permitted by law.
You may redistribute copies of GNU Emacs
under the terms of the GNU General Public License.
For more information about these matters,
see the files named COPYING.
For more information about these matters, see the files named COPYING.
@end smallexample
You should adapt this to your program, of course, filling in the proper
@@ -678,7 +664,7 @@ Report bugs to @var{mailing-address}.
Here is a table of long options used by GNU programs. It is surely
incomplete, but we aim to list all the options that a new program might
want to be compatible with. If you use names not already in the table,
please send @email{gnu@@gnu.org} a list of them, with their
please send @samp{gnu@@prep.ai.mit.edu} a list of them, with their
meanings, so we can update the table.
@c Please leave newlines between items in this table; it's much easier
@@ -1173,7 +1159,7 @@ Used in @code{su}.
@item machine
No listing of which programs already use this;
someone should check to
see if any actually do, and tell @email{gnu@@gnu.org}.
see if any actually do and tell @code{gnu@@prep.ai.mit.edu}.
@item macro-name
@samp{-M} in @code{ptx}.
@@ -1976,11 +1962,6 @@ its sense}. @samp{#else} should have a comment describing the condition
@dots{}
#endif /* not foo */
@end group
@group
#ifdef foo
@dots{}
#endif /* foo */
@end group
@end example
@noindent
@@ -1994,13 +1975,9 @@ but, by contrast, write the comments this way for a @samp{#ifndef}:
@dots{}
#endif /* foo */
@end group
@group
#ifndef foo
@dots{}
#endif /* not foo */
@end group
@end example
@node Syntactic Conventions
@section Clean Use of C Constructs
@@ -2456,7 +2433,7 @@ printf ((nfiles != 1 ? gettext ("%d files processed")
@end example
@noindent
This can be any method of forming the plural of the word for ``file'', and
This can any method of forming the plural of the word for ``file'', and
also handles languages that require agreement in the word for
``processed''.
@@ -2593,7 +2570,7 @@ also contain this information. If the manual is changing more
frequently than or independent of the program, also state a version
number for the manual in both of these places.
Each program documented in the manual should have a node named
Each program documented in the manual should should have a node named
@samp{@var{program} Invocation} or @samp{Invoking @var{program}}. This
node (together with its subnodes, if any) should describe the program's
command line arguments and how to run it (the sort of information people
@@ -2947,12 +2924,9 @@ to work with @var{package}.
@c Giving an optional @var{parameter} of
@c @samp{no} should omit @var{package}, if it is used by default.
Possible values of @var{package} include
@samp{gnu-as} (or @samp{gas}), @samp{gnu-ld}, @samp{gnu-libc},
@samp{gdb},
@samp{x},
and
@samp{x-toolkit}.
Possible values of @var{package} include @samp{x}, @samp{x-toolkit},
@samp{gnu-as} (or @samp{gas}), @samp{gnu-ld}, @samp{gnu-libc}, and
@samp{gdb}.
Do not use a @samp{--with} option to specify the file name to use to
find certain files. That is outside the scope of what @samp{--with}
@@ -3019,9 +2993,9 @@ ignore most of its arguments.
@node Releases
@section Making Releases
Package the distribution of @code{Foo version 69.96} up in a gzipped tar
file with the name @file{foo-69.96.tar.gz}. It should unpack into a
subdirectory named @file{foo-69.96}.
Package the distribution of Foo version 69.96 in a gzipped tar file
named @file{foo-69.96.tar.gz}. It should unpack into a subdirectory
named @file{foo-69.96}.
Building and installing the program should never modify any of the files
contained in the distribution. This means that all the files that form
@@ -3085,9 +3059,3 @@ other files to get.
@contents
@bye
Local variables:
update-date-leading-regexp: "@c This date is automagically updated when you save this file:\n@set lastupdate "
update-date-trailing-regexp: ""
eval: (load "/gd/gnuorg/update-date.el")
eval: (add-hook 'write-file-hooks 'update-date)
End:

View File

@@ -1,3 +0,0 @@
genrtl
genrtl.h
genrtl.c

View File

@@ -86,17 +86,10 @@ In cc1plus, print the current binding stack, frame by frame, up to and
including the global binding level.
end
# Put breakpoints at exit and fancy_abort in case abort is mapped
# to either fprintf/exit or fancy_abort.
b exit
b fancy_abort
# Don't let abort actually run, as it will make
# stdio stop working and therefore the `pr' command below as well.
b abort
# Make gdb complain about symbol reading errors. This is so that gcc
# developers can see and fix bugs in gcc debug output.
set complaints 20
# Don't let abort actually run, as it will make
# stdio stop working and therefore the `pr' command above as well.
# Put this last because gcc does not reference it any more unless
# USE_SYSTEM_ABORT is defined, so gdb may complain and bail out.
b abort

View File

@@ -1,542 +0,0 @@
Notes on GCC's Native Language Support
GCC's Native Language Support (NLS) is relatively new and
experimental, so NLS is currently disabled by default. Use
configure's --enable-nls option to enable it. Eventually, NLS will be
enabled by default, and you'll need --disable-nls to disable it. You
must enable NLS in order to make a GCC distribution.
By and large, only diagnostic messages have been internationalized.
Some work remains in other areas; for example, GCC does not yet allow
non-ASCII letters in identifiers.
Not all of GCC's diagnostic messages have been internationalized.
Programs like `enquire' and `genattr' are not internationalized, as
their users are GCC maintainers who typically need to be able to read
English anyway; internationalizing them would thus entail needless
work for the human translators. And no one has yet gotten around to
internationalizing the messages in the C++ compiler, or in the
specialized MIPS-specific programs mips-tdump and mips-tfile.
The GCC library should not contain any messages that need
internationalization, because it operates below the
internationalization library.
Currently, the only language translation supplied is en_UK (British English).
Unlike some other GNU programs, the GCC sources contain few instances
of explicit translation calls like _("string"). Instead, the
diagnostic printing routines automatically translate their arguments.
For example, GCC source code should not contain calls like `error
(_("unterminated comment"))'; it should contain calls like `error
("unterminated comment")' instead, as it is the `error' function's
responsibility to translate the message before the user sees it.
By convention, any function parameter in the GCC sources whose name
ends in `msgid' is expected to be a message requiring translation.
For example, the `error' function's first parameter is named `msgid'.
GCC's exgettext script uses this convention to determine which
function parameter strings need to be translated. The exgettext
script also assumes that any occurrence of `%eMSGID}' on a source
line, where MSGID does not contain `%' or `}', corresponds to a
message MSGID that requires translation; this is needed to identify
diagnostics in GCC spec strings.
If you enable NLS and modify source files, you'll need to use a
special version of the GNU gettext package to propagate the
modifications to the translation tables. Apply the following patch
(use `patch -p0') to GNU gettext 0.10.35, which you can retrieve from:
ftp://alpha.gnu.org/gnu/gettext-0.10.35.tar.gz
This patch has been submitted to the GNU gettext maintainer, so
eventually we shouldn't need this special gettext version.
This patch is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
This patch is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this patch; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA.
1998-07-26 Paul Eggert <eggert@twinsun.com>
* po/Makefile.in.in (maintainer-clean): Remove cat-id-tbl.c and
stamp-cat-id.
1998-07-24 Paul Eggert <eggert@twinsun.com>
* po/Makefile.in.in (cat-id-tbl.o): Depend on
$(top_srcdir)/intl/libgettext.h, not ../intl/libgettext.h.
1998-07-20 Paul Eggert <eggert@twinsun.com>
* po/Makefile.in.in (.po.pox, all-yes, $(srcdir)/cat-id-tbl.c,
$(srcdir)/stamp-cat-id, update-po): Prepend `$(srcdir)/' to
files built in the source directory; this is needed for
VPATH-based make in Solaris 2.6.
1998-07-17 Paul Eggert <eggert@twinsun.com>
Add support for user-specified argument numbers for keywords.
Extract all strings from a keyword arg, not just the first one.
Handle parenthesized commas inside keyword args correctly.
Warn about nested keywords.
* doc/gettext.texi: Document --keyword=id:argnum.
* src/xgettext.c (scan_c_file):
Warn about nested keywords, e.g. _(_("xxx")).
Warn also about not-yet-implemented but allowed nesting, e.g.
dcgettext(..._("xxx")..., "yyy").
Get all strings in a keyword arg, not just the first one.
Handle parenthesized commas inside keyword args correctly.
* src/xget-lex.h (enum xgettext_token_type_ty):
Replace xgettext_token_type_keyword1 and
xgettext_token_type_keyword2 with just plain
xgettext_token_type_keyword; it now has argnum value.
Add xgettext_token_type_rp.
(struct xgettext_token_ty): Add argnum member.
line_number and file_name are now also set for
xgettext_token_type_keyword.
(xgettext_lex_keyword): Arg is const char *.
* src/xget-lex.c: Include "hash.h".
(enum token_type_ty): Add token_type_rp.
(keywords): Now a hash table.
(phase5_get): Return token_type_rp for ')'.
(xgettext_lex, xgettext_lex_keyword): Add support for keyword argnums.
(xgettext_lex): Return xgettext_token_type_rp for ')'.
Report keyword argnum, line number, and file name back to caller.
1998-07-09 Paul Eggert <eggert@twinsun.com>
* intl/Makefile.in (uninstall):
Do nothing unless $(PACKAGE) is gettext.
===================================================================
RCS file: doc/gettext.texi,v
retrieving revision 0.10.35.0
retrieving revision 0.10.35.1
diff -pu -r0.10.35.0 -r0.10.35.1
--- doc/gettext.texi 1998/05/01 05:53:32 0.10.35.0
+++ doc/gettext.texi 1998/07/18 00:25:15 0.10.35.1
@@ -1854,13 +1854,19 @@ List of directories searched for input f
Join messages with existing file.
@item -k @var{word}
-@itemx --keyword[=@var{word}]
-Additonal keyword to be looked for (without @var{word} means not to
+@itemx --keyword[=@var{keywordspec}]
+Additonal keyword to be looked for (without @var{keywordspec} means not to
use default keywords).
-The default keywords, which are always looked for if not explicitly
-disabled, are @code{gettext}, @code{dgettext}, @code{dcgettext} and
-@code{gettext_noop}.
+If @var{keywordspec} is a C identifer @var{id}, @code{xgettext} looks
+for strings in the first argument of each call to the function or macro
+@var{id}. If @var{keywordspec} is of the form
+@samp{@var{id}:@var{argnum}}, @code{xgettext} looks for strings in the
+@var{argnum}th argument of the call.
+
+The default keyword specifications, which are always looked for if not
+explicitly disabled, are @code{gettext}, @code{dgettext:2},
+@code{dcgettext:2} and @code{gettext_noop}.
@item -m [@var{string}]
@itemx --msgstr-prefix[=@var{string}]
===================================================================
RCS file: intl/Makefile.in,v
retrieving revision 0.10.35.0
retrieving revision 0.10.35.1
diff -pu -r0.10.35.0 -r0.10.35.1
--- intl/Makefile.in 1998/04/27 21:53:18 0.10.35.0
+++ intl/Makefile.in 1998/07/09 21:39:18 0.10.35.1
@@ -143,10 +143,14 @@ install-data: all
installcheck:
uninstall:
- dists="$(DISTFILES.common)"; \
- for file in $$dists; do \
- rm -f $(gettextsrcdir)/$$file; \
- done
+ if test "$(PACKAGE)" = "gettext"; then \
+ dists="$(DISTFILES.common)"; \
+ for file in $$dists; do \
+ rm -f $(gettextsrcdir)/$$file; \
+ done
+ else \
+ : ; \
+ fi
info dvi:
===================================================================
RCS file: src/xget-lex.c,v
retrieving revision 0.10.35.0
retrieving revision 0.10.35.1
diff -pu -r0.10.35.0 -r0.10.35.1
--- src/xget-lex.c 1998/07/09 22:49:48 0.10.35.0
+++ src/xget-lex.c 1998/07/18 00:25:15 0.10.35.1
@@ -33,6 +33,7 @@
#include "error.h"
#include "system.h"
#include "libgettext.h"
+#include "hash.h"
#include "str-list.h"
#include "xget-lex.h"
@@ -83,6 +84,7 @@ enum token_type_ty
token_type_eoln,
token_type_hash,
token_type_lp,
+ token_type_rp,
token_type_comma,
token_type_name,
token_type_number,
@@ -109,7 +111,7 @@ static FILE *fp;
static int trigraphs;
static int cplusplus_comments;
static string_list_ty *comment;
-static string_list_ty *keywords;
+static hash_table keywords;
static int default_keywords = 1;
/* These are for tracking whether comments count as immediately before
@@ -941,6 +943,10 @@ phase5_get (tp)
tp->type = token_type_lp;
return;
+ case ')':
+ tp->type = token_type_rp;
+ return;
+
case ',':
tp->type = token_type_comma;
return;
@@ -1179,6 +1185,7 @@ xgettext_lex (tp)
while (1)
{
token_ty token;
+ void *keyword_value;
phase8_get (&token);
switch (token.type)
@@ -1213,17 +1220,20 @@ xgettext_lex (tp)
if (default_keywords)
{
xgettext_lex_keyword ("gettext");
- xgettext_lex_keyword ("dgettext");
- xgettext_lex_keyword ("dcgettext");
+ xgettext_lex_keyword ("dgettext:2");
+ xgettext_lex_keyword ("dcgettext:2");
xgettext_lex_keyword ("gettext_noop");
default_keywords = 0;
}
- if (string_list_member (keywords, token.string))
- {
- tp->type = (strcmp (token.string, "dgettext") == 0
- || strcmp (token.string, "dcgettext") == 0)
- ? xgettext_token_type_keyword2 : xgettext_token_type_keyword1;
+ if (find_entry (&keywords, token.string, strlen (token.string),
+ &keyword_value)
+ == 0)
+ {
+ tp->type = xgettext_token_type_keyword;
+ tp->argnum = (int) keyword_value;
+ tp->line_number = token.line_number;
+ tp->file_name = logical_file_name;
}
else
tp->type = xgettext_token_type_symbol;
@@ -1236,6 +1246,12 @@ xgettext_lex (tp)
tp->type = xgettext_token_type_lp;
return;
+ case token_type_rp:
+ last_non_comment_line = newline_count;
+
+ tp->type = xgettext_token_type_rp;
+ return;
+
case token_type_comma:
last_non_comment_line = newline_count;
@@ -1263,16 +1279,32 @@ xgettext_lex (tp)
void
xgettext_lex_keyword (name)
- char *name;
+ const char *name;
{
if (name == NULL)
default_keywords = 0;
else
{
- if (keywords == NULL)
- keywords = string_list_alloc ();
+ int argnum;
+ size_t len;
+ const char *sp;
+
+ if (keywords.table == NULL)
+ init_hash (&keywords, 100);
+
+ sp = strchr (name, ':');
+ if (sp)
+ {
+ len = sp - name;
+ argnum = atoi (sp + 1);
+ }
+ else
+ {
+ len = strlen (name);
+ argnum = 1;
+ }
- string_list_append_unique (keywords, name);
+ insert_entry (&keywords, name, len, (void *) argnum);
}
}
===================================================================
RCS file: src/xget-lex.h,v
retrieving revision 0.10.35.0
retrieving revision 0.10.35.1
diff -pu -r0.10.35.0 -r0.10.35.1
--- src/xget-lex.h 1998/07/09 22:49:48 0.10.35.0
+++ src/xget-lex.h 1998/07/18 00:25:15 0.10.35.1
@@ -23,9 +23,9 @@ Foundation, Inc., 59 Temple Place - Suit
enum xgettext_token_type_ty
{
xgettext_token_type_eof,
- xgettext_token_type_keyword1,
- xgettext_token_type_keyword2,
+ xgettext_token_type_keyword,
xgettext_token_type_lp,
+ xgettext_token_type_rp,
xgettext_token_type_comma,
xgettext_token_type_string_literal,
xgettext_token_type_symbol
@@ -37,8 +37,14 @@ struct xgettext_token_ty
{
xgettext_token_type_ty type;
- /* These 3 are only set for xgettext_token_type_string_literal. */
+ /* This 1 is set only for xgettext_token_type_keyword. */
+ int argnum;
+
+ /* This 1 is set only for xgettext_token_type_string_literal. */
char *string;
+
+ /* These 2 are set only for xgettext_token_type_keyword and
+ xgettext_token_type_string_literal. */
int line_number;
char *file_name;
};
@@ -50,7 +56,7 @@ void xgettext_lex PARAMS ((xgettext_toke
const char *xgettext_lex_comment PARAMS ((size_t __n));
void xgettext_lex_comment_reset PARAMS ((void));
/* void xgettext_lex_filepos PARAMS ((char **, int *)); FIXME needed? */
-void xgettext_lex_keyword PARAMS ((char *__name));
+void xgettext_lex_keyword PARAMS ((const char *__name));
void xgettext_lex_cplusplus PARAMS ((void));
void xgettext_lex_trigraphs PARAMS ((void));
===================================================================
RCS file: src/xgettext.c,v
retrieving revision 0.10.35.0
retrieving revision 0.10.35.1
diff -pu -r0.10.35.0 -r0.10.35.1
--- src/xgettext.c 1998/07/09 22:49:48 0.10.35.0
+++ src/xgettext.c 1998/07/18 00:25:15 0.10.35.1
@@ -835,6 +835,8 @@ scan_c_file(filename, mlp, is_cpp_file)
int is_cpp_file;
{
int state;
+ int commas_to_skip; /* defined only when in states 1 and 2 */
+ int paren_nesting; /* defined only when in state 2 */
/* Inform scanner whether we have C++ files or not. */
if (is_cpp_file)
@@ -854,63 +856,79 @@ scan_c_file(filename, mlp, is_cpp_file)
{
xgettext_token_ty token;
- /* A simple state machine is used to do the recognising:
+ /* A state machine is used to do the recognising:
State 0 = waiting for something to happen
- State 1 = seen one of our keywords with string in first parameter
- State 2 = was in state 1 and now saw a left paren
- State 3 = seen one of our keywords with string in second parameter
- State 4 = was in state 3 and now saw a left paren
- State 5 = waiting for comma after being in state 4
- State 6 = saw comma after being in state 5 */
+ State 1 = seen one of our keywords
+ State 2 = waiting for part of an argument */
xgettext_lex (&token);
switch (token.type)
{
- case xgettext_token_type_keyword1:
+ case xgettext_token_type_keyword:
+ if (!extract_all && state == 2)
+ {
+ if (commas_to_skip == 0)
+ {
+ error (0, 0,
+ _("%s:%d: warning: keyword nested in keyword arg"),
+ token.file_name, token.line_number);
+ continue;
+ }
+
+ /* Here we should nest properly, but this would require a
+ potentially unbounded stack. We haven't run across an
+ example that needs this functionality yet. For now,
+ we punt and forget the outer keyword. */
+ error (0, 0,
+ _("%s:%d: warning: keyword between outer keyword and its arg"),
+ token.file_name, token.line_number);
+ }
+ commas_to_skip = token.argnum - 1;
state = 1;
continue;
- case xgettext_token_type_keyword2:
- state = 3;
- continue;
-
case xgettext_token_type_lp:
switch (state)
{
case 1:
+ paren_nesting = 0;
state = 2;
break;
- case 3:
- state = 4;
+ case 2:
+ paren_nesting++;
break;
- default:
- state = 0;
}
continue;
+ case xgettext_token_type_rp:
+ if (state == 2 && paren_nesting != 0)
+ paren_nesting--;
+ else
+ state = 0;
+ continue;
+
case xgettext_token_type_comma:
- state = state == 5 ? 6 : 0;
+ if (state == 2 && commas_to_skip != 0)
+ commas_to_skip -= paren_nesting == 0;
+ else
+ state = 0;
continue;
case xgettext_token_type_string_literal:
- if (extract_all || state == 2 || state == 6)
- {
- remember_a_message (mlp, &token);
- state = 0;
- }
+ if (extract_all || (state == 2 && commas_to_skip == 0))
+ remember_a_message (mlp, &token);
else
{
free (token.string);
- state = (state == 4 || state == 5) ? 5 : 0;
+ state = state == 2 ? 2 : 0;
}
continue;
case xgettext_token_type_symbol:
- state = (state == 4 || state == 5) ? 5 : 0;
+ state = state == 2 ? 2 : 0;
continue;
default:
- state = 0;
- continue;
+ abort ();
case xgettext_token_type_eof:
break;
===================================================================
RCS file: po/Makefile.in.in,v
retrieving revision 0.10.35.0
retrieving revision 0.10.35.5
diff -u -r0.10.35.0 -r0.10.35.5
--- po/Makefile.in.in 1998/07/20 20:20:38 0.10.35.0
+++ po/Makefile.in.in 1998/07/26 09:07:52 0.10.35.5
@@ -62,7 +62,7 @@
$(COMPILE) $<
.po.pox:
- $(MAKE) $(PACKAGE).pot
+ $(MAKE) $(srcdir)/$(PACKAGE).pot
$(MSGMERGE) $< $(srcdir)/$(PACKAGE).pot -o $*.pox
.po.mo:
@@ -79,7 +79,7 @@
all: all-@USE_NLS@
-all-yes: cat-id-tbl.c $(CATALOGS)
+all-yes: $(srcdir)/cat-id-tbl.c $(CATALOGS)
all-no:
$(srcdir)/$(PACKAGE).pot: $(POTFILES)
@@ -90,8 +90,8 @@
|| ( rm -f $(srcdir)/$(PACKAGE).pot \
&& mv $(PACKAGE).po $(srcdir)/$(PACKAGE).pot )
-$(srcdir)/cat-id-tbl.c: stamp-cat-id; @:
-$(srcdir)/stamp-cat-id: $(PACKAGE).pot
+$(srcdir)/cat-id-tbl.c: $(srcdir)/stamp-cat-id; @:
+$(srcdir)/stamp-cat-id: $(srcdir)/$(PACKAGE).pot
rm -f cat-id-tbl.tmp
sed -f ../intl/po2tbl.sed $(srcdir)/$(PACKAGE).pot \
| sed -e "s/@PACKAGE NAME@/$(PACKAGE)/" > cat-id-tbl.tmp
@@ -180,7 +180,8 @@
check: all
-cat-id-tbl.o: ../intl/libgettext.h
+cat-id-tbl.o: $(srcdir)/cat-id-tbl.c $(top_srcdir)/intl/libgettext.h
+ $(COMPILE) $(srcdir)/cat-id-tbl.c
dvi info tags TAGS ID:
@@ -196,7 +197,7 @@
maintainer-clean: distclean
@echo "This command is intended for maintainers to use;"
@echo "it deletes files that may require special tools to rebuild."
- rm -f $(GMOFILES)
+ rm -f $(GMOFILES) cat-id-tbl.c stamp-cat-id
distdir = ../$(PACKAGE)-$(VERSION)/$(subdir)
dist distdir: update-po $(DISTFILES)
@@ -207,7 +208,7 @@
done
update-po: Makefile
- $(MAKE) $(PACKAGE).pot
+ $(MAKE) $(srcdir)/$(PACKAGE).pot
PATH=`pwd`/../src:$$PATH; \
cd $(srcdir); \
catalogs='$(CATALOGS)'; \

View File

@@ -1,226 +0,0 @@
Notes on the Free Translation Project
*************************************
Free software is going international! The Free Translation Project
is a way to get maintainers of free software, translators, and users all
together, so that will gradually become able to speak many languages.
A few packages already provide translations for their messages.
If you found this `ABOUT-NLS' file inside a distribution, you may
assume that the distributed package does use GNU `gettext' internally,
itself available at your nearest GNU archive site. But you do *not*
need to install GNU `gettext' prior to configuring, installing or using
this package with messages translated.
Installers will find here some useful hints. These notes also
explain how users should proceed for getting the programs to use the
available translations. They tell how people wanting to contribute and
work at translations should contact the appropriate team.
When reporting bugs in the `intl/' directory or bugs which may be
related to internationalization, you should tell about the version of
`gettext' which is used. The information can be found in the
`intl/VERSION' file, in internationalized packages.
One advise in advance
=====================
If you want to exploit the full power of internationalization, you
should configure it using
./configure --with-included-gettext
to force usage of internationalizing routines provided within this
package, despite the existence of internationalizing capabilities in the
operating system where this package is being installed. So far, only
the `gettext' implementation in the GNU C library version 2 provides as
many features (such as locale alias or message inheritance) as the
implementation here. It is also not possible to offer this additional
functionality on top of a `catgets' implementation. Future versions of
GNU `gettext' will very likely convey even more functionality. So it
might be a good idea to change to GNU `gettext' as soon as possible.
So you need not provide this option if you are using GNU libc 2 or
you have installed a recent copy of the GNU gettext package with the
included `libintl'.
INSTALL Matters
===============
Some packages are "localizable" when properly installed; the
programs they contain can be made to speak your own native language.
Most such packages use GNU `gettext'. Other packages have their own
ways to internationalization, predating GNU `gettext'.
By default, this package will be installed to allow translation of
messages. It will automatically detect whether the system provides
usable `catgets' (if using this is selected by the installer) or
`gettext' functions. If neither is available, the GNU `gettext' own
library will be used. This library is wholly contained within this
package, usually in the `intl/' subdirectory, so prior installation of
the GNU `gettext' package is *not* required. Installers may use
special options at configuration time for changing the default
behaviour. The commands:
./configure --with-included-gettext
./configure --with-catgets
./configure --disable-nls
will respectively bypass any pre-existing `catgets' or `gettext' to use
the internationalizing routines provided within this package, enable
the use of the `catgets' functions (if found on the locale system), or
else, *totally* disable translation of messages.
When you already have GNU `gettext' installed on your system and run
configure without an option for your new package, `configure' will
probably detect the previously built and installed `libintl.a' file and
will decide to use this. This might be not what is desirable. You
should use the more recent version of the GNU `gettext' library. I.e.
if the file `intl/VERSION' shows that the library which comes with this
package is more recent, you should use
./configure --with-included-gettext
to prevent auto-detection.
By default the configuration process will not test for the `catgets'
function and therefore they will not be used. The reasons are already
given above: the emulation on top of `catgets' cannot provide all the
extensions provided by the GNU `gettext' library. If you nevertheless
want to use the `catgets' functions use
./configure --with-catgets
to enable the test for `catgets' (this causes no harm if `catgets' is
not available on your system). If you really select this option we
would like to hear about the reasons because we cannot think of any
good one ourself.
Internationalized packages have usually many `po/LL.po' files, where
LL gives an ISO 639 two-letter code identifying the language. Unless
translations have been forbidden at `configure' time by using the
`--disable-nls' switch, all available translations are installed
together with the package. However, the environment variable `LINGUAS'
may be set, prior to configuration, to limit the installed set.
`LINGUAS' should then contain a space separated list of two-letter
codes, stating which languages are allowed.
Using This Package
==================
As a user, if your language has been installed for this package, you
only have to set the `LANG' environment variable to the appropriate
ISO 639 `LL' two-letter code prior to using the programs in the
package. For example, let's suppose that you speak German. At the
shell prompt, merely execute `setenv LANG de' (in `csh'),
`export LANG; LANG=de' (in `sh') or `export LANG=de' (in `bash'). This
can be done from your `.login' or `.profile' file, once and for all.
An operating system might already offer message localization for
many of its programs, while other programs have been installed locally
with the full capabilities of GNU `gettext'. Just using `gettext'
extended syntax for `LANG' would break proper localization of already
available operating system programs. In this case, users should set
both `LANGUAGE' and `LANG' variables in their environment, as programs
using GNU `gettext' give preference to `LANGUAGE'. For example, some
Swedish users would rather read translations in German than English for
when Swedish is not available. This is easily accomplished by setting
`LANGUAGE' to `sv:de' while leaving `LANG' to `sv'.
Translating Teams
=================
For the Free Translation Project to be a success, we need interested
people who like their own language and write it well, and who are also
able to synergize with other translators speaking the same language.
Each translation team has its own mailing list, courtesy of Linux
International. You may reach your translation team at the address
`LL@li.org', replacing LL by the two-letter ISO 639 code for your
language. Language codes are *not* the same as the country codes given
in ISO 3166. The following translation teams exist, as of December
1997:
Chinese `zh', Czech `cs', Danish `da', Dutch `nl', English `en',
Esperanto `eo', Finnish `fi', French `fr', German `de', Hungarian
`hu', Irish `ga', Italian `it', Indonesian `id', Japanese `ja',
Korean `ko', Latin `la', Norwegian `no', Persian `fa', Polish
`pl', Portuguese `pt', Russian `ru', Slovenian `sl', Spanish `es',
Swedish `sv', and Turkish `tr'.
For example, you may reach the Chinese translation team by writing to
`zh@li.org'.
If you'd like to volunteer to *work* at translating messages, you
should become a member of the translating team for your own language.
The subscribing address is *not* the same as the list itself, it has
`-request' appended. For example, speakers of Swedish can send a
message to `sv-request@li.org', having this message body:
subscribe
Keep in mind that team members are expected to participate
*actively* in translations, or at solving translational difficulties,
rather than merely lurking around. If your team does not exist yet and
you want to start one, or if you are unsure about what to do or how to
get started, please write to `translation@iro.umontreal.ca' to reach the
coordinator for all translator teams.
The English team is special. It works at improving and uniformizing
the terminology in use. Proven linguistic skill are praised more than
programming skill, here.
Available Packages
==================
Languages are not equally supported in all packages. The following
matrix shows the current state of internationalization, as of December
1997. The matrix shows, in regard of each package, for which languages
PO files have been submitted to translation coordination.
Ready PO files cs da de en es fi fr it ja ko nl no pl pt ru sl sv
.----------------------------------------------------.
bash | [] [] [] | 3
bison | [] [] [] | 3
clisp | [] [] [] [] | 4
cpio | [] [] [] [] [] [] | 6
diffutils | [] [] [] [] [] | 5
enscript | [] [] [] [] [] [] | 6
fileutils | [] [] [] [] [] [] [] [] [] [] | 10
findutils | [] [] [] [] [] [] [] [] [] | 9
flex | [] [] [] [] | 4
gcal | [] [] [] [] [] | 5
gettext | [] [] [] [] [] [] [] [] [] [] [] | 12
grep | [] [] [] [] [] [] [] [] [] [] | 10
hello | [] [] [] [] [] [] [] [] [] [] [] | 11
id-utils | [] [] [] | 3
indent | [] [] [] [] [] | 5
libc | [] [] [] [] [] [] [] | 7
m4 | [] [] [] [] [] [] | 6
make | [] [] [] [] [] [] | 6
music | [] [] | 2
ptx | [] [] [] [] [] [] [] [] | 8
recode | [] [] [] [] [] [] [] [] [] | 9
sh-utils | [] [] [] [] [] [] [] [] | 8
sharutils | [] [] [] [] [] [] | 6
tar | [] [] [] [] [] [] [] [] [] [] [] | 11
texinfo | [] [] [] | 3
textutils | [] [] [] [] [] [] [] [] [] | 9
wdiff | [] [] [] [] [] [] [] [] | 8
`----------------------------------------------------'
17 languages cs da de en es fi fr it ja ko nl no pl pt ru sl sv
27 packages 6 4 25 1 18 1 26 2 1 12 20 9 19 7 4 7 17 179
Some counters in the preceding matrix are higher than the number of
visible blocks let us expect. This is because a few extra PO files are
used for implementing regional variants of languages, or language
dialects.
For a PO file in the matrix above to be effective, the package to
which it applies should also have been internationalized and
distributed as such by its maintainer. There might be an observable
lag between the mere existence a PO file and its wide availability in a
distribution.
If December 1997 seems to be old, you may fetch a more recent copy
of this `ABOUT-NLS' file on most GNU archive sites.

View File

@@ -1,9 +1,9 @@
If you think you may have found a bug in GCC, please
If you think you may have found a bug in GNU CC, please
read the Bugs section of the GCC manual for advice on
(1) how to tell when to report a bug,
(2) where to send your bug report, and
(3) how to write a useful bug report and what information
(2) how to write a useful bug report and what information
it needs to have.
There are three ways to read the Bugs section.
@@ -20,8 +20,4 @@ to get to the section on bugs. Or use standalone Info in
a like manner. (Standalone Info is part of the Texinfo distribution.)
(3) By hand. Search for the chapter "Reporting Bugs" in gcc.texi, or
cat /usr/local/info/gcc* | more "+/^File: gcc.info, Node: Bugs,"
You may also want to take a look at the GCC FAQ, in which there are
additional instructions for submitting bug reports:
http://www.gnu.org/software/gcc/faq.html#bugreport
cat /usr/local/info/gcc* | more "+/^File: emacs, Node: Bugs,"

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

9207
gcc/ChangeLog.1 Normal file

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

7229
gcc/ChangeLog.2 Normal file

File diff suppressed because it is too large Load Diff

8063
gcc/ChangeLog.3 Normal file

File diff suppressed because it is too large Load Diff

10783
gcc/ChangeLog.4 Normal file

File diff suppressed because it is too large Load Diff

8954
gcc/ChangeLog.5 Normal file

File diff suppressed because it is too large Load Diff

8173
gcc/ChangeLog.6 Normal file

File diff suppressed because it is too large Load Diff

10376
gcc/ChangeLog.7 Normal file

File diff suppressed because it is too large Load Diff

11080
gcc/ChangeLog.8 Normal file

File diff suppressed because it is too large Load Diff

9968
gcc/ChangeLog.9 Normal file

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -1,30 +1,11 @@
This is Info file INSTALL, produced by Makeinfo version 1.68 from the
input file install1.texi.
This file documents the installation of the GNU compiler. Copyright
This file documents the installation of the GNU compiler. Copyright
(C) 1988, 1989, 1992, 1994, 1995 Free Software Foundation, Inc. You
may copy, distribute, and modify it freely as long as you preserve this
copyright notice and permission notice.

File: INSTALL, Node: Installation, Up: (dir)
Installing GNU CC
*****************
Note most of this information is out of date and superceded by the
EGCS install procedures. It is provided for historical reference only.
* Menu:
* Configurations:: Configurations Supported by GNU CC.
* Other Dir:: Compiling in a separate directory (not where the source is).
* Cross-Compiler:: Building and installing a cross-compiler.
* Sun Install:: See below for installation on the Sun.
* VMS Install:: See below for installation on VMS.
* Collect2:: How `collect2' works; how it finds `ld'.
* Header Dirs:: Understanding the standard header file directories.
Here is the procedure for installing GNU CC on a Unix system. See
*Note VMS Install::, for VMS systems. In this section we assume you
compile in the same directory that contains the source files; see *Note
@@ -64,13 +45,13 @@ and includes all the necessary compilation tools and libraries.
what your configuration is or guesses wrong.
In those cases, specify the build machine's "configuration name"
with the `--host' option; the host and target will default to be
the same as the host machine. (If you are building a
with the `--build' option; the host and target will default to be
the same as the build machine. (If you are building a
cross-compiler, see *Note Cross-Compiler::.)
Here is an example:
./configure --host=sparc-sun-sunos4.1
./configure --build=sparc-sun-sunos4.1
A configuration name may be canonical or it may be more or less
abbreviated.
@@ -85,7 +66,8 @@ and includes all the necessary compilation tools and libraries.
aliases. For example, `sun3' stands for `m68k-sun', so
`sun3-sunos4.1' is another way to specify a Sun 3. You can also
use simply `sun3-sunos', since the version of SunOS is assumed by
default to be version 4.
default to be version 4. `sun3-bsd' also works, since `configure'
knows that the only BSD variant on a Sun 3 is SunOS.
You can specify a version number after any of the system types,
and some of the CPU types. In most cases, the version is
@@ -122,11 +104,11 @@ and includes all the necessary compilation tools and libraries.
are
`hppa1.0-ANY-ANY', `hppa1.1-ANY-ANY', `i386-ANY-sysv',
`i386-ANY-isc',
`i860-ANY-bsd', `m68k-bull-sysv',
`m68k-hp-hpux', `m68k-sony-bsd',
`m68k-altos-sysv', `m68000-hp-hpux',
`m68000-att-sysv', `ANY-lynx-lynxos', and `mips-ANY'). On
any other system, `--with-gnu-as' has no effect.
`i860-ANY-bsd', `m68k-bull-sysv', `m68k-hp-hpux',
`m68k-sony-bsd',
`m68k-altos-sysv', `m68000-hp-hpux', `m68000-att-sysv',
`ANY-lynx-lynxos', and `mips-ANY'). On any other system,
`--with-gnu-as' has no effect.
On the systems listed above (except for the HP-PA, for ISC on
the 386, and for `mips-sgi-irix5.*'), if you use GAS, you
@@ -138,7 +120,9 @@ and includes all the necessary compilation tools and libraries.
This option does not cause the GNU linker to be installed; it
just modifies the behavior of GNU CC to work with the GNU
linker.
linker. Specifically, it inhibits the installation of
`collect2', a program which otherwise serves as a front-end
for the system's linker on most configurations.
`--with-stabs'
On MIPS based systems and on Alphas, you must specify whether
@@ -178,33 +162,6 @@ and includes all the necessary compilation tools and libraries.
`--nfp' currently has no effect, though perhaps there are
other systems where it could usefully make a difference.
`--enable-haifa'
`--disable-haifa'
Use `--enable-haifa' to enable use of an experimental
instruction scheduler (from IBM Haifa). This may or may not
produce better code. Some targets on which it is known to be
a win enable it by default; use `--disable-haifa' to disable
it in these cases. `configure' will print out whether the
Haifa scheduler is enabled when it is run.
`--enable-threads=TYPE'
Certain systems, notably Linux-based GNU systems, can't be
relied on to supply a threads facility for the Objective C
runtime and so will default to single-threaded runtime. They
may, however, have a library threads implementation
available, in which case threads can be enabled with this
option by supplying a suitable TYPE, probably `posix'. The
possibilities for TYPE are `single', `posix', `win32',
`solaris', `irix' and `mach'.
`--enable-checking'
When you specify this option, the compiler is built to
perform checking of tree node types when referencing fields
of that node. This does not change the generated code, but
adds error checking within the compiler. This will slow down
the compiler and may only work properly if you are building
the compiler with GNU C.
The `configure' script searches subdirectories of the source
directory for other compilers that are to be integrated into GNU
CC. The GNU compiler for C++, called G++ is in a subdirectory
@@ -250,40 +207,22 @@ and includes all the necessary compilation tools and libraries.
name to use instead of `/usr/local' for all purposes with one
exception: the directory `/usr/local/include' is searched for
header files no matter where you install the compiler. To override
this name, use the `--with-local-prefix' option below. The
directory you specify need not exist, but its parent directory
must exist.
this name, use the `--local-prefix' option below.
5. Specify `--with-local-prefix=DIR' if you want the compiler to
search directory `DIR/include' for locally installed header files
5. Specify `--local-prefix=DIR' if you want the compiler to search
directory `DIR/include' for locally installed header files
*instead* of `/usr/local/include'.
You should specify `--with-local-prefix' *only* if your site has a
You should specify `--local-prefix' *only* if your site has a
different convention (not `/usr/local') for where to put
site-specific files.
The default value for `--with-local-prefix' is `/usr/local'
regardless of the value of `--prefix'. Specifying `--prefix' has
no effect on which directory GNU CC searches for local header
files. This may seem counterintuitive, but actually it is logical.
The purpose of `--prefix' is to specify where to *install GNU CC*.
The local header files in `/usr/local/include'--if you put any in
that directory--are not part of GNU CC. They are part of other
programs--perhaps many others. (GNU CC installs its own header
files in another directory which is based on the `--prefix' value.)
*Do not* specify `/usr' as the `--with-local-prefix'! The
directory you use for `--with-local-prefix' *must not* contain any
of the system's standard header files. If it did contain them,
certain programs would be miscompiled (including GNU Emacs, on
certain targets), because this would override and nullify the
header file corrections made by the `fixincludes' script.
Indications are that people who use this option use it based on
mistaken ideas of what it is for. People use it as if it specified
where to install part of GNU CC. Perhaps they make this assumption
because installing GNU CC creates the directory.
*Do not* specify `/usr' as the `--local-prefix'! The directory
you use for `--local-prefix' *must not* contain any of the
system's standard header files. If it did contain them, certain
programs would be miscompiled (including GNU Emacs, on certain
targets), because this would override and nullify the header file
corrections made by the `fixincludes' script.
6. Make sure the Bison parser generator is installed. (This is
unnecessary if the Bison output files `c-parse.c' and `cexp.c' are
@@ -325,9 +264,8 @@ and includes all the necessary compilation tools and libraries.
escape sequence" are normal in `genopinit.c' and perhaps some
other files. Likewise, you should ignore warnings about "constant
is so large that it is unsigned" in `insn-emit.c' and
`insn-recog.c', a warning about a comparison always being zero in
`enquire.o', and warnings about shift counts exceeding type widths
in `cexp.y'. Any other compilation errors may represent bugs in
`insn-recog.c' and a warning about a comparison always being zero
in `enquire.o'. Any other compilation errors may represent bugs in
the port to your machine or operating system, and should be
investigated and reported.
@@ -459,17 +397,14 @@ and includes all the necessary compilation tools and libraries.
This copies the files `cc1', `cpp' and `libgcc.a' to files `cc1',
`cpp' and `libgcc.a' in the directory
`/usr/local/lib/gcc-lib/TARGET/VERSION', which is where the
compiler driver program looks for them. Here TARGET is the
canonicalized form of target machine type specified when you ran
`configure', and VERSION is the version number of GNU CC. This
naming scheme permits various versions and/or cross-compilers to
coexist. It also copies the executables for compilers for other
languages (e.g., `cc1plus' for C++) to the same directory.
compiler driver program looks for them. Here TARGET is the target
machine type specified when you ran `configure', and VERSION is
the version number of GNU CC. This naming scheme permits various
versions and/or cross-compilers to coexist.
This also copies the driver program `xgcc' into
`/usr/local/bin/gcc', so that it appears in typical execution
search paths. It also copies `gcc.1' into `/usr/local/man/man1'
and info pages into `/usr/local/info'.
search paths.
On some systems, this command causes recompilation of some files.
This is usually due to bugs in `make'. You should either ignore
@@ -486,88 +421,11 @@ and includes all the necessary compilation tools and libraries.
some other compiler.)
16. If you're going to use C++, it's likely that you need to also
install a C++ runtime library. Just as GNU C does not distribute
a C runtime library, it also does not include a C++ runtime
library. All I/O functionality, special class libraries, etc., are
provided by the C++ runtime library.
The standard C++ runtime library for GNU CC is called `libstdc++'.
An obsolescent library `libg++' may also be available, but it's
necessary only for older software that hasn't been converted yet;
if you don't know whether you need `libg++' then you probably don't
need it.
Here's one way to build and install `libstdc++' for GNU CC:
* Build and install GNU CC, so that invoking `gcc' obtains the
GNU CC that was just built.
* Obtain a copy of a compatible `libstdc++' distribution. For
example, the `libstdc++-2.8.0.tar.gz' distribution should be
compatible with GCC 2.8.0. GCC distributors normally
distribute `libstdc++' as well.
* Set the `CXX' environment variable to `gcc' while running the
`libstdc++' distribution's `configure' command. Use the same
`configure' options that you used when you invoked GCC's
`configure' command.
* Invoke `make' to build the C++ runtime.
* Invoke `make install' to install the C++ runtime.
To summarize, after building and installing GNU CC, invoke the
following shell commands in the topmost directory of the C++
library distribution. For CONFIGURE-OPTIONS, use the same options
that you used to configure GNU CC.
$ CXX=gcc ./configure CONFIGURE-OPTIONS
$ make
$ make install
17. GNU CC includes a runtime library for Objective-C because it is an
integral part of the language. You can find the files associated
with the library in the subdirectory `objc'. The GNU Objective-C
Runtime Library requires header files for the target's C library in
order to be compiled,and also requires the header files for the
target's thread library if you want thread support. *Note
Cross-Compilers and Header Files: Cross Headers, for discussion
about header files issues for cross-compilation.
When you run `configure', it picks the appropriate Objective-C
thread implementation file for the target platform. In some
situations, you may wish to choose a different back-end as some
platforms support multiple thread implementations or you may wish
to disable thread support completely. You do this by specifying a
value for the OBJC_THREAD_FILE makefile variable on the command
line when you run make, for example:
make CC="stage2/xgcc -Bstage2/" CFLAGS="-g -O2" OBJC_THREAD_FILE=thr-single
Below is a list of the currently available back-ends.
* thr-single Disable thread support, should work for all
platforms.
* thr-decosf1 DEC OSF/1 thread support.
* thr-irix SGI IRIX thread support.
* thr-mach Generic MACH thread support, known to work on
NEXTSTEP.
* thr-os2 IBM OS/2 thread support.
* thr-posix Generix POSIX thread support.
* thr-pthreads PCThreads on Linux-based GNU systems.
* thr-solaris SUN Solaris thread support.
* thr-win32 Microsoft Win32 API thread support.

File: INSTALL, Node: Configurations, Next: Other Dir, Up: Installation
install the libg++ distribution. It should be available from the
same place where you got the GNU C distribution. Just as GNU C
does not distribute a C runtime library, it also does not include
a C++ run-time library. All I/O functionality, special class
libraries, etc., are available in the libg++ distribution.
Configurations Supported by GNU CC
==================================
@@ -575,18 +433,17 @@ Configurations Supported by GNU CC
Here are the possible CPU types:
1750a, a29k, alpha, arm, cN, clipper, dsp16xx, elxsi, h8300,
hppa1.0, hppa1.1, i370, i386, i486, i586, i860, i960, m32r,
m68000, m68k, m88k, mips, mipsel, mips64, mips64el, ns32k,
powerpc, powerpcle, pyramid, romp, rs6000, sh, sparc, sparclite,
sparc64, vax, we32k.
hppa1.0, hppa1.1, i370, i386, i486, i586, i860, i960, m68000, m68k,
m88k, mips, mipsel, mips64, mips64el, ns32k, powerpc, powerpcle,
pyramid, romp, rs6000, sh, sparc, sparclite, sparc64, vax, we32k.
Here are the recognized company names. As you can see, customary
abbreviations are used rather than the longer official names.
acorn, alliant, altos, apollo, apple, att, bull, cbm, convergent,
convex, crds, dec, dg, dolphin, elxsi, encore, harris, hitachi,
hp, ibm, intergraph, isi, mips, motorola, ncr, next, ns, omron,
plexus, sequent, sgi, sony, sun, tti, unicom, wrs.
acorn, alliant, altos, apollo, att, bull, cbm, convergent, convex,
crds, dec, dg, dolphin, elxsi, encore, harris, hitachi, hp, ibm,
intergraph, isi, mips, motorola, ncr, next, ns, omron, plexus,
sequent, sgi, sony, sun, tti, unicom, wrs.
The company name is meaningful only to disambiguate when the rest of
the information supplied is insufficient. You can omit it, writing
@@ -595,9 +452,9 @@ is equivalent to `vax-dec-ultrix4.2'.
Here is a list of system types:
386bsd, aix, acis, amigaos, aos, aout, aux, bosx, bsd, clix, coff,
386bsd, aix, acis, amigados, aos, aout, bosx, bsd, clix, coff,
ctix, cxux, dgux, dynix, ebmon, ecoff, elf, esix, freebsd, hms,
genix, gnu, linux-gnu, hiux, hpux, iris, irix, isc, luna, lynxos,
genix, gnu, gnu/linux, hiux, hpux, iris, irix, isc, luna, lynxos,
mach, minix, msdos, mvs, netbsd, newsos, nindy, ns, osf, osfrose,
ptx, riscix, riscos, rtu, sco, sim, solaris, sunos, sym, sysv,
udi, ultrix, unicos, uniplus, unos, vms, vsta, vxworks, winnt,
@@ -648,11 +505,12 @@ special things you must know:
`1750a-*-*'
MIL-STD-1750A processors.
The MIL-STD-1750A cross configuration produces output for
`as1750', an assembler/linker available under the GNU Public
License for the 1750A. `as1750' can be obtained at
*ftp://ftp.fta-berlin.de/pub/crossgcc/1750gals/*. A similarly
licensed simulator for the 1750A is available from same address.
Starting with GCC 2.6.1, the MIL-STD-1750A cross configuration no
longer supports the Tektronix Assembler, but instead produces
output for `as1750', an assembler/linker available under the GNU
Public License for the 1750A. Contact *kellogg@space.otn.dasa.de*
for more details on obtaining `as1750'. A similarly licensed
simulator for the 1750A is available from same address.
You should ignore a fatal error during the building of libgcc
(libgcc is not yet implemented for the 1750A.)
@@ -683,7 +541,8 @@ special things you must know:
`alpha-*-osf1'
Systems using processors that implement the DEC Alpha architecture
and are running the DEC Unix (OSF/1) operating system, for example
the DEC Alpha AXP systems.CC.)
the DEC Alpha AXP systems. (VMS on the Alpha is not currently
supported by GNU CC.)
GNU CC writes a `.verstamp' directive to the assembler output file
unless it is built as a cross-compiler. It gets the version to
@@ -730,38 +589,22 @@ special things you must know:
DBX. DEC is now aware of this problem with the assembler and
hopes to provide a fix shortly.
`arc-*-elf'
Argonaut ARC processor. This configuration is intended for
embedded systems.
`arm-*-aout'
`arm'
Advanced RISC Machines ARM-family processors. These are often
used in embedded applications. There are no standard Unix
configurations. This configuration corresponds to the basic
instruction sequences and will produce `a.out' format object
modules.
instruction sequences and will produce a.out format object modules.
You may need to make a variant of the file `arm.h' for your
particular configuration.
`arm-*-linuxaout'
Any of the ARM family processors running the Linux-based GNU
system with the `a.out' binary format (ELF is not yet supported).
You must use version 2.8.1.0.7 or later of the GNU/Linux binutils,
which you can download from `sunsite.unc.edu:/pub/Linux/GCC' and
other mirror sites for Linux-based GNU systems.
`arm-*-riscix'
The ARM2 or ARM3 processor running RISC iX, Acorn's port of BSD
Unix. If you are running a version of RISC iX prior to 1.2 then
you must specify the version number during configuration. Note
that the assembler shipped with RISC iX does not support stabs
debugging information; a new version of the assembler, with stabs
support included, is now available from Acorn and via ftp
`ftp.acorn.com:/pub/riscix/as+xterm.tar.Z'. To enable stabs
debugging, pass `--with-gnu-as' to configure.
You will need to install GNU `sed' before you can run configure.
support included, is now available from Acorn.
`a29k'
AMD Am29k-family processors. These are normally used in embedded
@@ -776,10 +619,9 @@ special things you must know:
AMD Am29050 used in a system running a variant of BSD Unix.
`decstation-*'
MIPS-based DECstations can support three different personalities:
Ultrix, DEC OSF/1, and OSF/rose. (Alpha-based DECstation products
have a configuration name beginning with `alpha-dec'.) To
configure GCC for these platforms use the following configurations:
DECstations can support three different personalities: Ultrix, DEC
OSF/1, and OSF/rose. To configure GCC for these platforms use the
following configurations:
`decstation-ultrix'
Ultrix configuration.
@@ -809,57 +651,82 @@ special things you must know:
A port to the AT&T DSP1610 family of processors.
`h8300-*-*'
Hitachi H8/300 series of processors.
The calling convention and structure layout has changed in release
2.6. All code must be recompiled. The calling convention now
passes the first three arguments in function calls in registers.
Structures are no longer a multiple of 2 bytes.
`hppa*-*-*'
There are several variants of the HP-PA processor which run a
variety of operating systems. GNU CC must be configured to use
the correct processor type and operating system, or GNU CC will
not function correctly. The easiest way to handle this problem is
to *not* specify a target when configuring GNU CC, the `configure'
script will try to automatically determine the right processor
type and operating system.
There are two variants of this CPU, called 1.0 and 1.1, which have
different machine descriptions. You must use the right one for
your machine. All 7NN machines and 8N7 machines use 1.1, while
all other 8NN machines use 1.0.
The easiest way to handle this problem is to use `configure hpNNN'
or `configure hpNNN-hpux', where NNN is the model number of the
machine. Then `configure' will figure out if the machine is a 1.0
or 1.1. Use `uname -a' to find out the model number of your
machine.
`-g' does not work on HP-UX, since that system uses a peculiar
debugging format which GNU CC does not know about. However, `-g'
will work if you also use GAS and GDB in conjunction with GCC. We
highly recommend using GAS for all HP-PA configurations.
You should be using GAS-2.6 (or later) along with GDB-4.16 (or
You should be using GAS-2.3 (or later) along with GDB-4.12 (or
later). These can be retrieved from all the traditional GNU ftp
archive sites.
On some versions of HP-UX, you will need to install GNU `sed'.
Build GAS and install the resulting binary as:
You will need to be install GAS into a directory before `/bin',
`/usr/bin', and `/usr/ccs/bin' in your search path. You should
install GAS before you build GNU CC.
/usr/local/lib/gcc-lib/CONFIGURATION/GCCVERSION/as
To enable debugging, you must configure GNU CC with the
`--with-gnu-as' option before building.
where CONFIGURATION is the configuration name (perhaps
`hpNNN-hpux') and GCCVERSION is the GNU CC version number. Do
this *before* starting the build process, otherwise you will get
errors from the HPUX assembler while building `libgcc2.a'. The
command
make install-dir
will create the necessary directory hierarchy so you can install
GAS before building GCC.
To enable debugging, configure GNU CC with the `--with-gnu-as'
option before building.
It has been reported that GNU CC produces invalid assembly code for
1.1 machines running HP-UX 8.02 when using the HP assembler.
Typically the errors look like this:
as: bug.s @line#15 [err#1060]
Argument 0 or 2 in FARG upper
- lookahead = ARGW1=FR,RTNVAL=GR
as: foo.s @line#28 [err#1060]
Argument 0 or 2 in FARG upper
- lookahead = ARGW1=FR
You can check the version of HP-UX you are running by executing
the command `uname -r'. If you are indeed running HP-UX 8.02 on
a PA and using the HP assembler then configure GCC with
"hpNNN-hpux8.02".
`i370-*-*'
This port is very preliminary and has many known bugs. We hope to
have a higher-quality port for this machine soon.
`i386-*-linux-gnuoldld'
Use this configuration to generate `a.out' binaries on Linux-based
GNU systems if you do not have gas/binutils version 2.5.2 or later
installed. This is an obsolete configuration.
`i386-*-linuxoldld'
Use this configuration to generate a.out binaries on Linux if you
do not have gas/binutils version 2.5.2 or later installed. This is
an obsolete configuration.
`i386-*-linux-gnuaout'
Use this configuration to generate `a.out' binaries on Linux-based
GNU systems. This configuration is being superseded. You must use
gas/binutils version 2.5.2 or later.
`i386-*-linuxaout'
Use this configuration to generate a.out binaries on Linux. This
configuration is being superseded. You must use gas/binutils
version 2.5.2 or later.
`i386-*-linux-gnu'
Use this configuration to generate ELF binaries on Linux-based GNU
systems. You must use gas/binutils version 2.5.2 or later.
`i386-*-linux'
Use this configuration to generate ELF binaries on Linux. You must
use gas/binutils version 2.5.2 or later.
`i386-*-sco'
Compilation with RCC is recommended. Also, it may be a good idea
@@ -869,35 +736,6 @@ special things you must know:
`i386-*-sco3.2v4'
Use this configuration for SCO release 3.2 version 4.
`i386-*-sco3.2v5*'
Use this for the SCO OpenServer Release family including 5.0.0,
5.0.2, 5.0.4, 5.0.5, Internet FastStart 1.0, and Internet
FastStart 1.1.
GNU CC can generate COFF binaries if you specify `-mcoff' or ELF
binaries, the default. A full `make bootstrap' is recommended
so that an ELF compiler that builds ELF is generated.
You must have TLS597 from `ftp://ftp.sco.com/TLS' installed for ELF
C++ binaries to work correctly on releases before 5.0.4.
The native SCO assembler that is provided with the OS at no charge
is normally required. If, however, you must be able to use the GNU
assembler (perhaps you have complex asms) you must configure this
package `--with-gnu-as'. To do this, install (cp or symlink)
gcc/as to your copy of the GNU assembler. You must use a recent
version of GNU binutils; version 2.9.1 seems to work well. If you
select this option, you will be unable to build COFF images.
Trying to do so will result in non-obvious failures. In general,
the "-with-gnu-as" option isn't as well tested as the native
assembler.
*NOTE:* If you are building C++, you must follow the instructions
about invoking `make bootstrap' because the native OpenServer
compiler may build a `cc1plus' that will not correctly parse many
valid C++ programs. You must do a `make bootstrap' if you are
building with the native compiler.
`i386-*-isc'
It may be a good idea to link with GNU malloc instead of the
malloc that comes with the system.
@@ -910,15 +748,19 @@ special things you must know:
that comes with the system.
`i386-ibm-aix'
You need to use GAS version 2.1 or later, and LD from GNU binutils
version 2.2 or later.
You need to use GAS version 2.1 or later, and and LD from GNU
binutils version 2.2 or later.
`i386-sequent-bsd'
Go to the Berkeley universe before compiling.
Go to the Berkeley universe before compiling. In addition, you
probably need to create a file named `string.h' containing just
one line: `#include <strings.h>'.
`i386-sequent-ptx1*'
Sequent DYNIX/ptx 1.x.
`i386-sequent-ptx2*'
You must install GNU `sed' before running `configure'.
Sequent DYNIX/ptx 2.x.
`i386-sun-sunos4'
You may find that you need another version of GNU CC to begin
@@ -931,7 +773,7 @@ special things you must know:
Sun systems.
`i[345]86-*-winnt3.5'
This version requires a GAS that has not yet been released. Until
This version requires a GAS that has not let been released. Until
it is, you can get a prebuilt binary version via anonymous ftp from
`cs.washington.edu:pub/gnat' or `cs.nyu.edu:pub/gnat'. You must
also use the Microsoft header files from the Windows NT 3.5 SDK.
@@ -987,37 +829,19 @@ special things you must know:
You can tell GNU CC to use the GNU assembler and linker, by
specifying `--with-gnu-as --with-gnu-ld' when configuring. These
will produce COFF format object files and executables; otherwise
GNU CC will use the installed tools, which produce `a.out' format
GNU CC will use the installed tools, which produce a.out format
executables.
`m32r-*-elf'
Mitsubishi M32R processor. This configuration is intended for
embedded systems.
`m68000-hp-bsd'
HP 9000 series 200 running BSD. Note that the C compiler that
comes with this system cannot compile GNU CC; contact
`law@cygnus.com' to get binaries of GNU CC for bootstrapping.
`law@cs.utah.edu' to get binaries of GNU CC for bootstrapping.
`m68k-altos'
Altos 3068. You must use the GNU assembler, linker and debugger.
Also, you must fix a kernel bug. Details in the file
`README.ALTOS'.
`m68k-apple-aux'
Apple Macintosh running A/UX. You may configure GCC to use
either the system assembler and linker or the GNU assembler and
linker. You should use the GNU configuration if you can,
especially if you also want to use GNU C++. You enabled that
configuration with + the `--with-gnu-as' and `--with-gnu-ld'
options to `configure'.
Note the C compiler that comes with this system cannot compile GNU
CC. You can find binaries of GNU CC for bootstrapping on
`jagubox.gsfc.nasa.gov'. You will also a patched version of
`/bin/ld' there that raises some of the arbitrary limits found in
the original.
`m68k-att-sysv'
AT&T 3b1, a.k.a. 7300 PC. Special procedures are needed to
compile GNU CC with this machine's standard C compiler, due to
@@ -1029,7 +853,7 @@ special things you must know:
However, the following procedure might work. We are unable to
test it.
1. Comment out the `#include "config.h"' line near the start of
1. Comment out the `#include "config.h"' line on line 37 of
`cccp.c' and do `make cpp'. This makes a preliminary version
of GNU cpp.
@@ -1102,9 +926,9 @@ special things you must know:
In addition, if you wish to use gas `--with-gnu-as' you must use
gas version 2.1 or later, and you must use the GNU linker version
2.1 or later. Earlier versions of gas relied upon a program which
converted the gas output into the native HP-UX format, but that
converted the gas output into the native HP/UX format, but that
program has not been kept up to date. gdb does not understand
that native HP-UX format, so you must use gas if you wish to use
that native HP/UX format, so you must use gas if you wish to use
gdb.
`m68k-sun'
@@ -1264,7 +1088,9 @@ special things you must know:
Emacs.
`ns32k-sequent'
Go to the Berkeley universe before compiling.
Go to the Berkeley universe before compiling. In addition, you
probably need to create a file named `string.h' containing just
one line: `#include <strings.h>'.
`ns32k-utek'
UTEK ns32000 system ("merlin"). The C compiler that comes with
@@ -1291,15 +1117,13 @@ special things you must know:
xlc-1.2.1.8, xlc-1.3.0.0 (distributed with AIX 3.2.5), and
xlc-1.3.0.19. Both xlc-1.2.1.28 and xlc-1.3.0.24 (PTF 432238) are
known to produce working versions of GNU CC, but most other recent
releases correctly bootstrap GNU CC.
Release 4.3.0 of AIX and ones prior to AIX 3.2.4 include a version
of the IBM assembler which does not accept debugging directives:
assembler updates are available as PTFs. Also, if you are using
AIX 3.2.5 or greater and the GNU assembler, you must have a
version modified after October 16th, 1995 in order for the GNU C
compiler to build. See the file `README.RS6000' for more details
on any of these problems.
releases correctly bootstrap GNU CC. Also, releases of AIX prior
to AIX 3.2.4 include a version of the IBM assembler which does not
accept debugging directives: assembler updates are available as
PTFs. Also, if you are using AIX 3.2.5 or greater and the GNU
assembler, you must have a version modified after October 16th,
1995 in order for the GNU C compiler to build. See the file
`README.RS6000' for more details on of these problems.
GNU CC does not yet support the 64-bit PowerPC instructions.
@@ -1324,79 +1148,48 @@ special things you must know:
prevent the linker from producing a correct library or runnable
executable.
By default, AIX 4.1 produces code that can be used on either Power
or PowerPC processors.
You can specify a default version for the `-mcpu='CPU_TYPE switch
by using the configure option `--with-cpu-'CPU_TYPE.
`powerpc-*-elf'
`powerpc-*-sysv4'
PowerPC system in big endian mode, running System V.4.
You can specify a default version for the `-mcpu='CPU_TYPE switch
by using the configure option `--with-cpu-'CPU_TYPE.
`powerpc-*-linux-gnu'
PowerPC system in big endian mode, running the Linux-based GNU
system.
You can specify a default version for the `-mcpu='CPU_TYPE switch
by using the configure option `--with-cpu-'CPU_TYPE.
This configuration is currently under development.
`powerpc-*-eabiaix'
Embedded PowerPC system in big endian mode with -mcall-aix
selected as the default.
You can specify a default version for the `-mcpu='CPU_TYPE switch
by using the configure option `--with-cpu-'CPU_TYPE.
selected as the default. This system is currently under
development.
`powerpc-*-eabisim'
Embedded PowerPC system in big endian mode for use in running
under the PSIM simulator.
You can specify a default version for the `-mcpu='CPU_TYPE switch
by using the configure option `--with-cpu-'CPU_TYPE.
under the PSIM simulator. This system is currently under
development.
`powerpc-*-eabi'
Embedded PowerPC system in big endian mode.
You can specify a default version for the `-mcpu='CPU_TYPE switch
by using the configure option `--with-cpu-'CPU_TYPE.
This configuration is currently under development.
`powerpcle-*-elf'
`powerpcle-*-sysv4'
PowerPC system in little endian mode, running System V.4.
You can specify a default version for the `-mcpu='CPU_TYPE switch
by using the configure option `--with-cpu-'CPU_TYPE.
This configuration is currently under development.
`powerpcle-*-solaris2*'
PowerPC system in little endian mode, running Solaris 2.5.1 or
higher.
`powerpcle-*-sysv4'
Embedded PowerPC system in little endian mode.
You can specify a default version for the `-mcpu='CPU_TYPE switch
by using the configure option `--with-cpu-'CPU_TYPE. Beta
versions of the Sun 4.0 compiler do not seem to be able to build
GNU CC correctly. There are also problems with the host assembler
and linker that are fixed by using the GNU versions of these tools.
This system is currently under development.
`powerpcle-*-eabisim'
Embedded PowerPC system in little endian mode for use in running
under the PSIM simulator.
This system is currently under development.
`powerpcle-*-eabi'
Embedded PowerPC system in little endian mode.
You can specify a default version for the `-mcpu='CPU_TYPE switch
by using the configure option `--with-cpu-'CPU_TYPE.
`powerpcle-*-winnt'
`powerpcle-*-pe'
PowerPC system in little endian mode running Windows NT.
You can specify a default version for the `-mcpu='CPU_TYPE switch
by using the configure option `--with-cpu-'CPU_TYPE.
This configuration is currently under development.
`vax-dec-ultrix'
Don't try compiling with Vax C (`vcc'). It produces incorrect code
@@ -1446,9 +1239,6 @@ special things you must know:
You may need to raise the ULIMIT setting to build a C++ compiler,
as the file `cc1plus' is larger than one megabyte.

File: INSTALL, Node: Other Dir, Next: Cross-Compiler, Prev: Configurations, Up: Installation
Compilation in a Separate Directory
===================================
@@ -1493,9 +1283,6 @@ configuration steps shown above, when ordinary source files change. You
must, however, run `configure' again when the configuration files
change, if your system does not support symbolic links.

File: INSTALL, Node: Cross-Compiler, Next: Sun Install, Prev: Other Dir, Up: Installation
Building and Installing a Cross-Compiler
========================================
@@ -1522,20 +1309,6 @@ If you want to link on other than the target machine, you need a
cross-linker as well. You also need header files and libraries suitable
for the target machine that you can install on the host machine.
* Menu:
* Steps of Cross:: Using a cross-compiler involves several steps
that may be carried out on different machines.
* Configure Cross:: Configuring a cross-compiler.
* Tools and Libraries:: Where to put the linker and assembler, and the C library.
* Cross Headers:: Finding and installing header files
for a cross-compiler.
* Cross Runtime:: Supplying arithmetic runtime routines (`libgcc1.a').
* Build Cross:: Actually compiling the cross-compiler.

File: INSTALL, Node: Steps of Cross, Next: Configure Cross, Up: Cross-Compiler
Steps of Cross-Compilation
--------------------------
@@ -1561,9 +1334,6 @@ machine, since then you can do it all with a single invocation of GNU
CC. This requires a suitable cross-assembler and cross-linker. For
some targets, the GNU assembler and linker are available.

File: INSTALL, Node: Configure Cross, Next: Tools and Libraries, Prev: Steps of Cross, Up: Cross-Compiler
Configuring a Cross-Compiler
----------------------------
@@ -1576,9 +1346,6 @@ system running BSD on a system that `configure' can correctly identify:
./configure --target=m68k-hp-bsd4.3

File: INSTALL, Node: Tools and Libraries, Next: Cross Headers, Prev: Configure Cross, Up: Cross-Compiler
Tools and Libraries for a Cross-Compiler
----------------------------------------
@@ -1613,10 +1380,10 @@ supports.
If you want to install libraries to use with the cross-compiler,
such as a standard C library, put them in the directory
`/usr/local/TARGET/lib'; installation of GNU CC copies all the files in
that subdirectory into the proper place for GNU CC to find them and
link with them. Here's an example of copying some libraries from a
target machine:
`/usr/local/TARGET/lib'; installation of GNU CC copies all all the
files in that subdirectory into the proper place for GNU CC to find
them and link with them. Here's an example of copying some libraries
from a target machine:
ftp TARGET-MACHINE
lcd /usr/local/TARGET/lib
@@ -1647,9 +1414,6 @@ machine:
mget *crt*.o
quit

File: INSTALL, Node: Cross Runtime, Next: Build Cross, Prev: Cross Headers, Up: Cross-Compiler
`libgcc.a' and Cross-Compilers
------------------------------
@@ -1735,9 +1499,6 @@ Otherwise, you should place your replacement library under the name
`libgcc1.a' in the directory in which you will build the
cross-compiler, before you run `make'.

File: INSTALL, Node: Cross Headers, Next: Cross Runtime, Prev: Tools and Libraries, Up: Cross-Compiler
Cross-Compilers and Header Files
--------------------------------
@@ -1763,7 +1524,7 @@ from the host machine, the cross-compiler can use them also.
Otherwise, you're on your own in finding header files to use when
cross-compiling.
When you have found suitable header files, put them in the directory
When you have found suitable header files, put them in
`/usr/local/TARGET/include', before building the cross compiler. Then
installation will run fixincludes properly and install the corrected
versions of the header files where the compiler will use them.
@@ -1786,9 +1547,6 @@ machine. On the target machine, do this:
quit
tar xf tarfile

File: INSTALL, Node: Build Cross, Prev: Cross Runtime, Up: Cross-Compiler
Actually Building the Cross-Compiler
------------------------------------
@@ -1822,19 +1580,11 @@ must specify a 68030 as the host when you configure it.
To install the cross-compiler, use `make install', as usual.

File: INSTALL, Node: Sun Install, Next: VMS Install, Prev: Cross-Compiler, Up: Installation
Installing GNU CC on the Sun
============================
On Solaris, do not use the linker or other tools in `/usr/ucb' to
build GNU CC. Use `/usr/ccs/bin'.
If the assembler reports `Error: misaligned data' when bootstrapping,
you are probably using an obsolete version of the GNU assembler.
Upgrade to the latest version of GNU `binutils', or use the Solaris
assembler.
On Solaris (version 2.1), do not use the linker or other tools in
`/usr/ucb' to build GNU CC. Use `/usr/ccs/bin'.
Make sure the environment variable `FLOAT_OPTION' is not set when
you compile `libgcc.a'. If this option were set to `f68881' when
@@ -1854,15 +1604,6 @@ it by using the following command to compile GNU CC with Sun CC:
make CC="TERMCAP=x OBJS=x LIBFUNCS=x STAGESTUFF=x cc"
SunOS 4.1.3 and 4.1.3_U1 have bugs that can cause intermittent core
dumps when compiling GNU CC. A common symptom is an internal compiler
error which does not recur if you run it again. To fix the problem,
install Sun recommended patch 100726 (for SunOS 4.1.3) or 101508 (for
SunOS 4.1.3_U1), or upgrade to a later SunOS release.

File: INSTALL, Node: VMS Install, Next: Collect2, Prev: Sun Install, Up: Installation
Installing GNU CC on VMS
========================
@@ -1913,8 +1654,8 @@ perform the following steps:
disk:[gcc.gxx_include.] gnu_gxx_include
with the appropriate disk and directory name. If you are going to
be using a C++ runtime library, this is where its install
procedure will install its header files.
be using libg++, this is where the libg++ install procedure will
install the libg++ header files.
2. Obtain the file `gcc-cc1plus.exe', and place this in the same
directory that `gcc-cc1.exe' is kept.
@@ -2068,14 +1809,13 @@ edit the file `tm.h' (created by `vmsconfig.com') to define the macro
`QSORT_WORKAROUND' is always defined when GNU CC is compiled with
VAX C, to avoid a problem in case `gcclib.olb' is not yet available.

File: INSTALL, Node: Collect2, Next: Header Dirs, Prev: VMS Install, Up: Installation
`collect2'
==========
GNU CC uses a utility called `collect2' on nearly all systems to
arrange to call various initialization functions at start time.
Many target systems do not have support in the assembler and linker
for "constructors"--initialization functions to be called before the
official "start" of `main'. On such systems, GNU CC uses a utility
called `collect2' to arrange to call these functions at start time.
The program `collect2' works by linking the program once and looking
through the linker output file for symbols with particular names
@@ -2136,9 +1876,6 @@ search path.
`collect2' searches for the utilities `nm' and `strip' using the
same algorithm as above for `ld'.

File: INSTALL, Node: Header Dirs, Prev: Collect2, Up: Installation
Standard Header File Directories
================================
@@ -2151,8 +1888,8 @@ before GNU CC is built. If the cross compilation header files are
already suitable for ANSI C and GNU CC, nothing special need be done).
`GPLUS_INCLUDE_DIR' means the same thing for native and cross. It
is where `g++' looks first for header files. The C++ library installs
only target independent header files in that directory.
is where `g++' looks first for header files. `libg++' installs only
target independent header files in that directory.
`LOCAL_INCLUDE_DIR' is used only for a native compiler. It is
normally `/usr/local/include'. GNU CC searches this directory so that
@@ -2167,22 +1904,3 @@ use. For a cross-compiler, this is the equivalent of `/usr/include'.
When you build a cross-compiler, `fixincludes' processes any header
files in this directory.

Tag Table:
Node: Installation351
Node: Configurations26618
Node: Other Dir65739
Node: Cross-Compiler67454
Node: Steps of Cross69284
Node: Configure Cross70401
Node: Tools and Libraries71037
Node: Cross Runtime73475
Node: Cross Headers77555
Node: Build Cross79553
Node: Sun Install81428
Node: VMS Install83099
Node: Collect293028
Node: Header Dirs95592

End Tag Table

View File

@@ -1,91 +0,0 @@
Right now there is no documentation for the GCC tree -> rtl interfaces
(or more generally the interfaces for adding new languages).
Such documentation would be of great benefit to the project. Until such
time as we can formally start documenting the interface this file will
serve as a repository for information on these interface and any incompatable
changes we've made.
Aug 31, 1998:
The interface to HANDLE_PRAGMA has changed. It now takes three arguments.
The first two are pointers to functions that should be used to read characters
from the input stream, and to push them back into the input stream respectively.
The third argument is a pointer to a null terminate string which is the first
word after #pragma. The expression supplied by HANDLE_PRAGMA should return
non-zero if it parsed and implemented the pragma. Otherwise it should return
zero, and leave the input stream as it was before the expression was evaluated.
A new back-end definable macro has been added: INSERT_ATTRIBUTES. This macro
allows backend to add attributes to decls as they are created.
Jun 10, 1998:
The interface to lang_decode_option has changed. It now uses and argc/argv
interface to allow for options that use more than one input string. The new
declaration is: int lang_decode_option (int argc, char** argv). It now
returns the number of input strings processed, or 0 if the option is
unknown.
Jun 7, 1998:
Front-ends must now define lang_init_options. It is safe for this
function to do nothing. See c-lang.c.
Apr 21, 1998:
Front ends which link with c-common or other files from the C/C++
front-ends may need to handle TI types. Look for references to
[unsigned]int_DI_type_node in your front end. If you have references
to these variables, you'll need up update the front end.
To update the front end you must mirror all the code which currently
deals with intDI_type_node to also handle intTI_type_node.
Apr 7, 1998:
The interface between toplev.c and the language front ends for opening the
source file has changed:
o init_lex() has been renamed to init_parse (char *filename) where filename
is the name of the source file.
o The code in toplev.c which opened the source file should be moved to
the new init_parse function.
o toplev.c now calls finish_parse() instead of closing the source file
using fclose(). This should now be done in finish_parse, if necessary.
Apr 1, 1998:
Front-ends must now define lang_print_xnode. It is safe for this
function to do nothing. See c-lang.c.
Feb 1, 1998:
GCC used to store structure sizes & offsets to elements as bitsize
quantities. This causes problems because a structure can only be
(target memsize / 8) bytes long (this may effect arrays too). This
is particularly problematical on machines with small address spaces.
So:
All trees that represent sizes in bits should have a TREE_TYPE of
bitsizetype (rather than sizetype).
Accordingly, when such values are computed / initialized, care has to
be takes to use / compute the proper type.
When a size in bits is converted into a size in bytes, which is expressed
in trees, care should be taken to change the tree's type again to sizetype.
We've updated C, C++, Fortran & Objective-C to work with the new
scheme. Other languages will need to be updated accordingly.
Contact amylaar@cygnus.com for additional information.
?? 1997:
In an effort to decrease cache thrashing and useless loads we've changed the
third argument to the DEFTREECODE macro to be a single char. This will
effect languages that defined their own tree codes (usually in a .def file).
Old way:
DEFTREECODE (CLASS_METHOD_DECL, "class_method_decl", "d", 0)
New way:
DEFTREECODE (CLASS_METHOD_DECL, "class_method_decl", 'd', 0)

File diff suppressed because it is too large Load Diff

376
gcc/NEWS
View File

@@ -1,344 +1,93 @@
Noteworthy changes in GCC after EGCS 1.1.
-----------------------------------------
Noteworthy changes in GCC version 2.8.0:
Target specific NEWS
The -specs=file switch allows you to override default specs used in invoking
programs like cc1, as, etc.
RS6000/PowerPC: -mcpu=401 was added as an alias for -mcpu=403. -mcpu=e603e
was added to do -mcpu=603e and -msoft-float.
Options -Wall and -Wimplicit now cause GCC to warn about implicit int
in declarations (e.g. `register i;'), since the C Standard committee
has decided to disallow this in the next revision of the standard.
Noteworthy changes in GCC for EGCS 1.1.
---------------------------------------
The compiler now implements global common subexpression elimination (gcse) as
well as global constant/copy propagation. (link to gcse page).
More major improvements have been made to the alias analysis code. A new
option to allow front-ends to provide alias information to the optimizers
has also been added (-fstrict-aliasing). -fstrict-aliasing is off by default
now, but will be enabled by default in the future. (link to alias page)
Major changes continue in the exception handling support. This release
includes some changes to reduce static overhead for exception handling. It
also includes some major changes to the setjmp/longjmp based EH mechanism to
make it less pessimistic. And finally, major infrastructure improvements
to the dwarf2 EH mechanism have been made to make our EH support extensible.
We have fixed the infamous security problems with temporary files.
The "regmove" optimization pass has been nearly completely rewritten. It now
uses much more information about the target to determine profitability of
transformations.
The compiler now recomputes register usage information immediately before
register allocation. Previously such information was only not kept up to
date after instruction combination which led to poor register allocation
choices by our priority based register allocator.
The register reloading phase of the compiler has been improved to better
optimize spill code. This primarily helps targets which generate lots of
spills (like the x86 ports and many register poor embedded ports).
A few changes in the heuristics used by the register allocator and scheduler
have been made which can significantly improve performance for certain
applications.
The compiler's branch shortening algorithms have been significantly improved
to work better on targets which align jump targets.
The compiler now supports the "ADDRESSOF" optimization which can significantly
reduce the overhead for certain inline calls (and inline calls in general).
The compiler now supports a code size optimization switch (-Os). When enabled
the compiler will prefer optimizations which improve code size over those
which improve code speed.
The compiler has been improved to completely eliminate library calls which
compute constant values. This is particularly useful on machines which
do not have integer mul/div or floating point support on-chip.
GCC now supports a "--help" option to print detailed help information.
cpplib has been greatly improved. It is probably useable for some sites now
(major missing feature is trigraphs).
Memory footprint for the compiler has been significantly reduced for certain
pathalogical cases.
Build time improvements for targets which support lots of sched parameters
(alpha and mips primarily).
Compile time for certain programs using large constant initializers has been
improved (effects glibc significantly).
Plus an incredible number of infrastructure changes, warning fixes, bugfixes
and local optimizations.
Various improvements have been made to better support cross compilations. They
are still not easy, but they are improving.
Target specific NEWS
Sparc: Now includes V8 plus and V9 support, lots of tuning for Ultrasparcs
and uses the Haifa scheduler by default.
Alpha: EV6 tuned, optimized expansion of memcpy/bzero.
x86: Data in the static store is aligned per Intel recommendations. Jump
targets are aligned per Intel recommendations. Improved epilogue
sequences for Pentium chips. Backend improvements which should help
register allocation on all x86 variants. Support for PPro conditional
move instructions has been fixed and enabled. Random changes
throughout the port to make generated code more Pentium friendly.
Improved support for 64bit integer operations.
Unixware 7, a System V Release 5 target is now supported.
SCO OpenServer targets can support GAS. See gcc/INSTALL for details.
RS6000/PowerPC: Includes AIX4.3 support as well as PowerPC64 support.
Haifa instruction scheduling is enabled by default now.
MIPS: Multiply/Multiply-Add support has been largely rewritten to generate
more efficient code. Includes mips16 support.
M68K: Various micro-optimizations and Coldfire fixes.
M32r: Major improvements to this port.
Arm: Includes Thumb and super interworking support.
EGCS includes all gcc2 changes up to and including the June 9, 1998 snapshot.
Noteworthy changes in GCC version 2.8.1
---------------------------------------
Numerous bugs have been fixed and some minor performance
improvements (compilation speed) have been made.
Noteworthy changes in GCC version 2.8.0
---------------------------------------
A major change in this release is the addition of a framework for
exception handling, currently used by C++. Many internal changes and
optimization improvements have been made. These increase the
maintainability and portability of GCC. GCC now uses autoconf to
compute many host parameters.
The following lists changes that add new features or targets.
See cp/NEWS for new features of C++ in this release.
New tools and features:
The Dwarf 2 debugging information format is supported on ELF systems, and
is the default for -ggdb where available. It can also be used for C++.
The Dwarf version 1 debugging format is also permitted for C++, but
does not work well.
gcov.c is provided for test coverage analysis and branch profiling
analysis is also supported; see -fprofile-arcs, -ftest-coverage,
and -fbranch-probabilities.
Support for the Checker memory checking tool.
New switch, -fstack-check, to check for stack overflow on systems that
don't have such built into their ABI.
New switches, -Wundef and -Wno-undef to warn if an undefined identifier
is evaluated in an #if directive.
Options -Wall and -Wimplicit now cause GCC to warn about implicit int
in declarations (e.g. `register i;'), since the C Standard committee
has decided to disallow this in the next revision of the standard;
-Wimplicit-function-declarations and -Wimplicit-int are subsets of
this.
Option -Wsign-compare causes GCC to warn about comparison of signed and
unsigned values.
Add -dI option of cccp for cxref.
New features in configuration, installation and specs file handling:
New option --enable-c-cpplib to configure script.
You can use --with-cpu on the configure command to specify the default
CPU that GCC should generate code for.
The -specs=file switch allows you to override default specs used in
invoking programs like cc1, as, etc.
Allow including one specs file from another and renaming a specs
variable.
You can now relocate all GCC files with a single environment variable
or a registry entry under Windows 95 and Windows NT.
Changes in Objective-C:
The Objective-C Runtime Library has been made thread-safe.
The Objective-C Runtime Library contains an interface for creating
mutexes, condition mutexes, and threads; it requires a back-end
implementation for the specific platform and/or thread package.
Currently supported are DEC/OSF1, IRIX, Mach, OS/2, POSIX, PCThreads,
Solaris, and Windows32. The --enable-threads parameter can be used
when configuring GCC to enable and select a thread back-end.
Objective-C is now configured as separate front-end language to GCC,
making it more convenient to conditionally build it.
The internal structures of the Objective-C Runtime Library have
changed sufficiently to warrant a new version number; now version 8.
Programs compiled with an older version must be recompiled.
The Objective-C Runtime Library can be built as a DLL on Windows 95
and Windows NT systems.
The Objective-C Runtime Library implements +load.
The following new targets are supported (see also list under each
individual CPU below):
The following new targets are supported:
Solaris 2.5 running on UltraSPARC's.
The sparclet cpu (a.out file format).
Solaris 2.51 running on PowerPC's.
Linux running on PowerPC's.
Embedded target m32r-elf.
Embedded Hitachi Super-H using ELF.
RTEMS real-time system on various CPU targets.
ARC processor.
NEC V850 processor.
Matsushita MN10200 processor.
Matsushita MN10300 processor.
Sparc and PowerPC running on VxWorks.
Support both glibc versions 1 and 2 on Linux-based GNU systems.
New features for DEC Alpha systems:
New features for the Hitachi H8/300(H).
Allow detailed specification of IEEE fp support:
-mieee, -mieee-with-inexact, and -mieee-conformant
-mfp-trap-mode=xxx, -mfp-round-mode=xxx, -mtrap-precision=xxx
-mcpu=xxx for CPU selection
Support scheduling parameters for EV5.
Add support for BWX, CIX, and MAX instruction set extensions.
Support Linux-based GNU systems.
Support VMS.
-malign-300
-ms
Additional supported processors and systems for MIPS targets:
MIPS4 instruction set.
R4100, R4300 and R5000 processors.
N32 and N64 ABI.
IRIX 6.2.
SNI SINIX.
New features for Intel x86 family:
Add scheduling parameters for Pentium and Pentium Pro.
Support stabs on Solaris-x86.
Intel x86 processors running the SCO OpenServer 5 family.
Intel x86 processors running DG/UX.
Intel x86 using Cygwin32 or Mingw32 on Windows 95 and Windows NT.
New features for Motorola 68k family:
Support for 68060 processor.
More consistent switches to specify processor.
Motorola 68k family running AUX.
68040 running pSOS, ELF object files, DBX debugging.
Coldfire variant of Motorola m68k family.
New features for the HP PA RISC:
-mspace and -mno-space
-mlong-load-store and -mno-long-load-store
-mbig-switch -mno-big-switch
GCC on the PA requires either gas-2.7 or the HP assembler; for best
results using GAS is highly recommended. GAS is required for -g and
exception handling support.
The -ms switch generates code for the Hitachi H8/S processor.
New features for SPARC-based systems:
The ultrasparc cpu.
The sparclet cpu, supporting only a.out file format.
Sparc running SunOS 4 with the GNU assembler.
Sparc running the Linux-based GNU system.
Embedded Sparc processors running the ELF object file format.
-mcpu=xxx
-mtune=xxx
-malign-loops=xxx
-malign-jumps=xxx
-malign-functions=xxx
-mimpure-text and -mno-impure-text
Options -mno-v8 and -mno-sparclite are no longer supported on SPARC
targets. Options -mcypress, -mv8, -msupersparc, -msparclite, -mf930,
and -mf934 are deprecated and will be deleted in GCC 2.9. Use
-mcpu=xxx instead.
New features for all rs6000 and PowerPC systems:
New features for rs6000 and PowerPC systems:
Solaris 2.51 running on PowerPC's.
The Linux-based GNU system running on PowerPC's.
-mcpu=604e,602,603e,620,801,823,mpc505,821,860,power2
-mcpu=604e
-mcpu=801
-mcpu=823
-mtune=xxx
-mrelocatable-lib, -mno-relocatable-lib
-msim, -mmve, -memb
-mupdate, -mno-update
-mfused-madd, -mno-fused-madd
-mupdate
-mno-update
-mfused-madd
-mno-fused-madd
New features for PowerPC-based systems running either System V, Linux, Solaris,
or embedded systems:
-mregnames
-meabi
-mcall-linux, -mcall-solaris, -mcall-sysv-eabi, -mcall-sysv-noeabi
-msdata, -msdata=none, -msdata=default, -msdata=sysv, -msdata=eabi
-memb, -msim, -mmvme
-myellowknife, -mads
wchar_t is now of type long as per the ABI, not unsigned short.
-mcall-linux
-mcall-solaris
-mcall-sysv-eabi
-mcall-sysv-noeabi
-msdata
-msdata=none
-msdata=default
-msdata=sysv
-msdata=eabi
-memb
-msim
-mmvme
wchar_t is now of type long, not unsigned short as per ABI.
-p/-pg support
-mcpu=403 now implies -mstrict-align.
Implement System V profiling.
Aix 4.1 GCC targets now default to -mcpu=common so that programs
compiled can be moved between rs6000 and powerpc based systems. A
consequence of this is that -static won't work, and that some programs
may be slightly slower.
Options -mno-v8 and -mno-sparclite are no longer supported on SPARC
targets. Options -mcypress, -mv8, -msupersparc, -msparclite, -mf930,
and -mf934 are deprecated and will be deleted in GCC 2.9.
Use -mcpu=xxx instead.
You can select the default value to use for -mcpu=xxx on rs6000 and
powerpc targets by using the --with-cpu=xxx option when configuring the
compiler. In addition, a new options, -mtune=xxx was added that
selects the machine to schedule for but does not select the
architecture level.
GCC on the PA requires either gas-2.7 or the HP assembler; for best
results using GAS is highly recommended. GAS is required for -g
and exception handling support.
Directory names used for storing the multilib libraries on System V
and embedded PowerPC systems have been shortened to work with commands
like tar that have fixed limits on pathname size.
Aix 4.1 GCC targets now default to -mcpu=common so that programs compiled can
be moved between rs6000 and powerpc based systems. A consequence of this is
that -static won't work, and that some programs may be slightly slower.
New features for the Hitachi H8/300(H):
You can select the default value to use for -mcpu=xxx on rs6000 and powerpc
targets by using the --with-cpu=xxx option when confiuring the compiler. In
addition, a new options, -mtune=xxx was added that selects the machine to
schedule for but does not select the architecture level.
-malign-300
-ms (for the Hitachi H8/S processor)
-mint32
Directory names used for storing the multilib libraries on System V and
embedded PowerPC systems have been shortened to work with commands like tar
that have fixed limits on pathname size.
New features for the ARM:
-march=xxx, -mtune=xxx, -mcpu=xxx
Support interworking with Thumb code.
ARM processor with a.out object format, COFF, or AOF assembler.
ARM on "semi-hosted" platform.
ARM running NetBSD.
ARM running the Linux-based GNU system.
New feature for Solaris systems:
GCC installation no longer makes a copy of system include files,
thus insulating GCC better from updates to the operating system.
Noteworthy changes in GCC version 2.7.2
---------------------------------------
Noteworthy changes in GCC version 2.7.2:
A few bugs have been fixed (most notably the generation of an
invalid assembler opcode on some RS/6000 systems).
Noteworthy changes in GCC version 2.7.1
---------------------------------------
Noteworthy changes in GCC version 2.7.1:
This release fixes numerous bugs (mostly minor) in GCC 2.7.0, but
also contains a few new features, mostly related to specific targets.
@@ -362,9 +111,8 @@ sequence used in GCC version 2.7.0. That calling sequence was based on the AIX
calling sequence without function descriptors. To compile code for that older
calling sequence, either configure the compiler for powerpc-*-eabiaix or use
the -mcall-aix switch when compiling and linking.
Noteworthy changes in GCC version 2.7.0
---------------------------------------
Noteworthy changes in GCC version 2.7.0:
GCC now works better on systems that use ".obj" and ".exe" instead of
".o" and no extension. This involved changes to the driver program,
@@ -616,7 +364,7 @@ The following new configurations are supported:
GNU on x86 (instead of treating it like MACH)
NetBSD on Sparc and Motorola 68k
AIX 4.1 on RS/6000 and PowerPC systems
Sequent DYNIX/ptx 1.x and 2.x.
Sequent DYNUX/ptx 1.x and 2.x.
Both COFF and ELF configurations on AViiON without using /bin/gcc
Windows/NT on x86 architecture; preliminary
AT&T DSP1610 digital signal processor chips
@@ -840,7 +588,7 @@ to declare complex data types. See the manual for details.
* GCC now supports `long double' meaningfully on the Sparc (128-bit
floating point) and on the 386 (96-bit floating point). The Sparc
support is enabled on Solaris 2.x because earlier system versions
support is enabled on on Solaris 2.x because earlier system versions
(SunOS 4) have bugs in the emulation.
* All targets now have assertions for cpu, machine and system. So you

4003
gcc/ORDERS Normal file

File diff suppressed because it is too large Load Diff

448
gcc/PROJECTS Normal file
View File

@@ -0,0 +1,448 @@
0. Improved efficiency.
* Parse and output array initializers an element at a time, freeing
storage after each, instead of parsing the whole initializer first and
then outputting. This would reduce memory usage for large
initializers.
* See if the techniques describe in Oct 1991 SIGPLAN Notices
(Frazer and Hanson) are applicable to GCC.
1. Better optimization.
* Constants in unused inline functions
It would be nice to delay output of string constants so that string
constants mentioned in unused inline functions are never generated.
Perhaps this would also take care of string constants in dead code.
The difficulty is in finding a clean way for the RTL which refers
to the constant (currently, only by an assembler symbol name)
to point to the constant and cause it to be output.
* More cse
The techniques for doing full global cse are described in the red
dragon book, or (a different version) in Frederick Chow's thesis from
Stanford. It is likely to be slow and use a lot of memory, but it
might be worth offering as an additional option.
It is probably possible to extend cse to a few very frequent cases
without so much expense.
For example, it is not very hard to handle cse through if-then
statements with no else clauses. Here's how to do it. On reaching a
label, notice that the label's use-count is 1 and that the last
preceding jump jumps conditionally to this label. Now you know it
is a simple if-then statement. Remove from the hash table
all the expressions that were entered since that jump insn
and you can continue with cse.
It is probably not hard to handle cse from the end of a loop
around to the beginning, and a few loops would be greatly sped
up by this.
* Optimize a sequence of if statements whose conditions are exclusive.
It is possible to optimize
if (x == 1) ...;
if (x == 2) ...;
if (x == 3) ...;
into
if (x == 1) ...;
else if (x == 2) ...;
else if (x == 3) ...;
provided that x is not altered by the contents of the if statements.
It's not certain whether this is worth doing. Perhaps programmers
nearly always write the else's themselves, leaving few opportunities
to improve anything.
* Un-cse.
Perhaps we should have an un-cse step right after cse, which tries to
replace a reg with its value if the value can be substituted for the
reg everywhere, if that looks like an improvement. Which is if the
reg is used only a few times. Use rtx_cost to determine if the
change is really an improvement.
* Clean up how cse works.
The scheme is that each value has just one hash entry. The
first_same_value and next_same_value chains are no longer needed.
For arithmetic, each hash table elt has the following slots:
* Operation. This is an rtx code.
* Mode.
* Operands 0, 1 and 2. These point to other hash table elements.
So, if we want to enter (PLUS:SI (REG:SI 30) (CONST_INT 104)), we
first enter (CONST_INT 104) and find the entry that (REG:SI 30) now
points to. Then we put these elts into operands 0 and 1 of a new elt.
We put PLUS and SI into the new elt.
Registers and mem refs would never be entered into the table as such.
However, the values they contain would be entered. There would be a
table indexed by regno which points at the hash entry for the value in
that reg.
The hash entry index now plays the role of a qty number.
We still need qty_first_reg, reg_next_eqv, etc. to record which regs
share a particular qty.
When a reg is used whose contents are unknown, we need to create a
hash table entry whose contents say "unknown", as a place holder for
whatever the reg contains. If that reg is added to something, then
the hash entry for the sum will refer to the "unknown" entry. Use
UNKNOWN for the rtx code in this entry. This replaces make_new_qty.
For a constant, a unique hash entry would be made based on the
value of the constant.
What about MEM? Each time a memory address is referenced, we need a
qty (a hash table elt) to represent what is in it. (Just as for a
register.) If this isn't known, create one, just as for a reg whose
contents are unknown.
We need a way to find all mem refs that still contain a certain value.
Do this with a chain of hash elts (for memory addresses) that point to
locations that hold the value. The hash elt for the value itself should
point to the start of the chain. It would be good for the hash elt
for an address to point to the hash elt for the contents of that address
(but this ptr can be null if the contents have never been entered).
With this data structure, nothing need ever be invalidated except
the lists of which regs or mems hold a particular value. It is easy
to see if there is a reg or mem that is equiv to a particular value.
If the value is constant, it is always explicitly constant.
* Support more general tail-recursion among different functions.
This might be possible under certain circumstances, such as when
the argument lists of the functions have the same lengths.
Perhaps it could be done with a special declaration.
You would need to verify in the calling function that it does not
use the addresses of any local variables and does not use setjmp.
* Put short statics vars at low addresses and use short addressing mode?
Useful on the 68000/68020 and perhaps on the 32000 series,
provided one has a linker that works with the feature.
This is said to make a 15% speedup on the 68000.
* Keep global variables in registers.
Here is a scheme for doing this. A global variable, or a local variable
whose address is taken, can be kept in a register for an entire function
if it does not use non-constant memory addresses and (for globals only)
does not call other functions. If the entire function does not meet
this criterion, a loop may.
The VAR_DECL for such a variable would have to have two RTL expressions:
the true home in memory, and the pseudo-register used temporarily.
It is necessary to emit insns to copy the memory location into the
pseudo-register at the beginning of the function or loop, and perhaps
back out at the end. These insns should have REG_EQUIV notes so that,
if the pseudo-register does not get a hard register, it is spilled into
the memory location which exists in any case.
The easiest way to set up these insns is to modify the routine
put_var_into_stack so that it does not apply to the entire function
(sparing any loops which contain nothing dangerous) and to call it at
the end of the function regardless of where in the function the
address of a local variable is taken. It would be called
unconditionally at the end of the function for all relevant global
variables.
For debugger output, the thing to do is to invent a new binding level
around the appropriate loop and define the variable name as a register
variable with that scope.
* Live-range splitting.
Currently a variable is allocated a hard register either for the full
extent of its use or not at all. Sometimes it would be good to
allocate a variable a hard register for just part of a function; for
example, through a particular loop where the variable is mostly used,
or outside of a particular loop where the variable is not used. (The
latter is nice because it might let the variable be in a register most
of the time even though the loop needs all the registers.)
It might not be very hard to do this in global.c when a variable
fails to get a hard register for its entire life span.
The first step is to find a loop in which the variable is live, but
which is not the whole life span or nearly so. It's probably best to
use a loop in which the variable is heavily used.
Then create a new pseudo-register to represent the variable in that loop.
Substitute this for the old pseudo-register there, and insert move insns
to copy between the two at the loop entry and all exits. (When several
such moves are inserted at the same place, some new feature should be
added to say that none of those registers conflict merely because of
overlap between the new moves. And the reload pass should reorder them
so that a store precedes a load, for any given hard register.)
After doing this for all the reasonable candidates, run global-alloc
over again. With luck, one of the two pseudo-registers will be fit
somewhere. It may even have a much higher priority due to its reduced
life span.
There will be no room in general for the new pseudo-registers in
basic_block_live_at_start, so there will need to be a second such
matrix exclusively for the new ones. Various other vectors indexed by
register number will have to be made bigger, or there will have to be
secondary extender vectors just for global-alloc.
A simple new feature could arrange that both pseudo-registers get the
same stack slot if they both fail to get hard registers.
Other compilers split live ranges when they are not connected, or
try to split off pieces `at the edge'. I think splitting around loops
will provide more speedup.
Creating a fake binding block and a new like-named variable with
shorter life span and different address might succeed in describing
this technique for the debugger.
* Detect dead stores into memory?
A store into memory is dead if it is followed by another store into
the same location; and, in between, there is no reference to anything
that might be that location (including no reference to a variable
address).
* Loop optimization.
Strength reduction and iteration variable elimination could be
smarter. They should know how to decide which iteration variables are
not worth making explicit because they can be computed as part of an
address calculation. Based on this information, they should decide
when it is desirable to eliminate one iteration variable and create
another in its place.
It should be possible to compute what the value of an iteration
variable will be at the end of the loop, and eliminate the variable
within the loop by computing that value at the loop end.
When a loop has a simple increment that adds 1,
instead of jumping in after the increment,
decrement the loop count and jump to the increment.
This allows aob insns to be used.
* Using constraints on values.
Many operations could be simplified based on knowledge of the
minimum and maximum possible values of a register at any particular time.
These limits could come from the data types in the tree, via rtl generation,
or they can be deduced from operations that are performed. For example,
the result of an `and' operation one of whose operands is 7 must be in
the range 0 to 7. Compare instructions also tell something about the
possible values of the operand, in the code beyond the test.
Value constraints can be used to determine the results of a further
comparison. They can also indicate that certain `and' operations are
redundant. Constraints might permit a decrement and branch
instruction that checks zeroness to be used when the user has
specified to exit if negative.
* Smarter reload pass.
The reload pass as currently written can reload values only into registers
that are reserved for reloading. This means that in order to use a
register for reloading it must spill everything out of that register.
It would be straightforward, though complicated, for reload1.c to keep
track, during its scan, of which hard registers were available at each
point in the function, and use for reloading even registers that were
free only at the point they were needed. This would avoid much spilling
and make better code.
* Change the type of a variable.
Sometimes a variable is declared as `int', it is assigned only once
from a value of type `char', and then it is used only by comparison
against constants. On many machines, better code would result if
the variable had type `char'. If the compiler could detect this
case, it could change the declaration of the variable and change
all the places that use it.
* Better handling for very sparse switches.
There may be cases where it would be better to compile a switch
statement to use a fixed hash table rather than the current
combination of jump tables and binary search.
* Order of subexpressions.
It might be possible to make better code by paying attention
to the order in which to generate code for subexpressions of an expression.
* More code motion.
Consider hoisting common code up past conditional branches or
tablejumps.
* Trace scheduling.
This technique is said to be able to figure out which way a jump
will usually go, and rearrange the code to make that path the
faster one.
* Distributive law.
The C expression *(X + 4 * (Y + C)) compiles better on certain
machines if rewritten as *(X + 4*C + 4*Y) because of known addressing
modes. It may be tricky to determine when, and for which machines, to
use each alternative.
Some work has been done on this, in combine.c.
* Can optimize by changing if (x) y; else z; into z; if (x) y;
if z and x do not interfere and z has no effects not undone by y.
This is desirable if z is faster than jumping.
* For a two-insn loop on the 68020, such as
foo: movb a2@+,a3@+
jne foo
it is better to insert dbeq d0,foo before the jne.
d0 can be a junk register. The challenge is to fit this into
a portable framework: when can you detect this situation and
still be able to allocate a junk register?
2. Simpler porting.
Right now, describing the target machine's instructions is done
cleanly, but describing its addressing mode is done with several
ad-hoc macro definitions. Porting would be much easier if there were
an RTL description for addressing modes like that for instructions.
Tools analogous to genflags and genrecog would generate macros from
this description.
There would be one pattern in the address-description file for each
kind of addressing, and this pattern would have:
* the RTL expression for the address
* C code to verify its validity (since that may depend on
the exact data).
* C code to print the address in assembler language.
* C code to convert the address into a valid one, if it is not valid.
(This would replace LEGITIMIZE_ADDRESS).
* Register constraints for all indeterminates that appear
in the RTL expression.
3. Other languages.
Front ends for Pascal, Fortran, Algol, Cobol, Modula-2 and Ada are
desirable.
Pascal, Modula-2 and Ada require the implementation of functions
within functions. Some of the mechanisms for this already exist.
4. More extensions.
* Generated unique labels. Have some way of generating distinct labels
for use in extended asm statements. I don't know what a good syntax would
be.
* A way of defining a structure containing a union, in which the choice of
union alternative is controlled by a previous structure component.
Here is a possible syntax for this.
struct foo {
enum { INT, DOUBLE } code;
auto union { case INT: int i; case DOUBLE: double d;} value : code;
};
* Allow constructor expressions as lvalues, like this:
(struct foo) {a, b, c} = foo();
This would call foo, which returns a structure, and then store the
several components of the structure into the variables a, b, and c.
5. Generalize the machine model.
* Some new compiler features may be needed to do a good job on machines
where static data needs to be addressed using base registers.
* Some machines have two stacks in different areas of memory, one used
for scalars and another for large objects. The compiler does not
now have a way to understand this.
6. Useful warnings.
* Warn about statements that are undefined because the order of
evaluation of increment operators makes a big difference. Here is an
example:
*foo++ = hack (*foo);
7. Better documentation of how GCC works and how to port it.
Here is an outline proposed by Allan Adler.
I. Overview of this document
II. The machines on which GCC is implemented
A. Prose description of those characteristics of target machines and
their operating systems which are pertinent to the implementation
of GCC.
i. target machine characteristics
ii. comparison of this system of machine characteristics with
other systems of machine specification currently in use
B. Tables of the characteristics of the target machines on which
GCC is implemented.
C. A priori restrictions on the values of characteristics of target
machines, with special reference to those parts of the source code
which entail those restrictions
i. restrictions on individual characteristics
ii. restrictions involving relations between various characteristics
D. The use of GCC as a cross-compiler
i. cross-compilation to existing machines
ii. cross-compilation to non-existent machines
E. Assumptions which are made regarding the target machine
i. assumptions regarding the architecture of the target machine
ii. assumptions regarding the operating system of the target machine
iii. assumptions regarding software resident on the target machine
iv. where in the source code these assumptions are in effect made
III. A systematic approach to writing the files tm.h and xm.h
A. Macros which require special care or skill
B. Examples, with special reference to the underlying reasoning
IV. A systematic approach to writing the machine description file md
A. Minimal viable sets of insn descriptions
B. Examples, with special reference to the underlying reasoning
V. Uses of the file aux-output.c
VI. Specification of what constitutes correct performance of an
implementation of GCC
A. The components of GCC
B. The itinerary of a C program through GCC
C. A system of benchmark programs
D. What your RTL and assembler should look like with these benchmarks
E. Fine tuning for speed and size of compiled code
VII. A systematic procedure for debugging an implementation of GCC
A. Use of GDB
i. the macros in the file .gdbinit for GCC
ii. obstacles to the use of GDB
a. functions implemented as macros can't be called in GDB
B. Debugging without GDB
i. How to turn off the normal operation of GCC and access specific
parts of GCC
C. Debugging tools
D. Debugging the parser
i. how machine macros and insn definitions affect the parser
E. Debugging the recognizer
i. how machine macros and insn definitions affect the recognizer
ditto for other components
VIII. Data types used by GCC, with special reference to restrictions not
specified in the formal definition of the data type
IX. References to the literature for the algorithms used in GCC

View File

@@ -1,8 +1,8 @@
This directory contains the GNU Compiler Collection (GCC) version 2.95.
It includes all of the support for compiling C, C++, Objective C, Fortran,
Java, and Chill.
This directory contains the version 2.7.2 release of the GNU C
compiler. It includes all of the support for compiling C++ and
Objective C, including a run-time library for Objective C.
The GNU Compiler Collection is free software. See the file COPYING for copying
The GNU C compiler is free software. See the file COPYING for copying
permission.
See the file gcc.texi (together with other files that it includes) for

View File

@@ -1,48 +0,0 @@
This file describes the implementation notes of the GNU C Compiler for
the Texas Instruments Floating Point Digital Signal Processor
families, TMS320C3x and TMS320C4x (including the C30, C31, C32, C40,
and C44 chips).
Currently, only two code variants are generated---those for the C3x
and C4x architectures. Note that the new operand combinations for
parallel instructions, included in newer silicon revisions, are not
yet supported. These should be trivial to add for someone with the
newer chips and the inclination.
While the generated assembly code is fairly similar to that recognised
by the TI assembler, there are a few differences (currently the machine
option -mti, designed to enfore compatibility, is not fully
implemented). The major difference is the use of the ^ operator to
load the 16 MSBs of an address or constant for the C4x.
The generated assembly code requires the GNU assembler (GAS). This is
not currently included as part of the binutils package, due to the
many hacks required to be compatible with TI's kludged COFF
implementation, and the binutils not being designed for 32-bit bytes.
Patches against binutils-2.7.2 can be obtained from
http://www.elec.canterbury.ac.nz/c4x. This site also has patches for
the GNU debugger (GDB), incoporating a cycle accurate simulator that
can display profiles and histories of code execution, detailing
pipeline conflicts etc.
GCC can be configured as a cross compiler for both the C3x and C4x
architectures on the same system. Use `configure --target=c4x' to
configure GCC for both the C3x and C4x. Then use the -m30 option to
generate code for the C30 or -m40 (the default) for the C40.
Further installation notes and other optimization patches for the C4x
target can also be obtained from http://www.elec.canterbury.ac.nz/c4x.
A Majordomo mailing list, gcc_c40@atlantek.com.au, exists to discuss
related issues and suggestions for further optimizations. To
subscribe send a message with `subscribe gcc_c40' in the body to
majordomo@atlantek.com.au.
Michael Hayes, 26 Nov 98

View File

@@ -11,7 +11,7 @@ For general information about the DWARF debugging information language,
you should obtain the DWARF version 1 specification document (and perhaps
also the DWARF version 2 draft specification document) developed by the
UNIX International Programming Languages Special Interest Group. A copy
of the DWARF version 1 specification (in PostScript form) may be
of the the DWARF version 1 specification (in PostScript form) may be
obtained either from me <rfg@netcom.com> or from the main Data General
FTP server. (See below.) The file you are looking at now only describes
known deviations from the DWARF version 1 specification, together with
@@ -117,7 +117,7 @@ more of the formal parameter values, they may not have been "homed" yet,
so you may get inaccurate answers (or perhaps even addressing errors).
Some people may consider this simply a non-feature, but I consider it a
bug, and I hope to provide some GNU-specific attributes (on function
bug, and I hope to provide some some GNU-specific attributes (on function
DIEs) which will specify the address of the end of the prologue and the
address of the beginning of the epilogue in a future release.
@@ -159,7 +159,7 @@ is required by the current DWARF draft specification.
Specifically, the current DWARF draft specification seems to require that
the type of an non-unsigned integral bit-field member of a struct or union
type be represented as either a "signed" type or as a "plain" type,
depending upon the exact set of keywords that were used in the
depending upon the the exact set of keywords that were used in the
type specification for the given bit-field member. It was felt (by the
UI/PLSIG) that this distinction between "plain" and "signed" integral types
could have some significance (in the case of bit-fields) because ANSI C

View File

@@ -1,55 +1,6 @@
This file describes the implementation notes of the GNU C Compiler for
the National Semiconductor 32032 chip (and 32000 family).
Much of this file was obsolete. It described restrictions caused by
bugs in early versions of of the ns32032 chip and by bugs in sequent
assemblers and linkers of the time.
Many (all?) of the chip bugs were fixed in later revisions and
certainly fixed by later chips in the same series (ns32332 and
ns32532).
Conditional code to support sequent assembler and/or linker restrictions
has not been removed deliberately, but has probably not been tested in
a *very* long time.
Support for one sequent assembler bug has *not* been retained.
It was necessary to say:
addr _x,rn
cmpd _p,rn
rather than:
cmpd _p,@_x
This used to be forced by the use of "rmn" register constraints rather
than "g". This is bad for other platforms which do not have this
restraint.
It is likely that there are no Balance 8000's still in operation, but
if there are and the assembler bug was never fixed then the easiest
way to run gcc would be to also run gas.
The code required by the sequent assembler is still generated when the
-fpic flag is in effect and this is forced by the appropriate
definition of LEGITIMATE_PIC_OPERAND_P. If support for the old sequent
assembler bug is required, then this could be achieved by adding the
test from LEGITIMATE_PIC_OPERAND to the GO_IF_LEGITIMATE_ADDRESS
definition. Of course, this should be conditional on something in the
sequent.h config file.
The original contents of this file appear below as an historical note.
SEQUENT_ADDRESS_BUG mentioned below has been replaced by
INDEX_RATHER_THAN_BASE. Note that merlin.h still defines
SEQUENT_ADDRESS_BUG even though it is not used anywhere. Since it has
been like this for a long time, presumably either the
SEQUENT_ADDRESS_BUG is not required for the merlin, or no one is using
gcc on the merlin anymore.
HISTORICAL NOTE
The 32032 machine description and configuration file for this compiler
is, for NS32000 family machine, primarily machine independent.
However, since this release still depends on vendor-supplied

View File

@@ -1,107 +1,3 @@
AIX 4.3 archive libraries
AIX 4.3 utilizes a new "large format" archive to support both 32-bit and
64-bit object modules. The routines provided in AIX 4.3.0 and AIX 4.3.1
to parse archive libraries did not handle the new format correctly. These
routines are used by GCC and result in error messages during linking such
as "not a COFF file". The version of the routines shipped with AIX 4.3.1
should work for a 32-bit environment. The "-g" option of the archive
command may be used to create archives of 32-bit objects using the
original "small format". A correct version of the routines is shipped
with AIX 4.3.2.
AIX 4.3.2 binder
The AIX 4.3.2.1 linker (bos.rte.bind_cmds Level 4.3.2.1) will dump core
with a segmentation fault when invoked by any version of GCC. A fix for
APAR IX87327 will be available from IBM Customer Support.
AIX 4.3.0 assembler
The AIX 4.3.0.0 assembler generates incorrect object files if the ".bs"
pseudo-op references symbols in certain sections. If GCC is invoked with
the -g debugging option (including during bootstrapping), incorrect object
files will be produced and the AIX linker will fail with a severe error.
A fix for APAR IX74254 (64BIT DISASSEMBLED OUPUT FROM COMPILER FAILS TO
ASSEMBLE/BIND) is available from IBM Customer Support and from its
service.boulder.ibm.com website as PTF U453956.
AIX 4.1 binder
Some versions of the AIX binder (linker) can fail with a relocation
overflow severe error when the -bbigtoc option is used to link
GCC-produced object files into an executable that overflows the TOC.
Linking f771, the GNU Fortran backend, will fail in this manner. A fix
for APAR IX75823 (OVERFLOW DURING LINK WHEN USING GCC AND -BBIGTOC) is
available from IBM Customer Support and from its website as PTF U455193.
Due to changes in the way that GCC invokes the binder (linker) for AIX 4.1,
the link step now may produce warnings of duplicate symbols which were not
reported before. The assembly files generated by GCC for AIX always have
included multiple symbol definitions for certain global variable and
function declarations in the original program. The warnings should not
prevent the linker from producing a correct library or runnable executable.
AIX NLS problems
AIX on the RS/6000 provides support (NLS) for environments outside of
the United States. Compilers and assemblers use NLS to support
locale-specific representations of various objects including
floating-point numbers ("." vs "," for separating decimal fractions).
There have been problems reported where the library linked with GCC does
not produce the same floating-point formats that the assembler accepts.
If you have this problem, set the LANG environment variable to "C" or
"En_US".
AIX 3.2.5 XLC-1.3 problems
XLC version 1.3.0.0 distributed with AIX 3.2.5 will miscompile jump.c when
building the stage1 compiler during the bootstrap process. This will cause
GCC to crash and the bootstrap to fail later while compiling libgcc2.c. XLC
version 1.3.0.1 or later fixes this problem. XLC-1.3.0.19 also cannot
bootstrap GCC so please avoid that release as well. You can obtain
XLC-1.3.0.24 by requesting PTF 432238 from IBM, or just ask for the latest
release of XLC-1.3.
There also have been reports of problems bootstrapping GCC with some older
releases of xlc-1.2.1, including xlc-1.2.1.8. Newer releases of xlc-1.2.1
do not exhibit this problem: xlc-1.2.1.28 is known to bootstrap properly.
AIX 3.2 common-mode support
AIX common-mode providing transparent support of both the POWER and PowerPC
architectures is usable in AIX 3.2.3 and above but an export file and
support for hidden export via libc.a will not exist until AIX 4.1. libgcc.a
also must be compiled in common-mode. Note that executables generated for
the POWER (RIOS1 and RSC) architecture will run directly on systems using
the MPC601 chip. Common-mode only improves the performance of a single
executable run on both POWER and PowerPC architecture platforms by not using
POWER- or PowerPC-specific instructions and eliminating the need to trap to
emulation (for POWER instructions run on PowerPC).
To link a common-mode application prior to AIX 4.1 and run it on a system at
AIX level 3.2.3 or above, use the text between the "<>" as an export file
(e.g. milli.exp)
<><><><><><><><><><><>
#!
__mulh 0x3100
__mull 0x3180
__divss 0x3200
__divus 0x3280
__quoss 0x3300
__quous 0x3380
<><><><><><><><><><><>
and then link with -Wl,-bI:milli.exp.
AIX 3.1 and 3.2 assembler problems
Specifying the -g flag to GCC on the RS/6000 requires upgrading the
@@ -131,7 +27,8 @@ assembler.
Any customer can order and get the replacement assembler, and install it on
one or more machines. It is available on diskette from IBM Customer Support
and from its website.
and from the IBM Internet fix anonymous ftp server (FixDist) at
aix.boulder.ibm.com (198.17.57.66).
If you contact IBM Customer Support, they may also ask you for your customer
number. If you do not know it, you will still be able to get the fix, but
@@ -146,3 +43,69 @@ an assembler modified after October 16th, 1995 in order to build the GNU C
compiler. This is because the GNU C compiler wants to build a variant of its
library, libgcc.a with the -mcpu=common switch to support building programs
that can run on either the Power or PowerPC machines.
AIX NLS problems
AIX on the RS/6000 provides support (NLS) for environments outside of
the United States. Compilers and assemblers use NLS to support
locale-specific representations of various objects including
floating-point numbers ("." vs "," for separating decimal fractions).
There have been problems reported where the library linked with GCC does
not produce the same floating-point formats that the assembler accepts.
If you have this problem, set the LANG environment variable to "C" or
"En_US".
AIX 3.2.5 XLC-1.3 problems
XLC version 1.3.0.0 distributed with AIX 3.2.5 will miscompile jump.c when
building the stage1 compiler during the bootstrap process. This will cause
GCC to crash and the bootstrap to fail later while compiling libgcc2.c. XLC
version 1.3.0.1 or later fixes this problem. XLC-1.3.0.19 also cannot
bootstrap GCC so please avoid that release as well. You can obtain
XLC-1.3.0.24 by requesting PTF 432238 from IBM, or just ask for the latest
release of XLC-1.3.
There also have been reports of problems bootstrapping GCC with some older
releases of xlc-1.2.1, including xlc-1.2.1.8. Newer releases of xlc-1.2.1
do not exhibit this problem: xlc-1.2.1.28 is known to bootstrap properly.
AIX 3.2 common-mode support
AIX common-mode providing transparent support of both the POWER and PowerPC
architectures is usable in AIX 3.2.3 and above but an export file and
support for hidden export via libc.a will not exist until AIX 4.1. libgcc.a
also must be compiled in common-mode. Note that executables generated for
the POWER (RIOS1 and RSC) architecture will run directly on systems using
the MPC601 chip. Common-mode only improves the performance of a single
executable run on both POWER and PowerPC architecture platforms by not using
POWER- or PowerPC-specific instructions and eliminating the need to trap to
emulation (for POWER instructions run on PowerPC).
To link a common-mode application prior to AIX 4.1 and run it on a system at
AIX level 3.2.3 or above, use the text between the "<>" as an export file
(e.g. milli.exp)
<><><><><><><><><><><>
#!
__mulh 0x3100
__mull 0x3180
__divss 0x3200
__divus 0x3280
__quoss 0x3300
__quous 0x3380
<><><><><><><><><><><>
and then link with -Wl,-bI:milli.exp.
AIX 4.1 binder
Due to changes in the way that GCC invokes the binder (linker) for AIX 4.1,
the link step now may produce warnings of duplicate symbols which were not
reported before. The assembly files generated by GCC for AIX always have
included multiple symbol definitions for certain global variable and
function declarations in the original program. The warnings should not
prevent the linker from producing a correct library or runnable executable.

View File

@@ -20,7 +20,7 @@ IF YOU THINK YOU MIGHT COMPILE X FOR SOLARIS 2, then you really don't
need this patch: get /contrib/R5.SunOS5.patch.tar.Z from
export.lcs.mit.edu instead. It has everything you need to do the
build for Solaris 2, sets you up to everything with GCC, and is
backward compatible with SunOS 4.*. Get the README
backward compatible with Sunos 4.*. Get the the README
(/contrib/R5.SunOS5.patch.README at export) for more info.
If you see undefined symbols _dlopen, _dlsym, or _dlclose when linking

View File

@@ -1,435 +0,0 @@
The following patches are needed in order to build GNAT with EGCS.
These patches were tested with egcs-980308 and gnat-3.10p on a mips-sgi-irix6.3
system. The gnat build succeeded as per the instructions in the gnat
README.BUILD file for building one library, except that CFLAGS="-O -g" and
GNATLIBCFLAGS="-O -g" were substituted for the recommended "-O2" so that the
build could be debugged. There was no attempt to run the resulting build
against any testsuite or validation suite.
--
Developers Notes:
Every use of sizetype in the Ada front end should be checked to see if perhaps
it should be using bitsizetype instead. The change to maybe_pad_type is just
a hack to work around this problem, and may not be desirable in the long term.
There are many places in the Ada front end where it calls operand_equal_p to
see if two type sizes are the same. operand_equal_p fails if the two
arguments have different TYPE_MODEs. sizetype and bitsizetype can have
different TYPE_MODEs. Thus this code can fail if one type size is based
on sizetype, and the other is based on bitsizetype. The change to
maybe_pad_type fixes one very critical place where this happens. There may
be others.
--
Mon Mar 16 11:00:25 1998 Jim Wilson <wilson@cygnus.com>
* a-gtran3.c (maybe_pad_type): Convert both size and orig_size to
sizetype if they have differing modes.
* a-misc.c (gnat_tree_code_type): Change from string to char array.
(init_lex): Delete realloc calls for tree_code_* globals. Adjust
bcopy call for gnat_tree_code_type change.
* a-tree.def: Adjust for tree_code_* type changes.
* a-misc.c (init_lex): Rename to init_parse.
diff -c ada/a-gtran3.c /home/brolley/comp/egcs/tmp/ada/a-gtran3.c
*** ada/a-gtran3.c Mon Mar 30 16:29:04 1998
--- /home/brolley/comp/egcs/tmp/ada/a-gtran3.c Thu Apr 2 17:16:15 1998
***************
*** 3329,3334 ****
--- 3329,3341 ----
isn't changing. Likewise, clear the alignment if it isn't being
changed. Then return if we aren't doing anything. */
+ if (size != 0
+ && TYPE_MODE (TREE_TYPE (size)) != TYPE_MODE (TREE_TYPE (orig_size)))
+ {
+ size = convert (sizetype, size);
+ orig_size = convert (sizetype, orig_size);
+ }
+
if (size != 0
&& (operand_equal_p (size, orig_size, 0)
|| (TREE_CODE (orig_size) == INTEGER_CST
diff -c ada/a-misc.c /home/brolley/comp/egcs/tmp/ada/a-misc.c
*** ada/a-misc.c Mon Mar 30 16:29:05 1998
--- /home/brolley/comp/egcs/tmp/ada/a-misc.c Thu Apr 2 17:36:19 1998
***************
*** 70,77 ****
#define DEFTREECODE(SYM, NAME, TYPE, LENGTH) TYPE,
! char *gnat_tree_code_type[] = {
! "x",
#include "a-tree.def"
};
#undef DEFTREECODE
--- 70,77 ----
#define DEFTREECODE(SYM, NAME, TYPE, LENGTH) TYPE,
! char gnat_tree_code_type[] = {
! 'x',
#include "a-tree.def"
};
#undef DEFTREECODE
***************
*** 254,259 ****
--- 254,268 ----
print_lang_statistics ()
{}
+ void
+ lang_print_xnode (file, node, indent)
+ FILE *file;
+ tree node;
+ int indent;
+ {
+ }
+
+
/* integrate_decl_tree calls this function, but since we don't use the
DECL_LANG_SPECIFIC field, this is a no-op. */
***************
*** 603,622 ****
it, but it's where g++ does it. */
void
! init_lex ()
{
lang_expand_expr = gnat_expand_expr;
- tree_code_type
- = (char **) realloc (tree_code_type,
- sizeof (char *) * LAST_GNAT_TREE_CODE);
- tree_code_length
- = (int *) realloc (tree_code_length,
- sizeof (int) * LAST_GNAT_TREE_CODE);
- tree_code_name
- = (char **) realloc (tree_code_name,
- sizeof (char *) * LAST_GNAT_TREE_CODE);
-
bcopy ((char *) gnat_tree_code_type,
(char *) (tree_code_type + (int) LAST_AND_UNUSED_TREE_CODE),
((LAST_GNAT_TREE_CODE - (int) LAST_AND_UNUSED_TREE_CODE)
--- 612,622 ----
it, but it's where g++ does it. */
void
! init_parse (filename)
! char *filename;
{
lang_expand_expr = gnat_expand_expr;
bcopy ((char *) gnat_tree_code_type,
(char *) (tree_code_type + (int) LAST_AND_UNUSED_TREE_CODE),
((LAST_GNAT_TREE_CODE - (int) LAST_AND_UNUSED_TREE_CODE)
***************
*** 629,636 ****
bcopy ((char *) gnat_tree_code_name,
(char *) (tree_code_name + (int) LAST_AND_UNUSED_TREE_CODE),
! ((LAST_GNAT_TREE_CODE - (int) LAST_AND_UNUSED_TREE_CODE)
! * sizeof (char *)));
}
/* Sets some debug flags for the parsed. It does nothing here. */
--- 629,640 ----
bcopy ((char *) gnat_tree_code_name,
(char *) (tree_code_name + (int) LAST_AND_UNUSED_TREE_CODE),
! LAST_GNAT_TREE_CODE - (int) LAST_AND_UNUSED_TREE_CODE);
! }
!
! void
! finish_parse ()
! {
}
/* Sets some debug flags for the parsed. It does nothing here. */
diff -c ada/a-tree.def /home/brolley/comp/egcs/tmp/ada/a-tree.def
*** ada/a-tree.def Mon Mar 30 16:29:09 1998
--- /home/brolley/comp/egcs/tmp/ada/a-tree.def Thu Apr 2 17:20:38 1998
***************
*** 31,69 ****
The only field used if TREE_COMPLEXITY, which contains the GNAT node
number. */
! DEFTREECODE (TRANSFORM_EXPR, "transform_expr", "e", 0)
/* Perform an unchecked conversion between the input and the output.
if TREE_ADDRESSABLE is set, it means this is in an LHS; in that case,
we can only use techniques, such as pointer punning, that leave the
expression a "name". */
! DEFTREECODE (UNCHECKED_CONVERT_EXPR, "unchecked_convert_expr", "1", 1)
/* A type that is an unconstrained array itself. This node is never passed
to GCC. TREE_TYPE is the type of the fat pointer and TYPE_OBJECT_RECORD_TYPE
is the type of a record containing the template and data. */
! DEFTREECODE (UNCONSTRAINED_ARRAY_TYPE, "unconstrained_array_type", "t", 0)
/* A reference to an unconstrained array. This node only exists as an
intermediate node during the translation of a GNAT tree to a GCC tree;
it is never passed to GCC. The only field used is operand 0, which
is the fat pointer object. */
! DEFTREECODE (UNCONSTRAINED_ARRAY_REF, "unconstrained_array_ref", "r", 1)
/* An expression that returns an RTL suitable for its type. Operand 0
is an expression to be evaluated for side effects only. */
! DEFTREECODE (NULL_EXPR, "null_expr", "e", 1)
/* An expression that emits a USE for its single operand. */
! DEFTREECODE (USE_EXPR, "use_expr", "e", 1)
/* An expression that is treated as a conversion while generating code, but is
used to prevent infinite recursion when conversions of biased types are
involved. */
! DEFTREECODE (GNAT_NOP_EXPR, "gnat_nop_expr", "1", 1)
--- 31,69 ----
The only field used if TREE_COMPLEXITY, which contains the GNAT node
number. */
! DEFTREECODE (TRANSFORM_EXPR, "transform_expr", 'e', 0)
/* Perform an unchecked conversion between the input and the output.
if TREE_ADDRESSABLE is set, it means this is in an LHS; in that case,
we can only use techniques, such as pointer punning, that leave the
expression a "name". */
! DEFTREECODE (UNCHECKED_CONVERT_EXPR, "unchecked_convert_expr", '1', 1)
/* A type that is an unconstrained array itself. This node is never passed
to GCC. TREE_TYPE is the type of the fat pointer and TYPE_OBJECT_RECORD_TYPE
is the type of a record containing the template and data. */
! DEFTREECODE (UNCONSTRAINED_ARRAY_TYPE, "unconstrained_array_type", 't', 0)
/* A reference to an unconstrained array. This node only exists as an
intermediate node during the translation of a GNAT tree to a GCC tree;
it is never passed to GCC. The only field used is operand 0, which
is the fat pointer object. */
! DEFTREECODE (UNCONSTRAINED_ARRAY_REF, "unconstrained_array_ref", 'r', 1)
/* An expression that returns an RTL suitable for its type. Operand 0
is an expression to be evaluated for side effects only. */
! DEFTREECODE (NULL_EXPR, "null_expr", 'e', 1)
/* An expression that emits a USE for its single operand. */
! DEFTREECODE (USE_EXPR, "use_expr", 'e', 1)
/* An expression that is treated as a conversion while generating code, but is
used to prevent infinite recursion when conversions of biased types are
involved. */
! DEFTREECODE (GNAT_NOP_EXPR, "gnat_nop_expr", '1', 1)
This patch from Fred Fish to GNAT may make building simpler. We haven't
tested it.
> I put a very short blurb in the faq. GNAT is complicated enough that
> we should probably write a whole page on how to build/install it.
You may want to use some or all of these patches:
* Make-lang.in (gnattools): Depends upon GCC_PARTS.
(ada.start.encap): Depends upon gnattools.
(ada.rest.encap): Depends upon gnatlib.
* Makefile.in (../stamp-gnatlib1): Since we are still in the rts
subdir when the rule runs, we need to touch ../../stamp-gnatlib1.
(../stamp-gnatlib1): Don't unconditionally remove the rts directory,
create it if one does not exist.
(gnatlib): Remove superflous leading blank char at *-*-pe line.
* a-init.c: Define NULL if not yet defined.
Index: Make-lang.in
===================================================================
RCS file: /cvsroot/gg/egcs/gcc/ada/Make-lang.in,v
retrieving revision 1.1.1.1
retrieving revision 1.3
diff -c -r1.1.1.1 -r1.3
*** Make-lang.in 1997/10/17 06:19:09 1.1.1.1
--- Make-lang.in 1998/03/17 14:26:14 1.3
***************
*** 100,106 ****
# use host-gcc
# getopt*.o has to be built before CC=../xgcc
! gnattools: getopt.o getopt1.o force
$(MAKE) $(FLAGS_TO_PASS) $(ADA_FLAGS_TO_PASS)\
CC="../xgcc -B../" GNATBIND="../gnatbind" \
gnatf gnatlink gnatkr gnatmake gnatcmd gnatprep \
--- 100,107 ----
# use host-gcc
# getopt*.o has to be built before CC=../xgcc
! # GCC_PARTS has to be built before CC=../xgcc
! gnattools: getopt.o getopt1.o $(GCC_PARTS) force
$(MAKE) $(FLAGS_TO_PASS) $(ADA_FLAGS_TO_PASS)\
CC="../xgcc -B../" GNATBIND="../gnatbind" \
gnatf gnatlink gnatkr gnatmake gnatcmd gnatprep \
***************
*** 163,170 ****
-if [ -f gnatls$(exeext) ] ; then\
mv gnatls$(exeext) gnatls-cross$(exeext); fi
! ada.start.encap:
! ada.rest.encap:
ada.info:
ada.dvi:
--- 164,171 ----
-if [ -f gnatls$(exeext) ] ; then\
mv gnatls$(exeext) gnatls-cross$(exeext); fi
! ada.start.encap: gnattools
! ada.rest.encap: gnatlib
ada.info:
ada.dvi:
Index: Makefile.in
===================================================================
RCS file: /cvsroot/gg/egcs/gcc/ada/Makefile.in,v
retrieving revision 1.1.1.1
retrieving revision 1.5
diff -c -r1.1.1.1 -r1.5
*** Makefile.in 1997/10/17 06:19:09 1.1.1.1
--- Makefile.in 1998/02/19 14:16:34 1.5
***************
*** 798,806 ****
# 3. copy 3xyyy.ad[sb] -->-- i-yyy.ad[sb]
../stamp-gnatlib1: Makefile ../stamp-gnatlib2
! rm -rf rts
! mkdir rts
! chmod u+w rts
(\
case $(target) in \
sparc-sun-sunos4*) letter=u ;;\
--- 800,806 ----
# 3. copy 3xyyy.ad[sb] -->-- i-yyy.ad[sb]
../stamp-gnatlib1: Makefile ../stamp-gnatlib2
! if [ -d rts ]; then true; else mkdir rts; chmod u+w rts; fi
(\
case $(target) in \
sparc-sun-sunos4*) letter=u ;;\
***************
*** 888,894 ****
done;; \
esac ; \
rm -f ../stamp-gnatlib ; \
! touch ../stamp-gnatlib1)
gnatlib-common: ../stamp-gnatlib1
(subdir=`cd $(srcdir); pwd`; \
--- 888,894 ----
done;; \
esac ; \
rm -f ../stamp-gnatlib ; \
! touch ../../stamp-gnatlib1)
gnatlib-common: ../stamp-gnatlib1
(subdir=`cd $(srcdir); pwd`; \
***************
*** 923,929 ****
mips-sni-* |\
*-*-cygwin32* |\
*-*-mingw32* |\
! *-*-pe |\
*) \
\
$(MAKE) CC="../../xgcc -B../../" \
--- 923,929 ----
mips-sni-* |\
*-*-cygwin32* |\
*-*-mingw32* |\
! *-*-pe |\
*) \
\
$(MAKE) CC="../../xgcc -B../../" \
Index: a-init.c
===================================================================
RCS file: /cvsroot/gg/egcs/gcc/ada/a-init.c,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -c -r1.1.1.1 -r1.2
*** a-init.c 1997/10/17 06:19:10 1.1.1.1
--- a-init.c 1998/01/04 23:11:42 1.2
***************
*** 516,521 ****
--- 516,525 ----
__gnat_raise (exception);
}
+ #ifndef NULL
+ #define NULL 0
+ #endif
+
static void
__gnat_install_handler ()
{
Wed Jun 24 15:06:09 1998 Dave Brolley <brolley@cygnus.com>
* a-misc.c (lang_decode_option): New interface.
* a-misc.h (lang_decode_option): New interface.
*** /home/brolley/tmp/a-misc.c Wed Jun 24 15:01:22 1998
--- ada/a-misc.c Wed Jun 24 15:02:42 1998
*************** init_gnat_args ()
*** 162,170 ****
it returns 0. */
int
! lang_decode_option (p)
! char *p;
{
extern int save_argc;
extern char **save_argv;
--- 162,172 ----
it returns 0. */
int
! lang_decode_option (argc, argv)
! int argc;
! char **argv;
{
+ char *p = argv[0];
extern int save_argc;
extern char **save_argv;
*** /home/brolley/tmp/a-misc.h Wed Jun 24 15:01:22 1998
--- ada/a-misc.h Wed Jun 24 15:03:20 1998
*************** enum gnat_tree_code {
*** 63,69 ****
option decoding phase of GCC calls this routine on the flags that it cannot
decode. This routine returns 1 if it is successful, otherwise it
returns 0. */
! extern int lang_decode_option PROTO((char *));
/* Perform all the initialization steps that are language-specific. */
extern void lang_init PROTO((void));
--- 63,69 ----
option decoding phase of GCC calls this routine on the flags that it cannot
decode. This routine returns 1 if it is successful, otherwise it
returns 0. */
! extern int lang_decode_option PROTO((int, char **));
/* Perform all the initialization steps that are language-specific. */
extern void lang_init PROTO((void));

File diff suppressed because it is too large Load Diff

View File

@@ -1,49 +1,7 @@
/* Define if you can safely include both <string.h> and <strings.h>. */
#undef STRING_WITH_STRINGS
/* Define if printf supports "%p". */
#undef HAVE_PRINTF_PTR
/* Define if you want expensive run-time checks. */
#undef ENABLE_CHECKING
/* Define to 1 if NLS is requested. */
#undef ENABLE_NLS
/* Define as 1 if you have catgets and don't want to use GNU gettext. */
#undef HAVE_CATGETS
/* Define as 1 if you have gettext and don't want to use GNU gettext. */
#undef HAVE_GETTEXT
/* Define if your cpp understands the stringify operator. */
#undef HAVE_CPP_STRINGIFY
/* Define if your compiler understands volatile. */
#undef HAVE_VOLATILE
/* Define if your assembler supports specifying the maximum number
of bytes to skip when using the GAS .p2align command. */
#undef HAVE_GAS_MAX_SKIP_P2ALIGN
/* Define if your assembler supports .balign and .p2align. */
#undef HAVE_GAS_BALIGN_AND_P2ALIGN
/* Define if your assembler supports .subsection and .subsection -1 starts
emitting at the beginning of your section */
#undef HAVE_GAS_SUBSECTION_ORDERING
/* Define if your assembler uses the old HImode fild and fist notation. */
#undef HAVE_GAS_FILDS_FISTS
/* Define if you have a working <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
/* Define if your locale.h file contains LC_MESSAGES. */
#undef HAVE_LC_MESSAGES
/* Define as 1 if you have the stpcpy function. */
#undef HAVE_STPCPY
/* Include the old config.h as config2.h to simplify the transition
to autoconf. */
#include "config2.h"
/* Whether malloc must be declared even if <stdlib.h> is included. */
#undef NEED_DECLARATION_MALLOC
@@ -51,81 +9,6 @@
/* Whether realloc must be declared even if <stdlib.h> is included. */
#undef NEED_DECLARATION_REALLOC
/* Whether calloc must be declared even if <stdlib.h> is included. */
#undef NEED_DECLARATION_CALLOC
/* Whether free must be declared even if <stdlib.h> is included. */
#undef NEED_DECLARATION_FREE
/* Whether bcopy must be declared even if <string.h> is included. */
#undef NEED_DECLARATION_BCOPY
/* Whether bcmp must be declared even if <string.h> is included. */
#undef NEED_DECLARATION_BCMP
/* Whether bzero must be declared even if <string.h> is included. */
#undef NEED_DECLARATION_BZERO
/* Whether index must be declared even if <string.h> is included. */
#undef NEED_DECLARATION_INDEX
/* Whether rindex must be declared even if <string.h> is included. */
#undef NEED_DECLARATION_RINDEX
/* Whether getenv must be declared even if <stdlib.h> is included. */
#undef NEED_DECLARATION_GETENV
/* Whether atol must be declared even if <stdlib.h> is included. */
#undef NEED_DECLARATION_ATOL
/* Whether atof must be declared even if <stdlib.h> is included. */
#undef NEED_DECLARATION_ATOF
/* Whether sbrk must be declared even if <stdlib.h> is included. */
#undef NEED_DECLARATION_SBRK
/* Whether abort must be declared even if <stdlib.h> is included. */
#undef NEED_DECLARATION_ABORT
/* Whether strerror must be declared even if <string.h> is included. */
#undef NEED_DECLARATION_STRERROR
/* Whether strsignal must be declared even if <string.h> is included. */
#undef NEED_DECLARATION_STRSIGNAL
/* Whether strstr must be declared even if <string.h> is included. */
#undef NEED_DECLARATION_STRSTR
/* Whether getcwd must be declared even if <unistd.h> is included. */
#undef NEED_DECLARATION_GETCWD
/* Whether getwd must be declared even if <unistd.h> is included. */
#undef NEED_DECLARATION_GETWD
/* Whether getrlimit must be declared even if <sys/resource.h> is included. */
#undef NEED_DECLARATION_GETRLIMIT
/* Whether setrlimit must be declared even if <sys/resource.h> is included. */
#undef NEED_DECLARATION_SETRLIMIT
/* Whether putc_unlocked must be declared even if <stdio.h> is included. */
#undef NEED_DECLARATION_PUTC_UNLOCKED
/* Whether fputs_unlocked must be declared even if <stdio.h> is included. */
#undef NEED_DECLARATION_FPUTS_UNLOCKED
/* Define to enable the use of a default assembler. */
#undef DEFAULT_ASSEMBLER
/* Define to enable the use of a default linker. */
#undef DEFAULT_LINKER
/* Define if host mkdir takes a single argument. */
#undef MKDIR_TAKES_ONE_ARG
/* Define to the name of the distribution. */
#undef PACKAGE
/* Define to the version of the distribution. */
#undef VERSION
@TOP@

650
gcc/aclocal.m4 vendored
View File

@@ -1,659 +1,27 @@
dnl See whether we can include both string.h and strings.h.
AC_DEFUN(GCC_HEADER_STRING,
[AC_CACHE_CHECK([whether string.h and strings.h may both be included],
gcc_cv_header_string,
[AC_TRY_COMPILE([#include <string.h>
#include <strings.h>], , gcc_cv_header_string=yes, gcc_cv_header_string=no)])
if test $gcc_cv_header_string = yes; then
AC_DEFINE(STRING_WITH_STRINGS)
fi
])
dnl See whether we need a declaration for a function.
dnl GCC_NEED_DECLARATION(FUNCTION [, EXTRA-HEADER-FILES])
AC_DEFUN(GCC_NEED_DECLARATION,
[AC_MSG_CHECKING([whether $1 must be declared])
AC_CACHE_VAL(gcc_cv_decl_needed_$1,
[AC_TRY_COMPILE([
#include <stdio.h>
#ifdef STRING_WITH_STRINGS
# include <string.h>
# include <strings.h>
#ifdef HAVE_STRING_H
#include <string.h>
#else
# ifdef HAVE_STRING_H
# include <string.h>
# else
# ifdef HAVE_STRINGS_H
# include <strings.h>
# endif
# endif
#ifdef HAVE_STRINGS_H
#include <strings.h>
#endif
#endif
#ifdef HAVE_STDLIB_H
#include <stdlib.h>
#endif
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#ifndef HAVE_RINDEX
#define rindex strrchr
#endif
#ifndef HAVE_INDEX
#define index strchr
#endif
$2],
#endif],
[char *(*pfn) = (char *(*)) $1],
eval "gcc_cv_decl_needed_$1=no", eval "gcc_cv_decl_needed_$1=yes")])
if eval "test \"`echo '$gcc_cv_decl_needed_'$1`\" = yes"; then
AC_MSG_RESULT(yes)
gcc_cv_decl_needed_$1=no, gcc_cv_decl_needed_$1=yes)])
AC_MSG_RESULT($gcc_cv_decl_needed_$1)
if test $gcc_cv_decl_needed_$1 = yes; then
gcc_tr_decl=NEED_DECLARATION_`echo $1 | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
AC_DEFINE_UNQUOTED($gcc_tr_decl)
else
AC_MSG_RESULT(no)
fi
])dnl
dnl Check multiple functions to see whether each needs a declaration.
dnl GCC_NEED_DECLARATIONS(FUNCTION... [, EXTRA-HEADER-FILES])
AC_DEFUN(GCC_NEED_DECLARATIONS,
[for ac_func in $1
do
GCC_NEED_DECLARATION($ac_func, $2)
done
])
dnl Check if we have vprintf and possibly _doprnt.
dnl Note autoconf checks for vprintf even though we care about vfprintf.
AC_DEFUN(GCC_FUNC_VFPRINTF_DOPRNT,
[AC_FUNC_VPRINTF
vfprintf=
doprint=
if test $ac_cv_func_vprintf != yes ; then
vfprintf=vfprintf.o
if test $ac_cv_func__doprnt != yes ; then
doprint=doprint.o
fi
fi
AC_SUBST(vfprintf)
AC_SUBST(doprint)
])
dnl See if the printf functions in libc support %p in format strings.
AC_DEFUN(GCC_FUNC_PRINTF_PTR,
[AC_CACHE_CHECK(whether the printf functions support %p,
gcc_cv_func_printf_ptr,
[AC_TRY_RUN([#include <stdio.h>
main()
{
char buf[64];
char *p = buf, *q = NULL;
sprintf(buf, "%p", p);
sscanf(buf, "%p", &q);
exit (p != q);
}], gcc_cv_func_printf_ptr=yes, gcc_cv_func_printf_ptr=no,
gcc_cv_func_printf_ptr=no)
rm -f core core.* *.core])
if test $gcc_cv_func_printf_ptr = yes ; then
AC_DEFINE(HAVE_PRINTF_PTR)
fi
])
dnl See if symbolic links work and if not, try to substitute either hard links or simple copy.
AC_DEFUN(GCC_PROG_LN_S,
[AC_MSG_CHECKING(whether ln -s works)
AC_CACHE_VAL(gcc_cv_prog_LN_S,
[rm -f conftestdata_t
echo >conftestdata_f
if ln -s conftestdata_f conftestdata_t 2>/dev/null
then
gcc_cv_prog_LN_S="ln -s"
else
if ln conftestdata_f conftestdata_t 2>/dev/null
then
gcc_cv_prog_LN_S=ln
else
gcc_cv_prog_LN_S=cp
fi
fi
rm -f conftestdata_f conftestdata_t
])dnl
LN_S="$gcc_cv_prog_LN_S"
if test "$gcc_cv_prog_LN_S" = "ln -s"; then
AC_MSG_RESULT(yes)
else
if test "$gcc_cv_prog_LN_S" = "ln"; then
AC_MSG_RESULT([no, using ln])
else
AC_MSG_RESULT([no, and neither does ln, so using cp])
fi
fi
AC_SUBST(LN_S)dnl
])
dnl See if hard links work and if not, try to substitute either symbolic links or simple copy.
AC_DEFUN(GCC_PROG_LN,
[AC_MSG_CHECKING(whether ln works)
AC_CACHE_VAL(gcc_cv_prog_LN,
[rm -f conftestdata_t
echo >conftestdata_f
if ln conftestdata_f conftestdata_t 2>/dev/null
then
gcc_cv_prog_LN="ln"
else
if ln -s conftestdata_f conftestdata_t 2>/dev/null
then
gcc_cv_prog_LN="ln -s"
else
gcc_cv_prog_LN=cp
fi
fi
rm -f conftestdata_f conftestdata_t
])dnl
LN="$gcc_cv_prog_LN"
if test "$gcc_cv_prog_LN" = "ln"; then
AC_MSG_RESULT(yes)
else
if test "$gcc_cv_prog_LN" = "ln -s"; then
AC_MSG_RESULT([no, using ln -s])
else
AC_MSG_RESULT([no, and neither does ln -s, so using cp])
fi
fi
AC_SUBST(LN)dnl
])
dnl See whether the stage1 host compiler accepts the volatile keyword.
AC_DEFUN(GCC_C_VOLATILE,
[AC_CACHE_CHECK([for volatile], gcc_cv_c_volatile,
[AC_TRY_COMPILE(, [volatile int foo;],
gcc_cv_c_volatile=yes, gcc_cv_c_volatile=no)])
if test $gcc_cv_c_volatile = yes ; then
AC_DEFINE(HAVE_VOLATILE)
fi
])
dnl Define MKDIR_TAKES_ONE_ARG if mkdir accepts only one argument instead
dnl of the usual 2.
AC_DEFUN(GCC_FUNC_MKDIR_TAKES_ONE_ARG,
[AC_CACHE_CHECK([if mkdir takes one argument], gcc_cv_mkdir_takes_one_arg,
[AC_TRY_COMPILE([
#include <sys/types.h>
#ifdef HAVE_SYS_STAT_H
# include <sys/stat.h>
#endif
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
#ifdef HAVE_DIRECT_H
# include <direct.h>
#endif], [mkdir ("foo", 0);],
gcc_cv_mkdir_takes_one_arg=no, gcc_cv_mkdir_takes_one_arg=yes)])
if test $gcc_cv_mkdir_takes_one_arg = yes ; then
AC_DEFINE(MKDIR_TAKES_ONE_ARG)
fi
])
AC_DEFUN(EGCS_PROG_INSTALL,
[AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
# Find a good install program. We prefer a C program (faster),
# so one script is as good as another. But avoid the broken or
# incompatible versions:
# SysV /etc/install, /usr/sbin/install
# SunOS /usr/etc/install
# IRIX /sbin/install
# AIX /bin/install
# AFS /usr/afsws/bin/install, which mishandles nonexistent args
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
AC_MSG_CHECKING(for a BSD compatible install)
if test -z "$INSTALL"; then
AC_CACHE_VAL(ac_cv_path_install,
[ IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
for ac_dir in $PATH; do
# Account for people who put trailing slashes in PATH elements.
case "$ac_dir/" in
/|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
*)
# OSF1 and SCO ODT 3.0 have their own names for install.
for ac_prog in ginstall scoinst install; do
if test -f $ac_dir/$ac_prog; then
if test $ac_prog = install &&
grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
# AIX install. It has an incompatible calling convention.
# OSF/1 installbsd also uses dspmsg, but is usable.
:
else
ac_cv_path_install="$ac_dir/$ac_prog -c"
break 2
fi
fi
done
;;
esac
done
IFS="$ac_save_IFS"
])dnl
if test "${ac_cv_path_install+set}" = set; then
INSTALL="$ac_cv_path_install"
else
# As a last resort, use the slow shell script. We don't cache a
# path for INSTALL within a source directory, because that will
# break other packages using the cache if that directory is
# removed, or if the path is relative.
INSTALL="$ac_install_sh"
fi
fi
dnl We do special magic for INSTALL instead of AC_SUBST, to get
dnl relative paths right.
AC_MSG_RESULT($INSTALL)
AC_SUBST(INSTALL)dnl
# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
# It thinks the first close brace ends the variable substitution.
test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
AC_SUBST(INSTALL_PROGRAM)dnl
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
AC_SUBST(INSTALL_DATA)dnl
])
#serial 1
dnl This test replaces the one in autoconf.
dnl Currently this macro should have the same name as the autoconf macro
dnl because gettext's gettext.m4 (distributed in the automake package)
dnl still uses it. Otherwise, the use in gettext.m4 makes autoheader
dnl give these diagnostics:
dnl configure.in:556: AC_TRY_COMPILE was called before AC_ISC_POSIX
dnl configure.in:556: AC_TRY_RUN was called before AC_ISC_POSIX
undefine([AC_ISC_POSIX])
AC_DEFUN(AC_ISC_POSIX,
[
dnl This test replaces the obsolescent AC_ISC_POSIX kludge.
AC_CHECK_LIB(cposix, strerror, [LIBS="$LIBS -lcposix"])
]
)
# Macro to add for using GNU gettext.
# Ulrich Drepper <drepper@cygnus.com>, 1995.
#
# This file can be copied and used freely without restrictions. It can
# be used in projects which are not available under the GNU Public License
# but which still want to provide support for the GNU gettext functionality.
# Please note that the actual code is *not* freely available.
# serial 5
AC_DEFUN(AM_WITH_NLS,
[AC_MSG_CHECKING([whether NLS is requested])
dnl Default is enabled NLS
AC_ARG_ENABLE(nls,
[ --disable-nls do not use Native Language Support],
USE_NLS=$enableval, USE_NLS=yes)
AC_MSG_RESULT($USE_NLS)
AC_SUBST(USE_NLS)
USE_INCLUDED_LIBINTL=no
dnl If we use NLS figure out what method
if test "$USE_NLS" = "yes"; then
AC_DEFINE(ENABLE_NLS)
AC_MSG_CHECKING([whether included gettext is requested])
AC_ARG_WITH(included-gettext,
[ --with-included-gettext use the GNU gettext library included here],
nls_cv_force_use_gnu_gettext=$withval,
nls_cv_force_use_gnu_gettext=no)
AC_MSG_RESULT($nls_cv_force_use_gnu_gettext)
nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
dnl User does not insist on using GNU NLS library. Figure out what
dnl to use. If gettext or catgets are available (in this order) we
dnl use this. Else we have to fall back to GNU NLS library.
dnl catgets is only used if permitted by option --with-catgets.
nls_cv_header_intl=
nls_cv_header_libgt=
CATOBJEXT=NONE
AC_CHECK_HEADER(libintl.h,
[AC_CACHE_CHECK([for gettext in libc], gt_cv_func_gettext_libc,
[AC_TRY_LINK([#include <libintl.h>], [return (int) gettext ("")],
gt_cv_func_gettext_libc=yes, gt_cv_func_gettext_libc=no)])
if test "$gt_cv_func_gettext_libc" != "yes"; then
AC_CHECK_LIB(intl, bindtextdomain,
[AC_CACHE_CHECK([for gettext in libintl],
gt_cv_func_gettext_libintl,
[AC_CHECK_LIB(intl, gettext,
gt_cv_func_gettext_libintl=yes,
gt_cv_func_gettext_libintl=no)],
gt_cv_func_gettext_libintl=no)])
fi
if test "$gt_cv_func_gettext_libc" = "yes" \
|| test "$gt_cv_func_gettext_libintl" = "yes"; then
AC_DEFINE(HAVE_GETTEXT)
AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
[test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)dnl
if test "$MSGFMT" != "no"; then
AC_CHECK_FUNCS(dcgettext)
AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
[test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :)
AC_TRY_LINK(, [extern int _nl_msg_cat_cntr;
return _nl_msg_cat_cntr],
[CATOBJEXT=.gmo
DATADIRNAME=share],
[CATOBJEXT=.mo
DATADIRNAME=lib])
INSTOBJEXT=.mo
fi
fi
])
if test "$CATOBJEXT" = "NONE"; then
AC_MSG_CHECKING([whether catgets can be used])
AC_ARG_WITH(catgets,
[ --with-catgets use catgets functions if available],
nls_cv_use_catgets=$withval, nls_cv_use_catgets=no)
AC_MSG_RESULT($nls_cv_use_catgets)
if test "$nls_cv_use_catgets" = "yes"; then
dnl No gettext in C library. Try catgets next.
AC_CHECK_LIB(i, main)
AC_CHECK_FUNC(catgets,
[AC_DEFINE(HAVE_CATGETS)
INTLOBJS="\$(CATOBJS)"
AC_PATH_PROG(GENCAT, gencat, no)dnl
if test "$GENCAT" != "no"; then
AC_PATH_PROG(GMSGFMT, gmsgfmt, no)
if test "$GMSGFMT" = "no"; then
AM_PATH_PROG_WITH_TEST(GMSGFMT, msgfmt,
[test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)
fi
AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
[test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :)
USE_INCLUDED_LIBINTL=yes
CATOBJEXT=.cat
INSTOBJEXT=.cat
DATADIRNAME=lib
INTLDEPS='$(top_builddir)/intl/libintl.a'
INTLLIBS=$INTLDEPS
LIBS=`echo $LIBS | sed -e 's/-lintl//'`
nls_cv_header_intl=intl/libintl.h
nls_cv_header_libgt=intl/libgettext.h
fi])
fi
fi
if test "$CATOBJEXT" = "NONE"; then
dnl Neither gettext nor catgets in included in the C library.
dnl Fall back on GNU gettext library.
nls_cv_use_gnu_gettext=yes
fi
fi
if test "$nls_cv_use_gnu_gettext" = "yes"; then
dnl Mark actions used to generate GNU NLS library.
INTLOBJS="\$(GETTOBJS)"
AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
[test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], msgfmt)
AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
[test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :)
AC_SUBST(MSGFMT)
USE_INCLUDED_LIBINTL=yes
CATOBJEXT=.gmo
INSTOBJEXT=.mo
DATADIRNAME=share
INTLDEPS='$(top_builddir)/intl/libintl.a'
INTLLIBS=$INTLDEPS
LIBS=`echo $LIBS | sed -e 's/-lintl//'`
nls_cv_header_intl=intl/libintl.h
nls_cv_header_libgt=intl/libgettext.h
fi
dnl Test whether we really found GNU xgettext.
if test "$XGETTEXT" != ":"; then
dnl If it is no GNU xgettext we define it as : so that the
dnl Makefiles still can work.
if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
: ;
else
AC_MSG_RESULT(
[found xgettext program is not GNU xgettext; ignore it])
XGETTEXT=":"
fi
fi
# We need to process the po/ directory.
POSUB=po
else
DATADIRNAME=share
nls_cv_header_intl=intl/libintl.h
nls_cv_header_libgt=intl/libgettext.h
fi
AC_LINK_FILES($nls_cv_header_libgt, $nls_cv_header_intl)
AC_OUTPUT_COMMANDS(
[case "$CONFIG_FILES" in *po/Makefile.in*)
sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile
esac])
# If this is used in GNU gettext we have to set USE_NLS to `yes'
# because some of the sources are only built for this goal.
if test "$PACKAGE" = gettext; then
USE_NLS=yes
USE_INCLUDED_LIBINTL=yes
fi
dnl These rules are solely for the distribution goal. While doing this
dnl we only have to keep exactly one list of the available catalogs
dnl in configure.in.
for lang in $ALL_LINGUAS; do
GMOFILES="$GMOFILES $lang.gmo"
POFILES="$POFILES $lang.po"
done
dnl Make all variables we use known to autoconf.
AC_SUBST(USE_INCLUDED_LIBINTL)
AC_SUBST(CATALOGS)
AC_SUBST(CATOBJEXT)
AC_SUBST(DATADIRNAME)
AC_SUBST(GMOFILES)
AC_SUBST(INSTOBJEXT)
AC_SUBST(INTLDEPS)
AC_SUBST(INTLLIBS)
AC_SUBST(INTLOBJS)
AC_SUBST(POFILES)
AC_SUBST(POSUB)
])
AC_DEFUN(AM_GNU_GETTEXT,
[AC_REQUIRE([AC_PROG_MAKE_SET])dnl
AC_REQUIRE([AC_PROG_CC])dnl
AC_REQUIRE([AC_PROG_RANLIB])dnl
AC_REQUIRE([AC_ISC_POSIX])dnl
AC_REQUIRE([AC_HEADER_STDC])dnl
AC_REQUIRE([AC_C_CONST])dnl
AC_REQUIRE([AC_C_INLINE])dnl
AC_REQUIRE([AC_TYPE_OFF_T])dnl
AC_REQUIRE([AC_TYPE_SIZE_T])dnl
AC_REQUIRE([AC_FUNC_ALLOCA])dnl
AC_REQUIRE([AC_FUNC_MMAP])dnl
AC_CHECK_HEADERS([argz.h limits.h locale.h nl_types.h malloc.h string.h \
unistd.h sys/param.h])
AC_CHECK_FUNCS([getcwd munmap putenv setenv setlocale strchr strcasecmp \
strdup __argz_count __argz_stringify __argz_next])
if test "${ac_cv_func_stpcpy+set}" != "set"; then
AC_CHECK_FUNCS(stpcpy)
fi
if test "${ac_cv_func_stpcpy}" = "yes"; then
AC_DEFINE(HAVE_STPCPY)
fi
AM_LC_MESSAGES
AM_WITH_NLS
if test "x$CATOBJEXT" != "x"; then
if test "x$ALL_LINGUAS" = "x"; then
LINGUAS=
else
AC_MSG_CHECKING(for catalogs to be installed)
NEW_LINGUAS=
for lang in ${LINGUAS=$ALL_LINGUAS}; do
case "$ALL_LINGUAS" in
*$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;;
esac
done
LINGUAS=$NEW_LINGUAS
AC_MSG_RESULT($LINGUAS)
fi
dnl Construct list of names of catalog files to be constructed.
if test -n "$LINGUAS"; then
for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
fi
fi
dnl The reference to <locale.h> in the installed <libintl.h> file
dnl must be resolved because we cannot expect the users of this
dnl to define HAVE_LOCALE_H.
if test $ac_cv_header_locale_h = yes; then
INCLUDE_LOCALE_H="#include <locale.h>"
else
INCLUDE_LOCALE_H="\
/* The system does not provide the header <locale.h>. Take care yourself. */"
fi
AC_SUBST(INCLUDE_LOCALE_H)
dnl Determine which catalog format we have (if any is needed)
dnl For now we know about two different formats:
dnl Linux libc-5 and the normal X/Open format
test -d intl || mkdir intl
if test "$CATOBJEXT" = ".cat"; then
AC_CHECK_HEADER(linux/version.h, msgformat=linux, msgformat=xopen)
dnl Transform the SED scripts while copying because some dumb SEDs
dnl cannot handle comments.
sed -e '/^#/d' $srcdir/intl/$msgformat-msg.sed > intl/po2msg.sed
fi
dnl po2tbl.sed is always needed.
sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \
$srcdir/intl/po2tbl.sed.in > intl/po2tbl.sed
dnl In the intl/Makefile.in we have a special dependency which makes
dnl only sense for gettext. We comment this out for non-gettext
dnl packages.
if test "$PACKAGE" = "gettext"; then
GT_NO="#NO#"
GT_YES=
else
GT_NO=
GT_YES="#YES#"
fi
AC_SUBST(GT_NO)
AC_SUBST(GT_YES)
dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly
dnl find the mkinstalldirs script in another subdir but ($top_srcdir).
dnl Try to locate is.
MKINSTALLDIRS=
if test -n "$ac_aux_dir"; then
MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
fi
if test -z "$MKINSTALLDIRS"; then
MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
fi
AC_SUBST(MKINSTALLDIRS)
dnl *** For now the libtool support in intl/Makefile is not for real.
l=
AC_SUBST(l)
dnl Generate list of files to be processed by xgettext which will
dnl be included in po/Makefile.
test -d po || mkdir po
if test "x$srcdir" != "x."; then
if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
posrcprefix="$srcdir/"
else
posrcprefix="../$srcdir/"
fi
else
posrcprefix="../"
fi
rm -f po/POTFILES
sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
< $srcdir/po/POTFILES.in > po/POTFILES
])
# Check whether LC_MESSAGES is available in <locale.h>.
# Ulrich Drepper <drepper@cygnus.com>, 1995.
#
# This file can be copied and used freely without restrictions. It can
# be used in projects which are not available under the GNU Public License
# but which still want to provide support for the GNU gettext functionality.
# Please note that the actual code is *not* freely available.
# serial 1
AC_DEFUN(AM_LC_MESSAGES,
[if test $ac_cv_header_locale_h = yes; then
AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES,
[AC_TRY_LINK([#include <locale.h>], [return LC_MESSAGES],
am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)])
if test $am_cv_val_LC_MESSAGES = yes; then
AC_DEFINE(HAVE_LC_MESSAGES)
fi
fi])
# Search path for a program which passes the given test.
# Ulrich Drepper <drepper@cygnus.com>, 1996.
#
# This file can be copied and used freely without restrictions. It can
# be used in projects which are not available under the GNU Public License
# but which still want to provide support for the GNU gettext functionality.
# Please note that the actual code is *not* freely available.
# serial 1
dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR,
dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]])
AC_DEFUN(AM_PATH_PROG_WITH_TEST,
[# Extract the first word of "$2", so it can be a program name with args.
set dummy $2; ac_word=[$]2
AC_MSG_CHECKING([for $ac_word])
AC_CACHE_VAL(ac_cv_path_$1,
[case "[$]$1" in
/*)
ac_cv_path_$1="[$]$1" # Let the user override the test with a path.
;;
*)
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
for ac_dir in ifelse([$5], , $PATH, [$5]); do
test -z "$ac_dir" && ac_dir=.
if test -f $ac_dir/$ac_word; then
if [$3]; then
ac_cv_path_$1="$ac_dir/$ac_word"
break
fi
fi
done
IFS="$ac_save_ifs"
dnl If no 4th arg is given, leave the cache variable unset,
dnl so AC_PATH_PROGS will keep looking.
ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4"
])dnl
;;
esac])dnl
$1="$ac_cv_path_$1"
if test -n "[$]$1"; then
AC_MSG_RESULT([$]$1)
else
AC_MSG_RESULT(no)
fi
AC_SUBST($1)dnl
])

File diff suppressed because it is too large Load Diff

View File

@@ -1,5 +1,5 @@
/* Define control and data flow tables, and regsets.
Copyright (C) 1987, 1997, 1998, 1999 Free Software Foundation, Inc.
Copyright (C) 1987, 1997 Free Software Foundation, Inc.
This file is part of GNU CC.
@@ -20,8 +20,6 @@ Boston, MA 02111-1307, USA. */
#include "bitmap.h"
#include "sbitmap.h"
#include "varray.h"
typedef bitmap regset; /* Head of register set linked list. */
@@ -75,12 +73,6 @@ do { \
#define EXECUTE_IF_AND_COMPL_IN_REG_SET(REGSET1, REGSET2, MIN, REGNUM, CODE) \
EXECUTE_IF_AND_COMPL_IN_BITMAP (REGSET1, REGSET2, MIN, REGNUM, CODE)
/* Loop over all registers in REGSET1 and REGSET2, starting with MIN, setting
REGNUM to the register number and executing CODE for all registers that are
set in both regsets. */
#define EXECUTE_IF_AND_IN_REG_SET(REGSET1, REGSET2, MIN, REGNUM, CODE) \
EXECUTE_IF_AND_IN_BITMAP (REGSET1, REGSET2, MIN, REGNUM, CODE)
/* Allocate a register set with oballoc. */
#define OBSTACK_ALLOC_REG_SET(OBSTACK) BITMAP_OBSTACK_ALLOC (OBSTACK)
@@ -96,65 +88,24 @@ do { \
/* Grow any tables needed when the number of registers is calculated
or extended. For the linked list allocation, nothing needs to
be done, other than zero the statistics on the first allocation. */
#define MAX_REGNO_REG_SET(NUM_REGS, NEW_P, RENUMBER_P)
/* Control flow edge information. */
typedef struct edge_def {
/* Links through the predecessor and successor lists. */
struct edge_def *pred_next, *succ_next;
/* The two blocks at the ends of the edge. */
struct basic_block_def *src, *dest;
/* Instructions queued on the edge. */
rtx insns;
/* Auxiliary info specific to a pass. */
void *aux;
int flags; /* see EDGE_* below */
int probability; /* biased by REG_BR_PROB_BASE */
} *edge;
#define EDGE_FALLTHRU 1
#define EDGE_CRITICAL 2
#define EDGE_ABNORMAL 4
#define EDGE_ABNORMAL_CALL 8
#define EDGE_EH 16
#define EDGE_FAKE 32
/* Basic block information indexed by block number. */
typedef struct basic_block_def {
/* The first and last insns of the block. */
rtx head, end;
/* The edges into and out of the block. */
edge pred, succ;
/* Liveness info. */
regset local_set;
regset global_live_at_start;
regset global_live_at_end;
/* Auxiliary info specific to a pass. */
void *aux;
/* The index of this block. */
int index;
/* The loop depth of this block plus one. */
int loop_depth;
} *basic_block;
#define MAX_REGNO_REG_SET(NUM_REGS, NEW_P, RENUMBER_P)
/* Number of basic blocks in the current function. */
extern int n_basic_blocks;
/* Index by basic block number, get basic block struct info. */
/* Index by basic block number, get first insn in the block. */
extern varray_type basic_block_info;
extern rtx *basic_block_head;
#define BASIC_BLOCK(N) (VARRAY_BB (basic_block_info, (N)))
/* Index by basic block number, get last insn in the block. */
extern rtx *basic_block_end;
/* Index by basic block number, get address of regset
describing the registers live at the start of that block. */
extern regset *basic_block_live_at_start;
/* What registers are live at the setjmp call. */
@@ -170,93 +121,4 @@ extern regset regs_live_at_setjmp;
#define REG_BLOCK_UNKNOWN -1
#define REG_BLOCK_GLOBAL -2
#define REG_BASIC_BLOCK(N) (VARRAY_REG (reg_n_info, N)->basic_block)
/* List of integers.
These are used for storing things like predecessors, etc.
This scheme isn't very space efficient, especially on 64 bit machines.
The interface is designed so that the implementation can be replaced with
something more efficient if desirable. */
typedef struct int_list {
struct int_list *next;
int val;
} int_list;
typedef int_list *int_list_ptr;
/* Integer list elements are allocated in blocks to reduce the frequency
of calls to malloc and to reduce the associated space overhead. */
typedef struct int_list_block {
struct int_list_block *next;
int nodes_left;
#define INT_LIST_NODES_IN_BLK 500
struct int_list nodes[INT_LIST_NODES_IN_BLK];
} int_list_block;
/* Given a pointer to the list, return pointer to first element. */
#define INT_LIST_FIRST(il) (il)
/* Given a pointer to a list element, return pointer to next element. */
#define INT_LIST_NEXT(p) ((p)->next)
/* Return non-zero if P points to the end of the list. */
#define INT_LIST_END(p) ((p) == NULL)
/* Return element pointed to by P. */
#define INT_LIST_VAL(p) ((p)->val)
#define INT_LIST_SET_VAL(p, new_val) ((p)->val = (new_val))
extern void free_int_list PROTO ((int_list_block **));
/* Stuff for recording basic block info. */
#define BLOCK_HEAD(B) (BASIC_BLOCK (B)->head)
#define BLOCK_END(B) (BASIC_BLOCK (B)->end)
/* Special block numbers [markers] for entry and exit. */
#define ENTRY_BLOCK (-1)
#define EXIT_BLOCK (-2)
/* Similarly, block pointers for the edge list. */
extern struct basic_block_def entry_exit_blocks[2];
#define ENTRY_BLOCK_PTR (&entry_exit_blocks[0])
#define EXIT_BLOCK_PTR (&entry_exit_blocks[1])
/* from flow.c */
extern void free_regset_vector PROTO ((regset *, int nelts));
extern varray_type basic_block_for_insn;
#define BLOCK_FOR_INSN(INSN) VARRAY_BB (basic_block_for_insn, INSN_UID (INSN))
#define BLOCK_NUM(INSN) (BLOCK_FOR_INSN (INSN)->index + 0)
extern void set_block_for_insn PROTO ((rtx, basic_block));
extern void dump_bb_data PROTO ((FILE *, int_list_ptr *,
int_list_ptr *, int));
extern void free_bb_mem PROTO ((void));
extern void free_basic_block_vars PROTO ((int));
extern basic_block split_edge PROTO ((edge));
extern void insert_insn_on_edge PROTO ((rtx, edge));
extern void commit_edge_insertions PROTO ((void));
extern void compute_preds_succs PROTO ((int_list_ptr *, int_list_ptr *,
int *, int *));
extern void compute_dominators PROTO ((sbitmap *, sbitmap *,
int_list_ptr *,
int_list_ptr *));
extern void compute_immediate_dominators PROTO ((int *, sbitmap *));
/* In lcm.c */
extern void pre_lcm PROTO ((int, int, int_list_ptr *,
int_list_ptr *,
sbitmap *, sbitmap *,
sbitmap *, sbitmap *));
extern void pre_rev_lcm PROTO ((int, int, int_list_ptr *,
int_list_ptr *,
sbitmap *, sbitmap *,
sbitmap *, sbitmap *));
#define REG_BASIC_BLOCK(N) (reg_n_info[(N)].basic_block)

1018
gcc/bc-emit.c Normal file

File diff suppressed because it is too large Load Diff

133
gcc/bc-emit.h Normal file
View File

@@ -0,0 +1,133 @@
/* bc-emit.h - declare entry points for producing object files of bytecodes. */
/* Internal format of symbol table for the object file. */
struct bc_sym
{
/* Private copy separately malloc'd. */
char *name;
/* Symbol has a defined value. */
unsigned int defined:1;
/* Symbol has been globalized. */
unsigned int global:1;
/* Symbol is common. */
unsigned int common:1;
/* Value if defined. */
unsigned long int val;
/* Used in internal symbol table structure. */
struct bc_sym *next;
};
/* List of symbols defined in a particular segment. */
struct bc_segsym
{
struct bc_sym *sym;
struct bc_segsym *next;
};
/* List of relocations needed in a particular segment. */
struct bc_segreloc
{
/* Offset of datum to be relocated. */
unsigned int offset;
/* Symbol to be relocated by. */
struct bc_sym *sym;
struct bc_segreloc *next;
};
/* Segment of an object file. */
struct bc_seg
{
/* Size allocated to contents. */
unsigned int alloc;
/* Pointer to base of contents. */
char *data;
/* Actual size of contents. */
unsigned int size;
/* List of symbols defined in this segment. */
struct bc_segsym *syms;
/* List of relocations for this segment. */
struct bc_segreloc *relocs;
};
/* Anonymous bytecode label within a single function. */
struct bc_label
{
/* Offset of label from start of segment. */
unsigned int offset;
/* True when offset is valid. */
unsigned int defined:1;
/* Unique bytecode ID, used to determine innermost
block containment */
int uid;
/* Next node in list */
struct bc_label *next;
};
/* Reference to a bc_label; a list of all such references is kept for
the function, then when it is finished they are backpatched to
contain the correct values. */
struct bc_labelref
{
/* Label referenced. */
struct bc_label *label;
/* Code offset of reference. */
unsigned int offset;
/* Next labelref in list */
struct bc_labelref *next;
};
extern void bc_initialize();
extern int bc_begin_function();
extern char *bc_emit_trampoline();
extern void bc_emit_bytecode();
extern void bc_emit_bytecode_const();
extern struct bc_label *bc_get_bytecode_label();
extern int bc_emit_bytecode_labeldef();
extern void bc_emit_bytecode_labelref();
extern void bc_emit_code_labelref();
extern char *bc_end_function();
extern void bc_align_const();
extern void bc_emit_const();
extern void bc_emit_const_skip();
extern int bc_emit_const_labeldef();
extern void bc_emit_const_labelref();
extern void bc_align_data();
extern void bc_emit_data();
extern void bc_emit_data_skip();
extern int bc_emit_data_labeldef();
extern void bc_emit_data_labelref();
extern int bc_define_pointer ();
extern int bc_emit_common();
extern void bc_globalize_label();
extern void bc_text();
extern void bc_data();
extern void bc_align();
extern void bc_emit();
extern void bc_emit_skip();
extern int bc_emit_labeldef();
extern void bc_emit_labelref();
extern void bc_write_file();

798
gcc/bc-optab.c Normal file
View File

@@ -0,0 +1,798 @@
/* Bytecode conversion definitions for GNU C-compiler.
Copyright (C) 1993, 1994 Free Software Foundation, Inc.
This file is part of GNU CC.
GNU CC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU CC is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "config.h"
#include "tree.h"
#include "rtl.h"
#include "machmode.h"
#include "obstack.h"
#include "bytecode.h"
#include "bc-typecd.h"
#include "bc-opcode.h"
#include "bc-optab.h"
#define obstack_chunk_alloc xmalloc
#define obstack_chunk_free free
extern char *xmalloc ();
/* Table relating interpreter typecodes to machine modes. */
#define GET_TYPECODE_MODE(CODE) (typecode_mode[((int) CODE)])
enum machine_mode typecode_mode[] = {
#define DEFTYPECODE(CODE, NAME, MODE, TYPE) MODE,
#include "bc-typecd.def"
#undef DEFTYPECODE
};
/* Machine mode to type code map */
static enum typecode signed_mode_to_code_map[MAX_MACHINE_MODE+1];
static enum typecode unsigned_mode_to_code_map[MAX_MACHINE_MODE+1];
#define GET_TYPECODE_SIZE(CODE) GET_MODE_SIZE (GET_TYPECODE_MODE (CODE))
#define BIG_ARBITRARY_NUMBER 100000
/* Table of recipes for conversions among scalar types, to be filled
in as needed at run time. */
static struct conversion_recipe
{
unsigned char *opcodes; /* Bytecodes to emit in order. */
int nopcodes; /* Count of bytecodes. */
int cost; /* A rather arbitrary cost function. */
} conversion_recipe[NUM_TYPECODES][NUM_TYPECODES];
/* Binary operator tables. */
struct binary_operator optab_plus_expr[] = {
{ addSI, SIcode, SIcode, SIcode },
{ addDI, DIcode, DIcode, DIcode },
{ addSF, SFcode, SFcode, SFcode },
{ addDF, DFcode, DFcode, DFcode },
{ addXF, XFcode, XFcode, XFcode },
{ addPSI, Pcode, Pcode, SIcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_minus_expr[] = {
{ subSI, SIcode, SIcode, SIcode },
{ subDI, DIcode, DIcode, DIcode },
{ subSF, SFcode, SFcode, SFcode },
{ subDF, DFcode, DFcode, DFcode },
{ subXF, XFcode, XFcode, XFcode },
{ subPP, SIcode, Pcode, Pcode },
{ -1, -1, -1, -1 },
};
/* The ordering of the tables for multiplicative operators
is such that unsigned operations will be preferred to signed
operations when one argument is unsigned. */
struct binary_operator optab_mult_expr[] = {
{ mulSU, SUcode, SUcode, SUcode },
{ mulDU, DUcode, DUcode, DUcode },
{ mulSI, SIcode, SIcode, SIcode },
{ mulDI, DIcode, DIcode, DIcode },
{ mulSF, SFcode, SFcode, SFcode },
{ mulDF, DFcode, DFcode, DFcode },
{ mulXF, XFcode, XFcode, XFcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_trunc_div_expr[] = {
{ divSU, SUcode, SUcode, SUcode },
{ divDU, DUcode, DUcode, DUcode },
{ divSI, SIcode, SIcode, SIcode },
{ divDI, DIcode, DIcode, DIcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_trunc_mod_expr[] = {
{ modSU, SUcode, SUcode, SUcode },
{ modDU, DUcode, DUcode, DUcode },
{ modSI, SIcode, SIcode, SIcode },
{ modDI, DIcode, DIcode, DIcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_rdiv_expr[] = {
{ divSF, SFcode, SFcode, SFcode },
{ divDF, DFcode, DFcode, DFcode },
{ divXF, XFcode, XFcode, XFcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_bit_and_expr[] = {
{ andSI, SIcode, SIcode, SIcode },
{ andDI, DIcode, DIcode, DIcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_bit_ior_expr[] = {
{ iorSI, SIcode, SIcode, SIcode },
{ iorDI, DIcode, DIcode, DIcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_bit_xor_expr[] = {
{ xorSI, SIcode, SIcode, SIcode },
{ xorDI, DIcode, DIcode, DIcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_lshift_expr[] = {
{ lshiftSI, SIcode, SIcode, SIcode },
{ lshiftSU, SUcode, SUcode, SIcode },
{ lshiftDI, DIcode, DIcode, SIcode },
{ lshiftDU, DUcode, DUcode, SIcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_rshift_expr[] = {
{ rshiftSI, SIcode, SIcode, SIcode },
{ rshiftSU, SUcode, SUcode, SIcode },
{ rshiftDI, DIcode, DIcode, SIcode },
{ rshiftDU, DUcode, DUcode, SIcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_truth_and_expr[] = {
{ andSI, SIcode, Tcode, Tcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_truth_or_expr[] = {
{ iorSI, SIcode, Tcode, Tcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_lt_expr[] = {
{ ltSI, Tcode, SIcode, SIcode },
{ ltSU, Tcode, SUcode, SUcode },
{ ltDI, Tcode, DIcode, DIcode },
{ ltDU, Tcode, DUcode, DUcode },
{ ltSF, Tcode, SFcode, SFcode },
{ ltDF, Tcode, DFcode, DFcode },
{ ltXF, Tcode, XFcode, XFcode },
{ ltP, Tcode, Pcode, Pcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_le_expr[] = {
{ leSI, Tcode, SIcode, SIcode },
{ leSU, Tcode, SUcode, SUcode },
{ leDI, Tcode, DIcode, DIcode },
{ leDU, Tcode, DUcode, DUcode },
{ leSF, Tcode, SFcode, SFcode },
{ leDF, Tcode, DFcode, DFcode },
{ leXF, Tcode, XFcode, XFcode },
{ leP, Tcode, Pcode, Pcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_ge_expr[] = {
{ geSI, Tcode, SIcode, SIcode },
{ geSU, Tcode, SUcode, SUcode },
{ geDI, Tcode, DIcode, DIcode },
{ geDU, Tcode, DUcode, DUcode },
{ geSF, Tcode, SFcode, SFcode },
{ geDF, Tcode, DFcode, DFcode },
{ geXF, Tcode, XFcode, XFcode },
{ geP, Tcode, Pcode, Pcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_gt_expr[] = {
{ gtSI, Tcode, SIcode, SIcode },
{ gtSU, Tcode, SUcode, SUcode },
{ gtDI, Tcode, DIcode, DIcode },
{ gtDU, Tcode, DUcode, DUcode },
{ gtSF, Tcode, SFcode, SFcode },
{ gtDF, Tcode, DFcode, DFcode },
{ gtXF, Tcode, XFcode, XFcode },
{ gtP, Tcode, Pcode, Pcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_eq_expr[] = {
{ eqSI, Tcode, SIcode, SIcode },
{ eqDI, Tcode, DIcode, DIcode },
{ eqSF, Tcode, SFcode, SFcode },
{ eqDF, Tcode, DFcode, DFcode },
{ eqXF, Tcode, XFcode, XFcode },
{ eqP, Tcode, Pcode, Pcode },
{ -1, -1, -1, -1 },
};
struct binary_operator optab_ne_expr[] = {
{ neSI, Tcode, SIcode, SIcode },
{ neDI, Tcode, DIcode, DIcode },
{ neSF, Tcode, SFcode, SFcode },
{ neDF, Tcode, DFcode, DFcode },
{ neXF, Tcode, XFcode, XFcode },
{ neP, Tcode, Pcode, Pcode },
{ -1, -1, -1, -1 },
};
/* Unary operator tables. */
struct unary_operator optab_negate_expr[] = {
{ negSI, SIcode, SIcode },
{ negDI, DIcode, DIcode },
{ negSF, SFcode, SFcode },
{ negDF, DFcode, DFcode },
{ negXF, XFcode, XFcode },
{ -1, -1, -1 },
};
struct unary_operator optab_bit_not_expr[] = {
{ notSI, SIcode, SIcode },
{ notDI, DIcode, DIcode },
{ -1, -1, -1 },
};
struct unary_operator optab_truth_not_expr[] = {
{ notT, SIcode, SIcode },
{ -1, -1, -1 },
};
/* Increment operator tables. */
struct increment_operator optab_predecrement_expr[] = {
{ predecQI, QIcode },
{ predecQI, QUcode },
{ predecHI, HIcode },
{ predecHI, HUcode },
{ predecSI, SIcode },
{ predecSI, SUcode },
{ predecDI, DIcode },
{ predecDI, DUcode },
{ predecP, Pcode },
{ predecSF, SFcode },
{ predecDF, DFcode },
{ predecXF, XFcode },
{ -1, -1 },
};
struct increment_operator optab_preincrement_expr[] = {
{ preincQI, QIcode },
{ preincQI, QUcode },
{ preincHI, HIcode },
{ preincHI, HUcode },
{ preincSI, SIcode },
{ preincSI, SUcode },
{ preincDI, DIcode },
{ preincDI, DUcode },
{ preincP, Pcode },
{ preincSF, SFcode },
{ preincDF, DFcode },
{ preincXF, XFcode },
{ -1, -1 },
};
struct increment_operator optab_postdecrement_expr[] = {
{ postdecQI, QIcode },
{ postdecQI, QUcode },
{ postdecHI, HIcode },
{ postdecHI, HUcode },
{ postdecSI, SIcode },
{ postdecSI, SUcode },
{ postdecDI, DIcode },
{ postdecDI, DUcode },
{ postdecP, Pcode },
{ postdecSF, SFcode },
{ postdecDF, DFcode },
{ postdecXF, XFcode },
{ -1, -1 },
};
struct increment_operator optab_postincrement_expr[] = {
{ postincQI, QIcode },
{ postincQI, QUcode },
{ postincHI, HIcode },
{ postincHI, HUcode },
{ postincSI, SIcode },
{ postincSI, SUcode },
{ postincDI, DIcode },
{ postincDI, DUcode },
{ postincP, Pcode },
{ postincSF, SFcode },
{ postincDF, DFcode },
{ postincXF, XFcode },
{ -1, -1 },
};
/* Table of conversions supported by the interpreter. */
static struct conversion_info
{
enum bytecode_opcode opcode; /* here indicates the conversion needs no opcode. */
enum typecode from;
enum typecode to;
int cost; /* 1 for no-op conversions, 2 for widening conversions,
4 for int/float conversions, 8 for narrowing conversions. */
} conversion_info[] = {
{ -1, QIcode, QUcode, 1 },
{ -1, HIcode, HUcode, 1 },
{ -1, SIcode, SUcode, 1 },
{ -1, DIcode, DUcode, 1 },
{ -1, QUcode, QIcode, 1 },
{ -1, HUcode, HIcode, 1 },
{ -1, SUcode, SIcode, 1 },
{ -1, DUcode, DIcode, 1 },
{ -1, Tcode, SIcode, 1 },
{ convertQIHI, QIcode, HIcode, 2 },
{ convertQUHU, QUcode, HUcode, 2 },
{ convertQUSU, QUcode, SUcode, 2 },
{ convertHISI, HIcode, SIcode, 2 },
{ convertHUSU, HUcode, SUcode, 2 },
{ convertSIDI, SIcode, DIcode, 2 },
{ convertSUDU, SUcode, DUcode, 2 },
{ convertSFDF, SFcode, DFcode, 2 },
{ convertDFXF, DFcode, XFcode, 2 },
{ convertHIQI, HIcode, QIcode, 8 },
{ convertSIQI, SIcode, QIcode, 8 },
{ convertSIHI, SIcode, HIcode, 8 },
{ convertSUQU, SUcode, QUcode, 8 },
{ convertDISI, DIcode, SIcode, 8 },
{ convertDFSF, DFcode, SFcode, 8 },
{ convertXFDF, XFcode, DFcode, 8 },
{ convertPSI, Pcode, SIcode, 2 },
{ convertSIP, SIcode, Pcode, 2 },
{ convertSIT, SIcode, Tcode, 2 },
{ convertDIT, DIcode, Tcode, 2 },
{ convertSFT, SFcode, Tcode, 2 },
{ convertDFT, DFcode, Tcode, 2 },
{ convertXFT, XFcode, Tcode, 2 },
{ convertQISI, QIcode, SIcode, 2 },
{ convertPT, Pcode, Tcode, 2 },
{ convertSISF, SIcode, SFcode, 4 },
{ convertSIDF, SIcode, DFcode, 4 },
{ convertSIXF, SIcode, XFcode, 4 },
{ convertSUSF, SUcode, SFcode, 4 },
{ convertSUDF, SUcode, DFcode, 4 },
{ convertSUXF, SUcode, XFcode, 4 },
{ convertDISF, DIcode, SFcode, 4 },
{ convertDIDF, DIcode, DFcode, 4 },
{ convertDIXF, DIcode, XFcode, 4 },
{ convertDUSF, DUcode, SFcode, 4 },
{ convertDUDF, DUcode, DFcode, 4 },
{ convertDUXF, DUcode, XFcode, 4 },
{ convertSFSI, SFcode, SIcode, 4 },
{ convertDFSI, DFcode, SIcode, 4 },
{ convertXFSI, XFcode, SIcode, 4 },
{ convertSFSU, SFcode, SUcode, 4 },
{ convertDFSU, DFcode, SUcode, 4 },
{ convertXFSU, XFcode, SUcode, 4 },
{ convertSFDI, SFcode, DIcode, 4 },
{ convertDFDI, DFcode, DIcode, 4 },
{ convertXFDI, XFcode, DIcode, 4 },
{ convertSFDU, SFcode, DUcode, 4 },
{ convertDFDU, DFcode, DUcode, 4 },
{ convertXFDU, XFcode, DUcode, 4 },
{ convertSIQI, SIcode, QIcode, 8 },
};
#define NUM_CONVERSIONS (sizeof conversion_info / sizeof (struct conversion_info))
/* List form of a conversion recipe. */
struct conversion_list
{
enum bytecode_opcode opcode;
enum typecode to;
int cost;
struct conversion_list *prev;
};
/* Determine if it is "reasonable" to add a given conversion to
a given list of conversions. The following criteria define
"reasonable" conversion lists:
* No typecode appears more than once in the sequence (no loops).
* At most one conversion from integer to float or vice versa is present.
* Either sign extensions or zero extensions may be present, but not both.
* No widening conversions occur after a signed/unsigned conversion.
* The sequence of sizes must be strict nonincreasing or nondecreasing. */
static int
conversion_reasonable_p (conversion, list)
struct conversion_info *conversion;
struct conversion_list *list;
{
struct conversion_list *curr;
int curr_size, prev_size;
int has_int_float, has_float_int;
int has_sign_extend, has_zero_extend;
int has_signed_unsigned, has_unsigned_signed;
has_int_float = 0;
has_float_int = 0;
has_sign_extend = 0;
has_zero_extend = 0;
has_signed_unsigned = 0;
has_unsigned_signed = 0;
/* Make sure the destination typecode doesn't already appear in
the list. */
for (curr = list; curr; curr = curr->prev)
if (conversion->to == curr->to)
return 0;
/* Check for certain kinds of conversions. */
if (TYPECODE_INTEGER_P (conversion->from)
&& TYPECODE_FLOAT_P (conversion->to))
has_int_float = 1;
if (TYPECODE_FLOAT_P (conversion->from)
&& TYPECODE_INTEGER_P (conversion->to))
has_float_int = 1;
if (TYPECODE_SIGNED_P (conversion->from)
&& TYPECODE_SIGNED_P (conversion->to)
&& GET_TYPECODE_SIZE (conversion->from)
< GET_TYPECODE_SIZE (conversion->to))
has_sign_extend = 1;
if (TYPECODE_UNSIGNED_P (conversion->from)
&& TYPECODE_UNSIGNED_P (conversion->to)
&& GET_TYPECODE_SIZE (conversion->from)
< GET_TYPECODE_SIZE (conversion->to))
has_zero_extend = 1;
for (curr = list; curr && curr->prev; curr = curr->prev)
{
if (TYPECODE_INTEGER_P (curr->prev->to)
&& TYPECODE_FLOAT_P (curr->to))
has_int_float = 1;
if (TYPECODE_FLOAT_P (curr->prev->to)
&& TYPECODE_INTEGER_P (curr->to))
has_float_int = 1;
if (TYPECODE_SIGNED_P (curr->prev->to)
&& TYPECODE_SIGNED_P (curr->to)
&& GET_TYPECODE_SIZE (curr->prev->to)
< GET_TYPECODE_SIZE (curr->to))
has_sign_extend = 1;
if (TYPECODE_UNSIGNED_P (curr->prev->to)
&& TYPECODE_UNSIGNED_P (curr->to)
&& GET_TYPECODE_SIZE (curr->prev->to)
< GET_TYPECODE_SIZE (curr->to))
has_zero_extend = 1;
if (TYPECODE_SIGNED_P (curr->prev->to)
&& TYPECODE_UNSIGNED_P (curr->to))
has_signed_unsigned = 1;
if (TYPECODE_UNSIGNED_P (curr->prev->to)
&& TYPECODE_SIGNED_P (curr->to))
has_unsigned_signed = 1;
}
if (TYPECODE_INTEGER_P (conversion->from)
&& TYPECODE_INTEGER_P (conversion->to)
&& GET_TYPECODE_SIZE (conversion->to)
> GET_TYPECODE_SIZE (conversion->from)
&& (has_signed_unsigned || has_unsigned_signed))
return 0;
if (has_float_int && has_int_float || has_sign_extend && has_zero_extend)
return 0;
/* Make sure the sequence of destination typecode sizes is
strictly nondecreasing or strictly nonincreasing. */
prev_size = GET_TYPECODE_SIZE (conversion->to);
for (curr = list; curr; curr = curr->prev)
{
curr_size = GET_TYPECODE_SIZE (curr->to);
if (curr_size != prev_size)
break;
}
if (!curr)
return 1;
if (curr_size < prev_size)
for (prev_size = curr_size; curr; curr = curr->prev)
{
curr_size = GET_TYPECODE_SIZE (curr->to);
if (curr_size > prev_size)
return 0;
prev_size = curr_size;
}
else
for (prev_size = curr_size; curr; curr = curr->prev)
{
curr_size = GET_TYPECODE_SIZE (curr->to);
if (curr_size < prev_size)
return 0;
prev_size = curr_size;
}
return 1;
}
/* Exhaustively search all reasonable conversions to find one to
convert the given types. */
static struct conversion_recipe
deduce_conversion (from, to)
enum typecode from, to;
{
struct rl
{
struct conversion_list *list;
struct rl *next;
} *prev, curr, *good, *temp;
struct conversion_list *conv, *best;
int i, cost, bestcost;
struct conversion_recipe result;
struct obstack recipe_obstack;
obstack_init (&recipe_obstack);
curr.next = (struct rl *) obstack_alloc (&recipe_obstack, sizeof (struct rl));
curr.next->list
= (struct conversion_list *) obstack_alloc (&recipe_obstack,
sizeof (struct conversion_list));
curr.next->list->opcode = -1;
curr.next->list->to = from;
curr.next->list->cost = 0;
curr.next->list->prev = 0;
curr.next->next = 0;
good = 0;
while (curr.next)
{
/* Remove successful conversions from further consideration. */
for (prev = &curr; prev; prev = prev->next)
if (prev->next && prev->next->list->to == to)
{
temp = prev->next->next;
prev->next->next = good;
good = prev->next;
prev->next = temp;
}
/* Go through each of the pending conversion chains, trying
all possible candidate conversions on them. */
for (prev = curr.next, curr.next = 0; prev; prev = prev->next)
for (i = 0; i < NUM_CONVERSIONS; ++i)
if (conversion_info[i].from == prev->list->to
&& conversion_reasonable_p (&conversion_info[i], prev->list))
{
temp = (struct rl *) obstack_alloc (&recipe_obstack,
sizeof (struct rl));
temp->list = (struct conversion_list *)
obstack_alloc (&recipe_obstack,
sizeof (struct conversion_list));
temp->list->opcode = conversion_info[i].opcode;
temp->list->to = conversion_info[i].to;
temp->list->cost = conversion_info[i].cost;
temp->list->prev = prev->list;
temp->next = curr.next;
curr.next = temp;
}
}
bestcost = BIG_ARBITRARY_NUMBER;
best = 0;
for (temp = good; temp; temp = temp->next)
{
for (conv = temp->list, cost = 0; conv; conv = conv->prev)
cost += conv->cost;
if (cost < bestcost)
{
bestcost = cost;
best = temp->list;
}
}
if (!best)
abort ();
for (i = 0, conv = best; conv; conv = conv->prev)
if (conv->opcode != -1)
++i;
result.opcodes = (unsigned char *) xmalloc (i);
result.nopcodes = i;
for (conv = best; conv; conv = conv->prev)
if (conv->opcode != -1)
result.opcodes[--i] = conv->opcode;
result.cost = bestcost;
obstack_free (&recipe_obstack, 0);
return result;
}
#define DEDUCE_CONVERSION(FROM, TO) \
(conversion_recipe[(int) FROM][(int) TO].opcodes ? 0 \
: (conversion_recipe[(int) FROM][(int) TO] \
= deduce_conversion (FROM, TO), 0))
/* Emit a conversion between the given scalar types. */
void
emit_typecode_conversion (from, to)
enum typecode from, to;
{
int i;
DEDUCE_CONVERSION (from, to);
for (i = 0; i < conversion_recipe[(int) from][(int) to].nopcodes; ++i)
bc_emit_instruction (conversion_recipe[(int) from][(int) to].opcodes[i]);
}
/* Initialize mode_to_code_map[] */
void
bc_init_mode_to_code_map ()
{
int mode;
for (mode = 0; mode < MAX_MACHINE_MODE + 1; mode++)
{
signed_mode_to_code_map[mode]
= unsigned_mode_to_code_map[mode]
= LAST_AND_UNUSED_TYPECODE;
}
#define DEF_MODEMAP(SYM, CODE, UCODE, CONST, LOAD, STORE) \
{ signed_mode_to_code_map[(int) SYM] = CODE; \
unsigned_mode_to_code_map[(int) SYM] = UCODE; }
#include "modemap.def"
#undef DEF_MODEMAP
/* Initialize opcode maps for const, load, and store */
bc_init_mode_to_opcode_maps ();
}
/* Given a machine mode return the preferred typecode. */
enum typecode
preferred_typecode (mode, unsignedp)
enum machine_mode mode;
int unsignedp;
{
enum typecode code = (unsignedp
? unsigned_mode_to_code_map
: signed_mode_to_code_map) [MIN ((int) mode,
(int) MAX_MACHINE_MODE)];
if (code == LAST_AND_UNUSED_TYPECODE)
abort ();
return code;
}
/* Expand a conversion between the given types. */
void
bc_expand_conversion (from, to)
tree from, to;
{
enum typecode fcode, tcode;
fcode = preferred_typecode (TYPE_MODE (from), TREE_UNSIGNED (from));
tcode = preferred_typecode (TYPE_MODE (to), TREE_UNSIGNED (to));
emit_typecode_conversion (fcode, tcode);
}
/* Expand a conversion of the given type to a truth value. */
void
bc_expand_truth_conversion (from)
tree from;
{
enum typecode fcode;
fcode = preferred_typecode (TYPE_MODE (from), TREE_UNSIGNED (from));
emit_typecode_conversion (fcode, Tcode);
}
/* Emit an appropriate binary operation. */
void
bc_expand_binary_operation (optab, resulttype, arg0, arg1)
struct binary_operator optab[];
tree resulttype, arg0, arg1;
{
int i, besti, cost, bestcost;
enum typecode resultcode, arg0code, arg1code;
resultcode = preferred_typecode (TYPE_MODE (resulttype), TREE_UNSIGNED (resulttype));
arg0code = preferred_typecode (TYPE_MODE (TREE_TYPE (arg0)), TREE_UNSIGNED (resulttype));
arg1code = preferred_typecode (TYPE_MODE (TREE_TYPE (arg1)), TREE_UNSIGNED (resulttype));
besti = -1;
bestcost = BIG_ARBITRARY_NUMBER;
for (i = 0; optab[i].opcode != -1; ++i)
{
cost = 0;
DEDUCE_CONVERSION (arg0code, optab[i].arg0);
cost += conversion_recipe[(int) arg0code][(int) optab[i].arg0].cost;
DEDUCE_CONVERSION (arg1code, optab[i].arg1);
cost += conversion_recipe[(int) arg1code][(int) optab[i].arg1].cost;
if (cost < bestcost)
{
besti = i;
bestcost = cost;
}
}
if (besti == -1)
abort ();
expand_expr (arg1, 0, VOIDmode, 0);
emit_typecode_conversion (arg1code, optab[besti].arg1);
expand_expr (arg0, 0, VOIDmode, 0);
emit_typecode_conversion (arg0code, optab[besti].arg0);
bc_emit_instruction (optab[besti].opcode);
emit_typecode_conversion (optab[besti].result, resultcode);
}
/* Emit an appropriate unary operation. */
void
bc_expand_unary_operation (optab, resulttype, arg0)
struct unary_operator optab[];
tree resulttype, arg0;
{
int i, besti, cost, bestcost;
enum typecode resultcode, arg0code;
resultcode = preferred_typecode (TYPE_MODE (resulttype), TREE_UNSIGNED (resulttype));
arg0code = preferred_typecode (TYPE_MODE (TREE_TYPE (arg0)), TREE_UNSIGNED (TREE_TYPE (arg0)));
besti = -1;
bestcost = BIG_ARBITRARY_NUMBER;
for (i = 0; optab[i].opcode != -1; ++i)
{
DEDUCE_CONVERSION (arg0code, optab[i].arg0);
cost = conversion_recipe[(int) arg0code][(int) optab[i].arg0].cost;
if (cost < bestcost)
{
besti = i;
bestcost = cost;
}
}
if (besti == -1)
abort ();
expand_expr (arg0, 0, VOIDmode, 0);
emit_typecode_conversion (arg0code, optab[besti].arg0);
bc_emit_instruction (optab[besti].opcode);
emit_typecode_conversion (optab[besti].result, resultcode);
}
/* Emit an appropriate increment. */
void
bc_expand_increment (optab, type)
struct increment_operator optab[];
tree type;
{
enum typecode code;
int i;
code = preferred_typecode (TYPE_MODE (type), TREE_UNSIGNED (type));
for (i = 0; (int) optab[i].opcode >= 0; ++i)
if (code == optab[i].arg)
{
bc_emit_instruction (optab[i].opcode);
return;
}
abort ();
}

75
gcc/bc-optab.h Normal file
View File

@@ -0,0 +1,75 @@
/* Bytecode token definitions for GNU C-compiler.
Copyright (C) 1993 Free Software Foundation, Inc.
This file is part of GNU CC.
GNU CC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU CC is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
extern void bc_expand_conversion ();
extern void bc_expand_truth_conversion ();
extern void bc_expand_binary_operation ();
extern void bc_expand_unary_operation ();
struct binary_operator
{
enum bytecode_opcode opcode;
enum typecode result;
enum typecode arg0;
enum typecode arg1;
};
extern struct binary_operator optab_plus_expr[];
extern struct binary_operator optab_minus_expr[];
extern struct binary_operator optab_mult_expr[];
extern struct binary_operator optab_trunc_div_expr[];
extern struct binary_operator optab_trunc_mod_expr[];
extern struct binary_operator optab_rdiv_expr[];
extern struct binary_operator optab_bit_and_expr[];
extern struct binary_operator optab_bit_ior_expr[];
extern struct binary_operator optab_bit_xor_expr[];
extern struct binary_operator optab_lshift_expr[];
extern struct binary_operator optab_rshift_expr[];
extern struct binary_operator optab_truth_and_expr[];
extern struct binary_operator optab_truth_or_expr[];
extern struct binary_operator optab_lt_expr[];
extern struct binary_operator optab_le_expr[];
extern struct binary_operator optab_ge_expr[];
extern struct binary_operator optab_gt_expr[];
extern struct binary_operator optab_eq_expr[];
extern struct binary_operator optab_ne_expr[];
struct unary_operator
{
enum bytecode_opcode opcode;
enum typecode result;
enum typecode arg0;
};
extern struct unary_operator optab_negate_expr[];
extern struct unary_operator optab_bit_not_expr[];
extern struct unary_operator optab_truth_not_expr[];
struct increment_operator
{
enum bytecode_opcode opcode;
enum typecode arg;
};
extern struct increment_operator optab_predecrement_expr[];
extern struct increment_operator optab_preincrement_expr[];
extern struct increment_operator optab_postdecrement_expr[];
extern struct increment_operator optab_postincrement_expr[];

21
gcc/bc-typecd.def Normal file
View File

@@ -0,0 +1,21 @@
/* Typecodes used by the interpreter and their related
machine modes and types.
The last argument is used for retrieving the given
type from a varargs list. Due to a bug in varargs,
the type has to be the generic machine type of
larger. */
DEFTYPECODE (QIcode, "QI", QImode, SItype)
DEFTYPECODE (QUcode, "QU", QImode, SUtype)
DEFTYPECODE (HIcode, "HI", HImode, SItype)
DEFTYPECODE (HUcode, "HU", HImode, SUtype)
DEFTYPECODE (SIcode, "SI", SImode, SItype)
DEFTYPECODE (SUcode, "SU", SImode, SUtype)
DEFTYPECODE (DIcode, "DI", DImode, DItype)
DEFTYPECODE (DUcode, "DU", DImode, DUtype)
DEFTYPECODE (SFcode, "SF", SFmode, SFtype)
DEFTYPECODE (DFcode, "DF", DFmode, DFtype)
DEFTYPECODE (XFcode, "XF", XFmode, XFtype)
DEFTYPECODE (Pcode, "P", PSImode, Ptype)
DEFTYPECODE (Tcode, "T", SImode, SItype)

54
gcc/bc-typecd.h Normal file
View File

@@ -0,0 +1,54 @@
/* Typecode definitions for Bytecode Interpreter.
Copyright (C) 1993 Free Software Foundation, Inc.
This file is part of GNU CC.
GNU CC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU CC is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#ifndef TYPECODE_H
#define TYPECODE_H
enum typecode
{
#define DEFTYPECODE(CODE, NAME, MACHMODE, TYPE) CODE,
#include "bc-typecd.def"
#undef DEFTYPECODE
LAST_AND_UNUSED_TYPECODE
};
/* Determine if a given type is integer. */
#define TYPECODE_INTEGER_P(TYPECODE) ((int) (TYPECODE) < (int) SFcode)
/* Determine if a given type is unsigned. */
#define TYPECODE_UNSIGNED_P(TYPECODE) \
(TYPECODE_INTEGER_P(TYPECODE) && (int) (TYPECODE) & 1)
/* Determine if a given type is signed. */
#define TYPECODE_SIGNED_P(TYPECODE) \
(TYPECODE_INTEGER_P(TYPECODE) && !((int) (TYPECODE) & 1))
/* Determine if a given type is floating. */
#define TYPECODE_FLOAT_P(TYPECODE) \
((int) (TYPECODE) < (int) Pcode && !TYPECODE_INTEGER_P(TYPECODE))
/* Determine if the given type is arithmetic. */
#define TYPECODE_ARITH_P(TYPECODE) \
(TYPECODE_INTEGER_P(TYPECODE) || TYPECODE_FLOAT_P(TYPECODE))
#define NUM_TYPECODES ((int) LAST_AND_UNUSED_TYPECODE)
#endif

91
gcc/bi-arity.c Normal file
View File

@@ -0,0 +1,91 @@
/* Bytecode Interpreter utility to generate arity table.
Copyright (C) 1993 Free Software Foundation, Inc.
This file is part of GNU CC.
GNU CC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU CC is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include <stdio.h>
#include "hconfig.h"
#include "bi-defs.h"
int
length (n)
struct node *n;
{
int k;
for (k = 0; n; n = n->next)
++k;
return k;
}
int
main ()
{
struct def *d;
struct variation *v;
struct node *n;
yyparse ();
reverse ();
for (d = defs; d; d = d->next)
for (v = d->variations; v; v = v->next)
{
printf ("{ %d, %d, %d, {", length (v->inputs),
length (v->outputs), length (v->literals));
for (n = v->literals; n; n = n->next)
printf ("(char) %scode, ", n->text);
if (v->literals == 0)
printf ("0");
printf ("}},\n");
}
fflush (stdout);
exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
/* NOTREACHED */
return 0;
}
/* Safely allocate NBYTES bytes of memory. Returns pointer to block of
memory. */
char *
xmalloc (nbytes)
int nbytes;
{
char *tmp = (char *) malloc (nbytes);
if (!tmp)
{
fprintf (stderr, "can't allocate %d bytes (out of virtual memory)\n", nbytes);
exit (FATAL_EXIT_CODE);
}
return tmp;
}
/* More 'friendly' abort that prints the line and file.
config.h can #define abort fancy_abort if you like that sort of thing. */
void
fancy_abort ()
{
fprintf (stderr, "Internal gcc abort.\n");
exit (FATAL_EXIT_CODE);
}

View File

@@ -1,5 +1,4 @@
/* Definition of conversion functions.
/* Definitions for Bytecode Interpreter.
Copyright (C) 1993 Free Software Foundation, Inc.
This file is part of GNU CC.
@@ -19,10 +18,31 @@ along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/* Written by Jeffrey Hsu <hsu@cygnus.com> */
extern tree convert_to_boolean PROTO ((tree, tree));
extern tree convert_to_char PROTO ((tree, tree));
extern tree convert_to_integer PROTO ((tree type, tree expr));
extern tree convert_to_real PROTO ((tree type, tree expr));
extern tree convert_to_pointer PROTO ((tree type, tree expr));
struct node
{
char *text;
struct node *next;
};
struct variation
{
char *name;
int code;
struct node *inputs;
struct node *outputs;
struct node *literals;
struct variation *next;
};
struct def
{
char *basename;
char *template;
struct variation *variations;
struct def *next;
};
extern struct def *defs;
extern int ndefs;
extern void reverse();

167
gcc/bi-lexer.c Normal file
View File

@@ -0,0 +1,167 @@
/* Lexer for scanner of bytecode definition file.
Copyright (C) 1993, 1995 Free Software Foundation, Inc.
This file is part of GNU CC.
GNU CC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU CC is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include <stdio.h>
#include "hconfig.h"
#include "bi-parser.h"
/* Safely allocate NBYTES bytes of memory. Returns pointer to block of
memory. */
static char *
xmalloc (nbytes)
int nbytes;
{
char *tmp = (char *) malloc (nbytes);
if (!tmp)
{
fprintf (stderr, "can't allocate %d bytes (out of virtual memory)\n", nbytes);
exit (FATAL_EXIT_CODE);
}
return tmp;
}
/* Safely reallocate BLOCK so its size becomes NBYTES.
The block returned may be different from the one supplied. */
static char *
xrealloc (block, nbytes)
char *block;
int nbytes;
{
char *tmp = (block
? (char *) realloc (block, nbytes)
: (char *) malloc (nbytes));
if (!tmp)
{
fprintf (stderr, "can't reallocate %d bytes (out of virtual memory)\n", nbytes);
exit (FATAL_EXIT_CODE);
}
return tmp;
}
/* Scan for string token on standard input. A string is, for our
purposes here, a sequence of characters that starts with the regexp
``[^ #\t\n(),]'' and is then followed by the regexp ``[^#(),]*''. Any
character is accepted if preceded by a backslash, "\\". It is assumed
that the first character has already been checked by the main loop. */
static char *
scan_string ()
{
char *buffer = NULL;
char *point = NULL;
int buffer_size = 0;
int c;
while ((c = getc (stdin)) != EOF
&& c != '#' && c != '(' && c != ')' && c != ',')
{
/* Extend buffer, if necessary (minus two so there's room for the NUL
trailer as well as another character if this one is a backslash). */
if (!buffer_size || (point - buffer >= buffer_size-2))
{
int previous_point_index = point - buffer;
buffer_size = (!buffer_size ? 32 : buffer_size * 2);
if (!buffer)
buffer = xmalloc (buffer_size);
else
buffer = xrealloc (buffer, buffer_size);
point = buffer + previous_point_index;
}
*point++ = c & 0xff;
if (c == '\\')
{
c = getc (stdin);
/* Catch special case: backslash at end of file */
if (c == EOF)
break;
*point++ = c;
}
}
*point = 0;
if (c != EOF)
ungetc (c, stdin);
return buffer;
}
int
yylex ()
{
int c;
char *token;
/* First char determines what token we're looking at */
for (;;)
{
c = getc (stdin);
switch (c)
{
case EOF:
return 0;
case ' ':
case '\t':
case '\n':
/* Ignore whitespace */
continue;
case '#':
/* Comments advance to next line */
while ((c = getc (stdin)) != '\n' && c != EOF);
continue;
default:
if (c != '(' && c != ')' && c != '\\' && c != ',')
{
ungetc (c, stdin);
yylval.string = scan_string ();
/* Check if string is "define_operator"; if so, return
a DEFOP token instead. */
if (!strcmp (yylval.string, "define_operator"))
{
free (yylval.string);
yylval.string = 0;
return DEFOP;
}
return STRING;
}
return c & 0xff;
}
}
}

89
gcc/bi-opcode.c Normal file
View File

@@ -0,0 +1,89 @@
/* Utility to generate opcode list from bytecode definition.
Copyright (C) 1993, 1994 Free Software Foundation, Inc.
This file is part of GNU CC.
GNU CC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU CC is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include <stdio.h>
#include "hconfig.h"
#include "bi-defs.h"
int
main(argc, argv)
int argc;
char **argv;
{
struct def *d;
struct variation *v;
int i;
yyparse();
reverse();
printf ("/* This file is automatically generated from bytecode.def,\n");
printf ("do not make any changes here. Instead edit bytecode.def. */\n\n");
printf ("enum bytecode_opcode\n{");
i = 0;
for (d = defs; d; d = d->next)
for (v = d->variations; v; v = v->next)
{
printf (" %s%s,\n", d->basename, v->name);
++i;
}
puts (" LAST_AND_UNUSED_OPCODE\n};");
if (i > 256)
fprintf (stderr, "%s: warning, number of opcodes is %d\n", *argv, i);
else
fprintf (stderr, "(Number of opcodes is %d)\n", i);
fflush (stdout);
exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
/* NOTREACHED */
return 0;
}
/* Safely allocate NBYTES bytes of memory. Returns pointer to block of
memory. */
char *
xmalloc (nbytes)
int nbytes;
{
char *tmp = (char *) malloc (nbytes);
if (!tmp)
{
fprintf (stderr, "can't allocate %d bytes (out of virtual memory)\n", nbytes);
exit (FATAL_EXIT_CODE);
}
return tmp;
}
/* More 'friendly' abort that prints the line and file.
config.h can #define abort fancy_abort if you like that sort of thing. */
void
fancy_abort ()
{
fprintf (stderr, "Internal gcc abort.\n");
exit (FATAL_EXIT_CODE);
}

70
gcc/bi-opname.c Normal file
View File

@@ -0,0 +1,70 @@
/* Utility to generate opcode name list from bytecode definition file.
Copyright (C) 1993 Free Software Foundation, Inc.
This file is part of GNU CC.
GNU CC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU CC is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include <stdio.h>
#include "hconfig.h"
#include "bi-defs.h"
int
main()
{
struct def *d;
struct variation *v;
yyparse();
reverse();
for (d = defs; d; d = d->next)
for (v = d->variations; v; v = v->next)
printf("\"%s%s\",\n", d->basename, v->name);
fflush (stdout);
exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
/* NOTREACHED */
return 0;
}
/* Safely allocate NBYTES bytes of memory. Returns pointer to block of
memory. */
char *
xmalloc (nbytes)
int nbytes;
{
char *tmp = (char *) malloc (nbytes);
if (!tmp)
{
fprintf (stderr, "can't allocate %d bytes (out of virtual memory)\n", nbytes);
exit (FATAL_EXIT_CODE);
}
return tmp;
}
/* More 'friendly' abort that prints the line and file.
config.h can #define abort fancy_abort if you like that sort of thing. */
void
fancy_abort ()
{
fprintf (stderr, "Internal gcc abort.\n");
exit (FATAL_EXIT_CODE);
}

980
gcc/bi-parser.c Normal file
View File

@@ -0,0 +1,980 @@
/* A Bison parser, made from bi-parser.y with Bison version GNU Bison version 1.24
*/
#define YYBISON 1 /* Identify Bison output. */
#define DEFOP 258
#define STRING 259
#line 22 "bi-parser.y"
#include <stdio.h>
#include "hconfig.h"
#include "bi-defs.h"
extern char yytext[];
extern int yyleng;
/* Chain of all defs built by the parser. */
struct def *defs;
int ndefs;
static struct node *makenode ();
static struct variation *makevar ();
static struct def *makedef ();
void yyerror ();
#line 44 "bi-parser.y"
typedef union
{
char *string;
struct def *def;
struct variation *variation;
struct node *node;
} YYSTYPE;
#ifndef YYLTYPE
typedef
struct yyltype
{
int timestamp;
int first_line;
int first_column;
int last_line;
int last_column;
char *text;
}
yyltype;
#define YYLTYPE yyltype
#endif
#include <stdio.h>
#ifndef __cplusplus
#ifndef __STDC__
#define const
#endif
#endif
#define YYFINAL 39
#define YYFLAG -32768
#define YYNTBASE 8
#define YYTRANSLATE(x) ((unsigned)(x) <= 259 ? yytranslate[x] : 17)
static const char yytranslate[] = { 0,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 5,
7, 2, 2, 6, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 1, 2, 3, 4
};
#if YYDEBUG != 0
static const short yyprhs[] = { 0,
0, 2, 4, 7, 18, 20, 24, 28, 34, 42,
52, 53, 55, 59, 60, 62, 66
};
static const short yyrhs[] = { 9,
0, 10, 0, 9, 10, 0, 3, 5, 4, 6,
13, 6, 5, 11, 7, 7, 0, 12, 0, 11,
6, 12, 0, 5, 13, 7, 0, 5, 13, 6,
14, 7, 0, 5, 13, 6, 14, 6, 14, 7,
0, 5, 13, 6, 14, 6, 14, 6, 14, 7,
0, 0, 4, 0, 5, 15, 7, 0, 0, 16,
0, 16, 6, 15, 0, 4, 0
};
#endif
#if YYDEBUG != 0
static const short yyrline[] = { 0,
60, 65, 67, 71, 76, 78, 82, 85, 87, 89,
93, 95, 98, 101, 105, 108, 112
};
static const char * const yytname[] = { "$","error","$undefined.","DEFOP",
"STRING","'('","','","')'","top","defs","def","variations","variation","opt_string",
"list","items","item",""
};
#endif
static const short yyr1[] = { 0,
8, 9, 9, 10, 11, 11, 12, 12, 12, 12,
13, 13, 14, 14, 15, 15, 16
};
static const short yyr2[] = { 0,
1, 1, 2, 10, 1, 3, 3, 5, 7, 9,
0, 1, 3, 0, 1, 3, 1
};
static const short yydefact[] = { 0,
0, 1, 2, 0, 3, 0, 11, 12, 0, 0,
0, 11, 0, 5, 0, 0, 0, 14, 7, 6,
4, 0, 0, 17, 0, 15, 14, 8, 13, 0,
0, 16, 14, 9, 0, 10, 0, 0, 0
};
static const short yydefgoto[] = { 37,
2, 3, 13, 14, 9, 23, 25, 26
};
static const short yypact[] = { 2,
6, 2,-32768, 8,-32768, 7, 10,-32768, 9, 11,
12, 10, -5,-32768, -3, 12, 13, 14,-32768,-32768,
-32768, 17, 1,-32768, 15, 18, 14,-32768,-32768, 17,
3,-32768, 14,-32768, 16,-32768, 25, 26,-32768
};
static const short yypgoto[] = {-32768,
-32768, 27,-32768, 19, 20, -27, -12,-32768
};
#define YYLAST 35
static const short yytable[] = { 31,
16, 17, 18, 19, 1, 35, 27, 28, 33, 34,
4, 6, 7, 8, 10, 11, 12, 32, 22, 21,
24, 29, 36, 30, 38, 39, 0, 0, 5, 0,
0, 15, 0, 0, 20
};
static const short yycheck[] = { 27,
6, 7, 6, 7, 3, 33, 6, 7, 6, 7,
5, 4, 6, 4, 6, 5, 5, 30, 5, 7,
4, 7, 7, 6, 0, 0, -1, -1, 2, -1,
-1, 12, -1, -1, 16
};
/* -*-C-*- Note some compilers choke on comments on `#line' lines. */
#line 3 "/usr/local/share/bison.simple"
/* Skeleton output parser for bison,
Copyright (C) 1984, 1989, 1990 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
/* As a special exception, when this file is copied by Bison into a
Bison output file, you may use that output file without restriction.
This special exception was added by the Free Software Foundation
in version 1.24 of Bison. */
#ifndef alloca
#ifdef __GNUC__
#define alloca __builtin_alloca
#else /* not GNU C. */
#if (!defined (__STDC__) && defined (sparc)) || defined (__sparc__) || defined (__sparc) || defined (__sgi)
#include <alloca.h>
#else /* not sparc */
#if defined (MSDOS) && !defined (__TURBOC__)
#include <malloc.h>
#else /* not MSDOS, or __TURBOC__ */
#if defined(_AIX)
#include <malloc.h>
#pragma alloca
#else /* not MSDOS, __TURBOC__, or _AIX */
#ifdef __hpux
#ifdef __cplusplus
extern "C" {
void *alloca (unsigned int);
};
#else /* not __cplusplus */
void *alloca ();
#endif /* not __cplusplus */
#endif /* __hpux */
#endif /* not _AIX */
#endif /* not MSDOS, or __TURBOC__ */
#endif /* not sparc. */
#endif /* not GNU C. */
#endif /* alloca not defined. */
/* This is the parser code that is written into each bison parser
when the %semantic_parser declaration is not specified in the grammar.
It was written by Richard Stallman by simplifying the hairy parser
used when %semantic_parser is specified. */
/* Note: there must be only one dollar sign in this file.
It is replaced by the list of actions, each action
as one case of the switch. */
#define yyerrok (yyerrstatus = 0)
#define yyclearin (yychar = YYEMPTY)
#define YYEMPTY -2
#define YYEOF 0
#define YYACCEPT return(0)
#define YYABORT return(1)
#define YYERROR goto yyerrlab1
/* Like YYERROR except do call yyerror.
This remains here temporarily to ease the
transition to the new meaning of YYERROR, for GCC.
Once GCC version 2 has supplanted version 1, this can go. */
#define YYFAIL goto yyerrlab
#define YYRECOVERING() (!!yyerrstatus)
#define YYBACKUP(token, value) \
do \
if (yychar == YYEMPTY && yylen == 1) \
{ yychar = (token), yylval = (value); \
yychar1 = YYTRANSLATE (yychar); \
YYPOPSTACK; \
goto yybackup; \
} \
else \
{ yyerror ("syntax error: cannot back up"); YYERROR; } \
while (0)
#define YYTERROR 1
#define YYERRCODE 256
#ifndef YYPURE
#define YYLEX yylex()
#endif
#ifdef YYPURE
#ifdef YYLSP_NEEDED
#ifdef YYLEX_PARAM
#define YYLEX yylex(&yylval, &yylloc, YYLEX_PARAM)
#else
#define YYLEX yylex(&yylval, &yylloc)
#endif
#else /* not YYLSP_NEEDED */
#ifdef YYLEX_PARAM
#define YYLEX yylex(&yylval, YYLEX_PARAM)
#else
#define YYLEX yylex(&yylval)
#endif
#endif /* not YYLSP_NEEDED */
#endif
/* If nonreentrant, generate the variables here */
#ifndef YYPURE
int yychar; /* the lookahead symbol */
YYSTYPE yylval; /* the semantic value of the */
/* lookahead symbol */
#ifdef YYLSP_NEEDED
YYLTYPE yylloc; /* location data for the lookahead */
/* symbol */
#endif
int yynerrs; /* number of parse errors so far */
#endif /* not YYPURE */
#if YYDEBUG != 0
int yydebug; /* nonzero means print parse trace */
/* Since this is uninitialized, it does not stop multiple parsers
from coexisting. */
#endif
/* YYINITDEPTH indicates the initial size of the parser's stacks */
#ifndef YYINITDEPTH
#define YYINITDEPTH 200
#endif
/* YYMAXDEPTH is the maximum size the stacks can grow to
(effective only if the built-in stack extension method is used). */
#if YYMAXDEPTH == 0
#undef YYMAXDEPTH
#endif
#ifndef YYMAXDEPTH
#define YYMAXDEPTH 10000
#endif
/* Prevent warning if -Wstrict-prototypes. */
#ifdef __GNUC__
int yyparse (void);
#endif
#if __GNUC__ > 1 /* GNU C and GNU C++ define this. */
#define __yy_memcpy(FROM,TO,COUNT) __builtin_memcpy(TO,FROM,COUNT)
#else /* not GNU C or C++ */
#ifndef __cplusplus
/* This is the most reliable way to avoid incompatibilities
in available built-in functions on various systems. */
static void
__yy_memcpy (from, to, count)
char *from;
char *to;
int count;
{
register char *f = from;
register char *t = to;
register int i = count;
while (i-- > 0)
*t++ = *f++;
}
#else /* __cplusplus */
/* This is the most reliable way to avoid incompatibilities
in available built-in functions on various systems. */
static void
__yy_memcpy (char *from, char *to, int count)
{
register char *f = from;
register char *t = to;
register int i = count;
while (i-- > 0)
*t++ = *f++;
}
#endif
#endif
#line 192 "/usr/local/share/bison.simple"
/* The user can define YYPARSE_PARAM as the name of an argument to be passed
into yyparse. The argument should have type void *.
It should actually point to an object.
Grammar actions can access the variable by casting it
to the proper pointer type. */
#ifdef YYPARSE_PARAM
#define YYPARSE_PARAM_DECL void *YYPARSE_PARAM;
#else
#define YYPARSE_PARAM
#define YYPARSE_PARAM_DECL
#endif
int
yyparse(YYPARSE_PARAM)
YYPARSE_PARAM_DECL
{
register int yystate;
register int yyn;
register short *yyssp;
register YYSTYPE *yyvsp;
int yyerrstatus; /* number of tokens to shift before error messages enabled */
int yychar1 = 0; /* lookahead token as an internal (translated) token number */
short yyssa[YYINITDEPTH]; /* the state stack */
YYSTYPE yyvsa[YYINITDEPTH]; /* the semantic value stack */
short *yyss = yyssa; /* refer to the stacks thru separate pointers */
YYSTYPE *yyvs = yyvsa; /* to allow yyoverflow to reallocate them elsewhere */
#ifdef YYLSP_NEEDED
YYLTYPE yylsa[YYINITDEPTH]; /* the location stack */
YYLTYPE *yyls = yylsa;
YYLTYPE *yylsp;
#define YYPOPSTACK (yyvsp--, yyssp--, yylsp--)
#else
#define YYPOPSTACK (yyvsp--, yyssp--)
#endif
int yystacksize = YYINITDEPTH;
#ifdef YYPURE
int yychar;
YYSTYPE yylval;
int yynerrs;
#ifdef YYLSP_NEEDED
YYLTYPE yylloc;
#endif
#endif
YYSTYPE yyval; /* the variable used to return */
/* semantic values from the action */
/* routines */
int yylen;
#if YYDEBUG != 0
if (yydebug)
fprintf(stderr, "Starting parse\n");
#endif
yystate = 0;
yyerrstatus = 0;
yynerrs = 0;
yychar = YYEMPTY; /* Cause a token to be read. */
/* Initialize stack pointers.
Waste one element of value and location stack
so that they stay on the same level as the state stack.
The wasted elements are never initialized. */
yyssp = yyss - 1;
yyvsp = yyvs;
#ifdef YYLSP_NEEDED
yylsp = yyls;
#endif
/* Push a new state, which is found in yystate . */
/* In all cases, when you get here, the value and location stacks
have just been pushed. so pushing a state here evens the stacks. */
yynewstate:
*++yyssp = yystate;
if (yyssp >= yyss + yystacksize - 1)
{
/* Give user a chance to reallocate the stack */
/* Use copies of these so that the &'s don't force the real ones into memory. */
YYSTYPE *yyvs1 = yyvs;
short *yyss1 = yyss;
#ifdef YYLSP_NEEDED
YYLTYPE *yyls1 = yyls;
#endif
/* Get the current used size of the three stacks, in elements. */
int size = yyssp - yyss + 1;
#ifdef yyoverflow
/* Each stack pointer address is followed by the size of
the data in use in that stack, in bytes. */
#ifdef YYLSP_NEEDED
/* This used to be a conditional around just the two extra args,
but that might be undefined if yyoverflow is a macro. */
yyoverflow("parser stack overflow",
&yyss1, size * sizeof (*yyssp),
&yyvs1, size * sizeof (*yyvsp),
&yyls1, size * sizeof (*yylsp),
&yystacksize);
#else
yyoverflow("parser stack overflow",
&yyss1, size * sizeof (*yyssp),
&yyvs1, size * sizeof (*yyvsp),
&yystacksize);
#endif
yyss = yyss1; yyvs = yyvs1;
#ifdef YYLSP_NEEDED
yyls = yyls1;
#endif
#else /* no yyoverflow */
/* Extend the stack our own way. */
if (yystacksize >= YYMAXDEPTH)
{
yyerror("parser stack overflow");
return 2;
}
yystacksize *= 2;
if (yystacksize > YYMAXDEPTH)
yystacksize = YYMAXDEPTH;
yyss = (short *) alloca (yystacksize * sizeof (*yyssp));
__yy_memcpy ((char *)yyss1, (char *)yyss, size * sizeof (*yyssp));
yyvs = (YYSTYPE *) alloca (yystacksize * sizeof (*yyvsp));
__yy_memcpy ((char *)yyvs1, (char *)yyvs, size * sizeof (*yyvsp));
#ifdef YYLSP_NEEDED
yyls = (YYLTYPE *) alloca (yystacksize * sizeof (*yylsp));
__yy_memcpy ((char *)yyls1, (char *)yyls, size * sizeof (*yylsp));
#endif
#endif /* no yyoverflow */
yyssp = yyss + size - 1;
yyvsp = yyvs + size - 1;
#ifdef YYLSP_NEEDED
yylsp = yyls + size - 1;
#endif
#if YYDEBUG != 0
if (yydebug)
fprintf(stderr, "Stack size increased to %d\n", yystacksize);
#endif
if (yyssp >= yyss + yystacksize - 1)
YYABORT;
}
#if YYDEBUG != 0
if (yydebug)
fprintf(stderr, "Entering state %d\n", yystate);
#endif
goto yybackup;
yybackup:
/* Do appropriate processing given the current state. */
/* Read a lookahead token if we need one and don't already have one. */
/* yyresume: */
/* First try to decide what to do without reference to lookahead token. */
yyn = yypact[yystate];
if (yyn == YYFLAG)
goto yydefault;
/* Not known => get a lookahead token if don't already have one. */
/* yychar is either YYEMPTY or YYEOF
or a valid token in external form. */
if (yychar == YYEMPTY)
{
#if YYDEBUG != 0
if (yydebug)
fprintf(stderr, "Reading a token: ");
#endif
yychar = YYLEX;
}
/* Convert token to internal form (in yychar1) for indexing tables with */
if (yychar <= 0) /* This means end of input. */
{
yychar1 = 0;
yychar = YYEOF; /* Don't call YYLEX any more */
#if YYDEBUG != 0
if (yydebug)
fprintf(stderr, "Now at end of input.\n");
#endif
}
else
{
yychar1 = YYTRANSLATE(yychar);
#if YYDEBUG != 0
if (yydebug)
{
fprintf (stderr, "Next token is %d (%s", yychar, yytname[yychar1]);
/* Give the individual parser a way to print the precise meaning
of a token, for further debugging info. */
#ifdef YYPRINT
YYPRINT (stderr, yychar, yylval);
#endif
fprintf (stderr, ")\n");
}
#endif
}
yyn += yychar1;
if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != yychar1)
goto yydefault;
yyn = yytable[yyn];
/* yyn is what to do for this token type in this state.
Negative => reduce, -yyn is rule number.
Positive => shift, yyn is new state.
New state is final state => don't bother to shift,
just return success.
0, or most negative number => error. */
if (yyn < 0)
{
if (yyn == YYFLAG)
goto yyerrlab;
yyn = -yyn;
goto yyreduce;
}
else if (yyn == 0)
goto yyerrlab;
if (yyn == YYFINAL)
YYACCEPT;
/* Shift the lookahead token. */
#if YYDEBUG != 0
if (yydebug)
fprintf(stderr, "Shifting token %d (%s), ", yychar, yytname[yychar1]);
#endif
/* Discard the token being shifted unless it is eof. */
if (yychar != YYEOF)
yychar = YYEMPTY;
*++yyvsp = yylval;
#ifdef YYLSP_NEEDED
*++yylsp = yylloc;
#endif
/* count tokens shifted since error; after three, turn off error status. */
if (yyerrstatus) yyerrstatus--;
yystate = yyn;
goto yynewstate;
/* Do the default action for the current state. */
yydefault:
yyn = yydefact[yystate];
if (yyn == 0)
goto yyerrlab;
/* Do a reduction. yyn is the number of a rule to reduce with. */
yyreduce:
yylen = yyr2[yyn];
if (yylen > 0)
yyval = yyvsp[1-yylen]; /* implement default value of the action */
#if YYDEBUG != 0
if (yydebug)
{
int i;
fprintf (stderr, "Reducing via rule %d (line %d), ",
yyn, yyrline[yyn]);
/* Print the symbols being reduced, and their result. */
for (i = yyprhs[yyn]; yyrhs[i] > 0; i++)
fprintf (stderr, "%s ", yytname[yyrhs[i]]);
fprintf (stderr, " -> %s\n", yytname[yyr1[yyn]]);
}
#endif
switch (yyn) {
case 1:
#line 62 "bi-parser.y"
{ defs = yyvsp[0].def; ;
break;}
case 3:
#line 68 "bi-parser.y"
{ yyvsp[0].def->next = yyvsp[-1].def; yyval.def = yyvsp[0].def; ;
break;}
case 4:
#line 73 "bi-parser.y"
{ yyval.def = makedef (yyvsp[-7].string, yyvsp[-5].string, yyvsp[-2].variation); ;
break;}
case 6:
#line 79 "bi-parser.y"
{ yyvsp[0].variation->next = yyvsp[-2].variation; yyval.variation = yyvsp[0].variation; ;
break;}
case 7:
#line 84 "bi-parser.y"
{ yyval.variation = makevar (yyvsp[-1].string, (struct node *) NULL, (struct node *) NULL, (struct node *) NULL); ;
break;}
case 8:
#line 86 "bi-parser.y"
{ yyval.variation = makevar (yyvsp[-3].string, yyvsp[-1].node, (struct node *) NULL, (struct node *) NULL); ;
break;}
case 9:
#line 88 "bi-parser.y"
{ yyval.variation = makevar (yyvsp[-5].string, yyvsp[-3].node, yyvsp[-1].node, (struct node *) NULL); ;
break;}
case 10:
#line 90 "bi-parser.y"
{ yyval.variation = makevar (yyvsp[-7].string, yyvsp[-5].node, yyvsp[-3].node, yyvsp[-1].node); ;
break;}
case 11:
#line 94 "bi-parser.y"
{ yyval.string = ""; ;
break;}
case 12:
#line 95 "bi-parser.y"
{ yyval.string = yyvsp[0].string; ;
break;}
case 13:
#line 100 "bi-parser.y"
{ yyval.node = yyvsp[-1].node; ;
break;}
case 14:
#line 102 "bi-parser.y"
{ yyval.node = NULL; ;
break;}
case 16:
#line 109 "bi-parser.y"
{ yyvsp[-2].node->next = yyvsp[0].node; yyval.node = yyvsp[-2].node; ;
break;}
case 17:
#line 114 "bi-parser.y"
{ yyval.node = makenode (yyvsp[0].string); ;
break;}
}
/* the action file gets copied in in place of this dollarsign */
#line 487 "/usr/local/share/bison.simple"
yyvsp -= yylen;
yyssp -= yylen;
#ifdef YYLSP_NEEDED
yylsp -= yylen;
#endif
#if YYDEBUG != 0
if (yydebug)
{
short *ssp1 = yyss - 1;
fprintf (stderr, "state stack now");
while (ssp1 != yyssp)
fprintf (stderr, " %d", *++ssp1);
fprintf (stderr, "\n");
}
#endif
*++yyvsp = yyval;
#ifdef YYLSP_NEEDED
yylsp++;
if (yylen == 0)
{
yylsp->first_line = yylloc.first_line;
yylsp->first_column = yylloc.first_column;
yylsp->last_line = (yylsp-1)->last_line;
yylsp->last_column = (yylsp-1)->last_column;
yylsp->text = 0;
}
else
{
yylsp->last_line = (yylsp+yylen-1)->last_line;
yylsp->last_column = (yylsp+yylen-1)->last_column;
}
#endif
/* Now "shift" the result of the reduction.
Determine what state that goes to,
based on the state we popped back to
and the rule number reduced by. */
yyn = yyr1[yyn];
yystate = yypgoto[yyn - YYNTBASE] + *yyssp;
if (yystate >= 0 && yystate <= YYLAST && yycheck[yystate] == *yyssp)
yystate = yytable[yystate];
else
yystate = yydefgoto[yyn - YYNTBASE];
goto yynewstate;
yyerrlab: /* here on detecting error */
if (! yyerrstatus)
/* If not already recovering from an error, report this error. */
{
++yynerrs;
#ifdef YYERROR_VERBOSE
yyn = yypact[yystate];
if (yyn > YYFLAG && yyn < YYLAST)
{
int size = 0;
char *msg;
int x, count;
count = 0;
/* Start X at -yyn if nec to avoid negative indexes in yycheck. */
for (x = (yyn < 0 ? -yyn : 0);
x < (sizeof(yytname) / sizeof(char *)); x++)
if (yycheck[x + yyn] == x)
size += strlen(yytname[x]) + 15, count++;
msg = (char *) malloc(size + 15);
if (msg != 0)
{
strcpy(msg, "parse error");
if (count < 5)
{
count = 0;
for (x = (yyn < 0 ? -yyn : 0);
x < (sizeof(yytname) / sizeof(char *)); x++)
if (yycheck[x + yyn] == x)
{
strcat(msg, count == 0 ? ", expecting `" : " or `");
strcat(msg, yytname[x]);
strcat(msg, "'");
count++;
}
}
yyerror(msg);
free(msg);
}
else
yyerror ("parse error; also virtual memory exceeded");
}
else
#endif /* YYERROR_VERBOSE */
yyerror("parse error");
}
goto yyerrlab1;
yyerrlab1: /* here on error raised explicitly by an action */
if (yyerrstatus == 3)
{
/* if just tried and failed to reuse lookahead token after an error, discard it. */
/* return failure if at end of input */
if (yychar == YYEOF)
YYABORT;
#if YYDEBUG != 0
if (yydebug)
fprintf(stderr, "Discarding token %d (%s).\n", yychar, yytname[yychar1]);
#endif
yychar = YYEMPTY;
}
/* Else will try to reuse lookahead token
after shifting the error token. */
yyerrstatus = 3; /* Each real token shifted decrements this */
goto yyerrhandle;
yyerrdefault: /* current state does not do anything special for the error token. */
#if 0
/* This is wrong; only states that explicitly want error tokens
should shift them. */
yyn = yydefact[yystate]; /* If its default is to accept any token, ok. Otherwise pop it.*/
if (yyn) goto yydefault;
#endif
yyerrpop: /* pop the current state because it cannot handle the error token */
if (yyssp == yyss) YYABORT;
yyvsp--;
yystate = *--yyssp;
#ifdef YYLSP_NEEDED
yylsp--;
#endif
#if YYDEBUG != 0
if (yydebug)
{
short *ssp1 = yyss - 1;
fprintf (stderr, "Error: state stack now");
while (ssp1 != yyssp)
fprintf (stderr, " %d", *++ssp1);
fprintf (stderr, "\n");
}
#endif
yyerrhandle:
yyn = yypact[yystate];
if (yyn == YYFLAG)
goto yyerrdefault;
yyn += YYTERROR;
if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != YYTERROR)
goto yyerrdefault;
yyn = yytable[yyn];
if (yyn < 0)
{
if (yyn == YYFLAG)
goto yyerrpop;
yyn = -yyn;
goto yyreduce;
}
else if (yyn == 0)
goto yyerrpop;
if (yyn == YYFINAL)
YYACCEPT;
#if YYDEBUG != 0
if (yydebug)
fprintf(stderr, "Shifting error token, ");
#endif
*++yyvsp = yylval;
#ifdef YYLSP_NEEDED
*++yylsp = yylloc;
#endif
yystate = yyn;
goto yynewstate;
}
#line 117 "bi-parser.y"
static struct node *
makenode (s)
char *s;
{
struct node *n;
n = (struct node *) malloc (sizeof (struct node));
n->text = s;
n->next = NULL;
return n;
}
static struct variation *
makevar (name, inputs, outputs, literals)
char *name;
struct node *inputs, *outputs, *literals;
{
struct variation *v;
v = (struct variation *) malloc (sizeof (struct variation));
v->name = name;
v->code = ndefs++;
v->inputs = inputs;
v->outputs = outputs;
v->literals = literals;
v->next = NULL;
return v;
}
static struct def *
makedef (name, template, vars)
char *name, *template;
struct variation *vars;
{
struct def *d;
d = (struct def *) malloc (sizeof (struct def));
d->basename = name;
d->template = template;
d->variations = vars;
d->next = NULL;
return d;
}
void
yyerror (s)
char *s;
{
fprintf (stderr, "syntax error in input\n");
exit (FATAL_EXIT_CODE);
}

12
gcc/bi-parser.h Normal file
View File

@@ -0,0 +1,12 @@
typedef union
{
char *string;
struct def *def;
struct variation *variation;
struct node *node;
} YYSTYPE;
#define DEFOP 258
#define STRING 259
extern YYSTYPE yylval;

169
gcc/bi-parser.y Normal file
View File

@@ -0,0 +1,169 @@
/* Bytecode definition file parser.
Copyright (C) 1993 Free Software Foundation, Inc.
This file is part of GNU CC.
GNU CC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU CC is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
%{
#include <stdio.h>
#include "hconfig.h"
#include "bi-defs.h"
extern char yytext[];
extern int yyleng;
/* Chain of all defs built by the parser. */
struct def *defs;
int ndefs;
static struct node *makenode ();
static struct variation *makevar ();
static struct def *makedef ();
void yyerror ();
%}
%union
{
char *string;
struct def *def;
struct variation *variation;
struct node *node;
}
%token <string> DEFOP STRING
%type <string> opt_string
%type <def> defs def
%type <variation> variations variation
%type <node> list items item
%%
top:
defs
{ defs = $1; }
;
defs:
def
| defs def
{ $2->next = $1; $$ = $2; }
;
def:
DEFOP '(' STRING ',' opt_string ',' '(' variations ')' ')'
{ $$ = makedef ($3, $5, $8); }
;
variations:
variation
| variations ',' variation
{ $3->next = $1; $$ = $3; }
;
variation:
'(' opt_string ')'
{ $$ = makevar ($2, (struct node *) NULL, (struct node *) NULL, (struct node *) NULL); }
| '(' opt_string ',' list ')'
{ $$ = makevar ($2, $4, (struct node *) NULL, (struct node *) NULL); }
| '(' opt_string ',' list ',' list ')'
{ $$ = makevar ($2, $4, $6, (struct node *) NULL); }
| '(' opt_string ',' list ',' list ',' list ')'
{ $$ = makevar ($2, $4, $6, $8); }
;
opt_string:
/* empty */ { $$ = ""; }
| STRING { $$ = $1; }
;
list:
'(' items ')'
{ $$ = $2; }
| /* empty */
{ $$ = NULL; }
;
items:
item
/* Note right recursion. */
| item ',' items
{ $1->next = $3; $$ = $1; }
;
item:
STRING
{ $$ = makenode ($1); }
;
%%
static struct node *
makenode (s)
char *s;
{
struct node *n;
n = (struct node *) malloc (sizeof (struct node));
n->text = s;
n->next = NULL;
return n;
}
static struct variation *
makevar (name, inputs, outputs, literals)
char *name;
struct node *inputs, *outputs, *literals;
{
struct variation *v;
v = (struct variation *) malloc (sizeof (struct variation));
v->name = name;
v->code = ndefs++;
v->inputs = inputs;
v->outputs = outputs;
v->literals = literals;
v->next = NULL;
return v;
}
static struct def *
makedef (name, template, vars)
char *name, *template;
struct variation *vars;
{
struct def *d;
d = (struct def *) malloc (sizeof (struct def));
d->basename = name;
d->template = template;
d->variations = vars;
d->next = NULL;
return d;
}
void
yyerror (s)
char *s;
{
fprintf (stderr, "syntax error in input\n");
exit (FATAL_EXIT_CODE);
}

61
gcc/bi-reverse.c Normal file
View File

@@ -0,0 +1,61 @@
/* Reverse order of definitions obtained from bytecode definition file.
Copyright (C) 1993 Free Software Foundation, Inc.
This file is part of GNU CC.
GNU CC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
GNU CC is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "hconfig.h"
#include "bi-defs.h"
void
reverse()
{
struct def *dp, *d, *dn;
struct variation *vp, *v, *vn;
dp = defs;
if (dp)
{
vp = dp->variations;
if (vp)
{
for (v = vp->next, vp->next = 0; v; vp = v, v = vn)
{
vn = v->next;
v->next = vp;
}
dp->variations = vp;
}
for (d = dp->next, dp->next = 0; d; dp = d, d = dn)
{
vp = d->variations;
if (vp)
{
for (v = vp->next, vp->next = 0; v; vp = v, v = vn)
{
vn = v->next;
v->next = vp;
}
d->variations = vp;
}
dn = d->next;
d->next = dp;
}
defs = dp;
}
}

Some files were not shown because too many files have changed in this diff Show More