fake mknative, mostly enough to build real for mknative. trunk
authormrg <mrg@NetBSD.org>
Wed, 17 Apr 2019 08:56:10 +0000
branchtrunk
changeset 450541 902c25c1e79e
parent 450540 a3cfa94917c9
child 450542 c4aac29e1d95
fake mknative, mostly enough to build real for mknative.
external/gpl3/gcc/lib/libgcc/arch/riscv32/defs.mk
external/gpl3/gcc/lib/libgomp/arch/riscv32/config.h
external/gpl3/gcc/lib/libgomp/arch/riscv32/omp.h
external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/c++config.h
external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/cxxabi_tweaks.h
external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/defs.mk
external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/gstdint.h
external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/symver-config.h
external/gpl3/gcc/usr.bin/gcc/arch/riscv32/auto-host.h
external/gpl3/gcc/usr.bin/gcc/arch/riscv32/tm.h
external/lgpl3/gmp/lib/libgmp/arch/riscv32/Makefile.inc
external/lgpl3/gmp/lib/libgmp/arch/riscv32/gmp.h
--- a/external/gpl3/gcc/lib/libgcc/arch/riscv32/defs.mk	Wed Apr 17 07:55:33 2019 +0000
+++ b/external/gpl3/gcc/lib/libgcc/arch/riscv32/defs.mk	Wed Apr 17 08:56:10 2019 +0000
@@ -4,7 +4,7 @@
 #
 G_INCLUDES=-I. -I. -I../.././gcc -I${GNUHOSTDIST}/libgcc -I${GNUHOSTDIST}/libgcc/. -I${GNUHOSTDIST}/libgcc/../gcc -I${GNUHOSTDIST}/libgcc/../include 
 G_INTERNAL_CFLAGS=-g -O2 -O2  -g -O2 -DIN_GCC  -DCROSS_DIRECTORY_STRUCTURE  -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include   -fPIC -g -DIN_LIBGCC2 -fbuilding-libgcc -fno-stack-protector   -fPIC -I. -I. -I../.././gcc -I${GNUHOSTDIST}/libgcc -I${GNUHOSTDIST}/libgcc/. -I${GNUHOSTDIST}/libgcc/../gcc -I${GNUHOSTDIST}/libgcc/../include  -DHAVE_CC_TLS 
-G_LIB2ADD= enable-execute-stack.c
+G_LIB2ADD= ${GNUHOSTDIST}/libgcc/soft-fp/addtf3.c ${GNUHOSTDIST}/libgcc/soft-fp/divtf3.c ${GNUHOSTDIST}/libgcc/soft-fp/eqtf2.c ${GNUHOSTDIST}/libgcc/soft-fp/getf2.c ${GNUHOSTDIST}/libgcc/soft-fp/letf2.c ${GNUHOSTDIST}/libgcc/soft-fp/multf3.c ${GNUHOSTDIST}/libgcc/soft-fp/negtf2.c ${GNUHOSTDIST}/libgcc/soft-fp/subtf3.c ${GNUHOSTDIST}/libgcc/soft-fp/unordtf2.c ${GNUHOSTDIST}/libgcc/soft-fp/fixtfsi.c ${GNUHOSTDIST}/libgcc/soft-fp/fixunstfsi.c ${GNUHOSTDIST}/libgcc/soft-fp/floatsitf.c ${GNUHOSTDIST}/libgcc/soft-fp/floatunsitf.c ${GNUHOSTDIST}/libgcc/soft-fp/extendsftf2.c ${GNUHOSTDIST}/libgcc/soft-fp/extenddftf2.c ${GNUHOSTDIST}/libgcc/soft-fp/trunctfsf2.c ${GNUHOSTDIST}/libgcc/soft-fp/trunctfdf2.c enable-execute-stack.c
 G_LIB2ADDEH=${GNUHOSTDIST}/libgcc/unwind-dw2.c ${GNUHOSTDIST}/libgcc/unwind-dw2-fde-dip.c ${GNUHOSTDIST}/libgcc/unwind-sjlj.c ${GNUHOSTDIST}/libgcc/unwind-c.c ${GNUHOSTDIST}/libgcc/emutls.c
 G_LIB2ADD_ST=
 G_LIB1ASMFUNCS=
--- a/external/gpl3/gcc/lib/libgomp/arch/riscv32/config.h	Wed Apr 17 07:55:33 2019 +0000
+++ b/external/gpl3/gcc/lib/libgomp/arch/riscv32/config.h	Wed Apr 17 08:56:10 2019 +0000
@@ -1,6 +1,6 @@
 /* This file is automatically generated.  DO NOT EDIT! */
-/* Generated from: NetBSD: mknative-gcc,v 1.79 2014/05/29 16:27:50 skrll Exp  */
-/* Generated from: NetBSD: mknative.common,v 1.11 2014/02/17 21:39:43 christos Exp  */
+/* Generated from: NetBSD: mknative-gcc,v 1.100 2019/02/09 03:57:00 mrg Exp  */
+/* Generated from: NetBSD: mknative.common,v 1.16 2018/04/15 15:13:37 christos Exp  */
 
 /* config.h.  Generated from config.h.in by configure.  */
 /* config.h.in.  Generated from configure.ac by autoheader.  */
@@ -29,18 +29,39 @@
 /* Define to 1 if you have the <dlfcn.h> header file. */
 #define HAVE_DLFCN_H 1
 
+/* Define to 1 if you have the `getegid' function. */
+#define HAVE_GETEGID 1
+
+/* Define to 1 if you have the `geteuid' function. */
+#define HAVE_GETEUID 1
+
+/* Define to 1 if you have the `getgid' function. */
+#define HAVE_GETGID 1
+
 /* Define to 1 if you have the `getloadavg' function. */
 #define HAVE_GETLOADAVG 1
 
+/* Define to 1 if you have the `getuid' function. */
+#define HAVE_GETUID 1
+
 /* Define to 1 if you have the <inttypes.h> header file. */
 #define HAVE_INTTYPES_H 1
 
+/* Define to 1 if you have the `dl' library (-ldl). */
+/* #undef HAVE_LIBDL */
+
 /* Define to 1 if you have the <memory.h> header file. */
 #define HAVE_MEMORY_H 1
 
 /* Define if pthread_{,attr_}{g,s}etaffinity_np is supported. */
 /* #undef HAVE_PTHREAD_AFFINITY_NP */
 
+/* Define to 1 if you have the <pthread.h> header file. */
+#define HAVE_PTHREAD_H 1
+
+/* Define to 1 if you have the `secure_getenv' function. */
+/* #undef HAVE_SECURE_GETENV */
+
 /* Define to 1 if you have the <semaphore.h> header file. */
 #define HAVE_SEMAPHORE_H 1
 
@@ -59,9 +80,12 @@
 /* Define to 1 if you have the `strtoull' function. */
 #define HAVE_STRTOULL 1
 
+/* Define to 1 if the system has the type `struct _Mutex_Control'. */
+/* #undef HAVE_STRUCT__MUTEX_CONTROL */
+
 /* Define to 1 if the target runtime linker supports binding the same symbol
    to different versions. */
-/* #undef HAVE_SYMVER_SYMBOL_RENAMING_RUNTIME_SUPPORT */
+#define HAVE_SYMVER_SYMBOL_RENAMING_RUNTIME_SUPPORT 1
 
 /* Define to 1 if the target supports __sync_*_compare_and_swap */
 #define HAVE_SYNC_BUILTINS 1
@@ -72,6 +96,9 @@
 /* Define to 1 if you have the <sys/stat.h> header file. */
 #define HAVE_SYS_STAT_H 1
 
+/* Define to 1 if you have the <sys/sysctl.h> header file. */
+#define HAVE_SYS_SYSCTL_H 1
+
 /* Define to 1 if you have the <sys/time.h> header file. */
 #define HAVE_SYS_TIME_H 1
 
@@ -84,13 +111,28 @@
 /* Define to 1 if you have the <unistd.h> header file. */
 #define HAVE_UNISTD_H 1
 
+/* Define to 1 if you have the `__secure_getenv' function. */
+/* #undef HAVE___SECURE_GETENV */
+
+/* Define path to HSA runtime. */
+#define HSA_RUNTIME_LIB ""
+
 /* Define to 1 if GNU symbol versioning is used for libgomp. */
-/* #undef LIBGOMP_GNU_SYMBOL_VERSIONING */
+#define LIBGOMP_GNU_SYMBOL_VERSIONING 1
+
+/* Define to 1 if building libgomp for an accelerator-only target. */
+/* #undef LIBGOMP_OFFLOADED_ONLY */
+
+/* Define to 1 if libgomp should use POSIX threads. */
+#define LIBGOMP_USE_PTHREADS 1
 
 /* Define to the sub-directory in which libtool stores uninstalled libraries.
    */
 #define LT_OBJDIR ".libs/"
 
+/* Define to offload targets, separated by commas. */
+#define OFFLOAD_TARGETS ""
+
 /* Name of package */
 #define PACKAGE "libgomp"
 
@@ -98,10 +140,10 @@
 #define PACKAGE_BUGREPORT ""
 
 /* Define to the full name of this package. */
-#define PACKAGE_NAME "GNU OpenMP Runtime Library"
+#define PACKAGE_NAME "GNU Offloading and Multi Processing Runtime Library"
 
 /* Define to the full name and version of this package. */
-#define PACKAGE_STRING "GNU OpenMP Runtime Library 1.0"
+#define PACKAGE_STRING "GNU Offloading and Multi Processing Runtime Library 1.0"
 
 /* Define to the one symbol short name of this package. */
 #define PACKAGE_TARNAME "libgomp"
@@ -112,6 +154,19 @@
 /* Define to the version of this package. */
 #define PACKAGE_VERSION "1.0"
 
+/* Define to 1 if the HSA plugin is built, 0 if not. */
+#define PLUGIN_HSA 0
+
+/* Define to 1 if the NVIDIA plugin is built, 0 if not. */
+#define PLUGIN_NVPTX 0
+
+/* Define to 1 if the NVIDIA plugin should dlopen libcuda.so.1, 0 if it should
+   be linked against it. */
+#define PLUGIN_NVPTX_DYNAMIC 0
+
+/* Define if all infrastructure, needed for plugins, is supported. */
+/* #undef PLUGIN_SUPPORT */
+
 /* The size of `char', as computed by sizeof. */
 /* #undef SIZEOF_CHAR */
 
@@ -136,5 +191,8 @@
 /* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
 #define TIME_WITH_SYS_TIME 1
 
+/* Define to 1 if the target use emutls for thread-local storage. */
+/* #undef USE_EMUTLS */
+
 /* Version number of package */
 #define VERSION "1.0"
--- a/external/gpl3/gcc/lib/libgomp/arch/riscv32/omp.h	Wed Apr 17 07:55:33 2019 +0000
+++ b/external/gpl3/gcc/lib/libgomp/arch/riscv32/omp.h	Wed Apr 17 08:56:10 2019 +0000
@@ -1,11 +1,12 @@
 /* This file is automatically generated.  DO NOT EDIT! */
-/* Generated from: NetBSD: mknative-gcc,v 1.79 2014/05/29 16:27:50 skrll Exp  */
-/* Generated from: NetBSD: mknative.common,v 1.11 2014/02/17 21:39:43 christos Exp  */
+/* Generated from: NetBSD: mknative-gcc,v 1.94 2018/09/04 22:57:25 mrg Exp  */
+/* Generated from: NetBSD: mknative.common,v 1.16 2018/04/15 15:13:37 christos Exp  */
 
-/* Copyright (C) 2005-2013 Free Software Foundation, Inc.
+/* Copyright (C) 2005-2017 Free Software Foundation, Inc.
    Contributed by Richard Henderson <rth@redhat.com>.
 
-   This file is part of the GNU OpenMP Library (libgomp).
+   This file is part of the GNU Offloading and Multi Processing Library
+   (libgomp).
 
    Libgomp is free software; you can redistribute it and/or modify it
    under the terms of the GNU General Public License as published by
@@ -26,8 +27,8 @@
    see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
    <http://www.gnu.org/licenses/>.  */
 
-#ifndef OMP_H
-#define OMP_H 1
+#ifndef _OMP_H
+#define _OMP_H 1
 
 #ifndef _LIBGOMP_OMP_LOCK_DEFINED
 #define _LIBGOMP_OMP_LOCK_DEFINED 1
@@ -37,14 +38,14 @@
 
 typedef struct
 {
-  unsigned char _x[4] 
-    __attribute__((__aligned__(4)));
+  unsigned char _x[8] 
+    __attribute__((__aligned__(8)));
 } omp_lock_t;
 
 typedef struct
 {
-  unsigned char _x[12] 
-    __attribute__((__aligned__(4)));
+  unsigned char _x[24] 
+    __attribute__((__aligned__(8)));
 } omp_nest_lock_t;
 #endif
 
@@ -56,6 +57,24 @@
   omp_sched_auto = 4
 } omp_sched_t;
 
+typedef enum omp_proc_bind_t
+{
+  omp_proc_bind_false = 0,
+  omp_proc_bind_true = 1,
+  omp_proc_bind_master = 2,
+  omp_proc_bind_close = 3,
+  omp_proc_bind_spread = 4
+} omp_proc_bind_t;
+
+typedef enum omp_lock_hint_t
+{
+  omp_lock_hint_none = 0,
+  omp_lock_hint_uncontended = 1,
+  omp_lock_hint_contended = 2,
+  omp_lock_hint_nonspeculative = 4,
+  omp_lock_hint_speculative = 8,
+} omp_lock_hint_t;
+
 #ifdef __cplusplus
 extern "C" {
 # define __GOMP_NOTHROW throw ()
@@ -78,12 +97,16 @@
 extern int omp_get_nested (void) __GOMP_NOTHROW;
 
 extern void omp_init_lock (omp_lock_t *) __GOMP_NOTHROW;
+extern void omp_init_lock_with_hint (omp_lock_t *, omp_lock_hint_t)
+  __GOMP_NOTHROW;
 extern void omp_destroy_lock (omp_lock_t *) __GOMP_NOTHROW;
 extern void omp_set_lock (omp_lock_t *) __GOMP_NOTHROW;
 extern void omp_unset_lock (omp_lock_t *) __GOMP_NOTHROW;
 extern int omp_test_lock (omp_lock_t *) __GOMP_NOTHROW;
 
 extern void omp_init_nest_lock (omp_nest_lock_t *) __GOMP_NOTHROW;
+extern void omp_init_nest_lock_with_hint (omp_nest_lock_t *, omp_lock_hint_t)
+  __GOMP_NOTHROW;
 extern void omp_destroy_nest_lock (omp_nest_lock_t *) __GOMP_NOTHROW;
 extern void omp_set_nest_lock (omp_nest_lock_t *) __GOMP_NOTHROW;
 extern void omp_unset_nest_lock (omp_nest_lock_t *) __GOMP_NOTHROW;
@@ -92,20 +115,55 @@
 extern double omp_get_wtime (void) __GOMP_NOTHROW;
 extern double omp_get_wtick (void) __GOMP_NOTHROW;
 
-void omp_set_schedule (omp_sched_t, int) __GOMP_NOTHROW;
-void omp_get_schedule (omp_sched_t *, int *) __GOMP_NOTHROW;
-int omp_get_thread_limit (void) __GOMP_NOTHROW;
-void omp_set_max_active_levels (int) __GOMP_NOTHROW;
-int omp_get_max_active_levels (void) __GOMP_NOTHROW;
-int omp_get_level (void) __GOMP_NOTHROW;
-int omp_get_ancestor_thread_num (int) __GOMP_NOTHROW;
-int omp_get_team_size (int) __GOMP_NOTHROW;
-int omp_get_active_level (void) __GOMP_NOTHROW;
+extern void omp_set_schedule (omp_sched_t, int) __GOMP_NOTHROW;
+extern void omp_get_schedule (omp_sched_t *, int *) __GOMP_NOTHROW;
+extern int omp_get_thread_limit (void) __GOMP_NOTHROW;
+extern void omp_set_max_active_levels (int) __GOMP_NOTHROW;
+extern int omp_get_max_active_levels (void) __GOMP_NOTHROW;
+extern int omp_get_level (void) __GOMP_NOTHROW;
+extern int omp_get_ancestor_thread_num (int) __GOMP_NOTHROW;
+extern int omp_get_team_size (int) __GOMP_NOTHROW;
+extern int omp_get_active_level (void) __GOMP_NOTHROW;
+
+extern int omp_in_final (void) __GOMP_NOTHROW;
+
+extern int omp_get_cancellation (void) __GOMP_NOTHROW;
+extern omp_proc_bind_t omp_get_proc_bind (void) __GOMP_NOTHROW;
+extern int omp_get_num_places (void) __GOMP_NOTHROW;
+extern int omp_get_place_num_procs (int) __GOMP_NOTHROW;
+extern void omp_get_place_proc_ids (int, int *) __GOMP_NOTHROW;
+extern int omp_get_place_num (void) __GOMP_NOTHROW;
+extern int omp_get_partition_num_places (void) __GOMP_NOTHROW;
+extern void omp_get_partition_place_nums (int *) __GOMP_NOTHROW;
 
-int omp_in_final (void) __GOMP_NOTHROW;
+extern void omp_set_default_device (int) __GOMP_NOTHROW;
+extern int omp_get_default_device (void) __GOMP_NOTHROW;
+extern int omp_get_num_devices (void) __GOMP_NOTHROW;
+extern int omp_get_num_teams (void) __GOMP_NOTHROW;
+extern int omp_get_team_num (void) __GOMP_NOTHROW;
+
+extern int omp_is_initial_device (void) __GOMP_NOTHROW;
+extern int omp_get_initial_device (void) __GOMP_NOTHROW;
+extern int omp_get_max_task_priority (void) __GOMP_NOTHROW;
+
+extern void *omp_target_alloc (__SIZE_TYPE__, int) __GOMP_NOTHROW;
+extern void omp_target_free (void *, int) __GOMP_NOTHROW;
+extern int omp_target_is_present (void *, int) __GOMP_NOTHROW;
+extern int omp_target_memcpy (void *, void *, __SIZE_TYPE__, __SIZE_TYPE__,
+			      __SIZE_TYPE__, int, int) __GOMP_NOTHROW;
+extern int omp_target_memcpy_rect (void *, void *, __SIZE_TYPE__, int,
+				   const __SIZE_TYPE__ *,
+				   const __SIZE_TYPE__ *,
+				   const __SIZE_TYPE__ *,
+				   const __SIZE_TYPE__ *,
+				   const __SIZE_TYPE__ *, int, int)
+  __GOMP_NOTHROW;
+extern int omp_target_associate_ptr (void *, void *, __SIZE_TYPE__,
+				     __SIZE_TYPE__, int) __GOMP_NOTHROW;
+extern int omp_target_disassociate_ptr (void *, int) __GOMP_NOTHROW;
 
 #ifdef __cplusplus
 }
 #endif
 
-#endif /* OMP_H */
+#endif /* _OMP_H */
--- a/external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/c++config.h	Wed Apr 17 07:55:33 2019 +0000
+++ b/external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/c++config.h	Wed Apr 17 08:56:10 2019 +0000
@@ -1,10 +1,10 @@
 /* This file is automatically generated.  DO NOT EDIT! */
-/* Generated from: NetBSD: mknative-gcc,v 1.79 2014/05/29 16:27:50 skrll Exp  */
-/* Generated from: NetBSD: mknative.common,v 1.11 2014/02/17 21:39:43 christos Exp  */
+/* Generated from: NetBSD: mknative-gcc,v 1.101 2019/02/23 06:54:45 mrg Exp  */
+/* Generated from: NetBSD: mknative.common,v 1.16 2018/04/15 15:13:37 christos Exp  */
 
 // Predefined symbols and macros -*- C++ -*-
 
-// Copyright (C) 1997-2013 Free Software Foundation, Inc.
+// Copyright (C) 1997-2017 Free Software Foundation, Inc.
 //
 // This file is part of the GNU ISO C++ Library.  This library is free
 // software; you can redistribute it and/or modify it under the
@@ -34,8 +34,11 @@
 #ifndef _GLIBCXX_CXX_CONFIG_H
 #define _GLIBCXX_CXX_CONFIG_H 1
 
-// The current version of the C++ library in compressed ISO date format.
-#define __GLIBCXX__ 20141219
+// The major release number for the GCC release the C++ library belongs to.
+#define _GLIBCXX_RELEASE 7
+
+// The datestamp of the C++ library in compressed ISO date format.
+#define __GLIBCXX__ 20181206
 
 // Macros for various attributes.
 //   _GLIBCXX_PURE
@@ -107,14 +110,40 @@
 # endif
 #endif
 
+#ifndef _GLIBCXX14_CONSTEXPR
+# if __cplusplus >= 201402L
+#  define _GLIBCXX14_CONSTEXPR constexpr
+# else
+#  define _GLIBCXX14_CONSTEXPR
+# endif
+#endif
+
+#ifndef _GLIBCXX17_CONSTEXPR
+# if __cplusplus > 201402L
+#  define _GLIBCXX17_CONSTEXPR constexpr
+# else
+#  define _GLIBCXX17_CONSTEXPR
+# endif
+#endif
+
+#ifndef _GLIBCXX17_INLINE
+# if __cplusplus > 201402L
+#  define _GLIBCXX17_INLINE inline
+# else
+#  define _GLIBCXX17_INLINE
+# endif
+#endif
+
 // Macro for noexcept, to support in mixed 03/0x mode.
 #ifndef _GLIBCXX_NOEXCEPT
 # if __cplusplus >= 201103L
 #  define _GLIBCXX_NOEXCEPT noexcept
+#  define _GLIBCXX_NOEXCEPT_IF(_COND) noexcept(_COND)
 #  define _GLIBCXX_USE_NOEXCEPT noexcept
 #  define _GLIBCXX_THROW(_EXC)
 # else
 #  define _GLIBCXX_NOEXCEPT
+#  define _GLIBCXX_NOEXCEPT_IF(_COND)
 #  define _GLIBCXX_USE_NOEXCEPT throw()
 #  define _GLIBCXX_THROW(_EXC) throw(_EXC)
 # endif
@@ -125,14 +154,22 @@
 #endif
 
 #ifndef _GLIBCXX_THROW_OR_ABORT
-# if __EXCEPTIONS
+# if __cpp_exceptions
 #  define _GLIBCXX_THROW_OR_ABORT(_EXC) (throw (_EXC))
 # else
 #  define _GLIBCXX_THROW_OR_ABORT(_EXC) (__builtin_abort())
 # endif
 #endif
 
-// Macro for extern template, ie controling template linkage via use
+#if __cpp_noexcept_function_type
+#define _GLIBCXX_NOEXCEPT_PARM , bool _NE
+#define _GLIBCXX_NOEXCEPT_QUAL noexcept (_NE)
+#else
+#define _GLIBCXX_NOEXCEPT_PARM
+#define _GLIBCXX_NOEXCEPT_QUAL
+#endif
+
+// Macro for extern template, ie controlling template linkage via use
 // of extern keyword on template declaration. As documented in the g++
 // manual, it inhibits all implicit instantiations and is used
 // throughout the library to avoid multiple weak definitions for
