Commit 67f28219 by Zack Weinberg

aclocal.m4 (gcc_AC_PROG_GNAT): New.

top:
	* aclocal.m4 (gcc_AC_PROG_GNAT): New.
	* configure.in: Use it.
	* configure: Regenerated.
	* config/pa/t-linux, config/pa/t-pa, config/pa/t-pa64,
	config/pa/t-pro: Set T_ADAFLAGS, not ADA_CFLAGS.
ada:
	* Make-lang.in (ADAFLAGS): Add -W -Wall.
	(ADA_FLAGS_TO_PASS): Set ADA_CFLAGS=$(CFLAGS) also.
	(gnat1): Also depend on attribs.o.
	(gnatlib, gnatlib-shared): Set CC and ADAC in recursive make.
	* Makefile.in (X_ADAFLAGS, T_ADAFLAGS): New.
	(ADAC): Set to @ADAC@ in stage1, $(CC) later.
	(ADAFLAGS): Add -W -Wall.
	(ALL_ADAFLAGS, MOST_ADAFLAGS): Add X_ADAFLAGS and T_ADAFLAGS;
	take out CFLAGS.

	(.adb.o, .ads.o, a-numaux.o, a-teioed.o, s-interr.o,
	s-taskin.o, sdefault.o, s-tasdeb.o, s-vaflop.o, a-except.o,
	s-assert.o, s-stalib.o, s-memory.o, memtrack.o, mlib-tgt.o):
	Use $(ADAC), not $(CC), as compilation command.

	(gnattools): Depend directly on tools to build, don't use
	recursive make.
	(gnatlib): Set ADA_CFLAGS=$(GNATLIBCFLAGS) in recursive make.

	* einfo.h, sinfo.h: New files (autogenerated).

