Add new port lang/gcc6-aux

This will be the successor to lang/gcc5-aux.  GCC6 is still in development
although the Ada front end is generally stable.  Once gcc6-aux is released,
the lang/gcc-aux port will likely be removed.  For that to happen, the
gnatdroid compilers need to move from it to gcc5-aux or gcc6-aux.  The
Ada framework will also move to gcc6-aux by default as well.
This commit is contained in:
John Marino 2015-12-06 16:04:22 +00:00
parent eba05ee162
commit 320c206ea9
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=403127
13 changed files with 2419 additions and 0 deletions

View file

@ -101,6 +101,7 @@
SUBDIR += gcc5 SUBDIR += gcc5
SUBDIR += gcc5-aux SUBDIR += gcc5-aux
SUBDIR += gcc5-devel SUBDIR += gcc5-devel
SUBDIR += gcc6-aux
SUBDIR += gcc6-devel SUBDIR += gcc6-devel
SUBDIR += gcl SUBDIR += gcl
SUBDIR += gforth SUBDIR += gforth

284
lang/gcc6-aux/Makefile Normal file
View file

@ -0,0 +1,284 @@
# Created by: John Marino <marino@FreeBSD.org>
# $FreeBSD$
PORTNAME= gcc6-aux
PORTVERSION= ${SNAPSHOT}
PORTREVISION= ${MAIN_PR}
CATEGORIES= lang
MASTER_SITES= http://downloads.dragonlace.net/src/:boot \
LOCAL/marino:boot GCC/${MS_SUBDIR}
DISTFILES= ${IDENTIFICATION}.tar.bz2
MAINTAINER= marino@FreeBSD.org
COMMENT= Version of GCC ${GCC_BRANCH} with full Ada support
LICENSE= GPLv3 GPLv3RLE
LICENSE_COMB= multi
.include "${.CURDIR}/Makefile.common"
LANGS= c c++ ada
APPLY_DIFFS= core cxx ada
INTENDED_COMPILER= NATIVE
GARCH= ${ARCH:S/amd64/x86_64/}
BOOTSTRAP_COMPILER= gnat-bootstrap.${GARCH}.${OPSYS:tl}.tar.bz2
BLD_TARGET= ${GARCH}-aux-${OPSYS:tl}${OSREL}
FULL_GNATGCC= NOT_SET
OS_LABEL4VERS= [${OPSYS}${GARCH:M*64:S/amd_//:S/x86_//}]
NO_MTREE= yes
CPPFLAGS+= -I${LOCALBASE}/include
LDFLAGS+= -L${LOCALBASE}/lib
OPTIONS_GROUP= Standard Bootstrap
OPTIONS_GROUP_Standard= FORT OBJC NLS TESTSUITE ALLSTAGES STATIC
OPTIONS_GROUP_Bootstrap=BOOTSTRAP
OPTIONS_DEFAULT= FORT OBJC
NO_OPTIONS_SORT= yes
FORT_DESC= Fortran language support
OBJC_DESC= Objective-C language support
TESTSUITE_DESC= Activate test support
ALLSTAGES_DESC= Build compiler with itself (twice, brings in libcc1)
STATIC_DESC= Link compilers and drivers statically
BOOTSTRAP_DESC= Create bootstrap compiler (overrides other options)
# The BOOTSTRAP option overrides all the others. "make stage" will build a
# static compiler that supports C, C++, and Ada languages and then create
# a new distfile in $WRKDIR/newbsd with the name following the pattern:
# ada-bootstrap.$ARCH.$OPSYS.XY.tar.bz2. There is no need to "make install"
.include <bsd.port.options.mk>
.if ${OPSYS} == FreeBSD
ONLY_FOR_ARCHS= amd64 i386
MODERN_BINUTILS= yes
BOOTSTRAP_COMPILER= ada-bootstrap.${GARCH}.freebsd.100B.tar.bz2
.endif
.if ${OPSYS} == DragonFly
ONLY_FOR_ARCHS= x86_64
BOOTSTRAP_COMPILER= ada-bootstrap.${GARCH}.dragonfly.41.tar.bz2
.endif
.if defined(MODERN_BINUTILS)
# Apparently gcc 4.9 needs binutils 2.23 or greater to link Ada correctly
USE_BINUTILS= yes
RUN_DEPENDS+= ${LOCALBASE}/bin/as:${PORTSDIR}/devel/binutils
EXTRA_CONFIG+= --with-ld=${LOCALBASE}/bin/ld
EXTRA_CONFIG+= --with-as=${LOCALBASE}/bin/as
.else
EXTRA_CONFIG+= --with-ld=/usr/bin/ld
EXTRA_CONFIG+= --with-as=/usr/bin/as
.endif
WRKSRC= ${WRKDIR}/${IDENTIFICATION}
BUILDDIR= ${WRKDIR}/build
NEWBSDIR= ${WRKDIR}/newbs/bootstrap
CFG_SCRIPT= ${WRKSRC}/configure
REVFILE= ${WRKSRC}/gcc/REVISION
PHASEFILE= ${WRKSRC}/gcc/DEV-PHASE
BOOTSTRAP_PREFIX= ${WRKDIR}/bootstrap
PKG_PREFIX= ${PREFIX}/${PORTNAME}
MANPREFIX= ${PREFIX}/${PORTNAME}/share
BSFILENAME= ada-bootstrap.${GARCH}.${OPSYS:tl}.${OSREL:S/.//}.tar.bz2
# If we find gnatmake and friends in a standard location, then we'll use this
# compiler instead of downloading the bootstrap.
.if exists (${LOCALBASE}/${PORTNAME}/bin/ada)
.if exists (${LOCALBASE}/${PORTNAME}/bin/gnatbind)
.if exists (${LOCALBASE}/${PORTNAME}/bin/gnatlink)
.if exists (${LOCALBASE}/${PORTNAME}/bin/gnatmake)
FULL_GNATGCC=${LOCALBASE}/${PORTNAME}/bin/ada
FULL_GNATGXX=${LOCALBASE}/${PORTNAME}/bin/g++
FULL_PATH=/sbin:/bin:/usr/sbin:/usr/bin:${PREFIX}/${PORTNAME}/bin:${PREFIX}/bin
.endif
.endif
.endif
.endif
# If FULL_GNATGCC is not set, we'll request the bootstrap compiler
.if ${FULL_GNATGCC} == NOT_SET
INTENDED_COMPILER=BOOTSTRAP
FULL_GNATGCC=${BOOTSTRAP_PREFIX}/bin/gcc
FULL_GNATGXX=${BOOTSTRAP_PREFIX}/bin/g++
FULL_PATH=${BOOTSTRAP_PREFIX}/bin:/sbin:/bin:/usr/sbin:/usr/bin:${PREFIX}/bin
DISTFILES+= ${BOOTSTRAP_COMPILER}:boot
.endif
# for port maintenance, invoke "make makesum PLUS_BOOTSTRAPS=1"
.if defined(PLUS_BOOTSTRAPS)
DISTFILES= \
${IDENTIFICATION}.tar.bz2 \
ada-bootstrap.i386.freebsd.100B.tar.bz2:boot \
ada-bootstrap.x86_64.dragonfly.41.tar.bz2:boot \
ada-bootstrap.x86_64.freebsd.100B.tar.bz2:boot
.endif
.if ${PORT_OPTIONS:MFORT} && !${PORT_OPTIONS:MBOOTSTRAP}
LANGS+= fortran
EXTRA_CONFIG+= --enable-libquadmath
.else
EXTRA_CONFIG+= --disable-libquadmath
.endif
.if ${PORT_OPTIONS:MOBJC} && !${PORT_OPTIONS:MBOOTSTRAP}
LANGS+= objc
.endif
.if ${PORT_OPTIONS:MTESTSUITE} && !${PORT_OPTIONS:MBOOTSTRAP}
BUILD_DEPENDS+= dejagnu>=1.4:${PORTSDIR}/misc/dejagnu
APPLY_DIFFS+= ada-testsuite
APPLY_DIFFS+= gcc-testsuite
.endif
.if ${PORT_OPTIONS:MNLS} && !${PORT_OPTIONS:MBOOTSTRAP}
USES+= gettext
EXTRA_CONFIG+= --enable-nls
.else
EXTRA_CONFIG+= --disable-nls
.endif
.if ${PORT_OPTIONS:MSTATIC} && !${PORT_OPTIONS:MBOOTSTRAP}
EXTRA_CONFIG+= --with-stage1-ldflags=-static
.endif
.if ${PORT_OPTIONS:MBOOTSTRAP}
EXTRA_CONFIG+= --disable-shared --disable-lto
EXTRA_CONFIG+= --with-boot-ldflags=-static
.else
. if !${PORT_OPTIONS:MALLSTAGES}
# For reasons unknown, build fails at libcc1 when the compiler is not
# not bootstrapping. It appears to be an upstream error. LibCC1 is used
# for gdb 7.9 exclusively, so it's not really needed. Let's disable it
# by default, but let people that want it suffer a 3-stage build.
EXTRA_CONFIG+= --disable-bootstrap --disable-libcc1
. endif
USES+= iconv
.endif
# Establish Ada-aware compiler for use
ADA_CONFIGURE_ENV+= CC=${FULL_GNATGCC}
ADA_CONFIGURE_ENV+= CXX=${FULL_GNATGXX}
ADA_CONFIGURE_ENV+= CFLAGS="${CFLAGS}"
ADA_CONFIGURE_ENV+= CPPFLAGS="${CPPFLAGS}"
ADA_CONFIGURE_ENV+= CXXFLAGS="${CXXFLAGS}"
ADA_CONFIGURE_ENV+= LDFLAGS="${LDFLAGS}"
ADA_CONFIGURE_ENV+= build_configargs="CPPFLAGS=\"${CPPFLAGS}\""
ADA_CONFIGURE_ENV+= host_configargs="CPPFLAGS=\"${CPPFLAGS}\""
ADA_CONFIGURE_ENV+= PATH=${FULL_PATH}
ADA_MAKE_ENV+= PATH=${FULL_PATH}
# The standard configuration options
ADA_CONFIG_ARGS= --enable-languages=${LANGS:Q}
ADA_CONFIG_ARGS+= --build=${BLD_TARGET}
ADA_CONFIG_ARGS+= --prefix=${PKG_PREFIX:Q}
ADA_CONFIG_ARGS+= --with-system-zlib
ADA_CONFIG_ARGS+= --with-gmp=${PREFIX}
ADA_CONFIG_ARGS+= --with-mpfr=${PREFIX}
ADA_CONFIG_ARGS+= --with-mpc=${PREFIX}
ADA_CONFIG_ARGS+= ${ICONV_CONFIGURE_ARG}
ADA_CONFIG_ARGS+= --enable-shared
ADA_CONFIG_ARGS+= --enable-threads=posix
ADA_CONFIG_ARGS+= --enable-checking=release
ADA_CONFIG_ARGS+= --disable-libmudflap
ADA_CONFIG_ARGS+= --disable-libgomp
ADA_CONFIG_ARGS+= --disable-libssp
ADA_CONFIG_ARGS+= ${EXTRA_CONFIG}
post-extract:
# Personalize GNAT for each different machine
@${ECHO} "-=> GNAT AUX ${OS_LABEL4VERS}" > ${REVFILE}
@${ECHO} ${PHASE} > ${PHASEFILE}
# Apply required composite diff files
.for suffix in ${APPLY_DIFFS}
@${ECHO} "Applying composite patch diff-${suffix}"
@${PATCH} -d ${WRKSRC} -s -E < ${FILESDIR}/diff-${suffix}
.endfor
.if ${PORT_OPTIONS:MSTATIC} || ${PORT_OPTIONS:MBOOTSTRAP}
# Ensure GNAT tools are built statically
${REINPLACE_CMD} -e 's/^GCC_LINK_FLAGS=.*/GCC_LINK_FLAGS=-static/' \
${WRKSRC}/gcc/ada/gcc-interface/Makefile.in
.endif
# Update LINK_SPEC to add gcc-aux lib runpath in every binary
@${ECHO} "Configuring LINK_SPEC runpath"
@${REINPLACE_CMD} -e 's;\@PREFIX\@;${PREFIX};' \
-e 's;\@GCCAUX\@;${PORTNAME};' \
${WRKSRC}/gcc/config/dragonfly.h \
${WRKSRC}/gcc/config/i386/freebsd64.h \
${WRKSRC}/gcc/config/i386/freebsd.h
.if defined(MODERN_BINUTILS)
# Use dwarf4-compatible addr2line (affects FreeBSD only)
${REINPLACE_CMD} -e 's|/usr/bin/addr2line|${PREFIX}/bin/addr2line|g' \
${WRKSRC}/gcc/ada/traceback_symbolic.c
.endif
do-configure:
${MKDIR} ${BUILDDIR}
cd ${BUILDDIR} && ${SETENV} ${ADA_CONFIGURE_ENV} \
${CFG_SCRIPT} ${ADA_CONFIG_ARGS}
do-build:
cd ${BUILDDIR} && ${SETENV} ${ADA_MAKE_ENV} \
${MAKE_CMD} -j${MAKE_JOBS_NUMBER} ${MAKE_ARGS} all
.if ${PORT_OPTIONS:MTESTSUITE} && !${PORT_OPTIONS:MBOOTSTRAP}
test: build test-ada test-fortran test-objc test-cxx test-c
test-ada:
cd ${BUILDDIR} && ${SETENV} ${ADA_MAKE_ENV} \
${MAKE_CMD} -sk check-ada
test-cxx:
# libstdc++ testsuite will break every time, for TRUE to continue
cd ${BUILDDIR} && ${SETENV} ${ADA_MAKE_ENV} \
${MAKE_CMD} -j${MAKE_JOBS_NUMBER} -sk check-c++ || true
test-c:
cd ${BUILDDIR} && ${SETENV} ${ADA_MAKE_ENV} \
${MAKE_CMD} -j${MAKE_JOBS_NUMBER} -sk check-c
test-fortran:
. if ${PORT_OPTIONS:MFORT}
cd ${BUILDDIR} && ${SETENV} ${ADA_MAKE_ENV} \
${MAKE_CMD} -j${MAKE_JOBS_NUMBER} -sk check-fortran
. endif
test-objc:
. if ${PORT_OPTIONS:MOBJC}
cd ${BUILDDIR} && ${SETENV} ${ADA_MAKE_ENV} \
${MAKE_CMD} -j${MAKE_JOBS_NUMBER} -sk check-objc
. endif
.endif
do-install:
cd ${BUILDDIR} && ${SETENV} ${ADA_MAKE_ENV} \
${MAKE_CMD} install-strip ${MAKE_ARGS}
${MV} ${STAGEDIR}${PKG_PREFIX}/share ${WRKDIR}/moved_share
# Don't activate until this port builds gnatdroid
# Otherwise it will conflict with lang/gcc-aux
# Add "share" after {PORTNAME} on 3rd line of post-stage target
# ${MKDIR} ${STAGEDIR}${PREFIX}/share/dejagnu/baseboards \
# ${STAGEDIR}${PREFIX}/share/dejagnu/config
# ${INSTALL_DATA} ${FILESDIR}/android.exp \
# ${STAGEDIR}${PREFIX}/share/dejagnu/config
# ${INSTALL_DATA} ${FILESDIR}/gnatdroid.exp \
# ${STAGEDIR}${PREFIX}/share/dejagnu/baseboards
post-stage:
(cd ${STAGEDIR}${PKG_PREFIX}; ${FIND} * -type d -empty | \
${SORT} -dr | ${XARGS} ${RMDIR})
(cd ${STAGEDIR}${PREFIX}; ${FIND} ${PORTNAME} \
\( -type f -or -type l \) | ${SORT} | ${SED} \
-e 's/\/man\/man[1578]\/.*[1578]$$/&.gz/' >> ${TMPPLIST})
.if ${PORT_OPTIONS:MBOOTSTRAP}
${MKDIR} ${NEWBSDIR}
${CP} -a ${STAGEDIR}${PKG_PREFIX}/bin ${NEWBSDIR}/
${CP} -a ${STAGEDIR}${PKG_PREFIX}/lib ${NEWBSDIR}/
${CP} -a ${STAGEDIR}${PKG_PREFIX}/include ${NEWBSDIR}/
${CP} -a ${STAGEDIR}${PKG_PREFIX}/libexec ${NEWBSDIR}/
${RM} ${NEWBSDIR}/bin/${GARCH}*
${RM} -rf ${NEWBSDIR}/lib/gcc/${BLD_TARGET}/${GCC_VERSION}/include-fixed
(cd ${NEWBSDIR}/.. ; ${TAR} -cyf ${BSFILENAME} bootstrap)
.endif
.include <bsd.port.mk>

View file

@ -0,0 +1,14 @@
# $FreeBSD$
.include "Makefile.version"
LIB_DEPENDS= libgmp.so:${PORTSDIR}/math/gmp
LIB_DEPENDS+= libmpfr.so:${PORTSDIR}/math/mpfr
LIB_DEPENDS+= libmpc.so:${PORTSDIR}/math/mpc
ONLY_FOR_ARCHS= i386 amd64
GNU_CONFIGURE= yes
USES= gmake libtool perl5 tar:bzip2
USE_PERL5= build
ALL_TARGET= default

View file

@ -0,0 +1,22 @@
# $FreeBSD$
GCC_BRANCH= 6
GCC_POINT= 0.0
GCC_VERSION= ${GCC_BRANCH}.${GCC_POINT}
SNAPSHOT= 20151129
BUILD_RELEASE= no
MAIN_PR= 0
UTIL_PR= 0
ARMV7_PR= 0
.if ${BUILD_RELEASE:Mno}
# Snapshot naming pattern
IDENTIFICATION= gcc-${GCC_BRANCH}-${SNAPSHOT}
MS_SUBDIR= snapshots/${GCC_BRANCH}-${SNAPSHOT}
PHASE= snapshot
.else
# Release naming pattern
IDENTIFICATION= gcc-${GCC_VERSION}
MS_SUBDIR= releases/gcc-${GCC_VERSION}
PHASE= release
.endif

8
lang/gcc6-aux/distinfo Normal file
View file

@ -0,0 +1,8 @@
SHA256 (gcc-6-20151129.tar.bz2) = 9fc70384a69ced8d3014d1182d874c9376fdaaa5d2bb4adb47a0df35a81e3834
SIZE (gcc-6-20151129.tar.bz2) = 93779686
SHA256 (ada-bootstrap.i386.freebsd.100B.tar.bz2) = 7231209f2600275f554f788ad1d036cf633c4339ebd25bd479a5bb1ddcddedf3
SIZE (ada-bootstrap.i386.freebsd.100B.tar.bz2) = 41229192
SHA256 (ada-bootstrap.x86_64.dragonfly.41.tar.bz2) = eb7785d8b842aee2bb04b43adfb1346b178ee4e83d8775b4e6705fd23f1586f0
SIZE (ada-bootstrap.x86_64.dragonfly.41.tar.bz2) = 44956630
SHA256 (ada-bootstrap.x86_64.freebsd.100B.tar.bz2) = 1066d7c5e71d78b4416de3b73348227678ca07db52488409e270db7b00467f55
SIZE (ada-bootstrap.x86_64.freebsd.100B.tar.bz2) = 42163803

View file

@ -0,0 +1,106 @@
# This file is part of DejaGnu.
if {![info exists board]} {
error "must set $board before loading android.exp"
}
# For rcp_download, rsh_exec.
load_lib remote.exp
#
# unix_load -- load the program and execute it
#
# See default.exp for explanation of arguments and results.
#
proc unix_load { dest prog args } {
global ld_library_path
set output ""
set orig_ld_library_path ""
if { [llength $args] > 0 } {
set parg [lindex $args 0]
} else {
set parg ""
}
if { [llength $args] > 1 } {
set inp [lindex $args 1]
} else {
set inp ""
}
if {![file exists $prog]} then {
# We call both here because this should never happen.
perror "$prog does not exist in unix_load."
verbose -log "$prog does not exist." 3
return "untested"
}
verbose "loading to $dest" 2
if {![is_remote $dest]} {
if { "$inp" != "" } {
set command "$prog $parg < $inp"
} else {
set command "$prog $parg"
}
if {![info exists ld_library_path]} {
set ld_library_path ""
}
set orig_ld_library_path "[getenv LD_LIBRARY_PATH]"
setenv LD_LIBRARY_PATH "$ld_library_path:$orig_ld_library_path"
setenv SHLIB_PATH "$ld_library_path:$orig_ld_library_path"
verbose -log "Setting LD_LIBRARY_PATH to $ld_library_path:$orig_ld_library_path" 2
set id [remote_spawn $dest "$command" "readonly"]
if { $id < 0 } {
set output "remote_spawn failed"
set status -1
} else {
set status [remote_wait $dest 300]
set output [lindex $status 1]
set status [lindex $status 0]
}
# Unset them so we don't potentially get hosed when we try to run a
# non-testcase executable. (Setting LD_LIBRARY_PATH is the wrong
# fix in the first place; this just tries to minimize the resulting
# crap.)
if {[info exists ld_library_path]} {
setenv LD_LIBRARY_PATH $orig_ld_library_path
setenv SHLIB_PATH $orig_ld_library_path
}
} else {
set remotefile "/data/local/testsuite/[file tail $prog].[pid]"
set remotefile [remote_download $dest $prog $remotefile]
if { $remotefile == "" } {
verbose -log "Download of $prog to [board_info $dest name] failed." 3
return [list "unresolved" ""]
}
set status [remote_exec $dest "$remotefile" $parg $inp]
remote_file $dest delete $remotefile.o $remotefile
if { [lindex $status 0] < 0 } {
verbose -log "Couldn't execute $prog, [lindex $status 1]" 3
return [list "unresolved" ""]
}
set output [lindex $status 1]
set status [lindex $status 0]
}
setenv LD_LIBRARY_PATH $orig_ld_library_path
setenv SHLIB_PATH $orig_ld_library_path
verbose "Executed $prog, status $status" 2
if {![string match "" $output]} {
verbose -- "$output" 2
}
if { $status == 0 } {
set result "pass"
} else {
set result "fail"
}
return [list $result $output]
}
set_board_info protocol "unix"

1101
lang/gcc6-aux/files/diff-ada Normal file

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,705 @@
--- gcc/testsuite/ada/acats/run_acats.orig
+++ gcc/testsuite/ada/acats/run_acats
@@ -5,20 +5,6 @@
exit 1
fi
-# Provide which replacement.
-#
-# type -p is missing from Solaris 2 /bin/sh and /bin/ksh (ksh88), but both
-# ksh93 and bash have it.
-# type output format differs between ksh88 and ksh93, so avoid it if
-# type -p is present. Unfortunately, HP-UX /bin/sh ignores -p with type.
-# Fall back to whence which ksh88 and ksh93 provide, but bash does not.
-
-which () {
- path=`type -p $* 2>/dev/null` && { echo $path | awk '{print $NF}'; return 0; }
- path=`type $* 2>/dev/null` && { echo $path | awk '{print $NF}'; return 0; }
- path=`whence $* 2>/dev/null` && { echo $path; return 0; }
- return 1
-}
# Set up environment to use the Ada compiler from the object tree
--- gcc/testsuite/ada/acats/run_all.sh.orig
+++ gcc/testsuite/ada/acats/run_all.sh
@@ -18,21 +18,6 @@
# End of customization section.
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
display_noeol () {
printf "$@"
printf "$@" >> $dir/acats.sum
@@ -50,6 +35,14 @@
echo "$@" >> $dir/acats.log
}
+inform () {
+ printf "%04d %7s" $1 $2
+}
+
+disinform () {
+ printf "\r"
+}
+
dir=`${PWDCMD-pwd}`
if [ "$testdir" = "" ]; then
@@ -105,18 +98,6 @@
gnatls -v >> $dir/acats.log
display ""
-if [ -n "$GCC_RUNTEST_PARALLELIZE_DIR" ]; then
- dir_support=$dir/../acats/support
-
- rm -rf $dir/run
- mv $dir/tests $dir/tests.$$ 2> /dev/null
- rm -rf $dir/tests.$$ &
- mkdir -p $dir/run
-
- cp -pr $dir/../acats/tests $dir/
-else
- dir_support=$dir/support
-
display " === acats support ==="
display_noeol "Generating support files..."
@@ -213,9 +194,6 @@
display " done."
display ""
-
-fi
-
display " === acats tests ==="
if [ $# -eq 0 ]; then
@@ -227,14 +205,20 @@
glob_countn=0
glob_countok=0
glob_countu=0
-par_count=0
-par_countm=0
-par_last=
+countdown=0
for chapter in $chapters; do
- # Used to generate support once and finish after that.
- [ "$chapter" = "NONE" ] && continue
+ if [ -d $dir/tests/$chapter ]; then
+ cd $dir/tests/$chapter
+ ls *.a *.ada *.adt *.am *.dep 2> /dev/null | sed -e 's/\(.*\)\..*/\1/g' | \
+ cut -c1-7 | sort | uniq | comm -23 - $dir/support/norun.lst \
+ > $dir/tests/$chapter/${chapter}.lst
+ countn=`wc -l < $dir/tests/$chapter/${chapter}.lst`
+ countdown=`expr $countdown + $countn`
+ fi
+done
+for chapter in $chapters; do
display Running chapter $chapter ...
if [ ! -d $dir/tests/$chapter ]; then
@@ -243,45 +227,11 @@
continue
fi
- cd $dir/tests/$chapter
- ls *.a *.ada *.adt *.am *.dep 2> /dev/null | sed -e 's/\(.*\)\..*/\1/g' | \
- cut -c1-7 | sort | uniq | comm -23 - $dir_support/norun.lst \
- > $dir/tests/$chapter/${chapter}.lst
countn=`wc -l < $dir/tests/$chapter/${chapter}.lst`
- as_fn_arith $glob_countn + $countn
- glob_countn=$as_val
+ glob_countn=`expr $glob_countn + $countn`
+ counti=0
for i in `cat $dir/tests/$chapter/${chapter}.lst`; do
-
- # If running multiple run_all.sh jobs in parallel, decide
- # if we should run this test in the current instance.
- if [ -n "$GCC_RUNTEST_PARALLELIZE_DIR" ]; then
- case "$i" in
- # Ugh, some tests have inter-test dependencies, those
- # tests have to be scheduled on the same parallel instance
- # as previous test.
- ce2108f | ce2108h | ce3112d) ;;
- # All others can be hopefully scheduled freely.
- *)
- as_fn_arith $par_countm + 1
- par_countm=$as_val
- [ $par_countm -eq 10 ] && par_countm=0
- if [ $par_countm -eq 1 ]; then
- as_fn_arith $par_count + 1
- par_count=$as_val
- if mkdir $GCC_RUNTEST_PARALLELIZE_DIR/$par_count 2>/dev/null; then
- par_last=1
- else
- par_last=
- fi
- fi;;
- esac
- if [ -z "$par_last" ]; then
- as_fn_arith $glob_countn - 1
- glob_countn=$as_val
- continue
- fi
- fi
-
+ counti=`expr $counti + 1`
extraflags="-gnat95"
grep $i $testdir/overflow.lst > /dev/null 2>&1
if [ $? -eq 0 ]; then
@@ -299,10 +249,13 @@
if [ $? -eq 0 ]; then
extraflags="$extraflags -fstack-check"
fi
+ inform $countdown $i
+ countdown=`expr $countdown - 1`
test=$dir/tests/$chapter/$i
mkdir $test && cd $test >> $dir/acats.log 2>&1
if [ $? -ne 0 ]; then
+ disinform
display "FAIL: $i"
failed="${failed}${i} "
clean_dir
@@ -320,19 +273,22 @@
echo "BUILD $main" >> $dir/acats.log
EXTERNAL_OBJECTS=""
case $i in
- cxb30*) EXTERNAL_OBJECTS="$dir_support/cxb30040.o $dir_support/cxb30060.o $dir_support/cxb30130.o $dir_support/cxb30131.o";;
+ cxb30*) EXTERNAL_OBJECTS="$dir/support/cxb30040.o $dir/support/cxb30060.o $dir/support/cxb30130.o $dir/support/cxb30131.o";;
ca1020e) rm -f ca1020e_func1.adb ca1020e_func2.adb ca1020e_proc1.adb ca1020e_proc2.adb > /dev/null 2>&1;;
ca14028) rm -f ca14028_func2.ads ca14028_func3.ads ca14028_proc1.ads ca14028_proc3.ads > /dev/null 2>&1;;
+ cxh1001) extraflags="-a -f"; echo "pragma Normalize_Scalars;" > gnat.adc
esac
if [ "$main" = "" ]; then
+ disinform
display "FAIL: $i"
failed="${failed}${i} "
clean_dir
continue
fi
- target_gnatmake $extraflags -I$dir_support $main >> $dir/acats.log 2>&1
+ target_gnatmake $extraflags -I$dir/support $main >> $dir/acats.log 2>&1
if [ $? -ne 0 ]; then
+ disinform
display "FAIL: $i"
failed="${failed}${i} "
clean_dir
@@ -347,6 +303,7 @@
target_run $dir/tests/$chapter/$i/$binmain > $dir/tests/$chapter/$i/${i}.log 2>&1
cd $dir/tests/$chapter/$i
cat ${i}.log >> $dir/acats.log
+ disinform
egrep -e '(==== |\+\+\+\+ |\!\!\!\! )' ${i}.log > /dev/null 2>&1
if [ $? -ne 0 ]; then
grep 'tasking not implemented' ${i}.log > /dev/null 2>&1
@@ -356,15 +313,12 @@
failed="${failed}${i} "
else
log "UNSUPPORTED: $i"
- as_fn_arith $glob_countn - 1
- glob_countn=$as_val
- as_fn_arith $glob_countu + 1
- glob_countu=$as_val
+ glob_countn=`expr $glob_countn - 1`
+ glob_countu=`expr $glob_countu + 1`
fi
else
log "PASS: $i"
- as_fn_arith $glob_countok + 1
- glob_countok=$as_val
+ glob_countok=`expr $glob_countok + 1`
fi
clean_dir
done
--- /dev/null
+++ gcc/testsuite/ada/acats/run_remote.sh
@@ -0,0 +1,412 @@
+#!/bin/sh
+# Run ACATS with the GNU Ada compiler
+
+# The following functions are to be customized if you run in cross
+# environment or want to change compilation flags. Note that for
+# tests requiring checks not turned on by default, this script
+# automatically adds the needed flags to pass (ie: -gnato or -gnatE).
+
+# gccflags="-O3 -fomit-frame-pointer -funroll-all-loops -finline-functions"
+# gnatflags="-gnatN"
+
+gccflags="-O2"
+gnatflags="-gnatws"
+tabtarget="/data/local/testsuite"
+STRIP="@REMOTE_TARGET@-strip"
+
+target_run () {
+ # Run on rooted tablet (port 22 vs port 2222)
+ BN=`basename $*`
+ $STRIP_FOR_TARGET $*
+ /usr/bin/scp -qp $* root@tablet:$tabtarget/
+ /usr/bin/ssh -q tablet $tabtarget/$BN
+}
+
+target_cmd () {
+ /usr/bin/ssh -q tablet "$1"
+}
+
+# End of customization section.
+
+display_noeol () {
+ printf "$@"
+ printf "$@" >> $dir/acats.sum
+ printf "$@" >> $dir/acats.log
+}
+
+display () {
+ echo "$@"
+ echo "$@" >> $dir/acats.sum
+ echo "$@" >> $dir/acats.log
+}
+
+log () {
+ echo "$@" >> $dir/acats.sum
+ echo "$@" >> $dir/acats.log
+}
+
+inform () {
+ printf "%04d %7s" $1 $2
+}
+
+disinform () {
+ printf "\r"
+}
+
+dir=`${PWDCMD-pwd}`
+
+if [ "$testdir" = "" ]; then
+ echo You must use make check or make check-ada
+ exit 1
+fi
+
+if [ "$dir" = "$testdir" ]; then
+ echo "error: srcdir must be different than objdir, exiting."
+ exit 1
+fi
+
+target_gnatmake () {
+ echo gnatmake-cross --GCC=\"$GCC\" $gnatflags $gccflags $* -largs $EXTERNAL_OBJECTS --GCC=\"$GCC\" -fPIE -pie
+ gnatmake-cross --GCC="$GCC" $gnatflags $gccflags $* -largs $EXTERNAL_OBJECTS --GCC="$GCC" -fPIE -pie
+}
+
+target_gcc () {
+ $GCC $gccflags $*
+}
+
+clean_dir () {
+ rm -f "$binmain" *.o *.ali > /dev/null 2>&1
+}
+
+find_main () {
+ ls ${i}?.adb > ${i}.lst 2> /dev/null
+ ls ${i}*m.adb >> ${i}.lst 2> /dev/null
+ ls ${i}.adb >> ${i}.lst 2> /dev/null
+ main=`tail -1 ${i}.lst`
+}
+
+split_testid () {
+ local mysplit=`echo $1 | awk -F/ '{print "section=" $1 "; TN=" $2 "; prog=" $3 ";"}'`
+ eval ${mysplit}
+}
+
+EXTERNAL_OBJECTS=""
+# Global variable to communicate external objects to link with.
+
+rm -f $dir/acats.sum $dir/acats.log $dir/transfer.lst
+
+display "Test Run By $USER on `date`"
+
+display " === acats configuration ==="
+
+target=`$GCC -dumpmachine`
+
+display target gcc is $GCC
+display `$GCC -v 2>&1`
+display host=`gcc -dumpmachine`
+display target=$target
+display `type gnatmake-cross`
+gnatls-cross -v >> $dir/acats.log
+display ""
+
+# Let's be tidy and clear off the remote device first
+target_cmd "cd ${tabtarget}; rm logs/*; rmdir logs; rm *"
+
+display " === acats support ==="
+display_noeol "Generating support files..."
+
+rm -rf $dir/support
+mkdir -p $dir/support
+cd $dir/support
+
+cp $testdir/support/*.ada $testdir/support/*.a $testdir/support/*.tst $dir/support
+
+# Find out the size in bit of an address on the target
+target_gnatmake $testdir/support/impbit.adb >> $dir/acats.log 2>&1
+target_run $dir/support/impbit > $dir/support/impbit.out 2>&1
+target_bit=`cat $dir/support/impbit.out`
+echo target_bit="$target_bit" >> $dir/acats.log
+
+# Find out a suitable asm statement
+# Adapted from configure.ac gcc_cv_as_dwarf2_debug_line
+case "$target" in
+ ia64*-*-* | s390*-*-*)
+ target_insn="nop 0"
+ ;;
+ mmix-*-*)
+ target_insn="swym 0"
+ ;;
+ *)
+ target_insn="nop"
+ ;;
+esac
+echo target_insn="$target_insn" >> $dir/acats.log
+
+sed -e "s,ACATS4GNATDIR,$dir,g" \
+ < $testdir/support/impdef.a > $dir/support/impdef.a
+sed -e "s,ACATS4GNATDIR,$dir,g" \
+ -e "s,ACATS4GNATBIT,$target_bit,g" \
+ -e "s,ACATS4GNATINSN,$target_insn,g" \
+ < $testdir/support/macro.dfs > $dir/support/MACRO.DFS
+sed -e "s,ACATS4GNATDIR,$dir,g" \
+ < $testdir/support/tsttests.dat > $dir/support/TSTTESTS.DAT
+
+cp $testdir/tests/cd/*.c $dir/support
+cp $testdir/tests/cxb/*.c $dir/support
+grep -v '^#' $testdir/norun.lst | sort > $dir/support/norun.lst
+
+rm -rf $dir/run
+mv $dir/tests $dir/tests.$$ 2> /dev/null
+rm -rf $dir/tests.$$ &
+mkdir -p $dir/run
+
+cp -pr $testdir/tests $dir/
+
+for i in $dir/support/*.ada $dir/support/*.a; do
+ host_gnatchop $i >> $dir/acats.log 2>&1
+done
+
+# These tools are used to preprocess some ACATS sources
+# they need to be compiled native on the host.
+
+host_gnatmake -q -gnatws macrosub.adb
+if [ $? -ne 0 ]; then
+ display "**** Failed to compile macrosub"
+ exit 1
+fi
+./macrosub > macrosub.out 2>&1
+
+gcc -c cd300051.c
+host_gnatmake -q -gnatws widechr.adb
+if [ $? -ne 0 ]; then
+ display "**** Failed to compile widechr"
+ exit 1
+fi
+./widechr > widechr.out 2>&1
+
+rm -f $dir/support/macrosub
+rm -f $dir/support/widechr
+rm -f $dir/support/*.ali
+rm -f $dir/support/*.o
+
+display " done."
+
+# From here, all compilations will be made by the target compiler
+
+display_noeol "Compiling support files..."
+
+target_gcc -c *.c
+if [ $? -ne 0 ]; then
+ display "**** Failed to compile C code"
+ exit 1
+fi
+
+host_gnatchop *.adt >> $dir/acats.log 2>&1
+
+target_gnatmake -c -gnato -gnatE *.ads >> $dir/acats.log 2>&1
+target_gnatmake -c -gnato -gnatE *.adb >> $dir/acats.log 2>&1
+
+display " done."
+display ""
+display " === acats tests ==="
+
+if [ $# -eq 0 ]; then
+ chapters=`cd $dir/tests; echo [a-z]*`
+else
+ chapters=$*
+fi
+
+glob_countn=0
+glob_countok=0
+glob_countu=0
+countdown=0
+
+for chapter in $chapters; do
+ if [ -d $dir/tests/$chapter ]; then
+ cd $dir/tests/$chapter
+ ls *.a *.ada *.adt *.am *.dep 2> /dev/null | sed -e 's/\(.*\)\..*/\1/g' | \
+ cut -c1-7 | sort | uniq | comm -23 - $dir/support/norun.lst \
+ > $dir/tests/$chapter/${chapter}.lst
+ countn=`wc -l < $dir/tests/$chapter/${chapter}.lst`
+ countdown=`expr $countdown + $countn`
+ fi
+done
+
+cat > $dir/execute.sh << EOF
+inform () {
+ printf "left: %04d" \$1
+}
+disinform () {
+ printf "\r"
+}
+cycle () {
+ local countx=0
+ local total=\$(echo \$testlist | awk '{print NF}')
+ mkdir -p logs
+ echo "Executing \$total tests on remote device"
+ inform \$total
+ for x in \$testlist; do
+ timeout -t 30 ./\${x} > logs/\${x}.log 2>&1
+ countx=\$(expr \$countx + 1)
+ if [ \$countx -eq 25 ]; then
+ total=\$(expr \$total - 25)
+ countx=0
+ disinform
+ inform \$total
+ fi
+ done
+ disinform
+ tar -czf remote.logs.tar.gz logs
+}
+testlist=" \\
+EOF
+
+display "All tests are being cross-compiled without execution first."
+
+for chapter in $chapters; do
+ if [ ! -d $dir/tests/$chapter ]; then
+ continue
+ fi
+
+ countn=`wc -l < $dir/tests/$chapter/${chapter}.lst`
+ glob_countn=`expr $glob_countn + $countn`
+ counti=0
+ for i in `cat $dir/tests/$chapter/${chapter}.lst`; do
+ counti=`expr $counti + 1`
+ extraflags="-gnat95"
+ grep $i $testdir/overflow.lst > /dev/null 2>&1
+ if [ $? -eq 0 ]; then
+ extraflags="$extraflags -gnato"
+ fi
+ grep $i $testdir/elabd.lst > /dev/null 2>&1
+ if [ $? -eq 0 ]; then
+ extraflags="$extraflags -gnatE"
+ fi
+ grep $i $testdir/floatstore.lst > /dev/null 2>&1
+ if [ $? -eq 0 ]; then
+ extraflags="$extraflags -ffloat-store"
+ fi
+ grep $i $testdir/stackcheck.lst > /dev/null 2>&1
+ if [ $? -eq 0 ]; then
+ extraflags="$extraflags -fstack-check"
+ fi
+ inform $countdown $i
+ countdown=`expr $countdown - 1`
+ test=$dir/tests/$chapter/$i
+ mkdir $test && cd $test >> $dir/acats.log 2>&1
+
+ if [ $? -ne 0 ]; then
+ disinform
+ display "FAIL: $i"
+ failed="${failed}${i} "
+ clean_dir
+ continue
+ fi
+
+ host_gnatchop -c -w `ls ${test}*.a ${test}*.ada ${test}*.adt ${test}*.am ${test}*.dep 2> /dev/null` >> $dir/acats.log 2>&1
+ find_main
+ if [ -z "$main" ]; then
+ sync
+ find_main
+ fi
+ binmain=`echo $main | sed -e 's/\(.*\)\..*/\1/g'`
+ echo "BUILD $main" >> $dir/acats.log
+ EXTERNAL_OBJECTS=""
+ case $i in
+ cxb30*) EXTERNAL_OBJECTS="$dir/support/cxb30040.o $dir/support/cxb30060.o $dir/support/cxb30130.o $dir/support/cxb30131.o";;
+ ca1020e) rm -f ca1020e_func1.adb ca1020e_func2.adb ca1020e_proc1.adb ca1020e_proc2.adb > /dev/null 2>&1;;
+ ca14028) rm -f ca14028_func2.ads ca14028_func3.ads ca14028_proc1.ads ca14028_proc3.ads > /dev/null 2>&1;;
+ cxh1001) extraflags="-a -f"; echo "pragma Normalize_Scalars;" > gnat.adc
+ esac
+ if [ "$main" = "" ]; then
+ disinform
+ display "FAIL: $i"
+ failed="${failed}${i} "
+ clean_dir
+ continue
+ fi
+
+ target_gnatmake $extraflags -I$dir/support $main >> $dir/acats.log 2>&1
+ if [ $? -ne 0 ]; then
+ disinform
+ display "FAIL: $i"
+ failed="${failed}${i} "
+ clean_dir
+ continue
+ fi
+ echo $chapter/$i/$binmain >> $dir/transfer.lst
+ echo "$binmain \\" >> $dir/execute.sh
+ $STRIP $binmain
+ disinform
+ done
+done
+echo '"' >> $dir/execute.sh
+echo "cycle" >> $dir/execute.sh
+
+sync
+display "Transfer files to remote device: root@tablet:$tabtarget/"
+cd $dir/tests
+cat $dir/transfer.lst | xargs tar --strip-components=2 -czf - | \
+ target_cmd "tar -C $tabtarget -xzf -"
+cd $dir
+tar -czf - execute.sh | target_cmd "tar -C $tabtarget -xzf -"
+target_cmd "cd $tabtarget; sh execute.sh"
+rm -rf $dir/logs $dir/remote.logs.tar.gz
+/usr/bin/scp -q root@tablet:$tabtarget/remote.logs.tar.gz $dir/
+tar -xzf $dir/remote.logs.tar.gz
+
+countdown=`wc -l < $dir/transfer.lst`
+glob_countn=${countdown}
+for i in `cat $dir/transfer.lst`; do
+ split_testid $i
+ if [ "$section" != "$savedsect" ]; then
+ display Running chapter $section ...
+ fi
+ savedsect=$section
+
+ #inform $countdown $TN
+ countdown=`expr $countdown - 1`
+ proglog="$dir/logs/${prog}.log"
+ echo "RUN $prog" >> $dir/acats.log
+ if [ ! -f $proglog ]; then
+ echo "LOG NOT FOUND!" >> $proglog
+ fi
+
+ cat $proglog >> $dir/acats.log
+
+ egrep -e '(==== |\+\+\+\+ |\!\!\!\! )' $proglog > /dev/null 2>&1
+ if [ $? -ne 0 ]; then
+ grep 'tasking not implemented' $proglog > /dev/null 2>&1
+
+ if [ $? -ne 0 ]; then
+ display "FAIL: ${TN}"
+ failed="${failed}${TN} "
+ else
+ log "UNSUPPORTED: ${TN}"
+ glob_countn=`expr $glob_countn - 1`
+ glob_countu=`expr $glob_countu + 1`
+ fi
+ else
+ log "PASS: ${TN}"
+ glob_countok=`expr $glob_countok + 1`
+ fi
+ cd $dir/tests/$section/$TN
+ clean_dir
+ #disinform
+done
+
+display " === acats Summary ==="
+display "# of expected passes $glob_countok"
+display "# of unexpected failures `expr $glob_countn - $glob_countok`"
+
+if [ $glob_countu -ne 0 ]; then
+ display "# of unsupported tests $glob_countu"
+fi
+
+if [ $glob_countok -ne $glob_countn ]; then
+ display "*** FAILURES: $failed"
+fi
+
+display "$0 completed at `date`"
+
+exit 0
--- gcc/testsuite/gnat.dg/test_raise_from_pure.adb.orig
+++ gcc/testsuite/gnat.dg/test_raise_from_pure.adb
@@ -1,4 +1,4 @@
--- { dg-do run }
+-- { dg-do run { xfail *-*-openbsd* } }
-- { dg-options "-O2" }
-- This is an optimization test and its failure is only a missed optimization.
--- gcc/testsuite/gnat.dg/unchecked_convert5.adb.orig
+++ gcc/testsuite/gnat.dg/unchecked_convert5.adb
@@ -1,22 +0,0 @@
--- { dg-do run { target hppa*-*-* sparc*-*-* powerpc*-*-* } }
-
-with Unchecked_Conversion;
-
-procedure Unchecked_Convert5 is
-
- subtype c_1 is string(1..1);
-
- function int2c1 is -- { dg-warning "different sizes" }
- new unchecked_conversion (source => integer, target => c_1);
-
- c1 : c_1;
-
-begin
-
- c1 := int2c1(16#12#);
-
- if c1 (1) /= ASCII.Nul then
- raise Program_Error;
- end if;
-
-end;
--- gcc/testsuite/gnat.dg/unchecked_convert6.adb.orig
+++ gcc/testsuite/gnat.dg/unchecked_convert6.adb
@@ -1,22 +0,0 @@
--- { dg-do run { target hppa*-*-* sparc*-*-* powerpc*-*-* } }
-
-with Unchecked_Conversion;
-
-procedure Unchecked_Convert6 is
-
- subtype c_5 is string(1..5);
-
- function int2c5 is -- { dg-warning "different sizes" }
- new unchecked_conversion (source => integer, target => c_5);
-
- c5 : c_5;
-
-begin
-
- c5 := int2c5(16#12#);
-
- if c5 (4) /= ASCII.DC2 then
- raise Program_Error;
- end if;
-
-end;

View file

@ -0,0 +1,92 @@
--- gcc/config/i386/freebsd.h.orig
+++ gcc/config/i386/freebsd.h
@@ -77,6 +77,12 @@
When the -shared link option is used a final link is not being
done. */
+#if FBSD_MAJOR < 10
+#define ELF_HASH_STYLE "--hash-style=both "
+#else
+#define ELF_HASH_STYLE "--hash-style=gnu "
+#endif
+
#undef LINK_SPEC
#define LINK_SPEC "\
%{p:%nconsider using '-pg' instead of '-p' with gprof(1)} \
@@ -88,6 +94,7 @@
%{rdynamic:-export-dynamic} \
-dynamic-linker %(fbsd_dynamic_linker) } \
%{static:-Bstatic}} \
+ %{!static:" ELF_HASH_STYLE "-rpath @PREFIX@/@GCCAUX@/lib} \
%{symbolic:-Bsymbolic}"
/* A C statement to output to the stdio stream FILE an assembler
--- gcc/config/i386/freebsd64.h.orig
+++ gcc/config/i386/freebsd64.h
@@ -41,4 +41,5 @@
%{rdynamic:-export-dynamic} \
-dynamic-linker %(fbsd_dynamic_linker) } \
%{static:-Bstatic}} \
+ %{!static:" ELF_HASH_STYLE "-rpath @PREFIX@/@GCCAUX@/lib} \
%{symbolic:-Bsymbolic}"
--- gcc/Makefile.in.orig
+++ gcc/Makefile.in
@@ -1184,7 +1184,6 @@
insn-emit.o \
insn-extract.o \
insn-latencytab.o \
- insn-modes.o \
insn-opinit.o \
insn-output.o \
insn-peep.o \
@@ -1547,6 +1546,7 @@
$(OBJS-libcommon-target) main.o c-family/cppspec.o \
$(COLLECT2_OBJS) $(EXTRA_GCC_OBJS) $(GCOV_OBJS) $(GCOV_DUMP_OBJS) \
$(GCOV_TOOL_OBJS) $(GENGTYPE_OBJS) gcc-ar.o gcc-nm.o gcc-ranlib.o \
+ insn-modes.o insn-modes-ada.o \
lto-wrapper.o collect-utils.o
# This lists all host object files, whether they are included in this
@@ -1554,6 +1554,11 @@
ALL_HOST_OBJS = $(ALL_HOST_FRONTEND_OBJS) $(ALL_HOST_BACKEND_OBJS)
BACKEND = libbackend.a main.o libcommon-target.a libcommon.a \
+ insn-modes.o \
+ $(CPPLIB) $(LIBDECNUMBER)
+
+BACKEND2 = libbackend.a main.o libcommon-target.a libcommon.a \
+ insn-modes-ada.o \
$(CPPLIB) $(LIBDECNUMBER)
# This is defined to "yes" if Tree checking is enabled, which roughly means
@@ -2208,6 +2213,7 @@
insn-modes.c: s-modes; @true
insn-modes.h: s-modes-h; @true
+insn-modes-ada.c: s-modes-ada; @true
min-insn-modes.c: s-modes-m; @true
s-modes: build/genmodes$(build_exeext)
@@ -2225,6 +2231,12 @@
$(SHELL) $(srcdir)/../move-if-change tmp-min-modes.c min-insn-modes.c
$(STAMP) s-modes-m
+s-modes-ada: s-modes
+ $(shell sed -e 's/: TARGET_96_ROUND_53_LONG_DOUBLE \? &ieee_extended_intel_96_round_53_format //' \
+ < insn-modes.c > tmp-modes-ada.c)
+ $(SHELL) $(srcdir)/../move-if-change tmp-modes-ada.c insn-modes-ada.c
+ $(STAMP) s-modes-ada
+
insn-preds.c: s-preds; @true
tm-preds.h: s-preds-h; @true
tm-constrs.h: s-constrs-h; @true
@@ -3407,6 +3419,9 @@
( cd $(DESTDIR)$(bindir) && \
$(LN) $(GCC_INSTALL_NAME)$(exeext) $(FULL_DRIVER_NAME) ); \
fi; \
+ if [ -f gnat1$(exeext) ] ; then \
+ ( cd $(DESTDIR)$(bindir) && $(LN) $(GCC_INSTALL_NAME)$(exeext) ada$(exeext) ) \
+ fi; \
if [ ! -f gcc-cross$(exeext) ] \
&& [ "$(GCC_INSTALL_NAME)" != "$(GCC_TARGET_INSTALL_NAME)" ]; then \
rm -f $(DESTDIR)$(bindir)/$(target_noncanonical)-gcc-tmp$(exeext); \

View file

@ -0,0 +1,12 @@
--- libstdc++-v3/configure.host.orig
+++ libstdc++-v3/configure.host
@@ -262,6 +262,9 @@
freebsd*)
os_include_dir="os/bsd/freebsd"
;;
+ linux-android*)
+ os_include_dir="os/bionic"
+ ;;
linux-musl*)
os_include_dir="os/generic"
;;

View file

@ -0,0 +1,46 @@
--- gcc/testsuite/gcc.dg/format/ext-1.c.orig
+++ gcc/testsuite/gcc.dg/format/ext-1.c
@@ -8,7 +8,7 @@
#include "format.h"
void
-foo (quad_t q, u_quad_t uq, quad_t *qn, size_t z, size_t *zn, long long int ll,
+foo (quad2_t q, u_quad2_t uq, quad2_t *qn, size_t z, size_t *zn, long long int ll,
unsigned long long int ull, int i, unsigned int u, double d,
char *s, void *p, wchar_t *ls, wint_t lc, int *n, long int l)
{
--- gcc/testsuite/gcc.dg/format/ext-2.c.orig
+++ gcc/testsuite/gcc.dg/format/ext-2.c
@@ -8,7 +8,7 @@
#include "format.h"
void
-foo (quad_t *qp, u_quad_t *uqp, quad_t *qn, long long int *llp,
+foo (quad2_t *qp, u_quad2_t *uqp, quad2_t *qn, long long int *llp,
unsigned long long int *ullp, float *fp, char *s, void **pp, wchar_t *ls,
int *ip, unsigned int *up)
{
--- gcc/testsuite/gcc.dg/format/format.h.orig
+++ gcc/testsuite/gcc.dg/format/format.h
@@ -71,8 +71,8 @@
#endif
/* %q formats want a "quad"; GCC considers this to be a long long. */
-typedef llong quad_t;
-typedef ullong u_quad_t;
+typedef llong quad2_t;
+typedef ullong u_quad2_t;
__extension__ typedef __INTMAX_TYPE__ intmax_t;
__extension__ typedef __UINTMAX_TYPE__ uintmax_t;
--- gcc/testsuite/gcc.dg/pch/pch.exp.orig
+++ gcc/testsuite/gcc.dg/pch/pch.exp
@@ -44,6 +44,8 @@
set test "largefile.c"
set testh "largefile.hs"
set f [open $test w]
+puts $f "/* { dg-do run { target *-*-solaris* } } */"
+puts $f "/* { dg-error \"dummy\" \"fool dejagnu\" { target { ! *-*-solaris* } 20 } } */"
puts $f "/* { dg-timeout-factor 4.0 } */"
set v 0
for { set v 0 } { $v < 10000 } { incr v } {

View file

@ -0,0 +1,14 @@
# gnatdroid testsuite running over ssh.
load_generic_config "android"
process_multilib_options ""
# The default compiler for this target.
set_board_info compiler "[find_gcc]"
set_board_info rsh_prog /usr/bin/ssh
set_board_info rcp_prog /usr/bin/scp
set_board_info protocol standard
set_board_info hostname tablet
set_board_info username root

14
lang/gcc6-aux/pkg-descr Normal file
View file

@ -0,0 +1,14 @@
The AUX compiler supports several languages: Ada, C, C++, Fortran and
Objective-C. Since Ada support must be built by an Ada-capable compiler,
only platforms for which a bootstrap compiler is available can build it.
The AUX compiler is based on release versions of the Free Software
Foundation's GNU Compiler Collection. It uses the GCC Runtime Library
Exception, so the resulting binaries have no licensing requirements.
Binaries produced by the AUX compiler should be legally handled the same
as binaries produced by any FSF compiler.
This compiler implements the full Ada-83, Ada-95, Ada-2005 and Ada-2012
standards.
WWW: http://www.dragonlace.net/