@@ -154,7 +191,9 @@
     namespace __profile { }
     namespace __cxx1998 { }
 
-    namespace __detail { }
+    namespace __detail {
+      namespace __variant { }				// C++17
+    }
 
     namespace rel_ops { }
 
@@ -169,10 +208,16 @@
     
     namespace decimal { }
 
-    namespace chrono { }
-    namespace placeholders { }
-    namespace regex_constants { }
-    namespace this_thread { }
+    namespace chrono { }				// C++11
+    namespace placeholders { }				// C++11
+    namespace regex_constants { }			// C++11
+    namespace this_thread { }				// C++11
+    inline namespace literals {				// C++14
+      inline namespace chrono_literals { }		// C++14
+      inline namespace complex_literals { }		// C++14
+      inline namespace string_literals { }		// C++14
+      inline namespace string_view_literals { }		// C++17
+    }
   }
 
   namespace abi { }
@@ -195,6 +240,37 @@
 #endif
 }
 
+# define _GLIBCXX_USE_DUAL_ABI 1
+
+#if ! _GLIBCXX_USE_DUAL_ABI
+// Ignore any pre-defined value of _GLIBCXX_USE_CXX11_ABI
+# undef _GLIBCXX_USE_CXX11_ABI
+#endif
+
+#ifndef _GLIBCXX_USE_CXX11_ABI
+# define _GLIBCXX_USE_CXX11_ABI 1
+#endif
+
+#if _GLIBCXX_USE_CXX11_ABI
+namespace std
+{
+  inline namespace __cxx11 __attribute__((__abi_tag__ ("cxx11"))) { }
+}
+namespace __gnu_cxx
+{
+  inline namespace __cxx11 __attribute__((__abi_tag__ ("cxx11"))) { }
+}
+# define _GLIBCXX_NAMESPACE_CXX11 __cxx11::
+# define _GLIBCXX_BEGIN_NAMESPACE_CXX11 namespace __cxx11 {
+# define _GLIBCXX_END_NAMESPACE_CXX11 }
+# define _GLIBCXX_DEFAULT_ABI_TAG _GLIBCXX_ABI_TAG_CXX11
+#else
+# define _GLIBCXX_NAMESPACE_CXX11
+# define _GLIBCXX_BEGIN_NAMESPACE_CXX11
+# define _GLIBCXX_END_NAMESPACE_CXX11
+# define _GLIBCXX_DEFAULT_ABI_TAG
+#endif
+
 
 // Defined if inline namespaces are used for versioning.
 # define _GLIBCXX_INLINE_VERSION 0 
@@ -221,12 +297,30 @@
 
   namespace decimal { inline namespace __7 { } }
 
+#if __cplusplus >= 201103L
   namespace chrono { inline namespace __7 { } }
   namespace placeholders { inline namespace __7 { } }
   namespace regex_constants { inline namespace __7 { } }
   namespace this_thread { inline namespace __7 { } }
 
-  namespace __detail { inline namespace __7 { } }
+#if __cplusplus >= 201402L
+  inline namespace literals {
+    inline namespace chrono_literals { inline namespace __7 { } }
+    inline namespace complex_literals { inline namespace __7 { } }
+    inline namespace string_literals { inline namespace __7 { } }
+#if __cplusplus > 201402L
+    inline namespace string_view_literals { inline namespace __7 { } }
+#endif // C++17
+  }
+#endif // C++14
+#endif // C++11
+
+  namespace __detail {
+    inline namespace __7 { }
+#if __cplusplus > 201402L
+    namespace __variant { inline namespace __7 { } }
+#endif
+  }
 }
 
 namespace __gnu_cxx
@@ -250,9 +344,13 @@
   // Non-inline namespace for components replaced by alternates in active mode.
   namespace __cxx1998
   {
-#if _GLIBCXX_INLINE_VERSION
- inline namespace __7 { }
-#endif
+# if _GLIBCXX_INLINE_VERSION
+  inline namespace __7 { }
+# endif
+
+# if _GLIBCXX_USE_CXX11_ABI
+  inline namespace __cxx11 __attribute__((__abi_tag__ ("cxx11"))) { }
+# endif
   }
 
   // Inline namespace for debug mode.
@@ -305,8 +403,10 @@
 	 namespace _GLIBCXX_STD_C { _GLIBCXX_BEGIN_NAMESPACE_VERSION
 # define _GLIBCXX_END_NAMESPACE_CONTAINER \
 	 _GLIBCXX_END_NAMESPACE_VERSION }
-# undef _GLIBCXX_EXTERN_TEMPLATE
-# define _GLIBCXX_EXTERN_TEMPLATE -1
+#else
+# define _GLIBCXX_STD_C std
+# define _GLIBCXX_BEGIN_NAMESPACE_CONTAINER _GLIBCXX_BEGIN_NAMESPACE_VERSION
+# define _GLIBCXX_END_NAMESPACE_CONTAINER _GLIBCXX_END_NAMESPACE_VERSION
 #endif
 
 #ifdef _GLIBCXX_PARALLEL
@@ -315,30 +415,10 @@
 	 namespace _GLIBCXX_STD_A { _GLIBCXX_BEGIN_NAMESPACE_VERSION
 # define _GLIBCXX_END_NAMESPACE_ALGO \
 	 _GLIBCXX_END_NAMESPACE_VERSION }
-#endif
-
-#ifndef _GLIBCXX_STD_A
+#else
 # define _GLIBCXX_STD_A std
-#endif
-
-#ifndef _GLIBCXX_STD_C
-# define _GLIBCXX_STD_C std
-#endif
-
-#ifndef _GLIBCXX_BEGIN_NAMESPACE_ALGO
-# define _GLIBCXX_BEGIN_NAMESPACE_ALGO
-#endif
-
-#ifndef _GLIBCXX_END_NAMESPACE_ALGO
-# define _GLIBCXX_END_NAMESPACE_ALGO
-#endif
-
-#ifndef _GLIBCXX_BEGIN_NAMESPACE_CONTAINER
-# define _GLIBCXX_BEGIN_NAMESPACE_CONTAINER
-#endif
-
-#ifndef _GLIBCXX_END_NAMESPACE_CONTAINER
-# define _GLIBCXX_END_NAMESPACE_CONTAINER
+# define _GLIBCXX_BEGIN_NAMESPACE_ALGO _GLIBCXX_BEGIN_NAMESPACE_VERSION
+# define _GLIBCXX_END_NAMESPACE_ALGO _GLIBCXX_END_NAMESPACE_VERSION
 #endif
 
 // GLIBCXX_ABI Deprecated
@@ -359,11 +439,30 @@
 # define _GLIBCXX_BEGIN_NAMESPACE_LDBL
 # define _GLIBCXX_END_NAMESPACE_LDBL
 #endif
+#if _GLIBCXX_USE_CXX11_ABI
+# define _GLIBCXX_NAMESPACE_LDBL_OR_CXX11 _GLIBCXX_NAMESPACE_CXX11
+# define _GLIBCXX_BEGIN_NAMESPACE_LDBL_OR_CXX11 _GLIBCXX_BEGIN_NAMESPACE_CXX11
+# define _GLIBCXX_END_NAMESPACE_LDBL_OR_CXX11 _GLIBCXX_END_NAMESPACE_CXX11
+#else
+# define _GLIBCXX_NAMESPACE_LDBL_OR_CXX11 _GLIBCXX_NAMESPACE_LDBL
+# define _GLIBCXX_BEGIN_NAMESPACE_LDBL_OR_CXX11 _GLIBCXX_BEGIN_NAMESPACE_LDBL
+# define _GLIBCXX_END_NAMESPACE_LDBL_OR_CXX11 _GLIBCXX_END_NAMESPACE_LDBL
+#endif
+
+// Debug Mode implies checking assertions.
+#if defined(_GLIBCXX_DEBUG) && !defined(_GLIBCXX_ASSERTIONS)
+# define _GLIBCXX_ASSERTIONS 1
+#endif
+
+// Disable std::string explicit instantiation declarations in order to assert.
+#ifdef _GLIBCXX_ASSERTIONS
+# undef _GLIBCXX_EXTERN_TEMPLATE
+# define _GLIBCXX_EXTERN_TEMPLATE -1
+#endif
 
 // Assert.
-#if !defined(_GLIBCXX_DEBUG) && !defined(_GLIBCXX_PARALLEL)
-# define __glibcxx_assert(_Condition)
-#else
+#if defined(_GLIBCXX_ASSERTIONS) \
+  || defined(_GLIBCXX_PARALLEL) || defined(_GLIBCXX_PARALLEL_ASSERTIONS)
 namespace std
 {
   // Avoid the use of assert, because we're trying to keep the <cassert>
@@ -377,7 +476,7 @@
     __builtin_abort();
   }
 }
-#define __glibcxx_assert(_Condition)				   	 \
+#define __glibcxx_assert_impl(_Condition)				 \
   do 									 \
   {							      		 \
     if (! (_Condition))                                                  \
@@ -386,6 +485,12 @@
   } while (false)
 #endif
 
+#if defined(_GLIBCXX_ASSERTIONS)
+# define __glibcxx_assert(_Condition) __glibcxx_assert_impl(_Condition)
+#else
+# define __glibcxx_assert(_Condition)
+#endif
+
 // Macros for race detectors.
 // _GLIBCXX_SYNCHRONIZATION_HAPPENS_BEFORE(A) and
 // _GLIBCXX_SYNCHRONIZATION_HAPPENS_AFTER(A) should be used to explain
@@ -418,6 +523,8 @@
 # define _GLIBCXX_BEGIN_EXTERN_C extern "C" {
 # define _GLIBCXX_END_EXTERN_C }
 
+# define _GLIBCXX_USE_ALLOCATOR_NEW 1
+
 #else // !__cplusplus
 # define _GLIBCXX_BEGIN_EXTERN_C
 # define _GLIBCXX_END_EXTERN_C
@@ -445,6 +552,35 @@
 # define _GLIBCXX_WEAK_DEFINITION
 #endif
 
+// By default, we assume that __GXX_WEAK__ also means that there is support
+// for declaring functions as weak while not defining such functions.  This
+// allows for referring to functions provided by other libraries (e.g.,
+// libitm) without depending on them if the respective features are not used.
+#ifndef _GLIBCXX_USE_WEAK_REF
+# define _GLIBCXX_USE_WEAK_REF __GXX_WEAK__
+#endif
+
+// Conditionally enable annotations for the Transactional Memory TS on C++11.
+// Most of the following conditions are due to limitations in the current
+// implementation.
+#if __cplusplus >= 201103L && _GLIBCXX_USE_CXX11_ABI			\
+  && _GLIBCXX_USE_DUAL_ABI && __cpp_transactional_memory >= 201505L	\
+  &&  !_GLIBCXX_FULLY_DYNAMIC_STRING && _GLIBCXX_USE_WEAK_REF		\
+  && _GLIBCXX_USE_ALLOCATOR_NEW
+#define _GLIBCXX_TXN_SAFE transaction_safe
+#define _GLIBCXX_TXN_SAFE_DYN transaction_safe_dynamic
+#else
+#define _GLIBCXX_TXN_SAFE
+#define _GLIBCXX_TXN_SAFE_DYN
+#endif
+
+#if __cplusplus > 201402L
+// In C++17 mathematical special functions are in namespace std.
+# define _GLIBCXX_USE_STD_SPEC_FUNCS 1
+#elif __cplusplus >= 201103L && __STDCPP_WANT_MATH_SPEC_FUNCS__ != 0
+// For C++11 and C++14 they are in namespace std when requested.
+# define _GLIBCXX_USE_STD_SPEC_FUNCS 1
+#endif
 
 // The remainder of the prewritten config is automatic; all the
 // user hooks are listed above.
@@ -466,6 +602,47 @@
 #undef min
 #undef max
 
+// N.B. these _GLIBCXX_USE_C99_XXX macros are defined unconditionally
+// so they should be tested with #if not with #ifdef.
+#if __cplusplus >= 201103L
+# ifndef _GLIBCXX_USE_C99_MATH
+#  define _GLIBCXX_USE_C99_MATH _GLIBCXX11_USE_C99_MATH
+# endif
+# ifndef _GLIBCXX_USE_C99_COMPLEX
+# define _GLIBCXX_USE_C99_COMPLEX _GLIBCXX11_USE_C99_COMPLEX
+# endif
+# ifndef _GLIBCXX_USE_C99_STDIO
+# define _GLIBCXX_USE_C99_STDIO _GLIBCXX11_USE_C99_STDIO
+# endif
+# ifndef _GLIBCXX_USE_C99_STDLIB
+# define _GLIBCXX_USE_C99_STDLIB _GLIBCXX11_USE_C99_STDLIB
+# endif
+# ifndef _GLIBCXX_USE_C99_WCHAR
+# define _GLIBCXX_USE_C99_WCHAR _GLIBCXX11_USE_C99_WCHAR
+# endif
+#else
+# ifndef _GLIBCXX_USE_C99_MATH
+#  define _GLIBCXX_USE_C99_MATH _GLIBCXX98_USE_C99_MATH
+# endif
+# ifndef _GLIBCXX_USE_C99_COMPLEX
+# define _GLIBCXX_USE_C99_COMPLEX _GLIBCXX98_USE_C99_COMPLEX
+# endif
+# ifndef _GLIBCXX_USE_C99_STDIO
+# define _GLIBCXX_USE_C99_STDIO _GLIBCXX98_USE_C99_STDIO
+# endif
+# ifndef _GLIBCXX_USE_C99_STDLIB
+# define _GLIBCXX_USE_C99_STDLIB _GLIBCXX98_USE_C99_STDLIB
+# endif
+# ifndef _GLIBCXX_USE_C99_WCHAR
+# define _GLIBCXX_USE_C99_WCHAR _GLIBCXX98_USE_C99_WCHAR
+# endif
+#endif
+
+/* Define if __float128 is supported on this host. */
+#if defined(__FLOAT128__) || defined(__SIZEOF_FLOAT128__)
+#undef _GLIBCXX_USE_FLOAT128
+#endif
+
 // End of prewritten config; the settings discovered at configure time follow.
 /* config.h.  Generated from config.h.in by configure.  */
 /* config.h.in.  Generated from configure.ac by autoheader.  */
@@ -476,6 +653,9 @@
 /* Define to 1 if you have the `acosl' function. */
 #define _GLIBCXX_HAVE_ACOSL 1
 
+/* Define to 1 if you have the `aligned_alloc' function. */
+#define _GLIBCXX_HAVE_ALIGNED_ALLOC 1
+
 /* Define to 1 if you have the `asinf' function. */
 #define _GLIBCXX_HAVE_ASINF 1
 
@@ -524,6 +704,9 @@
 /* Define to 1 if you have the `cosl' function. */
 #define _GLIBCXX_HAVE_COSL 1
 
+/* Define to 1 if you have the <dirent.h> header file. */
+#define _GLIBCXX_HAVE_DIRENT_H 1
+
 /* Define to 1 if you have the <dlfcn.h> header file. */
 #define _GLIBCXX_HAVE_DLFCN_H 1
 
@@ -540,7 +723,7 @@
 #define _GLIBCXX_HAVE_EIDRM 1
 
 /* Define to 1 if you have the <endian.h> header file. */
-/* #undef _GLIBCXX_HAVE_ENDIAN_H */
+#define _GLIBCXX_HAVE_ENDIAN_H 1
 
 /* Define if ENODATA exists. */
 #define _GLIBCXX_HAVE_ENODATA 1
@@ -587,6 +770,9 @@
 /* Define if EWOULDBLOCK exists. */
 #define _GLIBCXX_HAVE_EWOULDBLOCK 1
 
+/* Define to 1 if GCC 4.6 supported std::exception_ptr for the target */
+#define _GLIBCXX_HAVE_EXCEPTION_PTR_SINCE_GCC46 1
+
 /* Define to 1 if you have the <execinfo.h> header file. */
 #define _GLIBCXX_HAVE_EXECINFO_H 1
 
@@ -602,6 +788,9 @@
 /* Define to 1 if you have the `fabsl' function. */
 #define _GLIBCXX_HAVE_FABSL 1
 
+/* Define to 1 if you have the <fcntl.h> header file. */
+#define _GLIBCXX_HAVE_FCNTL_H 1
+
 /* Define to 1 if you have the <fenv.h> header file. */
 #define _GLIBCXX_HAVE_FENV_H 1
 
@@ -639,12 +828,12 @@
 #define _GLIBCXX_HAVE_FREXPF 1
 
 /* Define to 1 if you have the `frexpl' function. */
-/* #undef _GLIBCXX_HAVE_FREXPL */
+#define _GLIBCXX_HAVE_FREXPL 1
 
 /* Define if _Unwind_GetIPInfo is available. */
 #define _GLIBCXX_HAVE_GETIPINFO 1
 
-/* Define if gets is available in <stdio.h>. */
+/* Define if gets is available in <stdio.h> before C++14. */
 #define _GLIBCXX_HAVE_GETS 1
 
 /* Define to 1 if you have the `hypot' function. */
@@ -666,10 +855,10 @@
 #define _GLIBCXX_HAVE_INT64_T 1
 
 /* Define if int64_t is a long. */
-/* #undef _GLIBCXX_HAVE_INT64_T_LONG */
+#define _GLIBCXX_HAVE_INT64_T_LONG 1
 
 /* Define if int64_t is a long long. */
-#define _GLIBCXX_HAVE_INT64_T_LONG_LONG 1
+/* #undef _GLIBCXX_HAVE_INT64_T_LONG_LONG */
 
 /* Define to 1 if you have the <inttypes.h> header file. */
 #define _GLIBCXX_HAVE_INTTYPES_H 1
@@ -702,7 +891,7 @@
 #define _GLIBCXX_HAVE_LDEXPF 1
 
 /* Define to 1 if you have the `ldexpl' function. */
-/* #undef _GLIBCXX_HAVE_LDEXPL */
+#define _GLIBCXX_HAVE_LDEXPL 1
 
 /* Define to 1 if you have the <libintl.h> header file. */
 /* #undef _GLIBCXX_HAVE_LIBINTL_H */
@@ -749,6 +938,9 @@
 /* Define if mbstate_t exists in wchar.h. */
 #define _GLIBCXX_HAVE_MBSTATE_T 1
 
+/* Define to 1 if you have the `memalign' function. */
+/* #undef _GLIBCXX_HAVE_MEMALIGN */
+
 /* Define to 1 if you have the <memory.h> header file. */
 #define _GLIBCXX_HAVE_MEMORY_H 1
 
@@ -764,9 +956,18 @@
 /* Define to 1 if you have the <nan.h> header file. */
 /* #undef _GLIBCXX_HAVE_NAN_H */
 
+/* Define if <math.h> defines obsolete isinf function. */
+/* #undef _GLIBCXX_HAVE_OBSOLETE_ISINF */
+
+/* Define if <math.h> defines obsolete isnan function. */
+/* #undef _GLIBCXX_HAVE_OBSOLETE_ISNAN */
+
 /* Define if poll is available in <poll.h>. */
 #define _GLIBCXX_HAVE_POLL 1
 
+/* Define to 1 if you have the `posix_memalign' function. */
+#define _GLIBCXX_HAVE_POSIX_MEMALIGN 1
+
 /* Define to 1 if you have the `powf' function. */
 #define _GLIBCXX_HAVE_POWF 1
 
@@ -813,7 +1014,7 @@
 #define _GLIBCXX_HAVE_SQRTL 1
 
 /* Define to 1 if you have the <stdalign.h> header file. */
-/* #undef _GLIBCXX_HAVE_STDALIGN_H */
+#define _GLIBCXX_HAVE_STDALIGN_H 1
 
 /* Define to 1 if you have the <stdbool.h> header file. */
 #define _GLIBCXX_HAVE_STDBOOL_H 1
@@ -842,12 +1043,15 @@
 /* Define to 1 if you have the `strtold' function. */
 #define _GLIBCXX_HAVE_STRTOLD 1
 
+/* Define to 1 if `d_type' is a member of `struct dirent'. */
+#define _GLIBCXX_HAVE_STRUCT_DIRENT_D_TYPE 1
+
 /* Define if strxfrm_l is available in <string.h>. */
 /* #undef _GLIBCXX_HAVE_STRXFRM_L */
 
 /* Define to 1 if the target runtime linker supports binding the same symbol
    to different versions. */
-/* #undef _GLIBCXX_HAVE_SYMVER_SYMBOL_RENAMING_RUNTIME_SUPPORT */
+#define _GLIBCXX_HAVE_SYMVER_SYMBOL_RENAMING_RUNTIME_SUPPORT 1
 
 /* Define to 1 if you have the <sys/filio.h> header file. */
 #define _GLIBCXX_HAVE_SYS_FILIO_H 1
@@ -876,6 +1080,9 @@
 /* Define to 1 if you have the <sys/sem.h> header file. */
 #define _GLIBCXX_HAVE_SYS_SEM_H 1
 
+/* Define to 1 if you have the <sys/statvfs.h> header file. */
+#define _GLIBCXX_HAVE_SYS_STATVFS_H 1
+
 /* Define to 1 if you have the <sys/stat.h> header file. */
 #define _GLIBCXX_HAVE_SYS_STAT_H 1
 
@@ -894,7 +1101,7 @@
 /* Define if S_IFREG is available in <sys/stat.h>. */
 /* #undef _GLIBCXX_HAVE_S_IFREG */
 
-/* Define if S_IFREG is available in <sys/stat.h>. */
+/* Define if S_ISREG is available in <sys/stat.h>. */
 #define _GLIBCXX_HAVE_S_ISREG 1
 
 /* Define to 1 if you have the `tanf' function. */
@@ -915,12 +1122,18 @@
 /* Define to 1 if the target supports thread-local storage. */
 #define _GLIBCXX_HAVE_TLS 1
 
+/* Define to 1 if you have the <uchar.h> header file. */
+/* #undef _GLIBCXX_HAVE_UCHAR_H */
+
 /* Define to 1 if you have the <unistd.h> header file. */
 #define _GLIBCXX_HAVE_UNISTD_H 1
 
 /* Defined if usleep exists. */
 /* #undef _GLIBCXX_HAVE_USLEEP */
 
+/* Define to 1 if you have the <utime.h> header file. */
+#define _GLIBCXX_HAVE_UTIME_H 1
+
 /* Defined if vfwscanf exists. */
 #define _GLIBCXX_HAVE_VFWSCANF 1
 
@@ -951,6 +1164,9 @@
 /* Define to 1 if you have the `_acosl' function. */
 /* #undef _GLIBCXX_HAVE__ACOSL */
 
+/* Define to 1 if you have the `_aligned_malloc' function. */
+/* #undef _GLIBCXX_HAVE__ALIGNED_MALLOC */
+
 /* Define to 1 if you have the `_asinf' function. */
 /* #undef _GLIBCXX_HAVE__ASINF */
 
@@ -1131,6 +1347,9 @@
 /* Define to 1 if you have the `_tanl' function. */
 /* #undef _GLIBCXX_HAVE__TANL */
 