From-SVN: r46085
parent c0bfe993
2001-10-08 Zack Weinberg <zack@codesourcery.com>
* aclocal.m4 (gcc_AC_PROG_GNAT): New.
* configure.in: Use it.
* configure: Regenerated.
* config/pa/t-linux, config/pa/t-pa, config/pa/t-pa64,
config/pa/t-pro: Set T_ADAFLAGS, not ADA_CFLAGS.
2001-10-08 Neil Booth <neil@daikokuya.demon.co.uk> 2001-10-08 Neil Booth <neil@daikokuya.demon.co.uk>
* cppfiles.c (open_file): Don't mark zero-length files * cppfiles.c (open_file): Don't mark zero-length files
......
...@@ -308,6 +308,57 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' ...@@ -308,6 +308,57 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
AC_SUBST(INSTALL_DATA)dnl AC_SUBST(INSTALL_DATA)dnl
]) ])
dnl Test for GNAT.
dnl We require the gnatbind program, and a compiler driver that
dnl understands Ada. The user may set the driver name explicitly
dnl with ADAC; also, the user's CC setting is tried. Failing that,
dnl we try gcc and cc, then a sampling of names known to be used for
dnl the Ada driver on various systems.
dnl
dnl Sets the shell variable have_gnat to yes or no as appropriate, and
dnl substitutes GNATBIND and ADAC.
AC_DEFUN([gcc_AC_PROG_GNAT],
[AC_REQUIRE([AC_CHECK_TOOL_PREFIX])
AC_CHECK_TOOL(GNATBIND, gnatbind, no)
AC_CACHE_CHECK([for compiler driver that understands Ada],
gcc_cv_prog_adac,
[cat >conftest.adb <<EOF
procedure conftest is begin null; end conftest;
EOF
gcc_cv_prog_adac=no
# Have to do ac_tool_prefix and user overrides by hand.
user_adac=$ADAC
user_cc=$CC
for cand in ${ac_tool_prefix}$user_adac $user_adac \
${ac_tool_prefix}$user_cc $user_cc \
${ac_tool_prefix}gcc gcc \
${ac_tool_prefix}cc cc \
${ac_tool_prefix}gnatgcc gnatgcc \
${ac_tool_prefix}gnatcc gnatcc \
${ac_tool_prefix}adagcc adagcc \
${ac_tool_prefix}adacc adacc ; do
# There is a bug in all released versions of GCC which causes the
# driver to exit successfully when the appropriate language module
# has not been installed. This is fixed in 2.95.4, 3.0.2, and 3.1.
# Therefore we must check for the error message as well as an
# unsuccessful exit.
errors=`$cand -c conftest.adb 2>&1 || echo failure`
if test x"$errors" = x; then
gcc_cv_prog_adac=$cand
break
fi
done
rm -f conftest.*])
ADAC=$gcc_cv_prog_adac
AC_SUBST(ADAC)
if test x$GNATBIND != xno && test x$ADAC != xno; then
have_gnat=yes
else
have_gnat=no
fi
])
#serial 1 #serial 1
dnl This test replaces the one in autoconf. dnl This test replaces the one in autoconf.
dnl Currently this macro should have the same name as the autoconf macro dnl Currently this macro should have the same name as the autoconf macro
......
2001-10-08 Zack Weinberg <zack@codesourcery.com>
* Make-lang.in (ADAFLAGS): Add -W -Wall.
(ADA_FLAGS_TO_PASS): Set ADA_CFLAGS=$(CFLAGS) also.
(gnat1): Also depend on attribs.o.
(gnatlib, gnatlib-shared): Set CC and ADAC in recursive make.
* Makefile.in (X_ADAFLAGS, T_ADAFLAGS): New.
(ADAC): Set to @ADAC@ in stage1, $(CC) later.
(ADAFLAGS): Add -W -Wall.
(ALL_ADAFLAGS, MOST_ADAFLAGS): Add X_ADAFLAGS and T_ADAFLAGS;
take out CFLAGS.
(.adb.o, .ads.o, a-numaux.o, a-teioed.o, s-interr.o,
s-taskin.o, sdefault.o, s-tasdeb.o, s-vaflop.o, a-except.o,
s-assert.o, s-stalib.o, s-memory.o, memtrack.o, mlib-tgt.o):
Use $(ADAC), not $(CC), as compilation command.
(gnattools): Depend directly on tools to build, don't use
recursive make.
(gnatlib): Set ADA_CFLAGS=$(GNATLIBCFLAGS) in recursive make.
* einfo.h, sinfo.h: New files (autogenerated).
2001-10-08 Richard Henderson <rth@redhat.com> 2001-10-08 Richard Henderson <rth@redhat.com>
* comperr.adb (Abort_In_Progress): New. * comperr.adb (Abort_In_Progress): New.
...@@ -6,20 +29,20 @@ ...@@ -6,20 +29,20 @@
2001-10-08 Robert Dewar <dewar@gnat.com> 2001-10-08 Robert Dewar <dewar@gnat.com>
* atree.adb: Set Error_Posted in Error node, helps error recovery. * atree.adb: Set Error_Posted in Error node, helps error recovery.
* par-endh.adb (Output_End_Expected): We should also not test * par-endh.adb (Output_End_Expected): We should also not test
Error_Posted on the Error node, since now it is always set. Error_Posted on the Error node, since now it is always set.
* cstand.adb (Create_Standard): Set Etype of Error to Any_Type * cstand.adb (Create_Standard): Set Etype of Error to Any_Type
to help error recovery. Part of general work on 9407-004. to help error recovery. Part of general work on 9407-004.
* par.adb: Add ??? for misuse of error * par.adb: Add ??? for misuse of error
* sem_res.adb: * sem_res.adb:
(Resolve): Defend against Error, fixes 9407-003. (Resolve): Defend against Error, fixes 9407-003.
(Resolve_Discrete_Subtype_Indication): Defend against Error. (Resolve_Discrete_Subtype_Indication): Defend against Error.
* sinfo.ads (N_Error): Now has Etype field (which will be set * sinfo.ads (N_Error): Now has Etype field (which will be set
to Any_Type to help error recovery). to Any_Type to help error recovery).
2001-10-08 Richard Kenner (kenner@gnat.com) 2001-10-08 Richard Kenner (kenner@gnat.com)
...@@ -50,70 +73,70 @@ ...@@ -50,70 +73,70 @@
* sysdep.c (__gnat_set_binary_mode, __gnat_set_text_mode): * sysdep.c (__gnat_set_binary_mode, __gnat_set_text_mode):
Arg is int, not FILE *, in dummy version of functions. Arg is int, not FILE *, in dummy version of functions.
* adaint.h (__gnat_set_binary_mode, __gnat_set_text_mode): * adaint.h (__gnat_set_binary_mode, __gnat_set_text_mode):
Arg is int, not FILE *. Arg is int, not FILE *.
2001-10-04 Geert Bosch <bosch@gnat.com> 2001-10-04 Geert Bosch <bosch@gnat.com>
* 3lsoccon.ads: Added file, missed with initial check ins. * 3lsoccon.ads: Added file, missed with initial check ins.
* 4lintnam.ads: Fix header format. * 4lintnam.ads: Fix header format.
Change Linux to GNU/Linux. Change Linux to GNU/Linux.
* 5iosinte.adb: Change Linux to GNU/Linux. * 5iosinte.adb: Change Linux to GNU/Linux.
* 5iosinte.ads: Change Linux to GNU/Linux. * 5iosinte.ads: Change Linux to GNU/Linux.
* 5itaprop.adb: Change Linux to GNU/Linux. * 5itaprop.adb: Change Linux to GNU/Linux.
* 5itaspri.ads: Change Linux to GNU/Linux. * 5itaspri.ads: Change Linux to GNU/Linux.
Update copyright notice. Update copyright notice.
* 5lintman.adb: Change Linux to GNU/Linux. * 5lintman.adb: Change Linux to GNU/Linux.
* 5lml-tgt.adb: Change Linux to GNU/Linux. * 5lml-tgt.adb: Change Linux to GNU/Linux.
* 5losinte.ads: Change Linux to GNU/Linux. * 5losinte.ads: Change Linux to GNU/Linux.
* 5lsystem.ads: Change Linux to GNU/Linux. * 5lsystem.ads: Change Linux to GNU/Linux.
* 5qosinte.adb: Change Linux to GNU/Linux. * 5qosinte.adb: Change Linux to GNU/Linux.
* 5qosinte.ads: Change Linux to GNU/Linux. * 5qosinte.ads: Change Linux to GNU/Linux.
* 5qparame.ads: Change Linux to GNU/Linux. * 5qparame.ads: Change Linux to GNU/Linux.
* 5qtaprop.adb: Change Linux to GNU/Linux. * 5qtaprop.adb: Change Linux to GNU/Linux.
* 5qtaspri.ads: Change Linux to GNU/Linux. * 5qtaspri.ads: Change Linux to GNU/Linux.
Add 2001 to copyright notice. Add 2001 to copyright notice.
* 5vintman.ads: Change Linux to GNU/Linux. * 5vintman.ads: Change Linux to GNU/Linux.
Fix header format. Add 2001 to copyright notice. Fix header format. Add 2001 to copyright notice.
* g-soccon.ads: Change Linux to GNU/Linux. * g-soccon.ads: Change Linux to GNU/Linux.
* g-trasym.ads: Change Linux to GNU/Linux. * g-trasym.ads: Change Linux to GNU/Linux.
Add 2001 to copyright notice. Add 2001 to copyright notice.
* memtrack.adb: Change Linux to GNU/Linux. * memtrack.adb: Change Linux to GNU/Linux.
* s-intman.ads: Change Linux to GNU/Linux. * s-intman.ads: Change Linux to GNU/Linux.
Add 2001 to copyright notice. Fix header format. Add 2001 to copyright notice. Fix header format.
* s-stache.adb: Change Linux to GNU/Linux. * s-stache.adb: Change Linux to GNU/Linux.
* adaint.c: Change Linux to GNU/Linux. * adaint.c: Change Linux to GNU/Linux.
* cio.c: Change Linux to GNU/Linux. * cio.c: Change Linux to GNU/Linux.
* cstreams.c: Change Linux to GNU/Linux. * cstreams.c: Change Linux to GNU/Linux.
* init.c: Change Linux to GNU/Linux. * init.c: Change Linux to GNU/Linux.
* gmem.c: Change Linux to GNU/Linux. * gmem.c: Change Linux to GNU/Linux.
* tracebak.c: Change Linux to GNU/Linux. * tracebak.c: Change Linux to GNU/Linux.
......
...@@ -46,7 +46,7 @@ shext = ...@@ -46,7 +46,7 @@ shext =
# Extra flags to pass to recursive makes. # Extra flags to pass to recursive makes.
BOOT_ADAFLAGS= $(ADAFLAGS) BOOT_ADAFLAGS= $(ADAFLAGS)
ADAFLAGS= -gnatpg -gnata ADAFLAGS= -W -Wall -gnatpg -gnata
GNATLIBFLAGS= -gnatpg GNATLIBFLAGS= -gnatpg
GNATLIBCFLAGS= -g -O2 GNATLIBCFLAGS= -g -O2
ADA_INCLUDE_DIR = $(libsubdir)/adainclude ADA_INCLUDE_DIR = $(libsubdir)/adainclude
...@@ -54,6 +54,7 @@ ADA_RTL_OBJ_DIR = $(libsubdir)/adalib ...@@ -54,6 +54,7 @@ ADA_RTL_OBJ_DIR = $(libsubdir)/adalib
THREAD_KIND=native THREAD_KIND=native
GNATBIND = gnatbind GNATBIND = gnatbind
ADA_FLAGS_TO_PASS = \ ADA_FLAGS_TO_PASS = \
"ADA_CFLAGS=$(CFLAGS)" \
"ADA_FOR_BUILD=$(ADA_FOR_BUILD)" \ "ADA_FOR_BUILD=$(ADA_FOR_BUILD)" \
"ADA_INCLUDE_DIR=$(ADA_INCLUDE_DIR)" \ "ADA_INCLUDE_DIR=$(ADA_INCLUDE_DIR)" \
"ADA_RTL_OBJ_DIR=$(ADA_RTL_OBJ_DIR)" \ "ADA_RTL_OBJ_DIR=$(ADA_RTL_OBJ_DIR)" \
...@@ -70,7 +71,7 @@ Ada ada: gnat1$(exeext) gnatbind$(exeext) ...@@ -70,7 +71,7 @@ Ada ada: gnat1$(exeext) gnatbind$(exeext)
# There are too many Ada sources to check against here. Let's # There are too many Ada sources to check against here. Let's
# always force the recursive make. # always force the recursive make.
gnat1$(exeext): prefix.o $(LIBDEPS) $(BACKEND) force gnat1$(exeext): prefix.o attribs.o $(LIBDEPS) $(BACKEND) force
$(MAKE) -C ada $(FLAGS_TO_PASS) $(ADA_FLAGS_TO_PASS) \ $(MAKE) -C ada $(FLAGS_TO_PASS) $(ADA_FLAGS_TO_PASS) \
../gnat1$(exeext) ../gnat1$(exeext)
...@@ -155,16 +156,20 @@ cross-gnattools: force ...@@ -155,16 +156,20 @@ cross-gnattools: force
gnatprep$(exeext) gnatpsta$(exeext) gnatpsys$(exeext) \ gnatprep$(exeext) gnatpsta$(exeext) gnatpsys$(exeext) \
gnatxref$(exeext) gnatfind$(exeext) $(EXTRA_GNATTOOLS) gnatxref$(exeext) gnatfind$(exeext) $(EXTRA_GNATTOOLS)
# use target-gcc
gnatlib: force gnatlib: force
$(MAKE) -C ada $(FLAGS_TO_PASS) \ $(MAKE) -C ada $(FLAGS_TO_PASS) \
CC="../xgcc -B../" ADAC="../xgcc -B../" STAGE_PREFIX=../ \
GNATLIBFLAGS="$(GNATLIBFLAGS)" \ GNATLIBFLAGS="$(GNATLIBFLAGS)" \
GNATLIBCFLAGS="$(GNATLIBCFLAGS)" \ GNATLIBCFLAGS="$(GNATLIBCFLAGS)" \
TARGET_LIBGCC2_CFLAGS="$(TARGET_LIBGCC2_CFLAGS)" \ TARGET_LIBGCC2_CFLAGS="$(TARGET_LIBGCC2_CFLAGS)" \
THREAD_KIND="$(THREAD_KIND)" \ THREAD_KIND="$(THREAD_KIND)" \
gnatlib gnatlib
# use target-gcc
gnatlib-shared: force gnatlib-shared: force
$(MAKE) -C ada $(FLAGS_TO_PASS) \ $(MAKE) -C ada $(FLAGS_TO_PASS) \
CC="../xgcc -B../" ADAC="../xgcc -B../" STAGE_PREFIX=../ \
GNATLIBFLAGS="$(GNATLIBFLAGS)" \ GNATLIBFLAGS="$(GNATLIBFLAGS)" \
GNATLIBCFLAGS="$(GNATLIBCFLAGS)" \ GNATLIBCFLAGS="$(GNATLIBCFLAGS)" \
GNATLIBLDFLAGS="$(GNATLIBLDFLAGS)" \ GNATLIBLDFLAGS="$(GNATLIBLDFLAGS)" \
......
...@@ -78,7 +78,18 @@ T_CFLAGS = ...@@ -78,7 +78,18 @@ T_CFLAGS =
X_CPPFLAGS = X_CPPFLAGS =
T_CPPFLAGS = T_CPPFLAGS =
X_ADAFLAGS =
T_ADAFLAGS =
CC = cc CC = cc
# Let the configure setting prevail only if CC hasn't been overridden
# to xgcc by the top level Makefile (in a later stage of bootstrap).
ifeq ($(findstring xgcc, $(CC)),)
ADAC = @ADAC@
else
ADAC = $(CC)
endif
BISON = bison BISON = bison
BISONFLAGS = BISONFLAGS =
ECHO = echo ECHO = echo
...@@ -103,13 +114,13 @@ MAKEINFO = makeinfo ...@@ -103,13 +114,13 @@ MAKEINFO = makeinfo
TEXI2DVI = texi2dvi TEXI2DVI = texi2dvi
GNATBIND = $(STAGE_PREFIX)gnatbind -C GNATBIND = $(STAGE_PREFIX)gnatbind -C
ADA_CFLAGS = ADA_CFLAGS =
ADAFLAGS = -gnatpg -gnata ADAFLAGS = -W -Wall -gnatpg -gnata
SOME_ADAFLAGS =-gnata SOME_ADAFLAGS =-gnata
FORCE_DEBUG_ADAFLAGS = -g FORCE_DEBUG_ADAFLAGS = -g
GNATLIBFLAGS = -gnatpg GNATLIBFLAGS = -gnatpg
GNATLIBCFLAGS= -g -O2 GNATLIBCFLAGS= -g -O2
ALL_ADAFLAGS = $(CFLAGS) $(ADA_CFLAGS) $(ADAFLAGS) ALL_ADAFLAGS = $(ADA_CFLAGS) $(X_ADAFLAGS) $(T_ADAFLAGS) $(ADAFLAGS)
MOST_ADAFLAGS = $(CFLAGS) $(ADA_CFLAGS) $(SOME_ADAFLAGS) MOST_ADAFLAGS = $(ADA_CFLAGS) $(X_ADAFLAGS) $(T_ADAFLAGS) $(SOME_ADAFLAGS)
THREAD_KIND=native THREAD_KIND=native
GMEM_LIB= GMEM_LIB=
MISCLIB = MISCLIB =
...@@ -268,9 +279,9 @@ ADA_INCLUDES_FOR_SUBDIR = -I. -I$(fsrcdir) ...@@ -268,9 +279,9 @@ ADA_INCLUDES_FOR_SUBDIR = -I. -I$(fsrcdir)
.c.o: .c.o:
$(CC) -c $(ALL_CFLAGS) $(ADA_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) $< $(CC) -c $(ALL_CFLAGS) $(ADA_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) $<
.adb.o: .adb.o:
$(CC) -c $(ALL_ADAFLAGS) $(ADA_INCLUDES) $< $(ADAC) -c $(ALL_ADAFLAGS) $(ADA_INCLUDES) $<
.ads.o: .ads.o:
$(CC) -c $(ALL_ADAFLAGS) $(ADA_INCLUDES) $< $(ADAC) -c $(ALL_ADAFLAGS) $(ADA_INCLUDES) $<
# This tells GNU make version 3 not to export all the variables # This tells GNU make version 3 not to export all the variables
# defined in this file into the environment. # defined in this file into the environment.
...@@ -836,11 +847,11 @@ ifeq ($(strip $(filter-out %86 interix,$(arch) $(osys))),) ...@@ -836,11 +847,11 @@ ifeq ($(strip $(filter-out %86 interix,$(arch) $(osys))),)
# Work around for gcc optimization bug wrt cxa5a09 # Work around for gcc optimization bug wrt cxa5a09
a-numaux.o : a-numaux.adb a-numaux.ads a-numaux.o : a-numaux.adb a-numaux.ads
$(CC) -c $(ALL_ADAFLAGS) -O2 $(ADA_INCLUDES) $< $(ADAC) -c $(ALL_ADAFLAGS) -O2 $(ADA_INCLUDES) $<
# Work around for gcc optimization bug wrt cxf3a01 # Work around for gcc optimization bug wrt cxf3a01
a-teioed.o : a-teioed.adb a-teioed.ads a-teioed.o : a-teioed.adb a-teioed.ads
$(CC) -c $(ALL_ADAFLAGS) -O0 $(ADA_INCLUDES) $< $(ADAC) -c $(ALL_ADAFLAGS) -O0 $(ADA_INCLUDES) $<
endif endif
...@@ -960,7 +971,7 @@ ifeq ($(strip $(filter-out m68k% wrs vx%,$(targ))),) ...@@ -960,7 +971,7 @@ ifeq ($(strip $(filter-out m68k% wrs vx%,$(targ))),)
# ??? work around a gcc -O2 bug on m68k # ??? work around a gcc -O2 bug on m68k
s-interr.o : s-interr.adb s-interr.ads s-interr.o : s-interr.adb s-interr.ads
$(CC) -c $(ALL_ADAFLAGS) -O1 $(ADA_INCLUDES) $< $(ADAC) -c $(ALL_ADAFLAGS) -O1 $(ADA_INCLUDES) $<
endif endif
ifeq ($(strip $(filter-out powerpc% wrs vx%,$(targ))),) ifeq ($(strip $(filter-out powerpc% wrs vx%,$(targ))),)
...@@ -1140,7 +1151,7 @@ ifeq ($(strip $(filter-out %86 solaris2%,$(arch) $(osys))),) ...@@ -1140,7 +1151,7 @@ ifeq ($(strip $(filter-out %86 solaris2%,$(arch) $(osys))),)
# ??? work around a gcc -O3 bug on x86 # ??? work around a gcc -O3 bug on x86
a-numaux.o : a-numaux.adb a-numaux.ads a-numaux.o : a-numaux.adb a-numaux.ads
$(CC) -c $(ALL_ADAFLAGS) -O2 $(ADA_INCLUDES) $< $(ADAC) -c $(ALL_ADAFLAGS) -O2 $(ADA_INCLUDES) $<
endif endif
ifeq ($(strip $(filter-out %86 linux%,$(arch) $(osys))),) ifeq ($(strip $(filter-out %86 linux%,$(arch) $(osys))),)
...@@ -1265,7 +1276,7 @@ a-tcbinf.o: s-tpgetc.ali ...@@ -1265,7 +1276,7 @@ a-tcbinf.o: s-tpgetc.ali
# force debug info so that workshop can find the All_Tasks_List symbol # force debug info so that workshop can find the All_Tasks_List symbol
s-taskin.o: s-taskin.adb s-taskin.ads s-taskin.o: s-taskin.adb s-taskin.ads
$(CC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) $(ADA_INCLUDES) $< $(ADAC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) $(ADA_INCLUDES) $<
endif endif
ifeq ($(strip $(filter-out hppa% hp hpux%,$(targ))),) ifeq ($(strip $(filter-out hppa% hp hpux%,$(targ))),)
...@@ -1484,7 +1495,7 @@ ifeq ($(strip $(filter-out cygwin32% mingw32% pe,$(osys))),) ...@@ -1484,7 +1495,7 @@ ifeq ($(strip $(filter-out cygwin32% mingw32% pe,$(osys))),)
# ??? work around a gcc -O3 bug on x86 # ??? work around a gcc -O3 bug on x86
a-numaux.o : a-numaux.adb a-numaux.ads a-numaux.o : a-numaux.adb a-numaux.ads
$(CC) -c $(ALL_ADAFLAGS) -O2 $(ADA_INCLUDES) $< $(ADAC) -c $(ALL_ADAFLAGS) -O2 $(ADA_INCLUDES) $<
endif endif
# The runtime library for gnat comprises two directories. One contains the # The runtime library for gnat comprises two directories. One contains the
...@@ -2076,12 +2087,7 @@ gnatbl.o: gnatbl.c adaint.h ...@@ -2076,12 +2087,7 @@ gnatbl.o: gnatbl.c adaint.h
true; \ true; \
fi fi
gnattools: force gnattools: ../gnatbl$(exeext) ../gnatchop$(exeext) ../gnatcmd$(exeext) \
$(MAKE) \
"CC=$(CC)" "ALL_CFLAGS=$(ALL_CFLAGS)" "INCLUDE=$(INCLUDES)" \
"LDFLAGS=$(LDFLAGS)" \
"MISCLIB=$(MISCLIB)" "exeext=$(exeext)" \
../gnatbl$(exeext) ../gnatchop$(exeext) ../gnatcmd$(exeext) \
../gnatkr$(exeext) ../gnatlink$(exeext) \ ../gnatkr$(exeext) ../gnatlink$(exeext) \
../gnatls$(exeext) ../gnatmake$(exeext) ../gnatmem$(exeext) \ ../gnatls$(exeext) ../gnatmake$(exeext) ../gnatmem$(exeext) \
../gnatprep$(exeext) ../gnatpsta$(exeext) ../gnatpsys$(exeext) \ ../gnatprep$(exeext) ../gnatpsta$(exeext) ../gnatpsys$(exeext) \
...@@ -2175,11 +2181,12 @@ gnatlib: ../stamp-gnatlib1 ../stamp-gnatlib2 ...@@ -2175,11 +2181,12 @@ gnatlib: ../stamp-gnatlib1 ../stamp-gnatlib2
$(MAKE) -C rts CC="../../xgcc -B../../" \ $(MAKE) -C rts CC="../../xgcc -B../../" \
INCLUDES="$(INCLUDES_FOR_SUBDIR) -I./../.." \ INCLUDES="$(INCLUDES_FOR_SUBDIR) -I./../.." \
CFLAGS="$(GNATLIBCFLAGS) $(TARGET_LIBGCC2_CFLAGS) -DIN_RTS" \ CFLAGS="$(GNATLIBCFLAGS) $(TARGET_LIBGCC2_CFLAGS) -DIN_RTS" \
ADA_CFLAGS="$(GNATLIBCFLAGS)" \
srcdir=$(fsrcdir) \ srcdir=$(fsrcdir) \
-f ../Makefile $(LIBGNAT_OBJS) -f ../Makefile $(LIBGNAT_OBJS)
$(MAKE) -C rts CC="../../xgcc -B../../" \ $(MAKE) -C rts CC="../../xgcc -B../../" \
ADA_INCLUDES="$(ADA_INCLUDES_FOR_SUBDIR)" \ ADA_INCLUDES="$(ADA_INCLUDES_FOR_SUBDIR)" \
CFLAGS="$(GNATLIBCFLAGS)" \ CFLAGS="$(GNATLIBCFLAGS)" ADA_CFLAGS="$(GNATLIBCFLAGS)" \
ADAFLAGS="$(GNATLIBFLAGS)" \ ADAFLAGS="$(GNATLIBFLAGS)" \
srcdir=$(fsrcdir) \ srcdir=$(fsrcdir) \
-f ../Makefile \ -f ../Makefile \
...@@ -2464,40 +2471,43 @@ ADA_TREE_H = ada-tree.h ada-tree.def ...@@ -2464,40 +2471,43 @@ ADA_TREE_H = ada-tree.h ada-tree.def
sdefault.o : sdefault.ads sdefault.adb types.ads unchdeal.ads \ sdefault.o : sdefault.ads sdefault.adb types.ads unchdeal.ads \
system.ads s-exctab.ads s-stalib.ads unchconv.ads system.ads s-exctab.ads s-stalib.ads unchconv.ads
$(CC) -c -O2 $(MOST_ADAFLAGS) $(ADA_INCLUDES) sdefault.adb $(ADAC) -c -O2 $(MOST_ADAFLAGS) $(ADA_INCLUDES) sdefault.adb
# force debugging information on s-tasdeb.o so that it is always # force debugging information on s-tasdeb.o so that it is always
# possible to set conditional breakpoints on tasks. # possible to set conditional breakpoints on tasks.
s-tasdeb.o : s-tasdeb.adb s-tasdeb.ads s-tasdeb.o : s-tasdeb.adb s-tasdeb.ads
$(CC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) $(ADA_INCLUDES) $< $(ADAC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) $(ADA_INCLUDES) $<
# force debugging information on s-vaflop.o so that it is always # force debugging information on s-vaflop.o so that it is always
# possible to call the VAX float debug print routines. # possible to call the VAX float debug print routines.
# force at least -O so that the inline assembly works. # force at least -O so that the inline assembly works.
s-vaflop.o : s-vaflop.adb s-vaflop.ads s-vaflop.o : s-vaflop.adb s-vaflop.ads
$(CC) -c -O $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) $(ADA_INCLUDES) $< $(ADAC) -c -O $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) \
$(ADA_INCLUDES) $<
# force debugging information on a-except.o so that it is always # force debugging information on a-except.o so that it is always
# possible to set conditional breakpoints on exceptions. # possible to set conditional breakpoints on exceptions.
# use -O1 otherwise gdb isn't able to get a full backtrace on mips targets. # use -O1 otherwise gdb isn't able to get a full backtrace on mips targets.
a-except.o : a-except.adb a-except.ads a-except.o : a-except.adb a-except.ads
$(CC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) -O1 -fno-inline \ $(ADAC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) -O1 -fno-inline \
$(ADA_INCLUDES) $< $(ADA_INCLUDES) $<
# force debugging information on s-assert.o so that it is always # force debugging information on s-assert.o so that it is always
# possible to set breakpoint on assert failures. # possible to set breakpoint on assert failures.
s-assert.o : s-assert.adb s-assert.ads a-except.ads s-assert.o : s-assert.adb s-assert.ads a-except.ads
$(CC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) -O2 $(ADA_INCLUDES) $< $(ADAC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) -O2 \
$(ADA_INCLUDES) $<
# force debugging information on s-stalib.o so that it is always # force debugging information on s-stalib.o so that it is always
# possible to set breakpoints on exceptions. # possible to set breakpoints on exceptions.
s-stalib.o : s-stalib.adb s-stalib.ads s-stalib.o : s-stalib.adb s-stalib.ads
$(CC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) -O2 $(ADA_INCLUDES) $< $(ADAC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) -O2 \
$(ADA_INCLUDES) $<
# force debugging information and no optimization on s-memory.o so that it # force debugging information and no optimization on s-memory.o so that it
# is always possible to set breakpoint on __gnat_malloc and __gnat_free # is always possible to set breakpoint on __gnat_malloc and __gnat_free
...@@ -2505,10 +2515,12 @@ s-stalib.o : s-stalib.adb s-stalib.ads ...@@ -2505,10 +2515,12 @@ s-stalib.o : s-stalib.adb s-stalib.ads
# memtrack.adb, and used by the post-mortem analysis with gnatmem. # memtrack.adb, and used by the post-mortem analysis with gnatmem.
s-memory.o : s-memory.adb s-memory.ads memtrack.o s-memory.o : s-memory.adb s-memory.ads memtrack.o
$(CC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) -O0 $(ADA_INCLUDES) $< $(ADAC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) -O0 \
$(ADA_INCLUDES) $<
memtrack.o : memtrack.adb s-memory.ads memtrack.o : memtrack.adb s-memory.ads
$(CC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) -O0 $(ADA_INCLUDES) $< $(ADAC) -c $(ALL_ADAFLAGS) $(FORCE_DEBUG_ADAFLAGS) -O0 \
$(ADA_INCLUDES) $<
# Need to keep the frame pointer in this file to pop the stack properly on # Need to keep the frame pointer in this file to pop the stack properly on
# some targets. # some targets.
...@@ -2599,7 +2611,7 @@ stamp-tool_src_dir: ...@@ -2599,7 +2611,7 @@ stamp-tool_src_dir:
touch stamp-tool_src_dir touch stamp-tool_src_dir
mlib-tgt.o : stamp-tool_src_dir mlib-tgt.o : stamp-tool_src_dir
$(CC) -c -Itools $(ALL_ADAFLAGS) $(ADA_INCLUDES) tools/mlib-tgt.adb $(ADAC) -c -Itools $(ALL_ADAFLAGS) $(ADA_INCLUDES) tools/mlib-tgt.adb
# GNAT DEPENDENCIES # GNAT DEPENDENCIES
# regular dependencies # regular dependencies
......
This diff is collapsed. Click to expand it.
This diff is collapsed. Click to expand it.
...@@ -15,4 +15,4 @@ CRTSTUFF_T_CFLAGS_S = -fPIC ...@@ -15,4 +15,4 @@ CRTSTUFF_T_CFLAGS_S = -fPIC
# Compile libgcc2.a as PIC. # Compile libgcc2.a as PIC.
TARGET_LIBGCC2_CFLAGS = -fPIC -DELF=1 -DLINUX=1 TARGET_LIBGCC2_CFLAGS = -fPIC -DELF=1 -DLINUX=1
ADA_CFLAGS=-mdisable-indexing T_ADAFLAGS=-mdisable-indexing
ADA_CFLAGS=-mdisable-indexing T_ADAFLAGS=-mdisable-indexing
LIB2FUNCS_EXTRA=lib2funcs.asm quadlib.c LIB2FUNCS_EXTRA=lib2funcs.asm quadlib.c
lib2funcs.asm: $(srcdir)/config/pa/lib2funcs.asm lib2funcs.asm: $(srcdir)/config/pa/lib2funcs.asm
......
...@@ -2,7 +2,7 @@ LIB1ASMFUNCS = _divI _divU _remI _remU _div_const ...@@ -2,7 +2,7 @@ LIB1ASMFUNCS = _divI _divU _remI _remU _div_const
LIB1ASMSRC = pa/milli64.S LIB1ASMSRC = pa/milli64.S
TARGET_LIBGCC2_CFLAGS = -fPIC -Dpa64=1 -DELF=1 TARGET_LIBGCC2_CFLAGS = -fPIC -Dpa64=1 -DELF=1
ADA_CFLAGS=-mdisable-indexing T_ADAFLAGS=-mdisable-indexing
LIB2FUNCS_EXTRA=quadlib.c LIB2FUNCS_EXTRA=quadlib.c
# We'll need this once .init sections are enabled on PA64. # We'll need this once .init sections are enabled on PA64.
......
ADA_CFLAGS=-mdisable-indexing T_ADAFLAGS=-mdisable-indexing
LIB2FUNCS_EXTRA=lib2funcs.asm LIB2FUNCS_EXTRA=lib2funcs.asm
......
...@@ -469,7 +469,7 @@ gcc_AC_C_COMPILE_ENDIAN ...@@ -469,7 +469,7 @@ gcc_AC_C_COMPILE_ENDIAN
gcc_AC_C_FLOAT_FORMAT gcc_AC_C_FLOAT_FORMAT
# See if GNAT has been installed # See if GNAT has been installed
AC_CHECK_PROG(have_gnat, gnatbind, yes, no) gcc_AC_PROG_GNAT
# See if we have the mktemp command. # See if we have the mktemp command.
AC_CHECK_PROG(have_mktemp_command, mktemp, yes, no) AC_CHECK_PROG(have_mktemp_command, mktemp, yes, no)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment