blob: bd5c2753992296c998be0bace0b611de3b4f66da [file] [log] [blame]
--- gcc-4.8.2.orig/gcc/config/arm/t-arm-elf 2013-01-10 20:38:27.000000000 +0000
+++ gcc-4.8.2/gcc/config/arm/t-arm-elf 2013-12-28 22:54:59.000000000 +0000
@@ -25,22 +25,36 @@
#MULTILIB_DIRNAMES += fa526 fa626 fa606te fa626te fmp626 fa726te
#MULTILIB_EXCEPTIONS += *mthumb*/*mcpu=fa526 *mthumb*/*mcpu=fa626
+# build a bunch of specialized versions of libcc for particular cores
+#MULTILIB_OPTIONS += mcpu=arm7tdmi/mcpu=arm9tdmi/mcpu=arm920t/mcpu=arm926ej-s/mcpu=arm1136j-s/mcpu=arm1136jf-s/mcpu=arm1176jz-s/mcpu=arm1176jzf-s/mcpu=xscale/mcpu=mpcore/mcpu=cortex-a8/cortex-a9/march=armv4t/march=armv5t/march=armv5te/march=armv6/march=armv6j/march=armv6k/march=armv6z/march=armv6zk/march=armv7-a/march=armv7-r
+#MULTILIB_DIRNAMES += arm7tdmi arm9tdmi arm920t arm926ej-s arm1136j-s arm1136jf-s arm1176jz-s arm1176jzf-s xscale mpcore cortex-a8 cortex-a9 cortex-m3 armv4t armv5t armv5te armv6 armv6j armv6k armv6z armv6zk armv7-a armv7-r
+#MULTILIB_OPTIONS += mcpu=arm7tdmi/mcpu=arm9tdmi/mcpu=arm920t/mcpu=arm926ej-s/mcpu=arm1136j-s/mcpu=arm1136jf-s/mcpu=arm1176jz-s/mcpu=arm1176jzf-s/mcpu=xscale/mcpu=mpcore/mcpu=cortex-a8/mcpu=cortex-a9
+#MULTILIB_DIRNAMES += arm7tdmi arm9tdmi arm920t arm926ej-s arm1136j-s arm1136jf-s arm1176jz-s arm1176jzf-s xscale mpcore cortex-a8 cortex-a9
+
+MULTILIB_OPTIONS += march=armv7
+MULTILIB_DIRNAMES += thumb2
+MULTILIB_EXCEPTIONS += march=armv7* marm/*march=armv7*
+MULTILIB_MATCHES += march?armv7=march?armv7-a
+MULTILIB_MATCHES += march?armv7=march?armv7-r
+MULTILIB_MATCHES += march?armv7=march?armv7-m
+MULTILIB_MATCHES += march?armv7=mcpu?cortex-a15
+MULTILIB_MATCHES += march?armv7=mcpu?cortex-a9
+MULTILIB_MATCHES += march?armv7=mcpu?cortex-a8
+MULTILIB_MATCHES += march?armv7=mcpu?cortex-r4
+MULTILIB_MATCHES += march?armv7=mcpu?cortex-m4
+MULTILIB_MATCHES += march?armv7=mcpu?cortex-m3
+
+#MULTILIB_OPTIONS += mfpu=vfp
+#MULTILIB_DIRNAMES += vfp
+#MULTILIB_MATCHES += mfpu?vfp=mcpu?arm1136jf-s
+#MULTILIB_MATCHES += mfpu?vfp=mcpu?arm1136jzf-s
-#MULTILIB_OPTIONS += march=armv7
-#MULTILIB_DIRNAMES += thumb2
-#MULTILIB_EXCEPTIONS += march=armv7* marm/*march=armv7*
-#MULTILIB_MATCHES += march?armv7=march?armv7-a
-#MULTILIB_MATCHES += march?armv7=march?armv7-r
-#MULTILIB_MATCHES += march?armv7=march?armv7-m
-#MULTILIB_MATCHES += march?armv7=mcpu?cortex-a8
-#MULTILIB_MATCHES += march?armv7=mcpu?cortex-r4
-#MULTILIB_MATCHES += march?armv7=mcpu?cortex-m3
# Not quite true. We can support hard-vfp calling in Thumb2, but how do we
# express that here? Also, we really need architecture v5e or later
# (mcrr etc).
+#MULTILIB_OPTIONS += mfloat-abi=hard
+#MULTILIB_DIRNAMES += fpu
+#MULTILIB_EXCEPTIONS += *mthumb/*mfloat-abi=hard*
-MULTILIB_OPTIONS += mfloat-abi=hard
-MULTILIB_DIRNAMES += fpu
-MULTILIB_EXCEPTIONS += *mthumb/*mfloat-abi=hard*
#MULTILIB_EXCEPTIONS += *mcpu=fa526/*mfloat-abi=hard*
#MULTILIB_EXCEPTIONS += *mcpu=fa626/*mfloat-abi=hard*
@@ -56,8 +70,8 @@
# MULTILIB_DIRNAMES += fpu soft
# MULTILIB_EXCEPTIONS += *mthumb/*mfloat-abi=hard*
#
+MULTILIB_OPTIONS += mno-thumb-interwork/mthumb-interwork
+MULTILIB_DIRNAMES += normal interwork
-# MULTILIB_OPTIONS += mno-thumb-interwork/mthumb-interwork
-# MULTILIB_DIRNAMES += normal interwork
#
# MULTILIB_OPTIONS += fno-leading-underscore/fleading-underscore
# MULTILIB_DIRNAMES += elf under
reverted:
--- gcc-4.8.2.orig/gcc/config/i386/t-x86_64-elf 1970-01-01 01:00:00.000000000 +0100
+++ gcc-4.8.2/gcc/config/i386/t-x86_64-elf 2013-12-29 12:47:35.000000000 +0000
@@ -0,0 +1,8 @@
+# Add redzoneless libgcc
+
+MULTILIB_OPTIONS += mno-red-zone
+MULTILIB_DIRNAMES += no-red-zone
+
+# Build a 32bit libgcc as well
+MULTILIB_OPTIONS += m32
+MULTILIB_DIRNAMES += 32
\ No newline at end of file
reverted:
--- gcc-4.8.2.orig/gcc/config.gcc 2013-10-03 01:47:24.000000000 +0100
+++ gcc-4.8.2/gcc/config.gcc 2013-12-29 12:06:18.000000000 +0000
@@ -1213,6 +1213,7 @@
tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h newlib-stdint.h i386/i386elf.h"
;;
x86_64-*-elf*)
+ tmake_file="${tmake_file} i386/t-x86_64-elf"
tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h newlib-stdint.h i386/i386elf.h i386/x86-64.h"
;;
i[34567]86-*-rdos*)
gcc/
2016-09-27 Roland McGrath <roland@hack.frob.com>
PR other/77609
* varasm.c (default_section_type_flags): Set SECTION_NOTYPE for
any section for which we don't know a specific type it should have,
regardless of name. Previously this was done only for the exact
names ".init_array", ".fini_array", and ".preinit_array".
diff --git a/gcc/varasm.c b/gcc/varasm.c
index b0f2af0..dcc9976 100644
--- a/gcc/varasm.c
+++ b/gcc/varasm.c
@@ -6193,15 +6193,20 @@ default_section_type_flags (tree decl, const char *name, int reloc)
|| strncmp (name, ".gnu.linkonce.tb.", 17) == 0)
flags |= SECTION_TLS | SECTION_BSS;
- /* These three sections have special ELF types. They are neither
- SHT_PROGBITS nor SHT_NOBITS, so when changing sections we don't
- want to print a section type (@progbits or @nobits). If someone
- is silly enough to emit code or TLS variables to one of these
- sections, then don't handle them specially. */
- if (!(flags & (SECTION_CODE | SECTION_BSS | SECTION_TLS))
- && (strcmp (name, ".init_array") == 0
- || strcmp (name, ".fini_array") == 0
- || strcmp (name, ".preinit_array") == 0))
+ /* Various sections have special ELF types that the assembler will
+ assign by default based on the name. They are neither SHT_PROGBITS
+ nor SHT_NOBITS, so when changing sections we don't want to print a
+ section type (@progbits or @nobits). Rather than duplicating the
+ assembler's knowledge of what those special name patterns are, just
+ let the assembler choose the type if we don't know a specific
+ reason to set it to something other than the default. SHT_PROGBITS
+ is the default for sections whose name is not specially known to
+ the assembler, so it does no harm to leave the choice to the
+ assembler when @progbits is the best thing we know to use. If
+ someone is silly enough to emit code or TLS variables to one of
+ these sections, then don't handle them specially. */
+ if (!(flags & (SECTION_CODE | SECTION_BSS | SECTION_TLS | SECTION_ENTSIZE))
+ && !(HAVE_COMDAT_GROUP && (flags & SECTION_LINKONCE)))
flags |= SECTION_NOTYPE;
return flags;
diff -dcprN gcc-6.2.0/config.sub gcc-6.2.0-fuchsia/config.sub
*** gcc-6.2.0/config.sub 2015-12-31 13:13:28.000000000 -0800
--- gcc-6.2.0-fuchsia/config.sub 2016-10-24 17:07:48.244523443 -0700
*************** case $os in
*** 1531,1536 ****
--- 1531,1539 ----
;;
-nacl*)
;;
+ -fuchsia*)
+ os=-fuchsia
+ ;;
-none)
;;
*)
diff -dcprN gcc-6.2.0/gcc/config/fuchsia.h gcc-6.2.0-fuchsia/gcc/config/fuchsia.h
*** gcc-6.2.0/gcc/config/fuchsia.h 1969-12-31 16:00:00.000000000 -0800
--- gcc-6.2.0-fuchsia/gcc/config/fuchsia.h 2016-10-31 13:08:34.707128162 -0700
***************
*** 0 ****
--- 1,49 ----
+ /* Base configuration file for all Fuchsia targets.
+ Copyright (C) 2016 Free Software Foundation, Inc.
+
+ This file is part of GCC.
+
+ GCC 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 3, or (at your option)
+ any later version.
+
+ GCC 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 GCC; see the file COPYING3. If not see
+ <http://www.gnu.org/licenses/>. */
+
+ /* Common Fuchsia configuration. */
+
+ /* In case we need to know. */
+ #define USING_CONFIG_FUCHSIA 1
+
+ #undef STARTFILE_SPEC
+ #define STARTFILE_SPEC "%{!shared: crt1.o%s}"
+
+ #undef ENDFILE_SPEC
+ #define ENDFILE_SPEC ""
+
+ #undef CC1_SPEC
+ #define CC1_SPEC "%{!fno-pic:%{!fno-PIC:%{!fpic:%{!fPIC: -fPIC}}}}"
+
+ #undef LIB_SPEC
+ #define LIB_SPEC "-lmxio -lmagenta -lc" \
+ "%{!static: -lgcc_s}"
+
+ #undef LINK_SPEC
+ #define LINK_SPEC "-z max-page-size=4096" \
+ " -z combreloc" \
+ " -z relro" \
+ " -z now" \
+ " -z text" \
+ "%{!hash-style: --hash-style=gnu}" \
+ "%{!no-eh-frame-hdr: --eh-frame-hdr}" \
+ "%{!no-build-id: --build-id}" \
+ "%{shared: -shared}" \
+ "%{!shared:%{!static:%{!dynamic-linker: -dynamic-linker=ld.so.1}}}"
+
diff -dcprN gcc-6.2.0/gcc/config.gcc gcc-6.2.0-fuchsia/gcc/config.gcc
*** gcc-6.2.0/gcc/config.gcc 2016-10-24 16:39:48.403676689 -0700
--- gcc-6.2.0-fuchsia/gcc/config.gcc 2016-10-31 15:26:25.548944871 -0700
*************** i[34567]86-*-interix[3-9]*)
*** 1792,1797 ****
--- 1792,1801 ----
tm_file="${tm_file} dbxcoff.h"
fi
;;
+ x86_64-*-fuchsia*)
+ tmake_file="${tmake_file} i386/t-x86_64-elf"
+ tm_file="${tm_file} i386/unix.h i386/att.h elfos.h newlib-stdint.h i386/i386elf.h i386/x86-64.h fuchsia.h"
+ ;;
ia64*-*-elf*)
tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h ia64/sysv4.h ia64/elf.h"
tmake_file="ia64/t-ia64"
diff -dcprN gcc-6.2.0/libgcc/config/t-slibgcc-fuchsia gcc-6.2.0-fuchsia/libgcc/config/t-slibgcc-fuchsia
*** gcc-6.2.0/libgcc/config/t-slibgcc-fuchsia 1969-12-31 16:00:00.000000000 -0800
--- gcc-6.2.0-fuchsia/libgcc/config/t-slibgcc-fuchsia 2016-10-28 10:05:17.778985385 -0700
***************
*** 0 ****
--- 1,22 ----
+ # Copyright (C) 2016 Free Software Foundation, Inc.
+ #
+ # This file is part of GCC.
+ #
+ # GCC 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 3, or (at your option)
+ # any later version.
+ #
+ # GCC 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 GCC; see the file COPYING3. If not see
+ # <http://www.gnu.org/licenses/>.
+
+ # Fuchsia-specific shared library overrides.
+
+ SHLIB_LDFLAGS = -Wl,--soname=$(SHLIB_SONAME) \
+ $(LDFLAGS)
diff -dcprN gcc-6.2.0/libgcc/config.host gcc-6.2.0-fuchsia/libgcc/config.host
*** gcc-6.2.0/libgcc/config.host 2016-05-16 23:15:52.000000000 -0700
--- gcc-6.2.0-fuchsia/libgcc/config.host 2016-10-31 15:15:46.787859155 -0700
*************** case ${host} in
*** 230,235 ****
--- 230,238 ----
;;
esac
;;
+ *-*-fuchsia*)
+ tmake_file="$tmake_file t-libgcc-pic t-eh-dw2-dip t-slibgcc t-slibgcc-fuchsia"
+ ;;
*-*-linux* | frv-*-*linux* | *-*-kfreebsd*-gnu | *-*-knetbsd*-gnu | *-*-gnu* | *-*-kopensolaris*-gnu)
tmake_file="$tmake_file t-crtstuff-pic t-libgcc-pic t-eh-dw2-dip t-slibgcc t-slibgcc-gld t-slibgcc-elf-ver t-linux"
extra_parts="crtbegin.o crtbeginS.o crtbeginT.o crtend.o crtendS.o"
*************** i[34567]86-*-elfiamcu)
*** 577,584 ****
i[34567]86-*-elf*)
tmake_file="$tmake_file i386/t-crtstuff t-crtstuff-pic t-libgcc-pic"
;;
! x86_64-*-elf* | x86_64-*-rtems*)
! tmake_file="$tmake_file i386/t-crtstuff t-crtstuff-pic t-libgcc-pic"
;;
i[34567]86-*-dragonfly*)
tmake_file="${tmake_file} i386/t-dragonfly i386/t-crtstuff"
--- 580,587 ----
i[34567]86-*-elf*)
tmake_file="$tmake_file i386/t-crtstuff t-crtstuff-pic t-libgcc-pic"
;;
! x86_64-*-elf* | x86_64-*-rtems* | x86_64-*-fuchsia*)
! tmake_file="$tmake_file t-libgcc-pic"
;;
i[34567]86-*-dragonfly*)
tmake_file="${tmake_file} i386/t-dragonfly i386/t-crtstuff"
diff -dcprN gcc-6.2.0/libstdc++-v3/configure gcc-6.2.0-fuchsia/libstdc++-v3/configure
*** gcc-6.2.0/libstdc++-v3/configure 2016-04-05 12:03:46.000000000 -0700
--- gcc-6.2.0-fuchsia/libstdc++-v3/configure 2016-10-25 16:25:08.882770549 -0700
*************** if test -z "$aix_libpath"; then aix_libp
*** 9825,9830 ****
--- 9825,9837 ----
hardcode_shlibpath_var=no
;;
+ fuchsia*)
+ archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
+ hardcode_libdir_flag_spec='-R$libdir'
+ hardcode_direct=yes
+ hardcode_shlibpath_var=no
+ ;;
+
hpux9*)
if test "$GCC" = yes; then
archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
*************** freebsd* | dragonfly*)
*** 10763,10768 ****
--- 10770,10781 ----
esac
;;
+ fuchsia*)
+ library_names_spec='${libname}${shared_ext}'
+ need_lib_prefix=no
+ need_version=no
+ ;;
+
gnu*)
version_type=linux
need_lib_prefix=no
*************** fi
*** 11372,11377 ****
--- 11385,11395 ----
;;
+ fuchsia*)
+ lt_cv_dlopen="dlopen"
+ lt_cv_dlopen_libs=
+ ;;
+
*)
ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
if test "x$ac_cv_func_shl_load" = x""yes; then :
*************** else
*** 11596,11602 ****
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
! #line 11599 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
--- 11614,11620 ----
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
! #line 11617 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
*************** else
*** 11702,11708 ****
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
! #line 11705 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
--- 11720,11726 ----
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
! #line 11723 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
*************** freebsd* | dragonfly*)
*** 14447,14452 ****
--- 14465,14476 ----
esac
;;
+ fuchsia*)
+ library_names_spec='${libname}${shared_ext}'
+ need_lib_prefix=no
+ need_version=no
+ ;;
+
gnu*)
version_type=linux
need_lib_prefix=no
*************** $as_echo "$glibcxx_cv_atomic_long_long"
*** 15388,15394 ****
# Fake what AC_TRY_COMPILE does.
cat > conftest.$ac_ext << EOF
! #line 15391 "configure"
int main()
{
typedef bool atomic_type;
--- 15412,15418 ----
# Fake what AC_TRY_COMPILE does.
cat > conftest.$ac_ext << EOF
! #line 15415 "configure"
int main()
{
typedef bool atomic_type;
*************** $as_echo "$glibcxx_cv_atomic_bool" >&6;
*** 15423,15429 ****
rm -f conftest*
cat > conftest.$ac_ext << EOF
! #line 15426 "configure"
int main()
{
typedef short atomic_type;
--- 15447,15453 ----
rm -f conftest*
cat > conftest.$ac_ext << EOF
! #line 15450 "configure"
int main()
{
typedef short atomic_type;
*************** $as_echo "$glibcxx_cv_atomic_short" >&6;
*** 15458,15464 ****
rm -f conftest*
cat > conftest.$ac_ext << EOF
! #line 15461 "configure"
int main()
{
// NB: _Atomic_word not necessarily int.
--- 15482,15488 ----
rm -f conftest*
cat > conftest.$ac_ext << EOF
! #line 15485 "configure"
int main()
{
// NB: _Atomic_word not necessarily int.
*************** $as_echo "$glibcxx_cv_atomic_int" >&6; }
*** 15494,15500 ****
rm -f conftest*
cat > conftest.$ac_ext << EOF
! #line 15497 "configure"
int main()
{
typedef long long atomic_type;
--- 15518,15524 ----
rm -f conftest*
cat > conftest.$ac_ext << EOF
! #line 15521 "configure"
int main()
{
typedef long long atomic_type;
*************** $as_echo "$as_me: WARNING: Performance o
*** 15573,15579 ****
# unnecessary for this test.
cat > conftest.$ac_ext << EOF
! #line 15576 "configure"
int main()
{
_Decimal32 d1;
--- 15597,15603 ----
# unnecessary for this test.
cat > conftest.$ac_ext << EOF
! #line 15600 "configure"
int main()
{
_Decimal32 d1;
*************** ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
*** 15615,15621 ****
# unnecessary for this test.
cat > conftest.$ac_ext << EOF
! #line 15618 "configure"
template<typename T1, typename T2>
struct same
{ typedef T2 type; };
--- 15639,15645 ----
# unnecessary for this test.
cat > conftest.$ac_ext << EOF
! #line 15642 "configure"
template<typename T1, typename T2>
struct same
{ typedef T2 type; };
*************** $as_echo "$enable_int128" >&6; }
*** 15649,15655 ****
rm -f conftest*
cat > conftest.$ac_ext << EOF
! #line 15652 "configure"
template<typename T1, typename T2>
struct same
{ typedef T2 type; };
--- 15673,15679 ----
rm -f conftest*
cat > conftest.$ac_ext << EOF
! #line 15676 "configure"
template<typename T1, typename T2>
struct same
{ typedef T2 type; };
*************** $as_echo "$ac_ld_relro" >&6; }
*** 53130,53135 ****
--- 53154,53165 ----
fi
;;
+
+ *-fuchsia*)
+ SECTION_FLAGS='-ffunction-sections -fdata-sections'
+ SECTION_LDFLAGS='-Wl,--gc-sections $SECTION_LDFLAGS'
+ ;;
+
*-hpux*)
SECTION_FLAGS='-ffunction-sections -fdata-sections'
diff -dcprN gcc-6.2.0/libstdc++-v3/crossconfig.m4 gcc-6.2.0-fuchsia/libstdc++-v3/crossconfig.m4
*** gcc-6.2.0/libstdc++-v3/crossconfig.m4 2015-10-11 15:34:28.000000000 -0700
--- gcc-6.2.0-fuchsia/libstdc++-v3/crossconfig.m4 2016-10-25 16:20:47.855807450 -0700
*************** case "${host}" in
*** 107,112 ****
--- 107,118 ----
AC_DEFINE(HAVE_ISNANL)
fi
;;
+
+ *-fuchsia*)
+ SECTION_FLAGS='-ffunction-sections -fdata-sections'
+ SECTION_LDFLAGS='-Wl,--gc-sections $SECTION_LDFLAGS'
+ ;;
+
*-hpux*)
SECTION_FLAGS='-ffunction-sections -fdata-sections'
AC_SUBST(SECTION_FLAGS)
diff -dcprN gcc-6.2.0/libtool.m4 gcc-6.2.0-fuchsia/libtool.m4
*** gcc-6.2.0/libtool.m4 2015-11-26 05:20:59.000000000 -0800
--- gcc-6.2.0-fuchsia/libtool.m4 2016-10-25 15:03:17.327232321 -0700
*************** else
*** 1748,1753 ****
--- 1748,1758 ----
])
;;
+ fuchsia*)
+ lt_cv_dlopen="dlopen"
+ lt_cv_dlopen_libs=
+ ;;
+
*)
AC_CHECK_FUNC([shl_load],
[lt_cv_dlopen="shl_load"],
*************** freebsd* | dragonfly*)
*** 2323,2328 ****
--- 2328,2339 ----
esac
;;
+ fuchsia*)
+ library_names_spec='${libname}${shared_ext}'
+ need_lib_prefix=no
+ need_version=no
+ ;;
+
gnu*)
version_type=linux
need_lib_prefix=no
*************** _LT_EOF
*** 4831,4836 ****
--- 4842,4854 ----
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
_LT_TAGVAR(hardcode_direct, $1)=yes
+ _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
+ ;;
+
+ fuchsia*)
+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
+ _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
+ _LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
diff -dcpr gcc-6.2.0-orig/gcc/config/fuchsia.h gcc-6.2.0/gcc/config/fuchsia.h
*** gcc-6.2.0-orig/gcc/config/fuchsia.h 2016-11-14 16:41:03.688822073 -0800
--- gcc-6.2.0/gcc/config/fuchsia.h 2016-11-15 15:41:41.047289495 -0800
*************** along with GCC; see the file COPYING3.
*** 47,49 ****
--- 47,53 ----
"%{shared: -shared}" \
"%{!shared:%{!static:%{!dynamic-linker: -dynamic-linker=ld.so.1}}}"
+ /* We are using MUSL as our libc. */
+ #undef OPTION_MUSL
+ #define OPTION_MUSL 1
+
diff -dcpr gcc-6.2.0-orig/gcc/config.gcc gcc-6.2.0/gcc/config.gcc
*** gcc-6.2.0-orig/gcc/config.gcc 2016-11-14 16:41:05.332815117 -0800
--- gcc-6.2.0/gcc/config.gcc 2016-11-15 15:42:09.055176481 -0800
*************** case ${target} in
*** 907,913 ****
esac
case ${target} in
! aarch64*-*-elf | aarch64*-*-rtems*)
tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h"
tm_file="${tm_file} aarch64/aarch64-elf.h aarch64/aarch64-elf-raw.h"
tmake_file="${tmake_file} aarch64/t-aarch64"
--- 907,913 ----
esac
case ${target} in
! aarch64*-*-elf | aarch64*-*-fuchsia* | aarch64*-*-rtems*)
tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h"
tm_file="${tm_file} aarch64/aarch64-elf.h aarch64/aarch64-elf-raw.h"
tmake_file="${tmake_file} aarch64/t-aarch64"
*************** aarch64*-*-elf | aarch64*-*-rtems*)
*** 915,920 ****
--- 915,923 ----
aarch64-*-elf*)
use_gcc_stdint=wrap
;;
+ aarch64-*-fuchsia*)
+ tm_file="${tm_file} fuchsia.h"
+ ;;
aarch64-*-rtems*)
tm_file="${tm_file} rtems.h aarch64/rtems.h"
;;
*************** arm*-*-uclinux*eabi*) # ARM ucLinux
*** 1097,1103 ****
# The EABI requires the use of __cxa_atexit.
default_use_cxa_atexit=yes
;;
! arm*-*-eabi* | arm*-*-symbianelf* | arm*-*-rtems*)
case ${target} in
arm*eb-*-eabi*)
tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1"
--- 1100,1106 ----
# The EABI requires the use of __cxa_atexit.
default_use_cxa_atexit=yes
;;
! arm*-*-eabi* | arm*-*-symbianelf* | arm*-*-rtems* | arm*-*-fuchsia*)
case ${target} in
arm*eb-*-eabi*)
tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1"
*************** arm*-*-eabi* | arm*-*-symbianelf* | arm*
*** 1111,1116 ****
--- 1114,1122 ----
tmake_file="${tmake_file} arm/t-bpabi"
use_gcc_stdint=wrap
;;
+ arm*-*-fuchsia*)
+ tm_file="${tm_file} fuchsia.h glibc-stdint.h"
+ ;;
arm*-*-rtems*)
tm_file="${tm_file} rtems.h arm/rtems.h newlib-stdint.h"
tmake_file="${tmake_file} arm/t-bpabi arm/t-rtems"
diff -dcpr gcc-6.2.0-orig/libgcc/config.host gcc-6.2.0/libgcc/config.host
*** gcc-6.2.0-orig/libgcc/config.host 2016-11-14 16:41:05.536814253 -0800
--- gcc-6.2.0/libgcc/config.host 2016-11-15 08:48:35.813137073 -0800
*************** aarch64*-*-elf | aarch64*-*-rtems*)
*** 336,341 ****
--- 336,345 ----
tmake_file="${tmake_file} ${cpu_type}/t-aarch64"
tmake_file="${tmake_file} ${cpu_type}/t-softfp t-softfp t-crtfm"
;;
+ aarch64*-*-fuchsia*)
+ tmake_file="${tmake_file} ${cpu_type}/t-aarch64"
+ tmake_file="${tmake_file} ${cpu_type}/t-softfp t-softfp"
+ ;;
aarch64*-*-linux*)
extra_parts="$extra_parts crtfastmath.o"
md_unwind_header=aarch64/linux-unwind.h
*************** arm*-*-freebsd*) # ARM Fr
*** 386,391 ****
--- 390,399 ----
unwind_header=config/arm/unwind-arm.h
tmake_file="${tmake_file} t-softfp-sfdf t-softfp-excl arm/t-softfp t-softfp"
;;
+ arm*-*-fuchsia*)
+ tmake_file="${tmake_file} arm/t-arm arm/t-elf"
+ tmake_file="${tmake_file} arm/tsoftfp t-softfp"
+ ;;
arm*-*-netbsdelf*)
tmake_file="$tmake_file arm/t-arm arm/t-netbsd t-slibgcc-gld-nover"
;;