+/* Define to 1 if you have the `__cxa_thread_atexit' function. */
+#define _GLIBCXX_HAVE___CXA_THREAD_ATEXIT 1
+
 /* Define to 1 if you have the `__cxa_thread_atexit_impl' function. */
 #define _GLIBCXX_HAVE___CXA_THREAD_ATEXIT_IMPL 1
 
@@ -1183,8 +1402,50 @@
 /* Version number of package */
 /* #undef _GLIBCXX_VERSION */
 
+/* Define if C99 functions in <complex.h> should be used in <complex> for
+   C++11. Using compiler builtins for these functions requires corresponding
+   C99 library functions to be present. */
+#define _GLIBCXX11_USE_C99_COMPLEX 1
+
+/* Define if C99 functions or macros in <math.h> should be imported in <cmath>
+   in namespace std for C++11. */
+#define _GLIBCXX11_USE_C99_MATH 1
+
+/* Define if C99 functions or macros in <stdio.h> should be imported in
+   <cstdio> in namespace std for C++11. */
+#define _GLIBCXX11_USE_C99_STDIO 1
+
+/* Define if C99 functions or macros in <stdlib.h> should be imported in
+   <cstdlib> in namespace std for C++11. */
+#define _GLIBCXX11_USE_C99_STDLIB 1
+
+/* Define if C99 functions or macros in <wchar.h> should be imported in
+   <cwchar> in namespace std for C++11. */
+#define _GLIBCXX11_USE_C99_WCHAR 1
+
+/* Define if C99 functions in <complex.h> should be used in <complex> for
+   C++98. Using compiler builtins for these functions requires corresponding
+   C99 library functions to be present. */
+#define _GLIBCXX98_USE_C99_COMPLEX 1
+
+/* Define if C99 functions or macros in <math.h> should be imported in <cmath>
+   in namespace std for C++98. */
+#define _GLIBCXX98_USE_C99_MATH 1
+
+/* Define if C99 functions or macros in <stdio.h> should be imported in
+   <cstdio> in namespace std for C++98. */
+#define _GLIBCXX98_USE_C99_STDIO 1
+
+/* Define if C99 functions or macros in <stdlib.h> should be imported in
+   <cstdlib> in namespace std for C++98. */
+#define _GLIBCXX98_USE_C99_STDLIB 1
+
+/* Define if C99 functions or macros in <wchar.h> should be imported in
+   <cwchar> in namespace std for C++98. */
+#define _GLIBCXX98_USE_C99_WCHAR 1
+
 /* Define if the compiler supports C++11 atomics. */
-/* #undef _GLIBCXX_ATOMIC_BUILTINS */
+#define _GLIBCXX_ATOMIC_BUILTINS 1
 
 /* Define to use concept checking code from the boost libraries. */
 /* #undef _GLIBCXX_CONCEPT_CHECKS */
@@ -1201,6 +1462,12 @@
 
 /* Define if compatibility should be provided for -mlong-double-64. */
 
+/* Define to the letter to which size_t is mangled. */
+#define _GLIBCXX_MANGLE_SIZE_T m
+
+/* Define if C99 llrint and llround functions are missing from <math.h>. */
+/* #undef _GLIBCXX_NO_C99_ROUNDING_FUNCS */
+
 /* Define if ptrdiff_t is int. */
 /* #undef _GLIBCXX_PTRDIFF_T_IS_INT */
 
@@ -1210,9 +1477,6 @@
 /* Define if size_t is unsigned int. */
 /* #undef _GLIBCXX_SIZE_T_IS_UINT */
 
-/* Define if the compiler is configured for setjmp/longjmp exceptions. */
-/* #undef _GLIBCXX_SJLJ_EXCEPTIONS */
-
 /* Define to the value of the EOF integer constant. */
 #define _GLIBCXX_STDIO_EOF -1
 
@@ -1223,13 +1487,13 @@
 #define _GLIBCXX_STDIO_SEEK_END 2
 
 /* Define to use symbol versioning in the shared library. */
-/* #undef _GLIBCXX_SYMVER */
+#define _GLIBCXX_SYMVER 1
 
 /* Define to use darwin versioning in the shared library. */
 /* #undef _GLIBCXX_SYMVER_DARWIN */
 
 /* Define to use GNU versioning in the shared library. */
-/* #undef _GLIBCXX_SYMVER_GNU */
+#define _GLIBCXX_SYMVER_GNU 1
 
 /* Define to use GNU namespace versioning in the shared library. */
 /* #undef _GLIBCXX_SYMVER_GNU_NAMESPACE */
@@ -1237,15 +1501,14 @@
 /* Define to use Sun versioning in the shared library. */
 /* #undef _GLIBCXX_SYMVER_SUN */
 
+/* Define if C11 functions in <uchar.h> should be imported into namespace std
+   in <cuchar>. */
+/* #undef _GLIBCXX_USE_C11_UCHAR_CXX11 */
+
 /* Define if C99 functions or macros from <wchar.h>, <math.h>, <complex.h>,
    <stdio.h>, and <stdlib.h> can be used or exposed. */
 #define _GLIBCXX_USE_C99 1
 
-/* Define if C99 functions in <complex.h> should be used in <complex>. Using
-   compiler builtins for these functions requires corresponding C99 library
-   functions to be present. */
-#define _GLIBCXX_USE_C99_COMPLEX 1
-
 /* Define if C99 functions in <complex.h> should be used in <tr1/complex>.
    Using compiler builtins for these functions requires corresponding C99
    library functions to be present. */
@@ -1257,7 +1520,7 @@
 
 /* Define if C99 functions in <fenv.h> should be imported in <tr1/cfenv> in
    namespace std::tr1. */
-/* #undef _GLIBCXX_USE_C99_FENV_TR1 */
+#define _GLIBCXX_USE_C99_FENV_TR1 1
 
 /* Define if C99 functions in <inttypes.h> should be imported in
    <tr1/cinttypes> in namespace std::tr1. */
@@ -1267,10 +1530,6 @@
    <tr1/cinttypes> in namespace std::tr1. */
 #define _GLIBCXX_USE_C99_INTTYPES_WCHAR_T_TR1 1
 
-/* Define if C99 functions or macros in <math.h> should be imported in <cmath>
-   in namespace std. */
-#define _GLIBCXX_USE_C99_MATH 1
-
 /* Define if C99 functions or macros in <math.h> should be imported in
    <tr1/cmath> in namespace std::tr1. */
 #define _GLIBCXX_USE_C99_MATH_TR1 1
@@ -1279,12 +1538,13 @@
    namespace std::tr1. */
 #define _GLIBCXX_USE_C99_STDINT_TR1 1
 
+/* Defined if clock_gettime syscall has monotonic and realtime clock support.
+   */
+/* #undef _GLIBCXX_USE_CLOCK_GETTIME_SYSCALL */
+
 /* Defined if clock_gettime has monotonic clock support. */
 #define _GLIBCXX_USE_CLOCK_MONOTONIC 1
 
-/* Defined if clock_gettime syscall has monotonic and realtime clock support. */
-/* #undef _GLIBCXX_USE_CLOCK_GETTIME_SYSCALL */
-
 /* Defined if clock_gettime has realtime clock support. */
 #define _GLIBCXX_USE_CLOCK_REALTIME 1
 
@@ -1292,8 +1552,11 @@
    this host. */
 /* #undef _GLIBCXX_USE_DECIMAL_FLOAT */
 
-/* Define if __float128 is supported on this host. */
-/* #undef _GLIBCXX_USE_FLOAT128 */
+/* Define if fchmod is available in <sys/stat.h>. */
+#define _GLIBCXX_USE_FCHMOD 1
+
+/* Define if fchmodat is available in <sys/stat.h>. */
+#define _GLIBCXX_USE_FCHMODAT 1
 
 /* Defined if gettimeofday is available. */
 #define _GLIBCXX_USE_GETTIMEOFDAY 1
@@ -1302,7 +1565,7 @@
 /* #undef _GLIBCXX_USE_GET_NPROCS */
 
 /* Define if __int128 is supported on this host. */
-/* #undef _GLIBCXX_USE_INT128 */
+/* #define _GLIBCXX_USE_INT128 1 */
 
 /* Define if LFS support is available. */
 /* #undef _GLIBCXX_USE_LFS */
@@ -1319,10 +1582,16 @@
 /* Define if pthreads_num_processors_np is available in <pthread.h>. */
 /* #undef _GLIBCXX_USE_PTHREADS_NUM_PROCESSORS_NP */
 
+/* Define if POSIX read/write locks are available in <gthr.h>. */
+#define _GLIBCXX_USE_PTHREAD_RWLOCK_T 1
+
 /* Define if /dev/random and /dev/urandom are available for the random_device
    of TR1 (Chapter 5.1). */
 #define _GLIBCXX_USE_RANDOM_TR1 1
 
+/* Define if usable realpath is available in <stdlib.h>. */
+/* #undef _GLIBCXX_USE_REALPATH */
+
 /* Defined if sched_yield is available. */
 #define _GLIBCXX_USE_SCHED_YIELD 1
 
@@ -1332,9 +1601,22 @@
 /* Define if _SC_NPROC_ONLN is available in <unistd.h>. */
 /* #undef _GLIBCXX_USE_SC_NPROC_ONLN */
 
+/* Define if sendfile is available in <sys/sendfile.h>. */
+/* #undef _GLIBCXX_USE_SENDFILE */
+
+/* Define if struct stat has timespec members. */
+#define _GLIBCXX_USE_ST_MTIM 1
+
 /* Define if sysctl(), CTL_HW and HW_NCPU are available in <sys/sysctl.h>. */
 #define _GLIBCXX_USE_SYSCTL_HW_NCPU 1
 
+/* Define if obsolescent tmpnam is available in <stdio.h>. */
+#define _GLIBCXX_USE_TMPNAM 1
+
+/* Define if utimensat and UTIME_OMIT are available in <sys/stat.h> and
+   AT_FDCWD in <fcntl.h>. */
+#define _GLIBCXX_USE_UTIMENSAT 1
+
 /* Define if code specialized for wchar_t should be used. */
 #define _GLIBCXX_USE_WCHAR_T 1
 
@@ -1347,6 +1629,16 @@
 /* Define to 1 if mutex_timedlock is available. */
 #define _GTHREAD_USE_MUTEX_TIMEDLOCK 0
 
+/* Define if all C++11 floating point overloads are available in <math.h>.  */
+#if __cplusplus >= 201103L
+/* #undef __CORRECT_ISO_CPP11_MATH_H_PROTO_FP */
+#endif
+
+/* Define if all C++11 integral type overloads are available in <math.h>.  */
+#if __cplusplus >= 201103L
+/* #undef __CORRECT_ISO_CPP11_MATH_H_PROTO_INT */
+#endif
+
 #if defined (_GLIBCXX_HAVE__ACOSF) && ! defined (_GLIBCXX_HAVE_ACOSF)
 # define _GLIBCXX_HAVE_ACOSF 1
 # define acosf _acosf
--- a/external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/cxxabi_tweaks.h	Wed Apr 17 07:55:33 2019 +0000
+++ b/external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/cxxabi_tweaks.h	Wed Apr 17 08:56:10 2019 +0000
@@ -1,10 +1,10 @@
 /* This file is automatically generated.  DO NOT EDIT! */
-/* Generated from: NetBSD: mknative-gcc,v 1.79 2014/05/29 16:27:50 skrll Exp  */
-/* Generated from: NetBSD: mknative.common,v 1.11 2014/02/17 21:39:43 christos Exp  */
+/* Generated from: NetBSD: mknative-gcc,v 1.101 2019/02/23 06:54:45 mrg Exp  */
+/* Generated from: NetBSD: mknative.common,v 1.16 2018/04/15 15:13:37 christos Exp  */
 
 // Control various target specific ABI tweaks.  Generic version.
 
-// Copyright (C) 2004-2013 Free Software Foundation, Inc.
+// Copyright (C) 2004-2017 Free Software Foundation, Inc.
 //
 // This file is part of the GNU ISO C++ Library.  This library is free
 // software; you can redistribute it and/or modify it under the
@@ -37,7 +37,7 @@
 #ifdef __cplusplus
 namespace __cxxabiv1
 {
-  extern "C" 
+  extern "C"
   {
 #endif
 
@@ -60,4 +60,4 @@
 } // namespace __cxxabiv1
 #endif
 
-#endif 
+#endif
--- a/external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/defs.mk	Wed Apr 17 07:55:33 2019 +0000
+++ b/external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/defs.mk	Wed Apr 17 08:56:10 2019 +0000
@@ -2,14 +2,21 @@
 # Generated from: NetBSD: mknative-gcc,v 1.79 2014/05/29 16:27:50 skrll Exp 
 # Generated from: NetBSD: mknative.common,v 1.11 2014/02/17 21:39:43 christos Exp 
 #
-G_LIBSUPCXX_SOURCES=array_type_info.cc atexit_arm.cc atexit_thread.cc bad_alloc.cc bad_cast.cc bad_typeid.cc class_type_info.cc del_op.cc del_opnt.cc del_opv.cc del_opvnt.cc dyncast.cc eh_alloc.cc eh_arm.cc eh_aux_runtime.cc eh_call.cc eh_catch.cc eh_exception.cc eh_globals.cc eh_personality.cc eh_ptr.cc eh_term_handler.cc eh_terminate.cc eh_tm.cc eh_throw.cc eh_type.cc eh_unex_handler.cc enum_type_info.cc function_type_info.cc fundamental_type_info.cc guard.cc guard_error.cc hash_bytes.cc nested_exception.cc new_handler.cc new_op.cc new_opnt.cc new_opv.cc new_opvnt.cc pbase_type_info.cc pmem_type_info.cc pointer_type_info.cc pure.cc si_class_type_info.cc tinfo.cc tinfo2.cc vec.cc vmi_class_type_info.cc vterminate.cc
+G_port_specific_symbol_files=
+G_cxx11_sources=compatibility-c++0x.cc compatibility-atomic-c++0x.cc compatibility-thread-c++0x.cc compatibility-chrono.cc compatibility-condvar.cc
+G_cxx98_sources=compatibility.cc compatibility-debug_list.cc compatibility-debug_list-2.cc 
+G_cxx98_sources=compatibility-debug_list.cc compatibility-debug_list-2.cc 
+G_LIBSUPCXX_SOURCES=array_type_info.cc atexit_arm.cc atexit_thread.cc bad_alloc.cc bad_array_length.cc bad_array_new.cc bad_cast.cc bad_typeid.cc class_type_info.cc del_op.cc del_ops.cc del_opnt.cc del_opv.cc del_opvs.cc del_opvnt.cc dyncast.cc eh_alloc.cc eh_arm.cc eh_aux_runtime.cc eh_call.cc eh_catch.cc eh_exception.cc eh_globals.cc eh_personality.cc eh_ptr.cc eh_term_handler.cc eh_terminate.cc eh_tm.cc eh_throw.cc eh_type.cc eh_unex_handler.cc enum_type_info.cc function_type_info.cc fundamental_type_info.cc guard.cc guard_error.cc hash_bytes.cc nested_exception.cc new_handler.cc new_op.cc new_opnt.cc new_opv.cc new_opvnt.cc new_opa.cc new_opant.cc new_opva.cc new_opvant.cc del_opa.cc del_opant.cc del_opsa.cc del_opva.cc del_opvant.cc del_opvsa.cc pbase_type_info.cc pmem_type_info.cc pointer_type_info.cc pure.cc si_class_type_info.cc tinfo.cc tinfo2.cc vec.cc vmi_class_type_info.cc vterminate.cc
 G_LIBSUPCXX_C_SOURCES=cp-demangle.c
-G_c_base_headers=cassert ccomplex cctype cerrno cfenv cfloat cinttypes ciso646 climits clocale cmath csetjmp csignal cstdalign cstdarg cstdbool cstddef cstdint cstdio cstdlib cstring ctgmath ctime cwchar cwctype
-G_std_headers=algorithm array atomic bitset chrono complex condition_variable deque forward_list fstream functional future iomanip ios iosfwd iostream istream iterator limits list locale map memory mutex numeric ostream queue random ratio regex scoped_allocator set sstream stack stdexcept streambuf string system_error thread tuple typeindex type_traits unordered_map unordered_set utility valarray vector
-G_SRC_SOURCES=compatibility.cc compatibility-debug_list.cc compatibility-debug_list-2.cc   compatibility-c++0x.cc compatibility-atomic-c++0x.cc compatibility-thread-c++0x.cc compatibility-chrono.cc
-G_CPP11_SOURCES=chrono.cc condition_variable.cc debug.cc functexcept.cc functional.cc future.cc hash_c++0x.cc hashtable_c++0x.cc limits.cc mutex.cc placeholders.cc random.cc regex.cc shared_ptr.cc system_error.cc thread.cc  fstream-inst.cc string-inst.cc wstring-inst.cc
-G_CPP98_SOURCES=bitmap_allocator.cc pool_allocator.cc mt_allocator.cc codecvt.cc complex_io.cc ctype.cc globals_io.cc hash_tr1.cc hashtable_tr1.cc ios.cc ios_failure.cc ios_init.cc ios_locale.cc list.cc list-aux.cc list-aux-2.cc list_associated.cc list_associated-2.cc locale.cc locale_init.cc locale_facets.cc localename.cc math_stubs_float.cc math_stubs_long_double.cc stdexcept.cc strstream.cc tree.cc istream.cc streambuf.cc valarray.cc atomicity.cc codecvt_members.cc collate_members.cc ctype_configure_char.cc ctype_members.cc messages_members.cc monetary_members.cc numeric_members.cc time_members.cc basic_file.cc c++locale.cc allocator-inst.cc concept-inst.cc ext-inst.cc ios-inst.cc iostream-inst.cc istream-inst.cc locale-inst.cc misc-inst.cc ostream-inst.cc sstream-inst.cc streambuf-inst.cc wlocale-inst.cc parallel_settings.cc
-G_ATOMICITY_SRCDIR=config/cpu/generic/atomicity_mutex
+G_c_base_headers=cassert ccomplex cctype cerrno cfenv cfloat cinttypes ciso646 climits clocale cmath csetjmp csignal cstdalign cstdarg cstdbool cstddef cstdint cstdio cstdlib cstring ctgmath ctime cuchar cwchar cwctype
+G_std_headers=algorithm any array atomic bitset chrono codecvt complex condition_variable deque forward_list fstream functional future iomanip ios iosfwd iostream istream iterator limits list locale map memory mutex numeric optional ostream queue random ratio regex scoped_allocator set shared_mutex sstream stack stdexcept streambuf string string_view system_error thread tuple typeindex type_traits unordered_map unordered_set utility valarray variant vector
+G_SRC_SOURCES=compatibility.cc compatibility-debug_list.cc compatibility-debug_list-2.cc  compatibility-c++0x.cc compatibility-atomic-c++0x.cc compatibility-thread-c++0x.cc compatibility-chrono.cc compatibility-condvar.cc
+G_SRC_SOURCES=compatibility-debug_list.cc compatibility-debug_list-2.cc  compatibility-c++0x.cc compatibility-atomic-c++0x.cc compatibility-thread-c++0x.cc compatibility-chrono.cc compatibility-condvar.cc
+G_CPP11_SOURCES=chrono.cc c11-codecvt.cc condition_variable.cc cow-stdexcept.cc ctype.cc debug.cc functexcept.cc functional.cc futex.cc future.cc hash_c++0x.cc hashtable_c++0x.cc ios.cc limits.cc mutex.cc placeholders.cc random.cc regex.cc shared_ptr.cc snprintf_lite.cc system_error.cc thread.cc cow-locale_init.cc cow-shim_facets.cc cxx11-hash_tr1.cc cxx11-ios_failure.cc cxx11-shim_facets.cc cxx11-stdexcept.cc ctype_configure_char.cc ctype_members.cc  cow-fstream-inst.cc cow-sstream-inst.cc cow-string-inst.cc cow-string-io-inst.cc cow-wstring-inst.cc cow-wstring-io-inst.cc cxx11-locale-inst.cc cxx11-wlocale-inst.cc sso_string.cc ext11-inst.cc fstream-inst.cc ios-inst.cc iostream-inst.cc istream-inst.cc locale-inst.cc ostream-inst.cc sstream-inst.cc streambuf-inst.cc string-inst.cc string-io-inst.cc wlocale-inst.cc wstring-inst.cc wstring-io-inst.cc
+G_GLIBCXX_ABI_FLAGS=-D_GLIBCXX_USE_CXX11_ABI=0
+G_CPP98_SOURCES=bitmap_allocator.cc pool_allocator.cc mt_allocator.cc c98-codecvt.cc complex_io.cc globals_io.cc hash_tr1.cc hashtable_tr1.cc ios_failure.cc ios_init.cc ios_locale.cc list.cc list-aux.cc list-aux-2.cc list_associated.cc list_associated-2.cc locale.cc locale_init.cc locale_facets.cc localename.cc math_stubs_float.cc math_stubs_long_double.cc stdexcept.cc strstream.cc tree.cc istream.cc istream-string.cc streambuf.cc valarray.cc cow-istream-string.cc collate_members_cow.cc messages_members_cow.cc monetary_members_cow.cc numeric_members_cow.cc atomicity.cc codecvt_members.cc collate_members.cc messages_members.cc monetary_members.cc numeric_members.cc time_members.cc basic_file.cc c++locale.cc allocator-inst.cc concept-inst.cc ext-inst.cc misc-inst.cc parallel_settings.cc
+G_FILESYSTEM_SOURCES=dir.cc ops.cc path.cc cow-dir.cc cow-ops.cc cow-path.cc
+G_ATOMICITY_SRCDIR=config/cpu/generic/atomicity_builtins
 G_BASIC_FILE_CC=config/io/basic_file_stdio.cc
 G_CLOCALE_CC=config/locale/generic/c_locale.cc
 G_CCODECVT_CC=config/locale/generic/codecvt_members.cc
@@ -24,10 +31,10 @@
 G_c_base_headers_extra=
 G_c_base_headers_extra_install=
 G_tr1_headers=tr1/array tr1/bessel_function.tcc tr1/beta_function.tcc tr1/ccomplex tr1/cctype tr1/cfenv tr1/cfloat tr1/cinttypes tr1/climits tr1/cmath tr1/complex tr1/complex.h tr1/cstdarg tr1/cstdbool tr1/cstdint tr1/cstdio tr1/cstdlib tr1/ctgmath tr1/ctime tr1/ctype.h tr1/cwchar tr1/cwctype tr1/ell_integral.tcc tr1/exp_integral.tcc tr1/fenv.h tr1/float.h tr1/functional tr1/functional_hash.h tr1/gamma.tcc tr1/hypergeometric.tcc tr1/hashtable.h tr1/hashtable_policy.h tr1/inttypes.h tr1/limits.h tr1/math.h tr1/memory tr1/modified_bessel_func.tcc tr1/poly_hermite.tcc tr1/poly_laguerre.tcc tr1/legendre_function.tcc tr1/random tr1/random.h tr1/random.tcc tr1/regex tr1/riemann_zeta.tcc tr1/shared_ptr.h tr1/special_function_util.h tr1/stdarg.h tr1/stdbool.h tr1/stdint.h tr1/stdio.h tr1/stdlib.h tr1/tgmath.h tr1/tuple tr1/type_traits tr1/unordered_map tr1/unordered_map.h tr1/unordered_set tr1/unordered_set.h tr1/utility tr1/wchar.h tr1/wctype.h
-G_tr2_headers=tr2/bool_set tr2/bool_set.tcc tr2/dynamic_bitset tr2/ratio tr2/type_traits
+G_tr2_headers=tr2/bool_set tr2/bool_set.tcc tr2/dynamic_bitset tr2/dynamic_bitset.tcc tr2/ratio tr2/type_traits
 G_decimal_headers=decimal/decimal decimal/decimal.h
 G_c_compatibility_headers_install=
-G_debug_headers=debug/array debug/bitset debug/debug.h debug/deque debug/formatter.h debug/forward_list debug/functions.h debug/list debug/map debug/macros.h debug/map.h debug/multimap.h debug/multiset.h debug/safe_base.h debug/safe_iterator.h debug/safe_iterator.tcc debug/safe_local_iterator.h debug/safe_local_iterator.tcc debug/safe_sequence.h debug/safe_sequence.tcc debug/safe_unordered_base.h debug/safe_unordered_container.h debug/safe_unordered_container.tcc debug/set debug/set.h debug/string debug/unordered_map debug/unordered_set debug/vector
+G_debug_headers=debug/array debug/assertions.h debug/bitset debug/debug.h debug/deque debug/formatter.h debug/forward_list debug/functions.h debug/helper_functions.h debug/list debug/map debug/macros.h debug/map.h debug/multimap.h debug/multiset.h debug/safe_base.h debug/safe_container.h debug/safe_iterator.h debug/safe_iterator.tcc debug/safe_local_iterator.h debug/safe_local_iterator.tcc debug/safe_sequence.h debug/safe_sequence.tcc debug/safe_unordered_base.h debug/safe_unordered_container.h debug/safe_unordered_container.tcc debug/set debug/set.h debug/stl_iterator.h debug/string debug/unordered_map debug/unordered_set debug/vector
 G_parallel_headers=parallel/algo.h parallel/algobase.h parallel/algorithm parallel/algorithmfwd.h parallel/balanced_quicksort.h parallel/base.h parallel/basic_iterator.h parallel/checkers.h parallel/compatibility.h parallel/compiletime_settings.h parallel/equally_split.h parallel/features.h parallel/find.h parallel/find_selectors.h parallel/for_each.h parallel/for_each_selectors.h parallel/iterator.h parallel/list_partition.h parallel/losertree.h parallel/merge.h parallel/multiseq_selection.h parallel/multiway_merge.h parallel/multiway_mergesort.h parallel/numeric parallel/numericfwd.h parallel/omp_loop.h parallel/omp_loop_static.h parallel/par_loop.h parallel/parallel.h parallel/partial_sum.h parallel/partition.h parallel/queue.h parallel/quicksort.h parallel/random_number.h parallel/random_shuffle.h parallel/search.h parallel/set_operations.h parallel/settings.h parallel/sort.h parallel/tags.h parallel/types.h parallel/unique_copy.h parallel/workstealing.h
 G_pb_headers1=ext/pb_ds/assoc_container.hpp ext/pb_ds/exception.hpp ext/pb_ds/hash_policy.hpp ext/pb_ds/list_update_policy.hpp ext/pb_ds/priority_queue.hpp ext/pb_ds/tag_and_trait.hpp ext/pb_ds/tree_policy.hpp ext/pb_ds/trie_policy.hpp ext/pb_ds/detail/branch_policy/branch_policy.hpp ext/pb_ds/detail/branch_policy/null_node_metadata.hpp ext/pb_ds/detail/branch_policy/traits.hpp ext/pb_ds/detail/binary_heap_/binary_heap_.hpp ext/pb_ds/detail/binary_heap_/const_iterator.hpp ext/pb_ds/detail/binary_heap_/point_const_iterator.hpp ext/pb_ds/detail/binary_heap_/constructors_destructor_fn_imps.hpp ext/pb_ds/detail/binary_heap_/debug_fn_imps.hpp ext/pb_ds/detail/binary_heap_/entry_cmp.hpp ext/pb_ds/detail/binary_heap_/entry_pred.hpp ext/pb_ds/detail/binary_heap_/erase_fn_imps.hpp ext/pb_ds/detail/binary_heap_/find_fn_imps.hpp ext/pb_ds/detail/binary_heap_/info_fn_imps.hpp ext/pb_ds/detail/binary_heap_/insert_fn_imps.hpp ext/pb_ds/detail/binary_heap_/iterators_fn_imps.hpp ext/pb_ds/detail/binary_heap_/policy_access_fn_imps.hpp ext/pb_ds/detail/binary_heap_/resize_policy.hpp ext/pb_ds/detail/binary_heap_/split_join_fn_imps.hpp ext/pb_ds/detail/binary_heap_/trace_fn_imps.hpp ext/pb_ds/detail/binomial_heap_base_/binomial_heap_base_.hpp ext/pb_ds/detail/binomial_heap_base_/constructors_destructor_fn_imps.hpp ext/pb_ds/detail/binomial_heap_base_/debug_fn_imps.hpp ext/pb_ds/detail/binomial_heap_base_/erase_fn_imps.hpp ext/pb_ds/detail/binomial_heap_base_/find_fn_imps.hpp ext/pb_ds/detail/binomial_heap_base_/insert_fn_imps.hpp ext/pb_ds/detail/binomial_heap_base_/split_join_fn_imps.hpp ext/pb_ds/detail/binomial_heap_/binomial_heap_.hpp ext/pb_ds/detail/binomial_heap_/constructors_destructor_fn_imps.hpp ext/pb_ds/detail/binomial_heap_/debug_fn_imps.hpp ext/pb_ds/detail/bin_search_tree_/bin_search_tree_.hpp
 G_pb_headers2=ext/pb_ds/detail/bin_search_tree_/constructors_destructor_fn_imps.hpp ext/pb_ds/detail/bin_search_tree_/debug_fn_imps.hpp ext/pb_ds/detail/bin_search_tree_/erase_fn_imps.hpp ext/pb_ds/detail/bin_search_tree_/find_fn_imps.hpp ext/pb_ds/detail/bin_search_tree_/info_fn_imps.hpp ext/pb_ds/detail/bin_search_tree_/insert_fn_imps.hpp ext/pb_ds/detail/bin_search_tree_/iterators_fn_imps.hpp ext/pb_ds/detail/bin_search_tree_/node_iterators.hpp ext/pb_ds/detail/bin_search_tree_/point_iterators.hpp ext/pb_ds/detail/bin_search_tree_/policy_access_fn_imps.hpp ext/pb_ds/detail/bin_search_tree_/r_erase_fn_imps.hpp ext/pb_ds/detail/bin_search_tree_/rotate_fn_imps.hpp ext/pb_ds/detail/bin_search_tree_/split_join_fn_imps.hpp ext/pb_ds/detail/bin_search_tree_/traits.hpp ext/pb_ds/detail/cc_hash_table_map_/cc_ht_map_.hpp ext/pb_ds/detail/cc_hash_table_map_/cmp_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/cond_key_dtor_entry_dealtor.hpp ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_no_store_hash_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/constructor_destructor_store_hash_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/debug_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/debug_no_store_hash_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/debug_store_hash_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/entry_list_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/erase_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/erase_no_store_hash_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/erase_store_hash_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/find_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/find_store_hash_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/info_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/insert_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/insert_no_store_hash_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/insert_store_hash_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/iterators_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/policy_access_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/resize_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/resize_no_store_hash_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/resize_store_hash_fn_imps.hpp ext/pb_ds/detail/cc_hash_table_map_/size_fn_imps.hpp
@@ -36,11 +43,11 @@
 G_pb_headers5=ext/pb_ds/detail/ov_tree_map_/policy_access_fn_imps.hpp ext/pb_ds/detail/ov_tree_map_/split_join_fn_imps.hpp ext/pb_ds/detail/ov_tree_map_/traits.hpp ext/pb_ds/detail/pairing_heap_/constructors_destructor_fn_imps.hpp ext/pb_ds/detail/pairing_heap_/debug_fn_imps.hpp ext/pb_ds/detail/pairing_heap_/erase_fn_imps.hpp ext/pb_ds/detail/pairing_heap_/find_fn_imps.hpp ext/pb_ds/detail/pairing_heap_/insert_fn_imps.hpp ext/pb_ds/detail/pairing_heap_/pairing_heap_.hpp ext/pb_ds/detail/pairing_heap_/split_join_fn_imps.hpp ext/pb_ds/detail/pat_trie_/constructors_destructor_fn_imps.hpp ext/pb_ds/detail/pat_trie_/debug_fn_imps.hpp ext/pb_ds/detail/pat_trie_/erase_fn_imps.hpp ext/pb_ds/detail/pat_trie_/find_fn_imps.hpp ext/pb_ds/detail/pat_trie_/info_fn_imps.hpp ext/pb_ds/detail/pat_trie_/insert_join_fn_imps.hpp ext/pb_ds/detail/pat_trie_/iterators_fn_imps.hpp ext/pb_ds/detail/pat_trie_/pat_trie_.hpp ext/pb_ds/detail/pat_trie_/pat_trie_base.hpp ext/pb_ds/detail/pat_trie_/policy_access_fn_imps.hpp ext/pb_ds/detail/pat_trie_/r_erase_fn_imps.hpp ext/pb_ds/detail/pat_trie_/rotate_fn_imps.hpp ext/pb_ds/detail/pat_trie_/split_fn_imps.hpp ext/pb_ds/detail/pat_trie_/synth_access_traits.hpp ext/pb_ds/detail/pat_trie_/trace_fn_imps.hpp ext/pb_ds/detail/pat_trie_/traits.hpp ext/pb_ds/detail/pat_trie_/update_fn_imps.hpp ext/pb_ds/detail/priority_queue_base_dispatch.hpp ext/pb_ds/detail/rb_tree_map_/constructors_destructor_fn_imps.hpp ext/pb_ds/detail/rb_tree_map_/debug_fn_imps.hpp
 G_pb_headers6=ext/pb_ds/detail/rb_tree_map_/erase_fn_imps.hpp ext/pb_ds/detail/rb_tree_map_/find_fn_imps.hpp ext/pb_ds/detail/rb_tree_map_/info_fn_imps.hpp ext/pb_ds/detail/rb_tree_map_/insert_fn_imps.hpp ext/pb_ds/detail/rb_tree_map_/node.hpp ext/pb_ds/detail/rb_tree_map_/rb_tree_.hpp ext/pb_ds/detail/rb_tree_map_/split_join_fn_imps.hpp ext/pb_ds/detail/rb_tree_map_/traits.hpp ext/pb_ds/detail/rc_binomial_heap_/constructors_destructor_fn_imps.hpp ext/pb_ds/detail/rc_binomial_heap_/debug_fn_imps.hpp ext/pb_ds/detail/rc_binomial_heap_/erase_fn_imps.hpp ext/pb_ds/detail/rc_binomial_heap_/insert_fn_imps.hpp ext/pb_ds/detail/rc_binomial_heap_/rc_binomial_heap_.hpp ext/pb_ds/detail/rc_binomial_heap_/rc.hpp ext/pb_ds/detail/rc_binomial_heap_/split_join_fn_imps.hpp ext/pb_ds/detail/rc_binomial_heap_/trace_fn_imps.hpp ext/pb_ds/detail/resize_policy/cc_hash_max_collision_check_resize_trigger_imp.hpp ext/pb_ds/detail/resize_policy/hash_exponential_size_policy_imp.hpp ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_imp.hpp ext/pb_ds/detail/resize_policy/hash_load_check_resize_trigger_size_base.hpp ext/pb_ds/detail/resize_policy/hash_prime_size_policy_imp.hpp ext/pb_ds/detail/resize_policy/hash_standard_resize_policy_imp.hpp ext/pb_ds/detail/resize_policy/sample_resize_policy.hpp ext/pb_ds/detail/resize_policy/sample_resize_trigger.hpp ext/pb_ds/detail/resize_policy/sample_size_policy.hpp ext/pb_ds/detail/splay_tree_/constructors_destructor_fn_imps.hpp ext/pb_ds/detail/splay_tree_/debug_fn_imps.hpp ext/pb_ds/detail/splay_tree_/erase_fn_imps.hpp ext/pb_ds/detail/splay_tree_/find_fn_imps.hpp ext/pb_ds/detail/splay_tree_/info_fn_imps.hpp ext/pb_ds/detail/splay_tree_/insert_fn_imps.hpp ext/pb_ds/detail/splay_tree_/node.hpp ext/pb_ds/detail/splay_tree_/splay_fn_imps.hpp ext/pb_ds/detail/splay_tree_/splay_tree_.hpp ext/pb_ds/detail/splay_tree_/split_join_fn_imps.hpp ext/pb_ds/detail/splay_tree_/traits.hpp ext/pb_ds/detail/standard_policies.hpp ext/pb_ds/detail/thin_heap_/constructors_destructor_fn_imps.hpp ext/pb_ds/detail/thin_heap_/debug_fn_imps.hpp ext/pb_ds/detail/thin_heap_/erase_fn_imps.hpp
 G_pb_headers7=ext/pb_ds/detail/thin_heap_/find_fn_imps.hpp ext/pb_ds/detail/thin_heap_/insert_fn_imps.hpp ext/pb_ds/detail/thin_heap_/split_join_fn_imps.hpp ext/pb_ds/detail/thin_heap_/thin_heap_.hpp ext/pb_ds/detail/thin_heap_/trace_fn_imps.hpp ext/pb_ds/detail/tree_policy/node_metadata_selector.hpp ext/pb_ds/detail/tree_policy/order_statistics_imp.hpp ext/pb_ds/detail/tree_policy/sample_tree_node_update.hpp ext/pb_ds/detail/tree_trace_base.hpp ext/pb_ds/detail/trie_policy/node_metadata_selector.hpp ext/pb_ds/detail/trie_policy/order_statistics_imp.hpp ext/pb_ds/detail/trie_policy/prefix_search_node_update_imp.hpp ext/pb_ds/detail/trie_policy/sample_trie_access_traits.hpp ext/pb_ds/detail/trie_policy/sample_trie_node_update.hpp ext/pb_ds/detail/trie_policy/trie_string_access_traits_imp.hpp ext/pb_ds/detail/trie_policy/trie_policy_base.hpp ext/pb_ds/detail/types_traits.hpp ext/pb_ds/detail/type_utils.hpp ext/pb_ds/detail/unordered_iterator/const_iterator.hpp ext/pb_ds/detail/unordered_iterator/point_const_iterator.hpp ext/pb_ds/detail/unordered_iterator/iterator.hpp ext/pb_ds/detail/unordered_iterator/point_iterator.hpp
-G_bits_headers=bits/algorithmfwd.h bits/alloc_traits.h bits/allocator.h bits/atomic_base.h bits/basic_ios.h bits/basic_ios.tcc bits/basic_string.h bits/basic_string.tcc bits/boost_concept_check.h bits/c++0x_warning.h bits/char_traits.h bits/codecvt.h bits/concept_check.h bits/cpp_type_traits.h bits/deque.tcc bits/forward_list.h bits/forward_list.tcc bits/fstream.tcc bits/functexcept.h bits/functional_hash.h bits/gslice.h bits/gslice_array.h bits/hashtable.h bits/hashtable_policy.h bits/indirect_array.h bits/ios_base.h bits/istream.tcc bits/list.tcc bits/locale_classes.h bits/locale_classes.tcc bits/locale_facets.h bits/locale_facets.tcc bits/locale_facets_nonio.h bits/locale_facets_nonio.tcc bits/localefwd.h bits/mask_array.h bits/memoryfwd.h bits/move.h bits/ostream.tcc bits/ostream_insert.h bits/postypes.h bits/ptr_traits.h bits/random.h bits/random.tcc bits/range_access.h bits/regex.h bits/regex_compiler.h bits/regex_constants.h  bits/regex_error.h     bits/stream_iterator.h bits/streambuf_iterator.h bits/shared_ptr.h bits/shared_ptr_base.h bits/slice_array.h bits/sstream.tcc bits/stl_algo.h bits/stl_algobase.h bits/stl_bvector.h bits/stl_construct.h bits/stl_deque.h bits/stl_function.h bits/stl_heap.h bits/stl_iterator.h bits/stl_iterator_base_funcs.h bits/stl_iterator_base_types.h bits/stl_list.h bits/stl_map.h bits/stl_multimap.h bits/stl_multiset.h bits/stl_numeric.h bits/stl_pair.h bits/stl_queue.h bits/stl_raw_storage_iter.h bits/stl_relops.h bits/stl_set.h bits/stl_stack.h bits/stl_tempbuf.h bits/stl_tree.h bits/stl_uninitialized.h bits/stl_vector.h bits/streambuf.tcc bits/stringfwd.h bits/unique_ptr.h bits/unordered_map.h bits/unordered_set.h bits/uses_allocator.h bits/valarray_array.h bits/valarray_array.tcc bits/valarray_before.h bits/valarray_after.h bits/vector.tcc
-G_ext_headers=ext/algorithm ext/alloc_traits.h ext/atomicity.h ext/array_allocator.h ext/bitmap_allocator.h ext/cast.h ext/cmath ext/codecvt_specializations.h ext/concurrence.h ext/debug_allocator.h ext/enc_filebuf.h ext/extptr_allocator.h ext/stdio_filebuf.h ext/stdio_sync_filebuf.h ext/functional ext/iterator ext/malloc_allocator.h ext/memory ext/mt_allocator.h ext/new_allocator.h ext/numeric ext/numeric_traits.h ext/pod_char_traits.h ext/pointer.h ext/pool_allocator.h ext/rb_tree ext/random ext/random.tcc ext/rope ext/ropeimpl.h ext/slist ext/string_conversions.h ext/throw_allocator.h ext/typelist.h ext/type_traits.h ext/rc_string_base.h ext/sso_string_base.h ext/vstring.h ext/vstring.tcc ext/vstring_fwd.h ext/vstring_util.h backward/hash_set backward/hash_map
+G_bits_headers=bits/algorithmfwd.h bits/alloc_traits.h bits/allocated_ptr.h bits/allocator.h bits/atomic_base.h bits/atomic_futex.h bits/basic_ios.h bits/basic_ios.tcc bits/basic_string.h bits/basic_string.tcc bits/boost_concept_check.h bits/c++0x_warning.h bits/char_traits.h bits/codecvt.h bits/concept_check.h bits/cpp_type_traits.h bits/deque.tcc bits/enable_special_members.h bits/forward_list.h bits/forward_list.tcc bits/fstream.tcc bits/functexcept.h bits/functional_hash.h bits/gslice.h bits/gslice_array.h bits/hashtable.h bits/hashtable_policy.h bits/indirect_array.h bits/invoke.h bits/ios_base.h bits/istream.tcc bits/list.tcc bits/locale_classes.h bits/locale_classes.tcc bits/locale_conv.h bits/locale_facets.h bits/locale_facets.tcc bits/locale_facets_nonio.h bits/locale_facets_nonio.tcc bits/localefwd.h bits/mask_array.h bits/specfun.h bits/memoryfwd.h bits/move.h bits/node_handle.h bits/ostream.tcc bits/ostream_insert.h bits/parse_numbers.h bits/postypes.h bits/predefined_ops.h bits/ptr_traits.h bits/quoted_string.h bits/random.h bits/random.tcc bits/range_access.h bits/refwrap.h bits/regex.h bits/regex.tcc bits/regex_constants.h bits/regex_error.h bits/regex_scanner.h bits/regex_scanner.tcc bits/regex_automaton.h bits/regex_automaton.tcc bits/regex_compiler.h bits/regex_compiler.tcc bits/regex_executor.h bits/regex_executor.tcc bits/shared_ptr.h bits/shared_ptr_atomic.h bits/shared_ptr_base.h bits/slice_array.h bits/sstream.tcc bits/std_abs.h bits/std_function.h bits/std_mutex.h bits/stl_algo.h bits/stl_algobase.h bits/stl_bvector.h bits/stl_construct.h bits/stl_deque.h bits/stl_function.h bits/stl_heap.h bits/stl_iterator.h bits/stl_iterator_base_funcs.h bits/stl_iterator_base_types.h bits/stl_list.h bits/stl_map.h bits/stl_multimap.h bits/stl_multiset.h bits/stl_numeric.h bits/stl_pair.h bits/stl_queue.h bits/stl_raw_storage_iter.h bits/stl_relops.h bits/stl_set.h bits/stl_stack.h bits/stl_tempbuf.h bits/stl_tree.h bits/stl_uninitialized.h bits/stl_vector.h bits/stream_iterator.h bits/streambuf_iterator.h bits/streambuf.tcc bits/stringfwd.h bits/string_view.tcc bits/uniform_int_dist.h bits/unique_ptr.h bits/unordered_map.h bits/unordered_set.h bits/uses_allocator.h bits/valarray_array.h bits/valarray_array.tcc bits/valarray_before.h bits/valarray_after.h bits/vector.tcc
+G_ext_headers=ext/algorithm ext/aligned_buffer.h ext/alloc_traits.h ext/atomicity.h ext/array_allocator.h ext/bitmap_allocator.h ext/cast.h ext/cmath ext/codecvt_specializations.h ext/concurrence.h ext/debug_allocator.h ext/enc_filebuf.h ext/extptr_allocator.h ext/stdio_filebuf.h ext/stdio_sync_filebuf.h ext/functional ext/iterator ext/malloc_allocator.h ext/memory ext/mt_allocator.h ext/new_allocator.h ext/numeric ext/numeric_traits.h ext/pod_char_traits.h ext/pointer.h ext/pool_allocator.h ext/rb_tree ext/random ext/random.tcc ext/rope ext/ropeimpl.h ext/slist ext/string_conversions.h ext/throw_allocator.h ext/typelist.h ext/type_traits.h ext/rc_string_base.h ext/sso_string_base.h ext/vstring.h ext/vstring.tcc ext/vstring_fwd.h ext/vstring_util.h backward/hash_set backward/hash_map
 G_host_headers=os/bsd/netbsd/ctype_base.h os/bsd/netbsd/ctype_inline.h os/bsd/netbsd/os_defines.h cpu/generic/atomic_word.h cpu/generic/cxxabi_tweaks.h cpu/generic/cpu_defines.h os/generic/error_constants.h precompiled/stdc++.h precompiled/stdtr1c++.h precompiled/extc++.h
 G_thread_host_headers=./riscv32--netbsd/bits/gthr.h ./riscv32--netbsd/bits/gthr-single.h ./riscv32--netbsd/bits/gthr-posix.h ./riscv32--netbsd/bits/gthr-default.h
-G_profile_headers=array base.h unordered_base.h unordered_map unordered_set vector bitset deque forward_list list map map.h multimap.h multiset.h set set.h iterator_tracker.h
+G_profile_headers=array base.h unordered_base.h unordered_map unordered_set vector bitset deque forward_list list map map.h multimap.h multiset.h ordered_base.h set set.h iterator_tracker.h
 G_profile_impl_headers=impl/profiler.h impl/profiler_algos.h impl/profiler_container_size.h impl/profiler_hash_func.h impl/profiler_hashtable_size.h impl/profiler_map_to_unordered_map.h impl/profiler_node.h impl/profiler_state.h impl/profiler_trace.h impl/profiler_vector_size.h impl/profiler_vector_to_list.h impl/profiler_list_to_vector.h impl/profiler_list_to_slist.h
 G_BASIC_FILE_H=config/io/basic_file_stdio.h
 G_ALLOCATOR_H=config/allocator/new_allocator_base.h
@@ -48,4 +55,3 @@
 G_CLOCALE_H=config/locale/generic/c_locale.h
 G_CMESSAGES_H=config/locale/generic/messages_members.h
 G_CTIME_H=config/locale/generic/time_members.h
-G_CONFIG_LINKS=${GNUHOSTDIST}/libgcc/enable-execute-stack-mprotect.c  enable-execute-stack.c ${GNUHOSTDIST}/libgcc/unwind-generic.h  unwind.h ${GNUHOSTDIST}/libgcc/config/no-unwind.h  md-unwind-support.h ${GNUHOSTDIST}/libgcc/config/no-sfp-machine.h  sfp-machine.h ${GNUHOSTDIST}/libgcc/gthr-posix.h  gthr-default.h 
--- a/external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/gstdint.h	Wed Apr 17 07:55:33 2019 +0000
+++ b/external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/gstdint.h	Wed Apr 17 08:56:10 2019 +0000
@@ -1,8 +1,8 @@
 /* This file is automatically generated.  DO NOT EDIT! */
-/* Generated from: NetBSD: mknative-gcc,v 1.79 2014/05/29 16:27:50 skrll Exp  */
-/* Generated from: NetBSD: mknative.common,v 1.11 2014/02/17 21:39:43 christos Exp  */
+/* Generated from: NetBSD: mknative-gcc,v 1.101 2019/02/23 06:54:45 mrg Exp  */
+/* Generated from: NetBSD: mknative.common,v 1.16 2018/04/15 15:13:37 christos Exp  */
 
-/* generated for  riscv32--netbsd-gcc (NetBSD nb1 20141012) 4.8.4 */
+/* generated for  riscv64--netbsd-gcc (NetBSD nb3 20190319) 7.4.0 */
 
 #ifndef GCC_GENERATED_STDINT_H
 #define GCC_GENERATED_STDINT_H 1
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/external/gpl3/gcc/lib/libstdc++-v3/arch/riscv32/symver-config.h	Wed Apr 17 08:56:10 2019 +0000
@@ -0,0 +1,1319 @@
+/* This file is automatically generated.  DO NOT EDIT! */
+/* Generated from: NetBSD: mknative-gcc,v 1.101 2019/02/23 06:54:45 mrg Exp  */
+/* Generated from: NetBSD: mknative.common,v 1.16 2018/04/15 15:13:37 christos Exp  */
+
+/* config.h.  Generated from config.h.in by configure.  */
+/* config.h.in.  Generated from configure.ac by autoheader.  */
+
+/* Define to 1 if you have the `acosf' function. */
+#define HAVE_ACOSF 1
+
+/* Define to 1 if you have the `acosl' function. */
+#define HAVE_ACOSL 1
+
+/* Define to 1 if you have the `aligned_alloc' function. */
+#define HAVE_ALIGNED_ALLOC 1
+
+/* Define to 1 if you have the `asinf' function. */
+#define HAVE_ASINF 1
+
+/* Define to 1 if you have the `asinl' function. */
+#define HAVE_ASINL 1
+
+/* Define to 1 if the target assembler supports .symver directive. */
+#define HAVE_AS_SYMVER_DIRECTIVE 1
+
+/* Define to 1 if you have the `atan2f' function. */
+#define HAVE_ATAN2F 1
+
+/* Define to 1 if you have the `atan2l' function. */
+#define HAVE_ATAN2L 1
+
+/* Define to 1 if you have the `atanf' function. */
+#define HAVE_ATANF 1
+
+/* Define to 1 if you have the `atanl' function. */
+#define HAVE_ATANL 1
+
+/* Define to 1 if you have the `at_quick_exit' function. */
+#define HAVE_AT_QUICK_EXIT 1
+
+/* Define to 1 if the target assembler supports thread-local storage. */
+/* #undef HAVE_CC_TLS */
+
+/* Define to 1 if you have the `ceilf' function. */
+#define HAVE_CEILF 1
+
+/* Define to 1 if you have the `ceill' function. */
+#define HAVE_CEILL 1
+
+/* Define to 1 if you have the <complex.h> header file. */
+#define HAVE_COMPLEX_H 1
+
+/* Define to 1 if you have the `cosf' function. */
+#define HAVE_COSF 1
+
+/* Define to 1 if you have the `coshf' function. */
+#define HAVE_COSHF 1
+
+/* Define to 1 if you have the `coshl' function. */
+#define HAVE_COSHL 1
+
+/* Define to 1 if you have the `cosl' function. */
+#define HAVE_COSL 1
+
+/* Define to 1 if you have the <dirent.h> header file. */
+#define HAVE_DIRENT_H 1
+
+/* Define to 1 if you have the <dlfcn.h> header file. */
+#define HAVE_DLFCN_H 1
+
+/* Define if EBADMSG exists. */
+#define HAVE_EBADMSG 1
+
+/* Define if ECANCELED exists. */
+#define HAVE_ECANCELED 1
+
+/* Define if ECHILD exists. */
+#define HAVE_ECHILD 1
+
+/* Define if EIDRM exists. */
+#define HAVE_EIDRM 1
+
+/* Define to 1 if you have the <endian.h> header file. */
+#define HAVE_ENDIAN_H 1
+
+/* Define if ENODATA exists. */
+#define HAVE_ENODATA 1
+
+/* Define if ENOLINK exists. */
+#define HAVE_ENOLINK 1
+
+/* Define if ENOSPC exists. */
+#define HAVE_ENOSPC 1
+
+/* Define if ENOSR exists. */
+#define HAVE_ENOSR 1
+
+/* Define if ENOSTR exists. */
+#define HAVE_ENOSTR 1
+
+/* Define if ENOTRECOVERABLE exists. */
+/* #undef HAVE_ENOTRECOVERABLE */
+
+/* Define if ENOTSUP exists. */
+#define HAVE_ENOTSUP 1
+
+/* Define if EOVERFLOW exists. */
+#define HAVE_EOVERFLOW 1
+
+/* Define if EOWNERDEAD exists. */
+/* #undef HAVE_EOWNERDEAD */
+
+/* Define if EPERM exists. */
+#define HAVE_EPERM 1
+
+/* Define if EPROTO exists. */
+#define HAVE_EPROTO 1
+
+/* Define if ETIME exists. */
+#define HAVE_ETIME 1
+
+/* Define if ETIMEDOUT exists. */
+#define HAVE_ETIMEDOUT 1
+
+/* Define if ETXTBSY exists. */
+#define HAVE_ETXTBSY 1
+
+/* Define if EWOULDBLOCK exists. */
+#define HAVE_EWOULDBLOCK 1
+
+/* Define to 1 if GCC 4.6 supported std::exception_ptr for the target */
+#define HAVE_EXCEPTION_PTR_SINCE_GCC46 1
+
+/* Define to 1 if you have the <execinfo.h> header file. */
+#define HAVE_EXECINFO_H 1
+
+/* Define to 1 if you have the `expf' function. */
+#define HAVE_EXPF 1
+
+/* Define to 1 if you have the `expl' function. */
+#define HAVE_EXPL 1
+
+/* Define to 1 if you have the `fabsf' function. */
+#define HAVE_FABSF 1
+
+/* Define to 1 if you have the `fabsl' function. */
+#define HAVE_FABSL 1
+
+/* Define to 1 if you have the <fcntl.h> header file. */
+#define HAVE_FCNTL_H 1
+
+/* Define to 1 if you have the <fenv.h> header file. */
+#define HAVE_FENV_H 1
+
+/* Define to 1 if you have the `finite' function. */
+#define HAVE_FINITE 1
+
+/* Define to 1 if you have the `finitef' function. */
+#define HAVE_FINITEF 1
+
+/* Define to 1 if you have the `finitel' function. */
+/* #undef HAVE_FINITEL */
+
+/* Define to 1 if you have the <float.h> header file. */
+#define HAVE_FLOAT_H 1
+
+/* Define to 1 if you have the `floorf' function. */
+#define HAVE_FLOORF 1
+
+/* Define to 1 if you have the `floorl' function. */
+#define HAVE_FLOORL 1
+
+/* Define to 1 if you have the `fmodf' function. */
+#define HAVE_FMODF 1
+
+/* Define to 1 if you have the `fmodl' function. */
+#define HAVE_FMODL 1
+
+/* Define to 1 if you have the `fpclass' function. */
+/* #undef HAVE_FPCLASS */
+
+/* Define to 1 if you have the <fp.h> header file. */
+/* #undef HAVE_FP_H */
+
+/* Define to 1 if you have the `frexpf' function. */
+#define HAVE_FREXPF 1
+
+/* Define to 1 if you have the `frexpl' function. */
+#define HAVE_FREXPL 1
+
+/* Define if _Unwind_GetIPInfo is available. */
+#define HAVE_GETIPINFO 1
+
+/* Define if gets is available in <stdio.h> before C++14. */
+#define HAVE_GETS 1
+
+/* Define to 1 if you have the `hypot' function. */
+#define HAVE_HYPOT 1
+
+/* Define to 1 if you have the `hypotf' function. */
+#define HAVE_HYPOTF 1
+
+/* Define to 1 if you have the `hypotl' function. */
+#define HAVE_HYPOTL 1
+
+/* Define if you have the iconv() function. */
+#define HAVE_ICONV 1
+
+/* Define to 1 if you have the <ieeefp.h> header file. */
+#define HAVE_IEEEFP_H 1
+
+/* Define if int64_t is available in <stdint.h>. */
+#define HAVE_INT64_T 1
+
+/* Define if int64_t is a long. */
+#define HAVE_INT64_T_LONG 1
+
+/* Define if int64_t is a long long. */
+/* #undef HAVE_INT64_T_LONG_LONG */
+
+/* Define to 1 if you have the <inttypes.h> header file. */
+#define HAVE_INTTYPES_H 1
+
+/* Define to 1 if you have the `isinf' function. */
+#define HAVE_ISINF 1
+
+/* Define to 1 if you have the `isinff' function. */
+#define HAVE_ISINFF 1
+
+/* Define to 1 if you have the `isinfl' function. */
+/* #undef HAVE_ISINFL */
+
+/* Define to 1 if you have the `isnan' function. */
+#define HAVE_ISNAN 1
+
+/* Define to 1 if you have the `isnanf' function. */
+#define HAVE_ISNANF 1
+
+/* Define to 1 if you have the `isnanl' function. */
+/* #undef HAVE_ISNANL */
+
+/* Defined if iswblank exists. */
+#define HAVE_ISWBLANK 1
+
+/* Define if LC_MESSAGES is available in <locale.h>. */
+#define HAVE_LC_MESSAGES 1
+
+/* Define to 1 if you have the `ldexpf' function. */
+#define HAVE_LDEXPF 1
+
+/* Define to 1 if you have the `ldexpl' function. */
+#define HAVE_LDEXPL 1
+
+/* Define to 1 if you have the <libintl.h> header file. */
+/* #undef HAVE_LIBINTL_H */
+
+/* Only used in build directory testsuite_hooks.h. */
+#define HAVE_LIMIT_AS 1
+
+/* Only used in build directory testsuite_hooks.h. */
+#define HAVE_LIMIT_DATA 1
+
+/* Only used in build directory testsuite_hooks.h. */
+#define HAVE_LIMIT_FSIZE 1
+
+/* Only used in build directory testsuite_hooks.h. */
+#define HAVE_LIMIT_RSS 1
+
+/* Only used in build directory testsuite_hooks.h. */
+#define HAVE_LIMIT_VMEM 1
+
+/* Define if futex syscall is available. */
+/* #undef HAVE_LINUX_FUTEX */
+
+/* Define to 1 if you have the <locale.h> header file. */
+#define HAVE_LOCALE_H 1
+
+/* Define to 1 if you have the `log10f' function. */
+#define HAVE_LOG10F 1
+
+/* Define to 1 if you have the `log10l' function. */
+#define HAVE_LOG10L 1
+
+/* Define to 1 if you have the `logf' function. */
+#define HAVE_LOGF 1
+
+/* Define to 1 if you have the `logl' function. */
+#define HAVE_LOGL 1
+
+/* Define to 1 if you have the <machine/endian.h> header file. */
+#define HAVE_MACHINE_ENDIAN_H 1
+
+/* Define to 1 if you have the <machine/param.h> header file. */
+#define HAVE_MACHINE_PARAM_H 1
+
+/* Define if mbstate_t exists in wchar.h. */
+#define HAVE_MBSTATE_T 1
+
+/* Define to 1 if you have the `memalign' function. */
+/* #undef HAVE_MEMALIGN */
+
+/* Define to 1 if you have the <memory.h> header file. */
+#define HAVE_MEMORY_H 1
+
+/* Define to 1 if you have the `modf' function. */
+#define HAVE_MODF 1
+
+/* Define to 1 if you have the `modff' function. */
+#define HAVE_MODFF 1
+
+/* Define to 1 if you have the `modfl' function. */
+#define HAVE_MODFL 1
+
+/* Define to 1 if you have the <nan.h> header file. */
+/* #undef HAVE_NAN_H */
+
+/* Define if <math.h> defines obsolete isinf function. */
+/* #undef HAVE_OBSOLETE_ISINF */
+
+/* Define if <math.h> defines obsolete isnan function. */
+/* #undef HAVE_OBSOLETE_ISNAN */
+
+/* Define if poll is available in <poll.h>. */
+#define HAVE_POLL 1
+
+/* Define to 1 if you have the `posix_memalign' function. */
+#define HAVE_POSIX_MEMALIGN 1
+
+/* Define to 1 if you have the `powf' function. */
+#define HAVE_POWF 1
+
+/* Define to 1 if you have the `powl' function. */
+#define HAVE_POWL 1
+
+/* Define to 1 if you have the `qfpclass' function. */
+/* #undef HAVE_QFPCLASS */
+
+/* Define to 1 if you have the `quick_exit' function. */
+#define HAVE_QUICK_EXIT 1
+
+/* Define to 1 if you have the `setenv' function. */
+#define HAVE_SETENV 1
+
+/* Define to 1 if you have the `sincos' function. */
+/* #undef HAVE_SINCOS */
+
+/* Define to 1 if you have the `sincosf' function. */
+/* #undef HAVE_SINCOSF */
+
+/* Define to 1 if you have the `sincosl' function. */
+/* #undef HAVE_SINCOSL */
+
+/* Define to 1 if you have the `sinf' function. */
+#define HAVE_SINF 1
+
+/* Define to 1 if you have the `sinhf' function. */
+#define HAVE_SINHF 1
+
+/* Define to 1 if you have the `sinhl' function. */
+#define HAVE_SINHL 1
+
+/* Define to 1 if you have the `sinl' function. */
+#define HAVE_SINL 1
+
+/* Defined if sleep exists. */
+/* #undef HAVE_SLEEP */
+
+/* Define to 1 if you have the `sqrtf' function. */
+#define HAVE_SQRTF 1
+
+/* Define to 1 if you have the `sqrtl' function. */
+#define HAVE_SQRTL 1
+
+/* Define to 1 if you have the <stdalign.h> header file. */
+#define HAVE_STDALIGN_H 1
+
+/* Define to 1 if you have the <stdbool.h> header file. */
+#define HAVE_STDBOOL_H 1
+
+/* Define to 1 if you have the <stdint.h> header file. */
+#define HAVE_STDINT_H 1
+
+/* Define to 1 if you have the <stdlib.h> header file. */
+#define HAVE_STDLIB_H 1
+
+/* Define if strerror_l is available in <string.h>. */
+/* #undef HAVE_STRERROR_L */
+
+/* Define if strerror_r is available in <string.h>. */
+#define HAVE_STRERROR_R 1
+
+/* Define to 1 if you have the <strings.h> header file. */
+#define HAVE_STRINGS_H 1
+
+/* Define to 1 if you have the <string.h> header file. */
+#define HAVE_STRING_H 1
+
+/* Define to 1 if you have the `strtof' function. */
+#define HAVE_STRTOF 1
+
+/* Define to 1 if you have the `strtold' function. */
+#define HAVE_STRTOLD 1
+
+/* Define to 1 if `d_type' is a member of `struct dirent'. */
+#define HAVE_STRUCT_DIRENT_D_TYPE 1
+
+/* Define if strxfrm_l is available in <string.h>. */
+/* #undef HAVE_STRXFRM_L */
+
+/* Define to 1 if the target runtime linker supports binding the same symbol
+   to different versions. */
+#define HAVE_SYMVER_SYMBOL_RENAMING_RUNTIME_SUPPORT 1
+
+/* Define to 1 if you have the <sys/filio.h> header file. */
+#define HAVE_SYS_FILIO_H 1
+
+/* Define to 1 if you have the <sys/ioctl.h> header file. */
+#define HAVE_SYS_IOCTL_H 1
+
+/* Define to 1 if you have the <sys/ipc.h> header file. */
+#define HAVE_SYS_IPC_H 1
+
+/* Define to 1 if you have the <sys/isa_defs.h> header file. */
+/* #undef HAVE_SYS_ISA_DEFS_H */
+
+/* Define to 1 if you have the <sys/machine.h> header file. */
+/* #undef HAVE_SYS_MACHINE_H */
+
+/* Define to 1 if you have the <sys/param.h> header file. */
+#define HAVE_SYS_PARAM_H 1
+
+/* Define to 1 if you have the <sys/resource.h> header file. */
+#define HAVE_SYS_RESOURCE_H 1
+
+/* Define to 1 if you have a suitable <sys/sdt.h> header file */
+/* #undef HAVE_SYS_SDT_H */
+
+/* Define to 1 if you have the <sys/sem.h> header file. */
+#define HAVE_SYS_SEM_H 1
+
+/* Define to 1 if you have the <sys/statvfs.h> header file. */
+#define HAVE_SYS_STATVFS_H 1
+
+/* Define to 1 if you have the <sys/stat.h> header file. */
+#define HAVE_SYS_STAT_H 1
+
+/* Define to 1 if you have the <sys/sysinfo.h> header file. */
+/* #undef HAVE_SYS_SYSINFO_H */
+
+/* Define to 1 if you have the <sys/time.h> header file. */
+#define HAVE_SYS_TIME_H 1
+
+/* Define to 1 if you have the <sys/types.h> header file. */
+#define HAVE_SYS_TYPES_H 1
+
+/* Define to 1 if you have the <sys/uio.h> header file. */
+#define HAVE_SYS_UIO_H 1
+
+/* Define if S_IFREG is available in <sys/stat.h>. */
+/* #undef HAVE_S_IFREG */
+
+/* Define if S_ISREG is available in <sys/stat.h>. */
+#define HAVE_S_ISREG 1
+
+/* Define to 1 if you have the `tanf' function. */
+#define HAVE_TANF 1
+
+/* Define to 1 if you have the `tanhf' function. */
+#define HAVE_TANHF 1
+
+/* Define to 1 if you have the `tanhl' function. */
+#define HAVE_TANHL 1
+
+/* Define to 1 if you have the `tanl' function. */
+#define HAVE_TANL 1
+
+/* Define to 1 if you have the <tgmath.h> header file. */
+#define HAVE_TGMATH_H 1
+
+/* Define to 1 if the target supports thread-local storage. */
+#define HAVE_TLS 1
+
+/* Define to 1 if you have the <uchar.h> header file. */
+/* #undef HAVE_UCHAR_H */
+
+/* Define to 1 if you have the <unistd.h> header file. */
+#define HAVE_UNISTD_H 1
+
+/* Defined if usleep exists. */
+/* #undef HAVE_USLEEP */
+
+/* Define to 1 if you have the <utime.h> header file. */
+#define HAVE_UTIME_H 1
+
+/* Defined if vfwscanf exists. */
+#define HAVE_VFWSCANF 1
+
+/* Defined if vswscanf exists. */
+#define HAVE_VSWSCANF 1
+
+/* Defined if vwscanf exists. */
+#define HAVE_VWSCANF 1
+
+/* Define to 1 if you have the <wchar.h> header file. */
+#define HAVE_WCHAR_H 1
+
+/* Defined if wcstof exists. */
+#define HAVE_WCSTOF 1
+
+/* Define to 1 if you have the <wctype.h> header file. */
+#define HAVE_WCTYPE_H 1
+
+/* Defined if Sleep exists. */
+/* #undef HAVE_WIN32_SLEEP */
+
+/* Define if writev is available in <sys/uio.h>. */
+#define HAVE_WRITEV 1
+
+/* Define to 1 if you have the `_acosf' function. */
+/* #undef HAVE__ACOSF */
+
+/* Define to 1 if you have the `_acosl' function. */
+/* #undef HAVE__ACOSL */
+
+/* Define to 1 if you have the `_aligned_malloc' function. */
+/* #undef HAVE__ALIGNED_MALLOC */
+
+/* Define to 1 if you have the `_asinf' function. */
+/* #undef HAVE__ASINF */
+
+/* Define to 1 if you have the `_asinl' function. */
+/* #undef HAVE__ASINL */
+
+/* Define to 1 if you have the `_atan2f' function. */
+/* #undef HAVE__ATAN2F */
+
+/* Define to 1 if you have the `_atan2l' function. */
+/* #undef HAVE__ATAN2L */
+
+/* Define to 1 if you have the `_atanf' function. */
+/* #undef HAVE__ATANF */
+
+/* Define to 1 if you have the `_atanl' function. */
+/* #undef HAVE__ATANL */
+
+/* Define to 1 if you have the `_ceilf' function. */
+/* #undef HAVE__CEILF */
+
+/* Define to 1 if you have the `_ceill' function. */
+/* #undef HAVE__CEILL */
+
+/* Define to 1 if you have the `_cosf' function. */
+/* #undef HAVE__COSF */
+
+/* Define to 1 if you have the `_coshf' function. */
+/* #undef HAVE__COSHF */
+
+/* Define to 1 if you have the `_coshl' function. */
+/* #undef HAVE__COSHL */
+
+/* Define to 1 if you have the `_cosl' function. */
+/* #undef HAVE__COSL */
+
+/* Define to 1 if you have the `_expf' function. */
+/* #undef HAVE__EXPF */
+
+/* Define to 1 if you have the `_expl' function. */
+/* #undef HAVE__EXPL */
+
+/* Define to 1 if you have the `_fabsf' function. */
+/* #undef HAVE__FABSF */
+
+/* Define to 1 if you have the `_fabsl' function. */
+/* #undef HAVE__FABSL */
+
+/* Define to 1 if you have the `_finite' function. */
+/* #undef HAVE__FINITE */
+
+/* Define to 1 if you have the `_finitef' function. */
+/* #undef HAVE__FINITEF */
+
+/* Define to 1 if you have the `_finitel' function. */
+/* #undef HAVE__FINITEL */
+
+/* Define to 1 if you have the `_floorf' function. */
+/* #undef HAVE__FLOORF */
+
+/* Define to 1 if you have the `_floorl' function. */
+/* #undef HAVE__FLOORL */
+
+/* Define to 1 if you have the `_fmodf' function. */
+/* #undef HAVE__FMODF */
+
+/* Define to 1 if you have the `_fmodl' function. */
+/* #undef HAVE__FMODL */
+
+/* Define to 1 if you have the `_fpclass' function. */
+/* #undef HAVE__FPCLASS */
+
+/* Define to 1 if you have the `_frexpf' function. */
+/* #undef HAVE__FREXPF */
+
+/* Define to 1 if you have the `_frexpl' function. */
+/* #undef HAVE__FREXPL */
+
+/* Define to 1 if you have the `_hypot' function. */
+/* #undef HAVE__HYPOT */
+
+/* Define to 1 if you have the `_hypotf' function. */
+/* #undef HAVE__HYPOTF */
+
+/* Define to 1 if you have the `_hypotl' function. */
+/* #undef HAVE__HYPOTL */
+
+/* Define to 1 if you have the `_isinf' function. */
+/* #undef HAVE__ISINF */
+
+/* Define to 1 if you have the `_isinff' function. */
+/* #undef HAVE__ISINFF */
+
+/* Define to 1 if you have the `_isinfl' function. */
+/* #undef HAVE__ISINFL */
+
+/* Define to 1 if you have the `_isnan' function. */
+/* #undef HAVE__ISNAN */
+
+/* Define to 1 if you have the `_isnanf' function. */
+/* #undef HAVE__ISNANF */
+
+/* Define to 1 if you have the `_isnanl' function. */
+/* #undef HAVE__ISNANL */
+
+/* Define to 1 if you have the `_ldexpf' function. */
+/* #undef HAVE__LDEXPF */
+
+/* Define to 1 if you have the `_ldexpl' function. */
+/* #undef HAVE__LDEXPL */
+
+/* Define to 1 if you have the `_log10f' function. */
+/* #undef HAVE__LOG10F */
+
+/* Define to 1 if you have the `_log10l' function. */
+/* #undef HAVE__LOG10L */
+
+/* Define to 1 if you have the `_logf' function. */
+/* #undef HAVE__LOGF */
+
+/* Define to 1 if you have the `_logl' function. */
+/* #undef HAVE__LOGL */
+
+/* Define to 1 if you have the `_modf' function. */
+/* #undef HAVE__MODF */
+
+/* Define to 1 if you have the `_modff' function. */
+/* #undef HAVE__MODFF */
+
+/* Define to 1 if you have the `_modfl' function. */
+/* #undef HAVE__MODFL */
+
+/* Define to 1 if you have the `_powf' function. */
+/* #undef HAVE__POWF */
+
+/* Define to 1 if you have the `_powl' function. */
+/* #undef HAVE__POWL */
+
+/* Define to 1 if you have the `_qfpclass' function. */
+/* #undef HAVE__QFPCLASS */
+
+/* Define to 1 if you have the `_sincos' function. */
+/* #undef HAVE__SINCOS */
+
+/* Define to 1 if you have the `_sincosf' function. */
+/* #undef HAVE__SINCOSF */
+
+/* Define to 1 if you have the `_sincosl' function. */
+/* #undef HAVE__SINCOSL */
+
+/* Define to 1 if you have the `_sinf' function. */
+/* #undef HAVE__SINF */
+
+/* Define to 1 if you have the `_sinhf' function. */
+/* #undef HAVE__SINHF */
+
+/* Define to 1 if you have the `_sinhl' function. */
+/* #undef HAVE__SINHL */
+
+/* Define to 1 if you have the `_sinl' function. */
+/* #undef HAVE__SINL */
+
+/* Define to 1 if you have the `_sqrtf' function. */
+/* #undef HAVE__SQRTF */
+
+/* Define to 1 if you have the `_sqrtl' function. */
+/* #undef HAVE__SQRTL */
+
+/* Define to 1 if you have the `_tanf' function. */
+/* #undef HAVE__TANF */
+
+/* Define to 1 if you have the `_tanhf' function. */
+/* #undef HAVE__TANHF */
+
+/* Define to 1 if you have the `_tanhl' function. */
+/* #undef HAVE__TANHL */
+
+/* Define to 1 if you have the `_tanl' function. */
+/* #undef HAVE__TANL */
+
+/* Define to 1 if you have the `__cxa_thread_atexit' function. */
+#define HAVE___CXA_THREAD_ATEXIT 1
+
+/* Define to 1 if you have the `__cxa_thread_atexit_impl' function. */
+#define HAVE___CXA_THREAD_ATEXIT_IMPL 1
+
+/* Define as const if the declaration of iconv() needs const. */
+#define ICONV_CONST const
+
+/* Define to the sub-directory in which libtool stores uninstalled libraries.
+   */
+#define LT_OBJDIR ".libs/"
+
+/* Name of package */
+/* #undef PACKAGE */
+
+/* Define to the address where bug reports for this package should be sent. */
+#define PACKAGE_BUGREPORT ""
+
+/* Define to the full name of this package. */
+#define PACKAGE_NAME "package-unused"
+
+/* Define to the full name and version of this package. */
+#define PACKAGE_STRING "package-unused version-unused"
+
+/* Define to the one symbol short name of this package. */
+#define PACKAGE_TARNAME "libstdc++"
+
+/* Define to the home page for this package. */
+#define PACKAGE_URL ""
+
+/* Define to the version of this package. */
+#define PACKAGE_VERSION "version-unused"
+
+/* The size of `char', as computed by sizeof. */
+/* #undef SIZEOF_CHAR */
+
+/* The size of `int', as computed by sizeof. */
+/* #undef SIZEOF_INT */
+
+/* The size of `long', as computed by sizeof. */
+/* #undef SIZEOF_LONG */
+
+/* The size of `short', as computed by sizeof. */
+/* #undef SIZEOF_SHORT */
+
+/* The size of `void *', as computed by sizeof. */
+/* #undef SIZEOF_VOID_P */
+
+/* Define to 1 if you have the ANSI C header files. */
+#define STDC_HEADERS 1
+
+/* Version number of package */
+/* #undef VERSION */
+
+/* Define if C99 functions in <complex.h> should be used in <complex> for
+   C++11. Using compiler builtins for these functions requires corresponding
+   C99 library functions to be present. */
+#define _GLIBCXX11_USE_C99_COMPLEX 1
+
+/* Define if C99 functions or macros in <math.h> should be imported in <cmath>
+   in namespace std for C++11. */
+#define _GLIBCXX11_USE_C99_MATH 1
+
+/* Define if C99 functions or macros in <stdio.h> should be imported in
+   <cstdio> in namespace std for C++11. */
+#define _GLIBCXX11_USE_C99_STDIO 1
+
+/* Define if C99 functions or macros in <stdlib.h> should be imported in
+   <cstdlib> in namespace std for C++11. */
+#define _GLIBCXX11_USE_C99_STDLIB 1
+
+/* Define if C99 functions or macros in <wchar.h> should be imported in
+   <cwchar> in namespace std for C++11. */
+#define _GLIBCXX11_USE_C99_WCHAR 1
+
+/* Define if C99 functions in <complex.h> should be used in <complex> for
+   C++98. Using compiler builtins for these functions requires corresponding
+   C99 library functions to be present. */
+#define _GLIBCXX98_USE_C99_COMPLEX 1
+
+/* Define if C99 functions or macros in <math.h> should be imported in <cmath>
+   in namespace std for C++98. */
+#define _GLIBCXX98_USE_C99_MATH 1
+
+/* Define if C99 functions or macros in <stdio.h> should be imported in
+   <cstdio> in namespace std for C++98. */
+#define _GLIBCXX98_USE_C99_STDIO 1
+
+/* Define if C99 functions or macros in <stdlib.h> should be imported in
+   <cstdlib> in namespace std for C++98. */
+#define _GLIBCXX98_USE_C99_STDLIB 1
+
+/* Define if C99 functions or macros in <wchar.h> should be imported in
+   <cwchar> in namespace std for C++98. */
+#define _GLIBCXX98_USE_C99_WCHAR 1
+
+/* Define if the compiler supports C++11 atomics. */
+/* #undef _GLIBCXX_ATOMIC_BUILTINS */
+
+/* Define to use concept checking code from the boost libraries. */
+/* #undef _GLIBCXX_CONCEPT_CHECKS */
+
+/* Define to 1 if a fully dynamic basic_string is wanted, 0 to disable,
+   undefined for platform defaults */
+#define _GLIBCXX_FULLY_DYNAMIC_STRING 0
+
+/* Define if gthreads library is available. */
+#define _GLIBCXX_HAS_GTHREADS 1
+
+/* Define to 1 if a full hosted library is built, or 0 if freestanding. */
+#define _GLIBCXX_HOSTED 1
+
+/* Define if compatibility should be provided for -mlong-double-64. */
+/* #undef _GLIBCXX_LONG_DOUBLE_COMPAT */
+
+/* Define to the letter to which size_t is mangled. */
+#define _GLIBCXX_MANGLE_SIZE_T m
+
+/* Define if C99 llrint and llround functions are missing from <math.h>. */
+/* #undef _GLIBCXX_NO_C99_ROUNDING_FUNCS */
+
+/* Define if ptrdiff_t is int. */
+/* #undef _GLIBCXX_PTRDIFF_T_IS_INT */
+
+/* Define if using setrlimit to set resource limits during "make check" */
+#define _GLIBCXX_RES_LIMITS 1
+
+/* Define if size_t is unsigned int. */
+/* #undef _GLIBCXX_SIZE_T_IS_UINT */
+
+/* Define to the value of the EOF integer constant. */
+#define _GLIBCXX_STDIO_EOF -1
+
+/* Define to the value of the SEEK_CUR integer constant. */
+#define _GLIBCXX_STDIO_SEEK_CUR 1
+
+/* Define to the value of the SEEK_END integer constant. */
+#define _GLIBCXX_STDIO_SEEK_END 2
+
+/* Define to use symbol versioning in the shared library. */
+#define _GLIBCXX_SYMVER 1
+
+/* Define to use darwin versioning in the shared library. */
+/* #undef _GLIBCXX_SYMVER_DARWIN */
+
+/* Define to use GNU versioning in the shared library. */
+#define _GLIBCXX_SYMVER_GNU 1
+
+/* Define to use GNU namespace versioning in the shared library. */
+/* #undef _GLIBCXX_SYMVER_GNU_NAMESPACE */
+
+/* Define to use Sun versioning in the shared library. */
+/* #undef _GLIBCXX_SYMVER_SUN */
+
+/* Define if C11 functions in <uchar.h> should be imported into namespace std
+   in <cuchar>. */
+/* #undef _GLIBCXX_USE_C11_UCHAR_CXX11 */
+
+/* Define if C99 functions or macros from <wchar.h>, <math.h>, <complex.h>,
+   <stdio.h>, and <stdlib.h> can be used or exposed. */
+#define _GLIBCXX_USE_C99 1
+
+/* Define if C99 functions in <complex.h> should be used in <tr1/complex>.
+   Using compiler builtins for these functions requires corresponding C99
+   library functions to be present. */
+#define _GLIBCXX_USE_C99_COMPLEX_TR1 1
+
+/* Define if C99 functions in <ctype.h> should be imported in <tr1/cctype> in
+   namespace std::tr1. */
+#define _GLIBCXX_USE_C99_CTYPE_TR1 1
+
+/* Define if C99 functions in <fenv.h> should be imported in <tr1/cfenv> in
+   namespace std::tr1. */
+/* #undef _GLIBCXX_USE_C99_FENV_TR1 */
+
+/* Define if C99 functions in <inttypes.h> should be imported in
+   <tr1/cinttypes> in namespace std::tr1. */
+#define _GLIBCXX_USE_C99_INTTYPES_TR1 1
+
+/* Define if wchar_t C99 functions in <inttypes.h> should be imported in
+   <tr1/cinttypes> in namespace std::tr1. */
+#define _GLIBCXX_USE_C99_INTTYPES_WCHAR_T_TR1 1
+
+/* Define if C99 functions or macros in <math.h> should be imported in
+   <tr1/cmath> in namespace std::tr1. */
+#define _GLIBCXX_USE_C99_MATH_TR1 1
+
+/* Define if C99 types in <stdint.h> should be imported in <tr1/cstdint> in
+   namespace std::tr1. */
+#define _GLIBCXX_USE_C99_STDINT_TR1 1
+
+/* Defined if clock_gettime syscall has monotonic and realtime clock support.
+   */
+/* #undef _GLIBCXX_USE_CLOCK_GETTIME_SYSCALL */
+
+/* Defined if clock_gettime has monotonic clock support. */
+#define _GLIBCXX_USE_CLOCK_MONOTONIC 1
+
+/* Defined if clock_gettime has realtime clock support. */
+#define _GLIBCXX_USE_CLOCK_REALTIME 1
+
+/* Define if ISO/IEC TR 24733 decimal floating point types are supported on
+   this host. */
+/* #undef _GLIBCXX_USE_DECIMAL_FLOAT */
+
+/* Define if fchmod is available in <sys/stat.h>. */
+#define _GLIBCXX_USE_FCHMOD 1
+
+/* Define if fchmodat is available in <sys/stat.h>. */
+#define _GLIBCXX_USE_FCHMODAT 1
+
+/* Defined if gettimeofday is available. */
+#define _GLIBCXX_USE_GETTIMEOFDAY 1
+
+/* Define if get_nprocs is available in <sys/sysinfo.h>. */
+/* #undef _GLIBCXX_USE_GET_NPROCS */
+
+/* Define if __int128 is supported on this host. */
+/* #define _GLIBCXX_USE_INT128 1 */
+
+/* Define if LFS support is available. */
+/* #undef _GLIBCXX_USE_LFS */
+
+/* Define if code specialized for long long should be used. */
+#define _GLIBCXX_USE_LONG_LONG 1
+
+/* Defined if nanosleep is available. */
+#define _GLIBCXX_USE_NANOSLEEP 1
+
+/* Define if NLS translations are to be used. */
+/* #undef _GLIBCXX_USE_NLS */
+
+/* Define if pthreads_num_processors_np is available in <pthread.h>. */
+/* #undef _GLIBCXX_USE_PTHREADS_NUM_PROCESSORS_NP */
+
+/* Define if POSIX read/write locks are available in <gthr.h>. */
+#define _GLIBCXX_USE_PTHREAD_RWLOCK_T 1
+
+/* Define if /dev/random and /dev/urandom are available for the random_device
+   of TR1 (Chapter 5.1). */
+#define _GLIBCXX_USE_RANDOM_TR1 1
+
+/* Define if usable realpath is available in <stdlib.h>. */
+/* #undef _GLIBCXX_USE_REALPATH */
+
+/* Defined if sched_yield is available. */
+#define _GLIBCXX_USE_SCHED_YIELD 1
+
+/* Define if _SC_NPROCESSORS_ONLN is available in <unistd.h>. */
+#define _GLIBCXX_USE_SC_NPROCESSORS_ONLN 1
+
+/* Define if _SC_NPROC_ONLN is available in <unistd.h>. */
+/* #undef _GLIBCXX_USE_SC_NPROC_ONLN */
+
+/* Define if sendfile is available in <sys/sendfile.h>. */
+/* #undef _GLIBCXX_USE_SENDFILE */
+
+/* Define if struct stat has timespec members. */
+#define _GLIBCXX_USE_ST_MTIM 1
+
+/* Define if sysctl(), CTL_HW and HW_NCPU are available in <sys/sysctl.h>. */
+#define _GLIBCXX_USE_SYSCTL_HW_NCPU 1
+
+/* Define if obsolescent tmpnam is available in <stdio.h>. */
+#define _GLIBCXX_USE_TMPNAM 1
+
+/* Define if utimensat and UTIME_OMIT are available in <sys/stat.h> and
+   AT_FDCWD in <fcntl.h>. */
+#define _GLIBCXX_USE_UTIMENSAT 1
+
+/* Define if code specialized for wchar_t should be used. */
+#define _GLIBCXX_USE_WCHAR_T 1
+
+/* Define to 1 if a verbose library is built, or 0 otherwise. */
+#define _GLIBCXX_VERBOSE 1
+
+/* Defined if as can handle rdrand. */
+/* #undef _GLIBCXX_X86_RDRAND */
+
+/* Define to 1 if mutex_timedlock is available. */
+#define _GTHREAD_USE_MUTEX_TIMEDLOCK 0
+
+/* Define if all C++11 floating point overloads are available in <math.h>.  */
+#if __cplusplus >= 201103L
+/* #undef __CORRECT_ISO_CPP11_MATH_H_PROTO_FP */
+#endif
+
+/* Define if all C++11 integral type overloads are available in <math.h>.  */
+#if __cplusplus >= 201103L
+/* #undef __CORRECT_ISO_CPP11_MATH_H_PROTO_INT */
+#endif
+
+#if defined (HAVE__ACOSF) && ! defined (HAVE_ACOSF)
+# define HAVE_ACOSF 1
+# define acosf _acosf
+#endif
+
+#if defined (HAVE__ACOSL) && ! defined (HAVE_ACOSL)
+# define HAVE_ACOSL 1
+# define acosl _acosl
+#endif
+
+#if defined (HAVE__ASINF) && ! defined (HAVE_ASINF)
+# define HAVE_ASINF 1
+# define asinf _asinf
+#endif
+
+#if defined (HAVE__ASINL) && ! defined (HAVE_ASINL)
+# define HAVE_ASINL 1
+# define asinl _asinl
+#endif
+
+#if defined (HAVE__ATAN2F) && ! defined (HAVE_ATAN2F)
+# define HAVE_ATAN2F 1
+# define atan2f _atan2f
+#endif
+
+#if defined (HAVE__ATAN2L) && ! defined (HAVE_ATAN2L)
+# define HAVE_ATAN2L 1
+# define atan2l _atan2l
+#endif
+
+#if defined (HAVE__ATANF) && ! defined (HAVE_ATANF)
+# define HAVE_ATANF 1
+# define atanf _atanf
+#endif
+
+#if defined (HAVE__ATANL) && ! defined (HAVE_ATANL)
+# define HAVE_ATANL 1
+# define atanl _atanl
+#endif
+
+#if defined (HAVE__CEILF) && ! defined (HAVE_CEILF)
+# define HAVE_CEILF 1
+# define ceilf _ceilf
+#endif
+
+#if defined (HAVE__CEILL) && ! defined (HAVE_CEILL)
+# define HAVE_CEILL 1
+# define ceill _ceill
+#endif
+
+#if defined (HAVE__COSF) && ! defined (HAVE_COSF)
+# define HAVE_COSF 1
+# define cosf _cosf
+#endif
+
+#if defined (HAVE__COSHF) && ! defined (HAVE_COSHF)
+# define HAVE_COSHF 1
+# define coshf _coshf
+#endif
+
+#if defined (HAVE__COSHL) && ! defined (HAVE_COSHL)
+# define HAVE_COSHL 1
+# define coshl _coshl
+#endif
+
+#if defined (HAVE__COSL) && ! defined (HAVE_COSL)
+# define HAVE_COSL 1
+# define cosl _cosl
+#endif
+
+#if defined (HAVE__EXPF) && ! defined (HAVE_EXPF)
+# define HAVE_EXPF 1
+# define expf _expf
+#endif
+
+#if defined (HAVE__EXPL) && ! defined (HAVE_EXPL)
+# define HAVE_EXPL 1
+# define expl _expl
+#endif
+
+#if defined (HAVE__FABSF) && ! defined (HAVE_FABSF)
+# define HAVE_FABSF 1
+# define fabsf _fabsf
+#endif
+
+#if defined (HAVE__FABSL) && ! defined (HAVE_FABSL)
+# define HAVE_FABSL 1
+# define fabsl _fabsl
+#endif
+
+#if defined (HAVE__FINITE) && ! defined (HAVE_FINITE)
+# define HAVE_FINITE 1
+# define finite _finite
+#endif
+
+#if defined (HAVE__FINITEF) && ! defined (HAVE_FINITEF)
+# define HAVE_FINITEF 1
+# define finitef _finitef
+#endif
+
+#if defined (HAVE__FINITEL) && ! defined (HAVE_FINITEL)
+# define HAVE_FINITEL 1
+# define finitel _finitel
+#endif
+
+#if defined (HAVE__FLOORF) && ! defined (HAVE_FLOORF)
+# define HAVE_FLOORF 1
+# define floorf _floorf
+#endif
+
+#if defined (HAVE__FLOORL) && ! defined (HAVE_FLOORL)
+# define HAVE_FLOORL 1
+# define floorl _floorl
+#endif
+
+#if defined (HAVE__FMODF) && ! defined (HAVE_FMODF)
+# define HAVE_FMODF 1
+# define fmodf _fmodf
+#endif
+
+#if defined (HAVE__FMODL) && ! defined (HAVE_FMODL)
+# define HAVE_FMODL 1
+# define fmodl _fmodl
+#endif
+
+#if defined (HAVE__FPCLASS) && ! defined (HAVE_FPCLASS)
+# define HAVE_FPCLASS 1
+# define fpclass _fpclass
+#endif
+
+#if defined (HAVE__FREXPF) && ! defined (HAVE_FREXPF)
+# define HAVE_FREXPF 1
+# define frexpf _frexpf
+#endif
+
+#if defined (HAVE__FREXPL) && ! defined (HAVE_FREXPL)
+# define HAVE_FREXPL 1
+# define frexpl _frexpl
+#endif
+
+#if defined (HAVE__HYPOT) && ! defined (HAVE_HYPOT)
+# define HAVE_HYPOT 1
+# define hypot _hypot
+#endif
+
+#if defined (HAVE__HYPOTF) && ! defined (HAVE_HYPOTF)
+# define HAVE_HYPOTF 1
+# define hypotf _hypotf
+#endif
+
+#if defined (HAVE__HYPOTL) && ! defined (HAVE_HYPOTL)
+# define HAVE_HYPOTL 1
+# define hypotl _hypotl
+#endif
+
+#if defined (HAVE__ISINF) && ! defined (HAVE_ISINF)
+# define HAVE_ISINF 1
+# define isinf _isinf
+#endif
+
+#if defined (HAVE__ISINFF) && ! defined (HAVE_ISINFF)
+# define HAVE_ISINFF 1
+# define isinff _isinff
+#endif
+
+#if defined (HAVE__ISINFL) && ! defined (HAVE_ISINFL)
+# define HAVE_ISINFL 1
+# define isinfl _isinfl
+#endif
+
+#if defined (HAVE__ISNAN) && ! defined (HAVE_ISNAN)
+# define HAVE_ISNAN 1
+# define isnan _isnan
+#endif
+
+#if defined (HAVE__ISNANF) && ! defined (HAVE_ISNANF)
+# define HAVE_ISNANF 1
+# define isnanf _isnanf
+#endif
+
+#if defined (HAVE__ISNANL) && ! defined (HAVE_ISNANL)
+# define HAVE_ISNANL 1
+# define isnanl _isnanl
+#endif
+
+#if defined (HAVE__LDEXPF) && ! defined (HAVE_LDEXPF)
+# define HAVE_LDEXPF 1
+# define ldexpf _ldexpf
+#endif
+
+#if defined (HAVE__LDEXPL) && ! defined (HAVE_LDEXPL)
+# define HAVE_LDEXPL 1
+# define ldexpl _ldexpl
+#endif
+
+#if defined (HAVE__LOG10F) && ! defined (HAVE_LOG10F)
+# define HAVE_LOG10F 1
+# define log10f _log10f
+#endif
+
+#if defined (HAVE__LOG10L) && ! defined (HAVE_LOG10L)
+# define HAVE_LOG10L 1
+# define log10l _log10l
+#endif
+
+#if defined (HAVE__LOGF) && ! defined (HAVE_LOGF)
+# define HAVE_LOGF 1
+# define logf _logf
+#endif
+
+#if defined (HAVE__LOGL) && ! defined (HAVE_LOGL)
+# define HAVE_LOGL 1
+# define logl _logl
+#endif
+
+#if defined (HAVE__MODF) && ! defined (HAVE_MODF)
+# define HAVE_MODF 1
+# define modf _modf
+#endif
+
+#if defined (HAVE__MODFF) && ! defined (HAVE_MODFF)
+# define HAVE_MODFF 1
+# define modff _modff
+#endif
+
+#if defined (HAVE__MODFL) && ! defined (HAVE_MODFL)
+# define HAVE_MODFL 1
+# define modfl _modfl
+#endif
+
+#if defined (HAVE__POWF) && ! defined (HAVE_POWF)
+# define HAVE_POWF 1
+# define powf _powf
+#endif
+
+#if defined (HAVE__POWL) && ! defined (HAVE_POWL)
+# define HAVE_POWL 1
+# define powl _powl
+#endif
+
+#if defined (HAVE__QFPCLASS) && ! defined (HAVE_QFPCLASS)
+# define HAVE_QFPCLASS 1
+# define qfpclass _qfpclass
+#endif
+
+#if defined (HAVE__SINCOS) && ! defined (HAVE_SINCOS)
+# define HAVE_SINCOS 1
+# define sincos _sincos
+#endif
+
+#if defined (HAVE__SINCOSF) && ! defined (HAVE_SINCOSF)
+# define HAVE_SINCOSF 1
+# define sincosf _sincosf
+#endif
+
+#if defined (HAVE__SINCOSL) && ! defined (HAVE_SINCOSL)
+# define HAVE_SINCOSL 1
+# define sincosl _sincosl
+#endif
+
+#if defined (HAVE__SINF) && ! defined (HAVE_SINF)
+# define HAVE_SINF 1
+# define sinf _sinf
+#endif
+
+#if defined (HAVE__SINHF) && ! defined (HAVE_SINHF)
+# define HAVE_SINHF 1
+# define sinhf _sinhf
+#endif
+
+#if defined (HAVE__SINHL) && ! defined (HAVE_SINHL)
+# define HAVE_SINHL 1
+# define sinhl _sinhl
+#endif
+
+#if defined (HAVE__SINL) && ! defined (HAVE_SINL)
+# define HAVE_SINL 1
+# define sinl _sinl
+#endif
+
+#if defined (HAVE__SQRTF) && ! defined (HAVE_SQRTF)
+# define HAVE_SQRTF 1
+# define sqrtf _sqrtf
+#endif
+
+#if defined (HAVE__SQRTL) && ! defined (HAVE_SQRTL)
+# define HAVE_SQRTL 1
+# define sqrtl _sqrtl
+#endif
+
+#if defined (HAVE__STRTOF) && ! defined (HAVE_STRTOF)
+# define HAVE_STRTOF 1
+# define strtof _strtof
+#endif
+
+#if defined (HAVE__STRTOLD) && ! defined (HAVE_STRTOLD)
+# define HAVE_STRTOLD 1
+# define strtold _strtold
+#endif
+
+#if defined (HAVE__TANF) && ! defined (HAVE_TANF)
+# define HAVE_TANF 1
+# define tanf _tanf
+#endif
+
+#if defined (HAVE__TANHF) && ! defined (HAVE_TANHF)
+# define HAVE_TANHF 1
+# define tanhf _tanhf
+#endif
+
+#if defined (HAVE__TANHL) && ! defined (HAVE_TANHL)
+# define HAVE_TANHL 1
+# define tanhl _tanhl
+#endif
+
+#if defined (HAVE__TANL) && ! defined (HAVE_TANL)
+# define HAVE_TANL 1
+# define tanl _tanl
+#endif
--- a/external/gpl3/gcc/usr.bin/gcc/arch/riscv32/auto-host.h	Wed Apr 17 07:55:33 2019 +0000
+++ b/external/gpl3/gcc/usr.bin/gcc/arch/riscv32/auto-host.h	Wed Apr 17 08:56:10 2019 +0000
@@ -1802,7 +1802,7 @@
 
 
 /* Define if your target C library provides sys/sdt.h */
-/* #undef HAVE_SYS_SDT_H */
+#define HAVE_SYS_SDT_H 1
 
 /* Define to 1 if you have the <sys/stat.h> header file. */
 #ifndef USED_FOR_TARGET
--- a/external/gpl3/gcc/usr.bin/gcc/arch/riscv32/tm.h	Wed Apr 17 07:55:33 2019 +0000
+++ b/external/gpl3/gcc/usr.bin/gcc/arch/riscv32/tm.h	Wed Apr 17 08:56:10 2019 +0000
@@ -16,9 +16,6 @@
 #ifndef LIBC_MUSL
 # define LIBC_MUSL 4
 #endif
-#ifndef NETBSD_ENABLE_PTHREADS
-# define NETBSD_ENABLE_PTHREADS
-#endif
 #ifndef CHAR_FAST8
 # define CHAR_FAST8 1
 #endif
--- a/external/lgpl3/gmp/lib/libgmp/arch/riscv32/Makefile.inc	Wed Apr 17 07:55:33 2019 +0000
+++ b/external/lgpl3/gmp/lib/libgmp/arch/riscv32/Makefile.inc	Wed Apr 17 08:56:10 2019 +0000
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile.inc,v 1.1 2014/09/19 17:23:57 matt Exp $
+#	$NetBSD: Makefile.inc,v 1.2 2019/04/17 08:56:10 mrg Exp $
 
 SRCS+= \
 	random.c \
@@ -15,7 +15,6 @@
 	toom8h_mul.c \
 	zero.c \
 	mod_1_4.c \
-	gcdext.c \
 	add_err3_n.c \
 	binvert.c \
 	mu_div_q.c \
@@ -26,14 +25,12 @@
 	dcpi1_div_qr.c \
 	hgcd_reduce.c \
 	matrix22_mul1_inverse_vector.c \
-	tabselect.c \
 	toom6_sqr.c \
 	divrem_1.c \
 	hgcd_step.c \
 	sub_err3_n.c \
 	mod_1.c \
 	toom42_mulmid.c \
-	divexact.c \
 	jacobi.c \
 	powlo.c \
 	mul.c \
@@ -65,7 +62,6 @@
 	rshift.c \
 	div_q.c \
 	jacbase.c \
-	addcnd_n.c \
 	hgcd_matrix.c \
 	toom_eval_dgr3_pm1.c \
 	mullo_n.c \
@@ -77,7 +73,6 @@
 	add_1.c \
 	sqr_basecase.c \
 	toom_interpolate_5pts.c \
-	sbpi1_bdiv_q.c \
 	pre_mod_1.c \
 	hgcd.c \
 	bdiv_dbm1c.c \
@@ -97,11 +92,9 @@
 	sub_n.c \
 	toom_eval_pm2.c \
 	add_n.c \
-	subcnd_n.c \
 	hgcd2.c \
 	toom62_mul.c \
 	comb_tables.c \
-	sbpi1_bdiv_qr.c \
 	sub_err2_n.c \
 	scan1.c \
 	brootinv.c \
@@ -136,10 +129,8 @@
 	dive_1.c \
 	cmp.c \
 	toom_eval_pm1.c \
-	hgcd_appr.c \
 	scan0.c \
 	gcd_subdiv_step.c \
-	sbpi1_div_qr.c \
 	invert.c \
 	sub.c \
 	toom_eval_pm2rexp.c \
@@ -155,30 +146,187 @@
 	pow_1.c \
 	get_d.c \
 	toom52_mul.c \
-	sbpi1_div_q.c \
 	diveby3.c \
 	fib2_ui.c \
 	bdiv_qr.c \
 	hgcd_jacobi.c \
 	toom3_sqr.c \
-	gcd.c \
 	redc_n.c \
 	sub_err1_n.c \
 
 C_SRCS_LIST= \
-	xor_n.c			mpn/generic/logops_n.c \
-	sb_div_r_sec.c		mpn/generic/sb_div_sec.c \
-	nand_n.c		mpn/generic/logops_n.c \
-	nior_n.c		mpn/generic/logops_n.c \
+	random.c		mpn/generic/random.c \
+	toom_interpolate_7pts.c		mpn/generic/toom_interpolate_7pts.c \
+	sbpi1_divappr_q.c		mpn/generic/sbpi1_divappr_q.c \
+	random2.c		mpn/generic/random2.c \
+	mu_bdiv_q.c		mpn/generic/mu_bdiv_q.c \
+	mulmid_basecase.c		mpn/generic/mulmid_basecase.c \
+	jacobi_2.c		mpn/generic/jacobi_2.c \
+	toom32_mul.c		mpn/generic/toom32_mul.c \
+	toom44_mul.c		mpn/generic/toom44_mul.c \
+	toom8h_mul.c		mpn/generic/toom8h_mul.c \
+	toom2_sqr.c		mpn/generic/toom2_sqr.c \
+	zero.c		mpn/generic/zero.c \
+	mod_1_4.c		mpn/generic/mod_1_4.c \
+	gcdext.c		mpn/generic/gcdext.c \
 	hamdist.c		mpn/generic/popham.c \
-	popcount.c		mpn/generic/popham.c \
-	sbpi1_div_qr_sec.c	mpn/generic/sbpi1_div_sec.c \
-	and_n.c			mpn/generic/logops_n.c \
-	ior_n.c			mpn/generic/logops_n.c \
-	sb_div_qr_sec.c		mpn/generic/sb_div_sec.c \
+	sec_powm.c		mpn/generic/sec_powm.c \
+	add_err3_n.c		mpn/generic/add_err3_n.c \
+	binvert.c		mpn/generic/binvert.c \
+	mu_div_q.c		mpn/generic/mu_div_q.c \
+	and_n.c		mpn/generic/logops_n.c \
+	invertappr.c		mpn/generic/invertappr.c \
+	add_n_sub_n.c		mpn/generic/add_n_sub_n.c \
+	dump.c		mpn/generic/dump.c \
+	mu_divappr_q.c		mpn/generic/mu_divappr_q.c \
+	dcpi1_div_qr.c		mpn/generic/dcpi1_div_qr.c \
+	hgcd_reduce.c		mpn/generic/hgcd_reduce.c \
+	matrix22_mul1_inverse_vector.c		mpn/generic/matrix22_mul1_inverse_vector.c \
+	toom6_sqr.c		mpn/generic/toom6_sqr.c \
+	divrem_1.c		mpn/generic/divrem_1.c \
+	hgcd_step.c		mpn/generic/hgcd_step.c \
+	sub_err3_n.c		mpn/generic/sub_err3_n.c \
+	mod_1.c		mpn/generic/mod_1.c \
+	toom42_mulmid.c		mpn/generic/toom42_mulmid.c \
+	sec_div_qr.c		mpn/generic/sec_div.c \
+	andn_n.c		mpn/generic/logops_n.c \
+	divexact.c		mpn/generic/divexact.c \
+	jacobi.c		mpn/generic/jacobi.c \
+	powlo.c		mpn/generic/powlo.c \
+	mul.c		mpn/generic/mul.c \
+	set_str.c		mpn/generic/set_str.c \
+	toom42_mul.c		mpn/generic/toom42_mul.c \
+	toom_interpolate_6pts.c		mpn/generic/toom_interpolate_6pts.c \
+	toom54_mul.c		mpn/generic/toom54_mul.c \
+	dcpi1_divappr_q.c		mpn/generic/dcpi1_divappr_q.c \
+	toom_eval_dgr3_pm2.c		mpn/generic/toom_eval_dgr3_pm2.c \
+	mod_1_3.c		mpn/generic/mod_1_3.c \
+	xor_n.c		mpn/generic/logops_n.c \
+	nior_n.c		mpn/generic/logops_n.c \
+	toom_couple_handling.c		mpn/generic/toom_couple_handling.c \
+	add.c		mpn/generic/add.c \
+	div_qr_2.c		mpn/generic/div_qr_2.c \
+	toom_interpolate_12pts.c		mpn/generic/toom_interpolate_12pts.c \
+	perfsqr.c		mpn/generic/perfsqr.c \
+	toom53_mul.c		mpn/generic/toom53_mul.c \
+	toom_eval_pm2exp.c		mpn/generic/toom_eval_pm2exp.c \
+	mu_div_qr.c		mpn/generic/mu_div_qr.c \
+	toom_interpolate_16pts.c		mpn/generic/toom_interpolate_16pts.c \
+	bdiv_q.c		mpn/generic/bdiv_q.c \
+	sec_invert.c		mpn/generic/sec_invert.c \
+	toom22_mul.c		mpn/generic/toom22_mul.c \
+	bsqrtinv.c		mpn/generic/bsqrtinv.c \
+	toom4_sqr.c		mpn/generic/toom4_sqr.c \
+	div_q.c		mpn/generic/div_q.c \
+	jacbase.c		mpn/generic/jacbase.c \
+	sec_sqr.c		mpn/generic/sec_sqr.c \
+	hgcd_matrix.c		mpn/generic/hgcd_matrix.c \
+	toom_eval_dgr3_pm1.c		mpn/generic/toom_eval_dgr3_pm1.c \
+	mullo_n.c		mpn/generic/mullo_n.c \
+	toom33_mul.c		mpn/generic/toom33_mul.c \
+	mod_1_2.c		mpn/generic/mod_1_2.c \
+	sqrlo.c		mpn/generic/sqrlo.c \
+	sub_1.c		mpn/generic/sub_1.c \
+	add_err2_n.c		mpn/generic/add_err2_n.c \
+	trialdiv.c		mpn/generic/trialdiv.c \
+	add_1.c		mpn/generic/add_1.c \
+	sqr_basecase.c		mpn/generic/sqr_basecase.c \
+	toom_interpolate_5pts.c		mpn/generic/toom_interpolate_5pts.c \
+	sbpi1_bdiv_q.c		mpn/generic/sbpi1_bdiv_q.c \
+	pre_mod_1.c		mpn/generic/pre_mod_1.c \
+	hgcd.c		mpn/generic/hgcd.c \
+	div_qr_1.c		mpn/generic/div_qr_1.c \
+	sqrtrem.c		mpn/generic/sqrtrem.c \
+	bdiv_q_1.c		mpn/generic/bdiv_q_1.c \
+	gcdext_1.c		mpn/generic/gcdext_1.c \
+	toom63_mul.c		mpn/generic/toom63_mul.c \
+	div_qr_2u_pi1.c		mpn/generic/div_qr_2u_pi1.c \
+	mul_basecase.c		mpn/generic/mul_basecase.c \
+	toom8_sqr.c		mpn/generic/toom8_sqr.c \
+	neg.c		mpn/generic/neg.c \
+	gcdext_lehmer.c		mpn/generic/gcdext_lehmer.c \
+	divis.c		mpn/generic/divis.c \
+	dcpi1_div_q.c		mpn/generic/dcpi1_div_q.c \
+	sec_div_r.c		mpn/generic/sec_div.c \
+	toom_eval_pm2.c		mpn/generic/toom_eval_pm2.c \
+	hgcd2.c		mpn/generic/hgcd2.c \
+	toom62_mul.c		mpn/generic/toom62_mul.c \
+	comb_tables.c		mpn/generic/comb_tables.c \
+	sbpi1_bdiv_qr.c		mpn/generic/sbpi1_bdiv_qr.c \
+	sub_err2_n.c		mpn/generic/sub_err2_n.c \
+	scan1.c		mpn/generic/scan1.c \
+	brootinv.c		mpn/generic/brootinv.c \
+	pre_divrem_1.c		mpn/generic/pre_divrem_1.c \
+	perfpow.c		mpn/generic/perfpow.c \
+	get_str.c		mpn/generic/get_str.c \
+	mulmod_bnm1.c		mpn/generic/mulmod_bnm1.c \
+	mullo_basecase.c		mpn/generic/mullo_basecase.c \
+	ior_n.c		mpn/generic/logops_n.c \
+	tdiv_qr.c		mpn/generic/tdiv_qr.c \
+	sec_pi1_div_qr.c		mpn/generic/sec_pi1_div.c \
+	div_qr_2n_pi1.c		mpn/generic/div_qr_2n_pi1.c \
+	toom43_mul.c		mpn/generic/toom43_mul.c \
+	mod_1_1.c		mpn/generic/mod_1_1.c \
+	matrix22_mul.c		mpn/generic/matrix22_mul.c \
+	sec_pi1_div_r.c		mpn/generic/sec_pi1_div.c \
 	xnor_n.c		mpn/generic/logops_n.c \
 	iorn_n.c		mpn/generic/logops_n.c \
-	sbpi1_div_r_sec.c	mpn/generic/sbpi1_div_sec.c \
-	andn_n.c		mpn/generic/logops_n.c \
+	divrem.c		mpn/generic/divrem.c \
+	bsqrt.c		mpn/generic/bsqrt.c \
+	gcd_1.c		mpn/generic/gcd_1.c \
+	dcpi1_bdiv_qr.c		mpn/generic/dcpi1_bdiv_qr.c \
+	mul_n.c		mpn/generic/mul_n.c \
+	redc_2.c		mpn/generic/redc_2.c \
+	toom6h_mul.c		mpn/generic/toom6h_mul.c \
+	sqrmod_bnm1.c		mpn/generic/sqrmod_bnm1.c \
+	mul_fft.c		mpn/generic/mul_fft.c \
+	mulmid.c		mpn/generic/mulmid.c \
+	powm.c		mpn/generic/powm.c \
+	rootrem.c		mpn/generic/rootrem.c \
+	cnd_sub_n.c		mpn/generic/cnd_sub_n.c \
+	cnd_add_n.c		mpn/generic/cnd_add_n.c \
+	toom_interpolate_8pts.c		mpn/generic/toom_interpolate_8pts.c \
+	remove.c		mpn/generic/remove.c \
+	lshiftc.c		mpn/generic/lshiftc.c \
+	sec_mul.c		mpn/generic/sec_mul.c \
+	cmp.c		mpn/generic/cmp.c \
+	toom_eval_pm1.c		mpn/generic/toom_eval_pm1.c \
+	nand_n.c		mpn/generic/logops_n.c \
+	hgcd_appr.c		mpn/generic/hgcd_appr.c \
+	cnd_swap.c		mpn/generic/cnd_swap.c \
+	scan0.c		mpn/generic/scan0.c \
+	gcd_subdiv_step.c		mpn/generic/gcd_subdiv_step.c \
+	sbpi1_div_qr.c		mpn/generic/sbpi1_div_qr.c \
+	invert.c		mpn/generic/invert.c \
+	sub.c		mpn/generic/sub.c \
+	sqrlo_basecase.c		mpn/generic/sqrlo_basecase.c \
+	toom_eval_pm2rexp.c		mpn/generic/toom_eval_pm2rexp.c \
+	sec_sub_1.c		mpn/generic/sec_aors_1.c \
+	broot.c		mpn/generic/broot.c \
+	sec_add_1.c		mpn/generic/sec_aors_1.c \
+	popcount.c		mpn/generic/popham.c \
+	dcpi1_bdiv_q.c		mpn/generic/dcpi1_bdiv_q.c \
+	hgcd2_jacobi.c		mpn/generic/hgcd2_jacobi.c \
+	add_err1_n.c		mpn/generic/add_err1_n.c \
+	mulmid_n.c		mpn/generic/mulmid_n.c \
+	redc_1.c		mpn/generic/redc_1.c \
+	sqr.c		mpn/generic/sqr.c \
+	nussbaumer_mul.c		mpn/generic/nussbaumer_mul.c \
+	zero_p.c		mpn/generic/zero_p.c \
+	mu_bdiv_qr.c		mpn/generic/mu_bdiv_qr.c \
+	pow_1.c		mpn/generic/pow_1.c \
+	get_d.c		mpn/generic/get_d.c \
+	toom52_mul.c		mpn/generic/toom52_mul.c \
+	sbpi1_div_q.c		mpn/generic/sbpi1_div_q.c \
+	diveby3.c		mpn/generic/diveby3.c \
+	fib2_ui.c		mpn/generic/fib2_ui.c \
+	bdiv_qr.c		mpn/generic/bdiv_qr.c \
+	hgcd_jacobi.c		mpn/generic/hgcd_jacobi.c \
+	div_qr_1n_pi1.c		mpn/generic/div_qr_1n_pi1.c \
+	sizeinbase.c		mpn/generic/sizeinbase.c \
+	toom3_sqr.c		mpn/generic/toom3_sqr.c \
+	gcd.c		mpn/generic/gcd.c \
+	redc_n.c		mpn/generic/redc_n.c \
+	sub_err1_n.c		mpn/generic/sub_err1_n.c
 
 GMP_LIMB_BITS=32
--- a/external/lgpl3/gmp/lib/libgmp/arch/riscv32/gmp.h	Wed Apr 17 07:55:33 2019 +0000
+++ b/external/lgpl3/gmp/lib/libgmp/arch/riscv32/gmp.h	Wed Apr 17 08:56:10 2019 +0000
@@ -1,23 +1,32 @@
 /* Definitions for GNU multiple precision functions.   -*- mode: c -*-
 
-Copyright 1991, 1993, 1994, 1995, 1996, 1997, 1999, 2000, 2001, 2002,
-2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Free
-Software Foundation, Inc.
+Copyright 1991, 1993-1997, 1999-2016 Free Software Foundation, Inc.
 
 This file is part of the GNU MP Library.
 
 The GNU MP Library is free software; you can redistribute it and/or modify
-it under the terms of the GNU Lesser General Public License as published by
-the Free Software Foundation; either version 3 of the License, or (at your
-option) any later version.
+it under the terms of either:
+
+  * the GNU Lesser General Public License as published by the Free
+    Software Foundation; either version 3 of the License, or (at your
+    option) any later version.
+
+or
+
+  * the GNU General Public License as published by the Free Software
+    Foundation; either version 2 of the License, or (at your option) any
+    later version.
+
+or both in parallel, as here.
 
 The GNU MP Library 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 Lesser General Public
-License for more details.
-
-You should have received a copy of the GNU Lesser General Public License
-along with the GNU MP Library.  If not, see http://www.gnu.org/licenses/.  */
+or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+for more details.
+
+You should have received copies of the GNU General Public License and the
+GNU Lesser General Public License along with the GNU MP Library.  If not,
+see https://www.gnu.org/licenses/.  */
 
 #ifndef __GMP_H__
 
@@ -40,23 +49,15 @@
 #define GMP_NAIL_MASK     (~ GMP_NUMB_MASK)
 
 
-/* The following (everything under ifndef __GNU_MP__) must be identical in
-   gmp.h and mp.h to allow both to be included in an application or during
-   the library build.  */
 #ifndef __GNU_MP__
-#define __GNU_MP__ 5
-
-#define __need_size_t  /* tell gcc stddef.h we only want size_t */
-#if defined (__cplusplus)
-#include <cstddef>     /* for size_t */
-#else
+#define __GNU_MP__ 6
+
 #include <stddef.h>    /* for size_t */
-#endif
-#undef __need_size_t
+#include <limits.h>
 
 /* Instantiated by configure. */
 #if ! defined (__GMP_WITHIN_CONFIGURE)
-/* #undef _LONG_LONG_LIMB */
+#define _LONG_LONG_LIMB 1
 #define __GMP_LIBGMP_DLL  0
 #endif
 
@@ -228,8 +229,6 @@
 typedef __mpq_struct *mpq_ptr;
 
 
-/* This is not wanted in mp.h, so put it outside the __GNU_MP__ common
-   section. */
 #if __GMP_LIBGMP_DLL
 #ifdef __GMP_WITHIN_GMPXX
 /* compiling to go into a DLL libgmpxx */
@@ -264,7 +263,8 @@
   || defined (_MSL_STDIO_H)           /* Metrowerks */          \
   || defined (_STDIO_H_INCLUDED)      /* QNX4 */		\
   || defined (_ISO_STDIO_ISO_H)       /* Sun C++ */		\
-  || defined (__STDIO_LOADED)         /* VMS */
+  || defined (__STDIO_LOADED)         /* VMS */			\
+  || defined (__DEFINED_FILE)         /* musl */
 #define _GMP_H_HAVE_FILE 1
 #endif
 
@@ -276,16 +276,14 @@
 #define _GMP_H_HAVE_OBSTACK 1
 #endif
 
-/* The prototypes for gmp_vprintf etc are provided only if va_list is
-   available, via an application having included <stdarg.h> or <varargs.h>.
-   Usually va_list is a typedef so can't be tested directly, but C99
-   specifies that va_start is a macro (and it was normally a macro on past
-   systems too), so look for that.
+/* The prototypes for gmp_vprintf etc are provided only if va_list is defined,
+   via an application having included <stdarg.h>.  Usually va_list is a typedef
+   so can't be tested directly, but C99 specifies that va_start is a macro.
 
    <stdio.h> will define some sort of va_list for vprintf and vfprintf, but
    let's not bother trying to use that since it's not standard and since
    application uses for gmp_vprintf etc will almost certainly require the
-   whole <stdarg.h> or <varargs.h> anyway.  */
+   whole <stdarg.h> anyway.  */
 
 #ifdef va_start
 #define _GMP_H_HAVE_VA_LIST 1
@@ -359,10 +357,11 @@
     GCC 4.3 and above with -std=c99 or -std=gnu99 implements ISO C99
     inline semantics, unless -fgnu89-inline is used.  */
 #ifdef __GNUC__
-#if (defined __GNUC_STDC_INLINE__) || \
-    (__GNUC__ == 4 && __GNUC_MINOR__ >= 2) || \
-    (__GNUC__ > 4)
+#if (defined __GNUC_STDC_INLINE__) || (__GNUC__ == 4 && __GNUC_MINOR__ == 2) \
+  || (defined __GNUC_GNU_INLINE__ && defined __cplusplus)
 #define __GMP_EXTERN_INLINE extern __inline__ __attribute__ ((__gnu_inline__))
+#else
+#define __GMP_EXTERN_INLINE      extern __inline__
 #endif
 #define __GMP_INLINE_PROTOTYPES  1
 #endif
@@ -443,12 +442,6 @@
 #define __GMP_ABS(x)   ((x) >= 0 ? (x) : -(x))
 #define __GMP_MAX(h,i) ((h) > (i) ? (h) : (i))
 
-/* __GMP_USHRT_MAX is not "~ (unsigned short) 0" because short is promoted
-   to int by "~".  */
-#define __GMP_UINT_MAX   (~ (unsigned) 0)
-#define __GMP_ULONG_MAX  (~ (unsigned long) 0)
-#define __GMP_USHRT_MAX  ((unsigned short) ~0)
-
 
 /* __builtin_expect is in gcc 3.0, and not in 2.95. */
 #if __GMP_GNUC_PREREQ (3,0)
@@ -466,7 +459,7 @@
 #endif
 
 
-/* Allow direct user access to numerator and denominator of a mpq_t object.  */
+/* Allow direct user access to numerator and denominator of an mpq_t object.  */
 #define mpq_numref(Q) (&((Q)->_mp_num))
 #define mpq_denref(Q) (&((Q)->_mp_den))
 
@@ -483,8 +476,8 @@
 
 #define mp_get_memory_functions __gmp_get_memory_functions
 __GMP_DECLSPEC void mp_get_memory_functions (void *(**) (size_t),
-                                      void *(**) (void *, size_t, size_t),
-                                      void (**) (void *, size_t)) __GMP_NOTHROW;
+				      void *(**) (void *, size_t, size_t),
+				      void (**) (void *, size_t)) __GMP_NOTHROW;
 
 #define mp_bits_per_limb __gmp_bits_per_limb
 __GMP_DECLSPEC extern const int mp_bits_per_limb;
@@ -1116,6 +1109,22 @@
 #define mpz_eor __gmpz_xor
 __GMP_DECLSPEC void mpz_xor (mpz_ptr, mpz_srcptr, mpz_srcptr);
 
+#define mpz_limbs_read __gmpz_limbs_read
+__GMP_DECLSPEC mp_srcptr mpz_limbs_read (mpz_srcptr);
+
+#define mpz_limbs_write __gmpz_limbs_write
+__GMP_DECLSPEC mp_ptr mpz_limbs_write (mpz_ptr, mp_size_t);
+
+#define mpz_limbs_modify __gmpz_limbs_modify
+__GMP_DECLSPEC mp_ptr mpz_limbs_modify (mpz_ptr, mp_size_t);
+
+#define mpz_limbs_finish __gmpz_limbs_finish
+__GMP_DECLSPEC void mpz_limbs_finish (mpz_ptr, mp_size_t);
+
+#define mpz_roinit_n __gmpz_roinit_n
+__GMP_DECLSPEC mpz_srcptr mpz_roinit_n (mpz_ptr, mp_srcptr, mp_size_t);
+
+#define MPZ_ROINIT_N(xp, xs) {{0, (xs),(xp) }}
 
 /**************** Rational (i.e. Q) routines.  ****************/
 
@@ -1145,6 +1154,9 @@
 #define _mpq_cmp_ui __gmpq_cmp_ui
 __GMP_DECLSPEC int _mpq_cmp_ui (mpq_srcptr, unsigned long int, unsigned long int) __GMP_ATTRIBUTE_PURE;
 
+#define mpq_cmp_z __gmpq_cmp_z
+__GMP_DECLSPEC int mpq_cmp_z (mpq_srcptr, mpz_srcptr) __GMP_ATTRIBUTE_PURE;
+
 #define mpq_div __gmpq_div
 __GMP_DECLSPEC void mpq_div (mpq_ptr, mpq_srcptr, mpq_srcptr);
 
@@ -1252,6 +1264,9 @@
 #define mpf_cmp __gmpf_cmp
 __GMP_DECLSPEC int mpf_cmp (mpf_srcptr, mpf_srcptr) __GMP_NOTHROW __GMP_ATTRIBUTE_PURE;
 
+#define mpf_cmp_z __gmpf_cmp_z
+__GMP_DECLSPEC int mpf_cmp_z (mpf_srcptr, mpz_srcptr) __GMP_NOTHROW __GMP_ATTRIBUTE_PURE;
+
 #define mpf_cmp_d __gmpf_cmp_d
 __GMP_DECLSPEC int mpf_cmp_d (mpf_srcptr, double) __GMP_ATTRIBUTE_PURE;
 
@@ -1462,6 +1477,14 @@
 __GMP_DECLSPEC int mpn_cmp (mp_srcptr, mp_srcptr, mp_size_t) __GMP_NOTHROW __GMP_ATTRIBUTE_PURE;
 #endif
 
+#define mpn_zero_p __MPN(zero_p)
+#if __GMP_INLINE_PROTOTYPES || defined (__GMP_FORCE_mpn_zero_p)
+__GMP_DECLSPEC int mpn_zero_p (mp_srcptr, mp_size_t) __GMP_NOTHROW __GMP_ATTRIBUTE_PURE;
+#endif
+
+#define mpn_divexact_1 __MPN(divexact_1)
+__GMP_DECLSPEC void mpn_divexact_1 (mp_ptr, mp_srcptr, mp_size_t, mp_limb_t);
+
 #define mpn_divexact_by3(dst,src,size) \
   mpn_divexact_by3c (dst, src, size, __GMP_CAST (mp_limb_t, 0))
 
@@ -1480,6 +1503,9 @@
 #define mpn_divrem_2 __MPN(divrem_2)
 __GMP_DECLSPEC mp_limb_t mpn_divrem_2 (mp_ptr, mp_size_t, mp_ptr, mp_size_t, mp_srcptr);
 
+#define mpn_div_qr_1 __MPN(div_qr_1)
+__GMP_DECLSPEC mp_limb_t mpn_div_qr_1 (mp_ptr, mp_limb_t *, mp_srcptr, mp_size_t, mp_limb_t);
+
 #define mpn_div_qr_2 __MPN(div_qr_2)
 __GMP_DECLSPEC mp_limb_t mpn_div_qr_2 (mp_ptr, mp_ptr, mp_srcptr, mp_size_t, mp_srcptr);
 
@@ -1525,9 +1551,7 @@
 #endif
 
 #define mpn_com __MPN(com)
-#if __GMP_INLINE_PROTOTYPES || defined (__GMP_FORCE_mpn_com)
 __GMP_DECLSPEC void mpn_com (mp_ptr, mp_srcptr, mp_size_t);
-#endif
 
 #define mpn_perfect_square_p __MPN(perfect_square_p)
 __GMP_DECLSPEC int mpn_perfect_square_p (mp_srcptr, mp_size_t) __GMP_ATTRIBUTE_PURE;
@@ -1563,6 +1587,9 @@
 #define mpn_set_str __MPN(set_str)
 __GMP_DECLSPEC mp_size_t mpn_set_str (mp_ptr, const unsigned char *, size_t, int);
 
+#define mpn_sizeinbase __MPN(sizeinbase)
+__GMP_DECLSPEC size_t mpn_sizeinbase (mp_srcptr, mp_size_t, int);
+
 #define mpn_sqrtrem __MPN(sqrtrem)
 __GMP_DECLSPEC mp_size_t mpn_sqrtrem (mp_ptr, mp_ptr, mp_srcptr, mp_size_t);
 
@@ -1609,8 +1636,56 @@
 #define mpn_zero __MPN(zero)
 __GMP_DECLSPEC void mpn_zero (mp_ptr, mp_size_t);
 
-#define mpn_udiv_w_sdiv __MPN(udiv_w_sdiv)
-__GMP_DECLSPEC mp_limb_t mpn_udiv_w_sdiv (mp_limb_t *, mp_limb_t, mp_limb_t, mp_limb_t);
+#define mpn_cnd_add_n __MPN(cnd_add_n)
+__GMP_DECLSPEC mp_limb_t mpn_cnd_add_n (mp_limb_t, mp_ptr, mp_srcptr, mp_srcptr, mp_size_t);
+#define mpn_cnd_sub_n __MPN(cnd_sub_n)
+__GMP_DECLSPEC mp_limb_t mpn_cnd_sub_n (mp_limb_t, mp_ptr, mp_srcptr, mp_srcptr, mp_size_t);
+
+#define mpn_sec_add_1 __MPN(sec_add_1)
+__GMP_DECLSPEC mp_limb_t mpn_sec_add_1 (mp_ptr, mp_srcptr, mp_size_t, mp_limb_t, mp_ptr);
+#define mpn_sec_add_1_itch __MPN(sec_add_1_itch)
+__GMP_DECLSPEC mp_size_t mpn_sec_add_1_itch (mp_size_t) __GMP_ATTRIBUTE_PURE;
+
+#define mpn_sec_sub_1 __MPN(sec_sub_1)
+__GMP_DECLSPEC mp_limb_t mpn_sec_sub_1 (mp_ptr, mp_srcptr, mp_size_t, mp_limb_t, mp_ptr);
+#define mpn_sec_sub_1_itch __MPN(sec_sub_1_itch)
+__GMP_DECLSPEC mp_size_t mpn_sec_sub_1_itch (mp_size_t) __GMP_ATTRIBUTE_PURE;
+
+#define mpn_cnd_swap  __MPN(cnd_swap)
+__GMP_DECLSPEC void mpn_cnd_swap (mp_limb_t, volatile mp_limb_t *, volatile mp_limb_t *, mp_size_t);
+
+#define mpn_sec_mul __MPN(sec_mul)
+__GMP_DECLSPEC void mpn_sec_mul (mp_ptr, mp_srcptr, mp_size_t, mp_srcptr, mp_size_t, mp_ptr);
+#define mpn_sec_mul_itch __MPN(sec_mul_itch)
+__GMP_DECLSPEC mp_size_t mpn_sec_mul_itch (mp_size_t, mp_size_t) __GMP_ATTRIBUTE_PURE;
+
+#define mpn_sec_sqr __MPN(sec_sqr)
+__GMP_DECLSPEC void mpn_sec_sqr (mp_ptr, mp_srcptr, mp_size_t, mp_ptr);
+#define mpn_sec_sqr_itch __MPN(sec_sqr_itch)
+__GMP_DECLSPEC mp_size_t mpn_sec_sqr_itch (mp_size_t) __GMP_ATTRIBUTE_PURE;
+
+#define mpn_sec_powm __MPN(sec_powm)
+__GMP_DECLSPEC void mpn_sec_powm (mp_ptr, mp_srcptr, mp_size_t, mp_srcptr, mp_bitcnt_t, mp_srcptr, mp_size_t, mp_ptr);
+#define mpn_sec_powm_itch __MPN(sec_powm_itch)
+__GMP_DECLSPEC mp_size_t mpn_sec_powm_itch (mp_size_t, mp_bitcnt_t, mp_size_t) __GMP_ATTRIBUTE_PURE;
+
+#define mpn_sec_tabselect __MPN(sec_tabselect)
+__GMP_DECLSPEC void mpn_sec_tabselect (volatile mp_limb_t *, volatile const mp_limb_t *, mp_size_t, mp_size_t, mp_size_t);
+
+#define mpn_sec_div_qr __MPN(sec_div_qr)
+__GMP_DECLSPEC mp_limb_t mpn_sec_div_qr (mp_ptr, mp_ptr, mp_size_t, mp_srcptr, mp_size_t, mp_ptr);
+#define mpn_sec_div_qr_itch __MPN(sec_div_qr_itch)
+__GMP_DECLSPEC mp_size_t mpn_sec_div_qr_itch (mp_size_t, mp_size_t) __GMP_ATTRIBUTE_PURE;
+#define mpn_sec_div_r __MPN(sec_div_r)
+__GMP_DECLSPEC void mpn_sec_div_r (mp_ptr, mp_size_t, mp_srcptr, mp_size_t, mp_ptr);
+#define mpn_sec_div_r_itch __MPN(sec_div_r_itch)
+__GMP_DECLSPEC mp_size_t mpn_sec_div_r_itch (mp_size_t, mp_size_t) __GMP_ATTRIBUTE_PURE;
+
+#define mpn_sec_invert __MPN(sec_invert)
+__GMP_DECLSPEC int mpn_sec_invert (mp_ptr, mp_ptr, mp_srcptr, mp_size_t, mp_bitcnt_t, mp_ptr);
+#define mpn_sec_invert_itch __MPN(sec_invert_itch)
+__GMP_DECLSPEC mp_size_t mpn_sec_invert_itch (mp_size_t) __GMP_ATTRIBUTE_PURE;
+
 
 /**************** mpz inlines ****************/
 
@@ -1658,7 +1733,7 @@
 int
 mpz_fits_uint_p (mpz_srcptr __gmp_z) __GMP_NOTHROW
 {
-  __GMPZ_FITS_UTYPE_P (__gmp_z, __GMP_UINT_MAX);
+  __GMPZ_FITS_UTYPE_P (__gmp_z, UINT_MAX);
 }
 #endif
 
@@ -1669,7 +1744,7 @@
 int
 mpz_fits_ulong_p (mpz_srcptr __gmp_z) __GMP_NOTHROW
 {
-  __GMPZ_FITS_UTYPE_P (__gmp_z, __GMP_ULONG_MAX);
+  __GMPZ_FITS_UTYPE_P (__gmp_z, ULONG_MAX);
 }
 #endif
 
@@ -1680,7 +1755,7 @@
 int
 mpz_fits_ushort_p (mpz_srcptr __gmp_z) __GMP_NOTHROW
 {
-  __GMPZ_FITS_UTYPE_P (__gmp_z, __GMP_USHRT_MAX);
+  __GMPZ_FITS_UTYPE_P (__gmp_z, USHRT_MAX);
 }
 #endif
 
@@ -1697,7 +1772,7 @@
   /* This is a "#if" rather than a plain "if" so as to avoid gcc warnings
      about "<< GMP_NUMB_BITS" exceeding the type size, and to avoid Borland
      C++ 6.0 warnings about condition always true for something like
-     "__GMP_ULONG_MAX < GMP_NUMB_MASK".  */
+     "ULONG_MAX < GMP_NUMB_MASK".  */
 #if GMP_NAIL_BITS == 0 || defined (_LONG_LONG_LIMB)
   /* limb==long and no nails, or limb==longlong, one limb is enough */
   return (__gmp_n != 0 ? __gmp_l : 0);
@@ -1765,7 +1840,7 @@
   mp_bitcnt_t    __gmp_result;
 
   __gmp_usize = __gmp_u->_mp_size;
-  __gmp_result = (__gmp_usize < 0 ? __GMP_ULONG_MAX : 0);
+  __gmp_result = (__gmp_usize < 0 ? ULONG_MAX : 0);
   if (__GMP_LIKELY (__gmp_usize > 0))
     __gmp_result =  mpn_popcount (__gmp_u->_mp_d, __gmp_usize);
   return __gmp_result;
@@ -2088,6 +2163,22 @@
 }
 #endif
 
+#if defined (__GMP_EXTERN_INLINE) || defined (__GMP_FORCE_mpn_zero_p)
+#if ! defined (__GMP_FORCE_mpn_zero_p)
+__GMP_EXTERN_INLINE
+#endif
+int
+mpn_zero_p (mp_srcptr __gmp_p, mp_size_t __gmp_n) __GMP_NOTHROW
+{
+  /* if (__GMP_LIKELY (__gmp_n > 0)) */
+    do {
+      if (__gmp_p[--__gmp_n] != 0)
+	return 0;
+    } while (__gmp_n != 0);
+  return 1;
+}
+#endif
+
 #if defined (__GMP_EXTERN_INLINE) || defined (__GMP_FORCE_mpn_sub)
 #if ! defined (__GMP_FORCE_mpn_sub)
 __GMP_EXTERN_INLINE
@@ -2121,14 +2212,20 @@
 mp_limb_t
 mpn_neg (mp_ptr __gmp_rp, mp_srcptr __gmp_up, mp_size_t __gmp_n)
 {
-  mp_limb_t __gmp_ul, __gmp_cy;
-  __gmp_cy = 0;
-  do {
-      __gmp_ul = *__gmp_up++;
-      *__gmp_rp++ = -__gmp_ul - __gmp_cy;
-      __gmp_cy |= __gmp_ul != 0;
-  } while (--__gmp_n != 0);
-  return __gmp_cy;
+  while (*__gmp_up == 0) /* Low zero limbs are unchanged by negation. */
+    {
+      *__gmp_rp = 0;
+      if (!--__gmp_n) /* All zero */
+	return 0;
+      ++__gmp_up; ++__gmp_rp;
+    }
+
+  *__gmp_rp = (- *__gmp_up) & GMP_NUMB_MASK;
+
+  if (--__gmp_n) /* Higher limbs get complemented. */
+    mpn_com (++__gmp_rp, ++__gmp_up, __gmp_n);
+
+  return 1;
 }
 #endif
 
@@ -2147,17 +2244,18 @@
 #define mpz_cmp_ui(Z,UI) \
   (__builtin_constant_p (UI) && (UI) == 0				\
    ? mpz_sgn (Z) : _mpz_cmp_ui (Z,UI))
-#define mpz_cmp_si(Z,SI) \
-  (__builtin_constant_p (SI) && (SI) == 0 ? mpz_sgn (Z)			\
-   : __builtin_constant_p (SI) && (SI) > 0				\
-    ? _mpz_cmp_ui (Z, __GMP_CAST (unsigned long int, SI))		\
+#define mpz_cmp_si(Z,SI)						\
+  (__builtin_constant_p ((SI) >= 0) && (SI) >= 0			\
+   ? mpz_cmp_ui (Z, __GMP_CAST (unsigned long, SI))			\
    : _mpz_cmp_si (Z,SI))
-#define mpq_cmp_ui(Q,NUI,DUI) \
-  (__builtin_constant_p (NUI) && (NUI) == 0				\
-   ? mpq_sgn (Q) : _mpq_cmp_ui (Q,NUI,DUI))
-#define mpq_cmp_si(q,n,d)                       \
-  (__builtin_constant_p ((n) >= 0) && (n) >= 0  \
-   ? mpq_cmp_ui (q, __GMP_CAST (unsigned long, n), d) \
+#define mpq_cmp_ui(Q,NUI,DUI)					\
+  (__builtin_constant_p (NUI) && (NUI) == 0 ? mpq_sgn (Q)	\
+   : __builtin_constant_p ((NUI) == (DUI)) && (NUI) == (DUI)	\
+   ? mpz_cmp (mpq_numref (Q), mpq_denref (Q))			\
+   : _mpq_cmp_ui (Q,NUI,DUI))
+#define mpq_cmp_si(q,n,d)				\
+  (__builtin_constant_p ((n) >= 0) && (n) >= 0		\
+   ? mpq_cmp_ui (q, __GMP_CAST (unsigned long, n), d)	\
    : _mpq_cmp_si (q, n, d))
 #else
 #define mpz_cmp_ui(Z,UI) _mpz_cmp_ui (Z,UI)
@@ -2221,10 +2319,10 @@
 #define __GMP_CC "gcc -std=gnu99"
 #define __GMP_CFLAGS "-O2 -pedantic -m32"
 
-/* Major version number is the value of __GNU_MP__ too, above and in mp.h. */
-#define __GNU_MP_VERSION            5
+/* Major version number is the value of __GNU_MP__ too, above. */
+#define __GNU_MP_VERSION            6
 #define __GNU_MP_VERSION_MINOR      1
-#define __GNU_MP_VERSION_PATCHLEVEL 3
+#define __GNU_MP_VERSION_PATCHLEVEL 2
 #define __GNU_MP_RELEASE (__GNU_MP_VERSION * 10000 + __GNU_MP_VERSION_MINOR * 100 + __GNU_MP_VERSION_PATCHLEVEL)
 
 #define __GMP_H__