1 diff -ruN gcc-9-20190324/configure gcc-9-20190324.aros/configure
2 --- gcc-9-20190324/configure 2019-01-17 12:34:28.000000000 +0000
3 +++ gcc-9-20190324.aros/configure 2019-03-29 13:46:01.297414900 +0000
6 noconfigdirs="$noconfigdirs gdb sim tcl tk itcl"
9 + noconfigdirs="$noconfigdirs patch diff make tk tcl expect dejagnu autoconf automake texinfo bison send-pr gprof rcs guile perl itcl tix gnuserv gdb"
12 noconfigdirs="$noconfigdirs gdb"
16 host_makefile_frag="config/mh-ppc-aix"
23 diff -ruN gcc-9-20190324/configure.ac gcc-9-20190324.aros/configure.ac
24 --- gcc-9-20190324/configure.ac 2019-01-17 12:34:28.000000000 +0000
25 +++ gcc-9-20190324.aros/configure.ac 2019-03-29 13:46:01.304383400 +0000
28 noconfigdirs="$noconfigdirs gdb sim tcl tk itcl"
31 + noconfigdirs="$noconfigdirs patch diff make tk tcl expect dejagnu autoconf automake texinfo bison send-pr gprof rcs guile perl itcl tix gnuserv gdb"
34 noconfigdirs="$noconfigdirs gdb"
38 host_makefile_frag="config/mh-ppc-aix"
45 diff -ruN gcc-9-20190324/fixincludes/configure gcc-9-20190324.aros/fixincludes/configure
46 --- gcc-9-20190324/fixincludes/configure 2018-10-31 17:03:16.000000000 +0000
47 +++ gcc-9-20190324.aros/fixincludes/configure 2019-03-29 13:46:01.312382300 +0000
53 i?86-*-msdosdjgpp* | \
56 diff -ruN gcc-9-20190324/fixincludes/configure.ac gcc-9-20190324.aros/fixincludes/configure.ac
57 --- gcc-9-20190324/fixincludes/configure.ac 2018-10-31 17:03:16.000000000 +0000
58 +++ gcc-9-20190324.aros/fixincludes/configure.ac 2019-03-29 13:46:01.319414900 +0000
64 i?86-*-msdosdjgpp* | \
67 diff -ruN gcc-9-20190324/gcc/config/aarch64/aros.h gcc-9-20190324.aros/gcc/config/aarch64/aros.h
68 --- gcc-9-20190324/gcc/config/aarch64/aros.h 1970-01-01 00:00:00.000000000 +0000
69 +++ gcc-9-20190324.aros/gcc/config/aarch64/aros.h 2019-03-29 13:46:01.325499100 +0000
71 +/* Configuration file for ARM AROS EABI targets.
72 + Copyright (C) 2004, 2005, 2006, 2007, 2010
73 + Free Software Foundation, Inc.
74 + Contributed by Pavel Fedin
75 + Based on linux-eabi.h and other AROS targets
77 + This file is part of GCC.
79 + GCC is free software; you can redistribute it and/or modify it
80 + under the terms of the GNU General Public License as published
81 + by the Free Software Foundation; either version 3, or (at your
82 + option) any later version.
84 + GCC is distributed in the hope that it will be useful, but WITHOUT
85 + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
86 + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
87 + License for more details.
89 + You should have received a copy of the GNU General Public License
90 + along with GCC; see the file COPYING3. If not see
91 + <http://www.gnu.org/licenses/>. */
93 +/* On EABI GNU/Linux, we want both the BPABI builtins and the
94 + GNU/Linux builtins. */
95 +#undef TARGET_OS_CPP_BUILTINS
96 +#define TARGET_OS_CPP_BUILTINS() \
99 + builtin_define_std ("AROS"); \
100 + builtin_define ("AMIGA"); \
101 + builtin_define ("_AMIGA"); \
102 + builtin_assert ("system=posix"); \
105 + builtin_define ("__PIC__"); \
106 + builtin_define ("__pic__"); \
111 +/* TARGET_BIG_ENDIAN_DEFAULT is set in
112 + config.gcc for big endian configurations. */
113 +#undef TARGET_LINKER_EMULATION
114 +#if TARGET_BIG_ENDIAN_DEFAULT
115 +#define TARGET_LINKER_EMULATION "aarch64elfb_aros"
117 +#define TARGET_LINKER_EMULATION "aarch64elf_aros"
120 +#undef SUBTARGET_CPP_SPEC
121 +#define SUBTARGET_CPP_SPEC "-D__ELF__ %{!nostdinc:%{!nostdc:%{!noposixc: -idirafter %R/include/aros/posixc} -idirafter %R/include/aros/stdc}}"
123 +#undef SUBTARGET_EXTRA_LINK_SPEC
124 +#define SUBTARGET_EXTRA_LINK_SPEC " -m " TARGET_LINKER_EMULATION
126 +/* Provide a LINK_SPEC appropriate for AROS. */
128 +#define LINK_SPEC SUBTARGET_EXTRA_LINK_SPEC " -L %R/lib"
130 +/* Use own supplement to libgcc. */
132 +#define LIBGCC_SPEC "-lgcc"
134 diff -ruN gcc-9-20190324/gcc/config/aarch64/t-aros gcc-9-20190324.aros/gcc/config/aarch64/t-aros
135 --- gcc-9-20190324/gcc/config/aarch64/t-aros 1970-01-01 00:00:00.000000000 +0000
136 +++ gcc-9-20190324.aros/gcc/config/aarch64/t-aros 2019-03-29 13:46:01.329415500 +0000
138 +# Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
139 +# 2008, 2010 Free Software Foundation, Inc.
141 +# This file is part of GCC.
143 +# GCC is free software; you can redistribute it and/or modify
144 +# it under the terms of the GNU General Public License as published by
145 +# the Free Software Foundation; either version 3, or (at your option)
146 +# any later version.
148 +# GCC is distributed in the hope that it will be useful,
149 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
150 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
151 +# GNU General Public License for more details.
153 +# You should have received a copy of the GNU General Public License
154 +# along with GCC; see the file COPYING3. If not see
155 +# <http://www.gnu.org/licenses/>.
159 diff -ruN gcc-9-20190324/gcc/config/arm/aros.h gcc-9-20190324.aros/gcc/config/arm/aros.h
160 --- gcc-9-20190324/gcc/config/arm/aros.h 1970-01-01 00:00:00.000000000 +0000
161 +++ gcc-9-20190324.aros/gcc/config/arm/aros.h 2019-03-29 13:46:01.375415500 +0000
163 +/* Configuration file for ARM AROS EABI targets.
164 + Copyright (C) 2004, 2005, 2006, 2007, 2010
165 + Free Software Foundation, Inc.
166 + Contributed by Pavel Fedin
167 + Based on linux-eabi.h and other AROS targets
169 + This file is part of GCC.
171 + GCC is free software; you can redistribute it and/or modify it
172 + under the terms of the GNU General Public License as published
173 + by the Free Software Foundation; either version 3, or (at your
174 + option) any later version.
176 + GCC is distributed in the hope that it will be useful, but WITHOUT
177 + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
178 + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
179 + License for more details.
181 + You should have received a copy of the GNU General Public License
182 + along with GCC; see the file COPYING3. If not see
183 + <http://www.gnu.org/licenses/>. */
185 +/* On EABI GNU/Linux, we want both the BPABI builtins and the
186 + GNU/Linux builtins. */
187 +#undef TARGET_OS_CPP_BUILTINS
188 +#define TARGET_OS_CPP_BUILTINS() \
191 + TARGET_BPABI_CPP_BUILTINS(); \
192 + builtin_define_std ("AROS"); \
193 + builtin_define ("AMIGA"); \
194 + builtin_define ("_AMIGA"); \
195 + builtin_assert ("system=posix"); \
198 + builtin_define ("__PIC__"); \
199 + builtin_define ("__pic__"); \
204 +/* We default to a softfp ABI so that we are compatible
205 + with the Linux EABI (as used by the linker). */
206 +#undef TARGET_DEFAULT_FLOAT_ABI
207 +#define TARGET_DEFAULT_FLOAT_ABI ARM_FLOAT_ABI_SOFTFP
209 +/* We default to the "aapcs-linux" ABI so that enums are int-sized by
211 +#undef ARM_DEFAULT_ABI
212 +#define ARM_DEFAULT_ABI ARM_ABI_AAPCS_LINUX
214 +/* Default to armv5t so that thumb shared libraries work.
215 + The ARM10TDMI core is the default for armv5t, so set
216 + SUBTARGET_CPU_DEFAULT to achieve this. */
217 +#undef SUBTARGET_CPU_DEFAULT
218 +#define SUBTARGET_CPU_DEFAULT TARGET_CPU_arm10tdmi
220 +/* TARGET_BIG_ENDIAN_DEFAULT is set in
221 + config.gcc for big endian configurations. */
222 +#undef TARGET_LINKER_EMULATION
223 +#if TARGET_BIG_ENDIAN_DEFAULT
224 +#define TARGET_LINKER_EMULATION "armelfb_aros"
226 +#define TARGET_LINKER_EMULATION "armelf_aros"
229 +#undef SUBTARGET_CPP_SPEC
230 +#define SUBTARGET_CPP_SPEC "-D__ELF__ %{!nostdinc:%{!nostdc:%{!noposixc: -idirafter %R/include/aros/posixc} -idirafter %R/include/aros/stdc}}"
232 +#undef SUBTARGET_EXTRA_LINK_SPEC
233 +#define SUBTARGET_EXTRA_LINK_SPEC " -m " TARGET_LINKER_EMULATION
235 +/* Provide a LINK_SPEC appropriate for AROS. */
237 +#define LINK_SPEC SUBTARGET_EXTRA_LINK_SPEC " -L %R/lib"
239 +/* Use own supplement to libgcc. */
241 +#define LIBGCC_SPEC "-laeabi -lgcc"
243 +/* FIXME: AROS doesn't support dw2 unwinding yet. */
244 +#undef MD_FALLBACK_FRAME_STATE_FOR
245 diff -ruN gcc-9-20190324/gcc/config/arm/t-aros gcc-9-20190324.aros/gcc/config/arm/t-aros
246 --- gcc-9-20190324/gcc/config/arm/t-aros 1970-01-01 00:00:00.000000000 +0000
247 +++ gcc-9-20190324.aros/gcc/config/arm/t-aros 2019-03-29 13:46:01.379417300 +0000
249 +# Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
250 +# 2008, 2010 Free Software Foundation, Inc.
252 +# This file is part of GCC.
254 +# GCC is free software; you can redistribute it and/or modify
255 +# it under the terms of the GNU General Public License as published by
256 +# the Free Software Foundation; either version 3, or (at your option)
257 +# any later version.
259 +# GCC is distributed in the hope that it will be useful,
260 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
261 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
262 +# GNU General Public License for more details.
264 +# You should have received a copy of the GNU General Public License
265 +# along with GCC; see the file COPYING3. If not see
266 +# <http://www.gnu.org/licenses/>.
268 +# Enumeration of multilibs
270 +MULTILIB_OPTIONS = marm march=armv6/march=armv7-a/march=armv7-a+simd
271 +MULTILIB_DIRNAMES = arm armv6 armv7-a armv7-a+simd
272 +MULTILIB_EXCEPTIONS =
277 +MULTILIB_OPTIONS += mfloat-abi=hard/mfloat-abi=soft
278 +MULTILIB_DIRNAMES += fpu soft
279 +MULTILIB_MATCHES += mfloat-abi?hard=mhard-float mfloat-abi?soft=msoft-float
281 +MULTILIB_OPTIONS += mbig-endian
282 +MULTILIB_DIRNAMES += eb
283 diff -ruN gcc-9-20190324/gcc/config/aros-stdint.h gcc-9-20190324.aros/gcc/config/aros-stdint.h
284 --- gcc-9-20190324/gcc/config/aros-stdint.h 1970-01-01 00:00:00.000000000 +0000
285 +++ gcc-9-20190324.aros/gcc/config/aros-stdint.h 2019-03-29 13:46:01.383396100 +0000
287 +/* Definitions for <stdint.h> types for AROS systems.
288 + Copyright (C) 2018 Free Software Foundation, Inc.
289 + Contributed by Nick Andrews <kalamatee@gmail.com>
291 +This file is part of GCC.
293 +GCC is free software; you can redistribute it and/or modify
294 +it under the terms of the GNU General Public License as published by
295 +the Free Software Foundation; either version 3, or (at your option)
298 +GCC is distributed in the hope that it will be useful,
299 +but WITHOUT ANY WARRANTY; without even the implied warranty of
300 +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
301 +GNU General Public License for more details.
303 +Under Section 7 of GPL version 3, you are granted additional
304 +permissions described in the GCC Runtime Library Exception, version
305 +3.1, as published by the Free Software Foundation.
307 +You should have received a copy of the GNU General Public License and
308 +a copy of the GCC Runtime Library Exception along with this program;
309 +see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
310 +<http://www.gnu.org/licenses/>. */
312 +#define SIG_ATOMIC_TYPE "int"
314 +#define INT8_TYPE "signed char"
315 +#define INT16_TYPE "short int"
316 +#define INT32_TYPE "int"
317 +#define INT64_TYPE (LONG_TYPE_SIZE == 64 ? "long int" : "long long int")
318 +#define UINT8_TYPE "unsigned char"
319 +#define UINT16_TYPE "short unsigned int"
320 +#define UINT32_TYPE "unsigned int"
321 +#define UINT64_TYPE (LONG_TYPE_SIZE == 64 ? "long unsigned int" : "long long unsigned int")
323 +#define INT_LEAST8_TYPE INT8_TYPE
324 +#define INT_LEAST16_TYPE INT16_TYPE
325 +#define INT_LEAST32_TYPE INT32_TYPE
326 +#define INT_LEAST64_TYPE INT64_TYPE
327 +#define UINT_LEAST8_TYPE UINT8_TYPE
328 +#define UINT_LEAST16_TYPE UINT16_TYPE
329 +#define UINT_LEAST32_TYPE UINT32_TYPE
330 +#define UINT_LEAST64_TYPE UINT64_TYPE
332 +#define INT_FAST8_TYPE INT32_TYPE
333 +#define INT_FAST16_TYPE INT32_TYPE
334 +#define INT_FAST32_TYPE INT32_TYPE
335 +#define INT_FAST64_TYPE INT64_TYPE
336 +#define UINT_FAST8_TYPE UINT32_TYPE
337 +#define UINT_FAST16_TYPE UINT32_TYPE
338 +#define UINT_FAST32_TYPE UINT32_TYPE
339 +#define UINT_FAST64_TYPE UINT64_TYPE
341 +#define INTPTR_TYPE (LONG_TYPE_SIZE == 64 ? INT64_TYPE : INT32_TYPE)
342 +#define UINTPTR_TYPE (LONG_TYPE_SIZE == 64 ? UINT64_TYPE : UINT32_TYPE)
343 diff -ruN gcc-9-20190324/gcc/config/aros.h gcc-9-20190324.aros/gcc/config/aros.h
344 --- gcc-9-20190324/gcc/config/aros.h 1970-01-01 00:00:00.000000000 +0000
345 +++ gcc-9-20190324.aros/gcc/config/aros.h 2019-03-29 13:46:01.388389900 +0000
347 +/* Definitions for AROS
348 + Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
349 + Contributed by Fabio Alemagna
350 + Based upon linux.h, contributed by Eric Youngdale.
352 +This file is part of GNU CC.
354 +GNU CC is free software; you can redistribute it and/or modify
355 +it under the terms of the GNU General Public License as published by
356 +the Free Software Foundation; either version 2, or (at your option)
359 +GNU CC is distributed in the hope that it will be useful,
360 +but WITHOUT ANY WARRANTY; without even the implied warranty of
361 +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
362 +GNU General Public License for more details.
364 +You should have received a copy of the GNU General Public License
365 +along with GNU CC; see the file COPYING. If not, write to
366 +the Free Software Foundation, 59 Temple Place - Suite 330,
367 +Boston, MA 02111-1307, USA. */
370 +#define SIZE_TYPE "long unsigned int"
373 +#define WCHAR_TYPE "char"
375 +#undef WCHAR_TYPE_SIZE
376 +#define WCHAR_TYPE_SIZE 8
379 +#define PTRDIFF_TYPE "long int"
381 +#undef TARGET_OS_CPP_BUILTINS
382 +#define TARGET_OS_CPP_BUILTINS() \
385 + builtin_define_std ("AROS"); \
386 + builtin_define ("AMIGA"); \
387 + builtin_define ("_AMIGA"); \
388 + builtin_define ("__ELF__"); \
389 + builtin_assert ("system=posix"); \
394 +#define ASM_APP_ON "#APP\n"
397 +#define ASM_APP_OFF "#NO_APP\n"
399 +#undef MD_EXEC_PREFIX
400 +#undef MD_STARTFILE_PREFIX
402 +/* Provide a STARTFILE_SPEC appropriate for AROS. AROS has its own
403 + set of startup files which also take care of handling C++
404 + constructors/destructors. */
406 +#undef STARTFILE_SPEC
407 +#define STARTFILE_SPEC \
408 + "startup%O%s %{detach:detach%O%s} %{nix:nixmain%O%s}"
410 +/* Provide a ENDFILE_SPEC appropriate for AROS. */
413 +#define ENDFILE_SPEC \
416 +/* The compiler is configured with ONLY the gcc/g++ standard headers.
417 + N.B-: NATIVE_SYSTEM_HEADER_DIR must come after GCC_INCLUDE_DIR with gcc6!! */
418 +#undef INCLUDE_DEFAULTS
419 +#define INCLUDE_DEFAULTS \
421 + { GPLUSPLUS_INCLUDE_DIR, "G++", 1, 1, GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT, 0 }, \
422 + { GPLUSPLUS_TOOL_INCLUDE_DIR, "G++", 1, 1, GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT, 1 }, \
423 + { GPLUSPLUS_BACKWARD_INCLUDE_DIR, "G++", 1, 1, GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT, 0 }, \
424 + { GCC_INCLUDE_DIR, "GCC", 0, 0, 0, 0 }, \
425 + { NATIVE_SYSTEM_HEADER_DIR, NATIVE_SYSTEM_HEADER_COMPONENT, 0, 0, 1, 0 }, \
426 + { 0, 0, 0, 0, 0, 0 } \
430 +#define CPP_SPEC "%(cpp_cpu) %{fPIC:-D__PIC__ -D__pic__} %{fpic:-D__PIC__ -D__pic__} %{posix:-D_POSIX_SOURCE} %{pthread:-D_REENTRANT} %{nix:-D__NIX__} %{!nostdinc:%{!nostdc:%{!noposixc:-idirafter %R/include/aros/posixc} -idirafter %R/include/aros/stdc}}"
432 +/* This is for -profile to use -lc_p instead of -lc. */
434 +#define CC1_SPEC "%{profile:-p}"
437 +/* The GNU C++ standard library requires that these macros be defined. */
438 +#undef CPLUSPLUS_CPP_SPEC
439 +#define CPLUSPLUS_CPP_SPEC "-D_GNU_SOURCE %(cpp)"
443 + "--start-group -lmui -larossupport -lamiga %{!nostartfiles:%{!static:%{!nostdc:%{!noposixc:-lposixc} -lstdcio -lstdc}}%{static:%{!nostdc:-lstdc.static}}} -lcodesets -lkeymap -lexpansion -lcommodities -ldiskfont -lasl -lmuimaster -ldatatypes -lcybergraphics -lworkbench -licon -lintuition -lgadtools -llayers -laros -lpartition -liffparse -lgraphics -llocale -ldos -lutility -loop %{!nosysbase:-lexec} -lautoinit -llibinit %{nostartfiles:%{static:-lstdc.static}} --end-group"
445 +#undef LIBSTDCXX_STATIC
446 +#define LIBSTDCXX_STATIC "pthread"
448 +#if !defined(USE_GNULIBC_1) && defined(HAVE_LD_EH_FRAME_HDR)
449 +#define LINK_EH_SPEC "%{!static:--eh-frame-hdr} "
452 +/* AROS uses its own collect-like program for the moment. */
454 +#define LINKER_NAME "collect-aros"
456 +#define TARGET_HAS_F_SETLKW
458 +#define TARGET_POSIX_IO
459 diff -ruN gcc-9-20190324/gcc/config/aros.opt gcc-9-20190324.aros/gcc/config/aros.opt
460 --- gcc-9-20190324/gcc/config/aros.opt 1970-01-01 00:00:00.000000000 +0000
461 +++ gcc-9-20190324.aros/gcc/config/aros.opt 2019-03-29 13:46:01.392389200 +0000
463 +; Processor-independent options for AROS.
465 +; Copyright (C) 2015 Free Software Foundation, Inc.
467 +; This file is part of GCC.
469 +; GCC is free software; you can redistribute it and/or modify it under
470 +; the terms of the GNU General Public License as published by the Free
471 +; Software Foundation; either version 3, or (at your option) any later
474 +; GCC is distributed in the hope that it will be useful, but WITHOUT ANY
475 +; WARRANTY; without even the implied warranty of MERCHANTABILITY or
476 +; FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
479 +; You should have received a copy of the GNU General Public License
480 +; along with GCC; see the file COPYING3. If not see
481 +; <http://www.gnu.org/licenses/>.
498 diff -ruN gcc-9-20190324/gcc/config/i386/aros.h gcc-9-20190324.aros/gcc/config/i386/aros.h
499 --- gcc-9-20190324/gcc/config/i386/aros.h 1970-01-01 00:00:00.000000000 +0000
500 +++ gcc-9-20190324.aros/gcc/config/i386/aros.h 2019-03-29 13:46:01.397420300 +0000
502 +/* Definitions for Intel 386 running AROS systems with ELF format.
503 + Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002
504 + Free Software Foundation, Inc.
505 + Contributed by Fabio Alemagna.
506 + Based upon i386/linux.h by Eric Youngdale.
508 +This file is part of GNU CC.
510 +GNU CC is free software; you can redistribute it and/or modify
511 +it under the terms of the GNU General Public License as published by
512 +the Free Software Foundation; either version 2, or (at your option)
515 +GNU CC is distributed in the hope that it will be useful,
516 +but WITHOUT ANY WARRANTY; without even the implied warranty of
517 +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
518 +GNU General Public License for more details.
520 +You should have received a copy of the GNU General Public License
521 +along with GNU CC; see the file COPYING. If not, write to
522 +the Free Software Foundation, 59 Temple Place - Suite 330,
523 +Boston, MA 02111-1307, USA. */
526 +#define LINK_SPEC "-m elf_i386 -L%R/lib"
527 diff -ruN gcc-9-20190324/gcc/config/i386/aros64.h gcc-9-20190324.aros/gcc/config/i386/aros64.h
528 --- gcc-9-20190324/gcc/config/i386/aros64.h 1970-01-01 00:00:00.000000000 +0000
529 +++ gcc-9-20190324.aros/gcc/config/i386/aros64.h 2019-03-29 13:46:01.401414900 +0000
531 +/* Definitions for AMD x86_64 running AROS systems with ELF64 format.
532 + Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002
533 + Free Software Foundation, Inc.
534 + Contributed by Stanislaw Szymczyk <sszymczy@gmail.com>. Based on aros.h.
536 +This file is part of GNU CC.
538 +GNU CC is free software; you can redistribute it and/or modify
539 +it under the terms of the GNU General Public License as published by
540 +the Free Software Foundation; either version 2, or (at your option)
543 +GNU CC is distributed in the hope that it will be useful,
544 +but WITHOUT ANY WARRANTY; without even the implied warranty of
545 +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
546 +GNU General Public License for more details.
548 +You should have received a copy of the GNU General Public License
549 +along with GNU CC; see the file COPYING. If not, write to
550 +the Free Software Foundation, 59 Temple Place - Suite 330,
551 +Boston, MA 02111-1307, USA. */
553 +/* The svr4 ABI for the i386 says that records and unions are returned
554 + in memory. In the 64bit compilation we will turn this flag off in
555 + override_options, as we never do pcc_struct_return scheme on this target. */
556 +#undef DEFAULT_PCC_STRUCT_RETURN
557 +#define DEFAULT_PCC_STRUCT_RETURN 1
559 +/* Provide a LINK_SPEC appropriate for AROS. */
562 +#define LINK_SPEC "%{!m32:-m elf_x86_64} %{m32:-m elf_i386} -L %R/lib"
564 +/* FIXME: AROS doesn't support dw2 unwinding yet. */
565 diff -ruN gcc-9-20190324/gcc/config/m68k/m68k.c gcc-9-20190324.aros/gcc/config/m68k/m68k.c
566 --- gcc-9-20190324/gcc/config/m68k/m68k.c 2019-03-11 13:58:44.000000000 +0000
567 +++ gcc-9-20190324.aros/gcc/config/m68k/m68k.c 2019-03-29 13:46:01.407428500 +0000
568 @@ -4482,7 +4482,7 @@
569 else if (letter == '/')
570 asm_fprintf (file, "%R");
571 else if (letter == '?')
572 - asm_fprintf (file, m68k_library_id_string);
573 + asm_fprintf (file, "%s", m68k_library_id_string);
574 else if (letter == 'p')
576 output_addr_const (file, op);
577 diff -ruN gcc-9-20190324/gcc/config/m68k/m68k.h gcc-9-20190324.aros/gcc/config/m68k/m68k.h
578 --- gcc-9-20190324/gcc/config/m68k/m68k.h 2019-01-01 12:31:55.000000000 +0000
579 +++ gcc-9-20190324.aros/gcc/config/m68k/m68k.h 2019-03-29 13:46:01.416387400 +0000
581 register elimination. */
582 #define FIRST_PSEUDO_REGISTER 25
584 -/* All m68k targets (except AmigaOS) use %a5 as the PIC register */
585 +/* All m68k targets (except AmigaOS) use %a5 as the PIC register.
586 + * On AmigaOS, we use %a4
588 #define PIC_OFFSET_TABLE_REGNUM \
589 (!flag_pic ? INVALID_REGNUM \
590 : reload_completed ? REGNO (pic_offset_table_rtx) \
592 /* Most m68k targets use %a6 as a frame pointer. The AmigaOS
593 ABI uses %a6 for shared library calls, therefore the frame
594 pointer is shifted to %a5 on this target. */
595 -#define FRAME_POINTER_REGNUM A6_REG
596 +#define FRAME_POINTER_REGNUM A5_REG
597 +#define PIC_REG A4_REG
599 /* Base register for access to arguments of the function.
600 * This isn't a hardware register. It will be eliminated to the
601 diff -ruN gcc-9-20190324/gcc/config/m68k/m68k.md gcc-9-20190324.aros/gcc/config/m68k/m68k.md
602 --- gcc-9-20190324/gcc/config/m68k/m68k.md 2019-01-01 12:31:55.000000000 +0000
603 +++ gcc-9-20190324.aros/gcc/config/m68k/m68k.md 2019-03-29 13:46:01.424383500 +0000
614 @@ -7166,7 +7167,7 @@
616 if (TARGET_ID_SHARED_LIBRARY)
618 - operands[1] = gen_rtx_REG (Pmode, PIC_REG);
619 + operands[1] = gen_rtx_REG (Pmode, A4_REG);
620 return MOTOROLA ? "move.l %?(%1),%0" : "movel %1@(%?), %0";
623 diff -ruN gcc-9-20190324/gcc/config/m68k/t-aros gcc-9-20190324.aros/gcc/config/m68k/t-aros
624 --- gcc-9-20190324/gcc/config/m68k/t-aros 1970-01-01 00:00:00.000000000 +0000
625 +++ gcc-9-20190324.aros/gcc/config/m68k/t-aros 2019-03-29 13:46:01.428409600 +0000
627 +# Custom multilibs for AROS
628 +M68K_MLIB_CPU += && match(MLIB, "^68")
629 diff -ruN gcc-9-20190324/gcc/config/rs6000/aros.h gcc-9-20190324.aros/gcc/config/rs6000/aros.h
630 --- gcc-9-20190324/gcc/config/rs6000/aros.h 1970-01-01 00:00:00.000000000 +0000
631 +++ gcc-9-20190324.aros/gcc/config/rs6000/aros.h 2019-03-29 13:46:01.433418500 +0000
633 +/* Definitions for Powerpc running AROS systems with ELF format.
634 + Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002
635 + Free Software Foundation, Inc.
636 + Contributed by Markus Weiss.
637 + Based upon i386/aros.h by Fabio Alemagna.
639 +This file is part of GNU CC.
641 +GNU CC is free software; you can redistribute it and/or modify
642 +it under the terms of the GNU General Public License as published by
643 +the Free Software Foundation; either version 2, or (at your option)
646 +GNU CC is distributed in the hope that it will be useful,
647 +but WITHOUT ANY WARRANTY; without even the implied warranty of
648 +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
649 +GNU General Public License for more details.
651 +You should have received a copy of the GNU General Public License
652 +along with GNU CC; see the file COPYING. If not, write to
653 +the Free Software Foundation, 59 Temple Place - Suite 330,
654 +Boston, MA 02111-1307, USA. */
656 +/* Symbols missing in comparison to i386/aros.h are either
657 + defined in elfos.h, rs6000/rs6000.h rs6000/sysv4.h
658 + or not needed for PowerPC.
661 +/* We need to define __powerpc__. */
663 +#undef TARGET_OS_CPP_BUILTINS
664 +#define TARGET_OS_CPP_BUILTINS() \
667 + builtin_define_std ("AROS"); \
668 + builtin_define ("AMIGA"); \
669 + builtin_define ("_AMIGA"); \
670 + builtin_define ("__powerpc__"); \
671 + builtin_define ("__ELF__"); \
672 + builtin_assert ("system=posix"); \
675 + builtin_define ("__PIC__"); \
676 + builtin_define ("__pic__"); \
681 +/* This one taken from linux.h. */
682 +/* We are 32-bit all the time, so optimize a little. */
684 +#define TARGET_64BIT 0
686 +/* The svr4 ABI for the i386 says that records and unions are returned
688 +/*#undef DEFAULT_PCC_STRUCT_RETURN
689 +#define DEFAULT_PCC_STRUCT_RETURN 1
694 +#undef ASM_COMMENT_START
695 +#define ASM_COMMENT_START "#"
700 +#undef DBX_REGISTER_NUMBER
701 +#define DBX_REGISTER_NUMBER(n) \
702 + (TARGET_64BIT ? dbx64_register_map[n] : svr4_dbx_register_map[n])
706 +/* Output assembler code to FILE to call the profiler.
707 + To the best of my knowledge, no Linux libc has required the label
708 + argument to mcount. */
711 +#define NO_PROFILE_COUNTERS 1
712 +not used by other similar ppc compilers
713 +only in darwin.h rs6000/linux64.h rs6000/rs6000.c
718 +#define MCOUNT_NAME "mcount"
719 +see rs6000/sysv4.h RS6000_MCOUNT
722 +/* The GLIBC version of mcount for the x86 assumes that there is a
723 + frame, so we cannot allow profiling without a frame pointer. */
725 +#undef SUBTARGET_FRAME_POINTER_REQUIRED
726 +#define SUBTARGET_FRAME_POINTER_REQUIRED crtl->profile
727 +seems to be handled by rs6000/rs6000.h
731 +#define CC1_SPEC "%(cc1_cpu) %{profile:-p}"
733 +/* Provide a LINK_SPEC appropriate for AROS. */
736 +#define LINK_SPEC "-m elf32ppc -L %R/lib"
738 +/* A C statement (sans semicolon) to output to the stdio stream
739 + FILE the assembler definition of uninitialized global DECL named
740 + NAME whose size is SIZE bytes and alignment is ALIGN bytes.
741 + Try to use asm_output_aligned_bss to implement this macro. */
743 +#define ASM_OUTPUT_ALIGNED_BSS(FILE, DECL, NAME, SIZE, ALIGN) \
744 + asm_output_aligned_bss (FILE, DECL, NAME, SIZE, ALIGN)
748 +/* A C statement to output to the stdio stream FILE an assembler
749 + command to advance the location counter to a multiple of 1<<LOG
750 + bytes if it is within MAX_SKIP bytes.
752 + This is used to align code labels according to Intel recommendations. */
754 +#ifdef HAVE_GAS_MAX_SKIP_P2ALIGN
755 +#define ASM_OUTPUT_MAX_SKIP_ALIGN(FILE,LOG,MAX_SKIP) \
757 + if ((LOG) != 0) { \
758 + if ((MAX_SKIP) == 0) fprintf ((FILE), "\t.p2align %d\n", (LOG)); \
759 + else fprintf ((FILE), "\t.p2align %d,,%d\n", (LOG), (MAX_SKIP)); \
766 +/* Handle special EH pointer encodings. Absolute, pc-relative, and
767 + indirect are handled automatically. */
769 +#define ASM_MAYBE_OUTPUT_ENCODED_ADDR_RTX(FILE, ENCODING, SIZE, ADDR, DONE) \
771 + if ((SIZE) == 4 && ((ENCODING) & 0x70) == DW_EH_PE_datarel) \
773 + fputs (ASM_LONG, FILE); \
774 + assemble_name (FILE, XSTR (ADDR, 0)); \
775 + fputs (((ENCODING) & DW_EH_PE_indirect ? "@GOT" : "@GOTOFF"), FILE); \
779 +not used for PowerPC
782 +/* FIXME: AROS doesn't support dw2 unwinding yet. */
783 +#undef MD_FALLBACK_FRAME_STATE_FOR
784 diff -ruN gcc-9-20190324/gcc/config/rs6000/rs6000.c gcc-9-20190324.aros/gcc/config/rs6000/rs6000.c
785 --- gcc-9-20190324/gcc/config/rs6000/rs6000.c 2019-03-24 20:26:53.000000000 +0000
786 +++ gcc-9-20190324.aros/gcc/config/rs6000/rs6000.c 2019-03-29 13:46:01.449499000 +0000
787 @@ -1526,6 +1526,8 @@
788 rs6000_handle_longcall_attribute, NULL },
789 { "shortcall", 0, 0, false, true, true, false,
790 rs6000_handle_longcall_attribute, NULL },
791 + { "stackparm", 0, 0, false, true, true, false,
792 + rs6000_handle_longcall_attribute, NULL },
793 { "ms_struct", 0, 0, false, false, false, false,
794 rs6000_handle_struct_attribute, NULL },
795 { "gcc_struct", 0, 0, false, false, false, false,
796 @@ -10809,6 +10811,9 @@
800 + cum->stackparm = fntype && lookup_attribute("stackparm",
801 + TYPE_ATTRIBUTES(fntype));
803 if (TARGET_DEBUG_ARG)
805 fprintf (stderr, "\ninit_cumulative_args:");
806 @@ -11893,6 +11898,9 @@
808 rs6000_discover_homogeneous_aggregate (mode, type, &elt_mode, &n_elts);
810 + if (cum->stackparm)
813 if (TARGET_MACHO && rs6000_darwin64_struct_check_p (mode, type))
815 rtx rslt = rs6000_darwin64_record_arg (cum, type, named, /*retval= */false);
816 @@ -12497,6 +12505,8 @@
818 /* Skip the last named argument. */
819 next_cum = *get_cumulative_args (cum);
820 + if (next_cum.stackparm)
822 rs6000_function_arg_advance_1 (&next_cum, mode, type, true, 0);
824 if (DEFAULT_ABI == ABI_V4)
825 diff -ruN gcc-9-20190324/gcc/config/rs6000/rs6000.h gcc-9-20190324.aros/gcc/config/rs6000/rs6000.h
826 --- gcc-9-20190324/gcc/config/rs6000/rs6000.h 2019-02-11 15:19:59.000000000 +0000
827 +++ gcc-9-20190324.aros/gcc/config/rs6000/rs6000.h 2019-03-29 13:46:01.465415600 +0000
828 @@ -1554,6 +1554,7 @@
829 int nargs_prototype; /* # args left in the current prototype */
830 int prototype; /* Whether a prototype was defined */
831 int stdarg; /* Whether function is a stdarg function. */
832 + int stackparm; /* Whether function has all args on the stack */
833 int call_cookie; /* Do special things for this call */
834 int sysv_gregno; /* next available GP register */
835 int intoffset; /* running offset in struct (darwin64) */
836 diff -ruN gcc-9-20190324/gcc/config/t-aros gcc-9-20190324.aros/gcc/config/t-aros
837 --- gcc-9-20190324/gcc/config/t-aros 1970-01-01 00:00:00.000000000 +0000
838 +++ gcc-9-20190324.aros/gcc/config/t-aros 2019-03-29 13:46:01.471415700 +0000
840 +# In AROS, "/usr" is a four-letter word.
841 +# Must match NATIVE_SYSTEM_HEADER_COMPONENT in aros.h !
842 +NATIVE_SYSTEM_HEADER_DIR = /include
844 +# Don't add AROS target include path when compiling host compiler
847 +# Copy AROS specific include replacement files
848 +LIBGCC_DEPS += stmp-aros-hrds
850 +EXTRA_AROS_HEADERS = aros/types/size_t.h aros/types/ptrdiff_t.h \
851 + aros/types/wchar_t.h aros/types/wint_t.h aros/types/null.h
853 +stmp-int-hdrs : | include/aros/types
855 +include/aros/types : $(addprefix $(srcdir)/ginclude/,$(EXTRA_AROS_HEADERS))
856 + -if [ -d include ] ; then true; else mkdir include; chmod a+rx include; fi
857 + -if [ -d include/aros/types ] ; \
860 + mkdir include/aros; chmod a+rx include/aros; \
861 + mkdir include/aros/types; chmod a+rx include/aros/types; \
863 + for file in $(EXTRA_AROS_HEADERS); do \
864 + $(STAMP) include/$$file; \
865 + rm -fr include/$$file; \
866 + cp $(srcdir)/ginclude/$$file include/$$file; \
867 + chmod a+r include/$$file; \
869 diff -ruN gcc-9-20190324/gcc/config.build gcc-9-20190324.aros/gcc/config.build
870 --- gcc-9-20190324/gcc/config.build 2019-01-01 12:31:55.000000000 +0000
871 +++ gcc-9-20190324.aros/gcc/config.build 2019-03-29 13:46:01.475460800 +0000
873 build_xm_file=i386/xm-djgpp.h
877 + build_xm_file=xm-aros.h
880 # All other System V variants.
881 build_install_headers_dir=install-headers-cpio
882 diff -ruN gcc-9-20190324/gcc/config.gcc gcc-9-20190324.aros/gcc/config.gcc
883 --- gcc-9-20190324/gcc/config.gcc 2019-03-02 00:36:22.000000000 +0000
884 +++ gcc-9-20190324.aros/gcc/config.gcc 2019-03-29 13:46:01.484384700 +0000
886 default_use_cxa_atexit=yes
887 target_has_targetdm=yes
890 + aros_tm_file="aros-stdint.h"
895 + xm_defines='STDC_HEADERS=1'
896 + extra_options="${extra_options} aros.opt"
900 tmake_file="t-openbsd"
901 case ${enable_threads} in
907 + tm_file="${tm_file} ${aros_tm_file} dbxelf.h elfos.h aarch64/aarch64-elf.h aros.h aarch64/aros.h"
908 + tmake_file="${tmake_file} aarch64/t-aarch64 aarch64/t-aros t-aros"
909 + xm_file="xm-aros.h"
912 + tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1"
916 aarch64*-*-elf | aarch64*-*-fuchsia* | aarch64*-*-rtems*)
917 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h"
918 tm_file="${tm_file} aarch64/aarch64-elf.h aarch64/aarch64-elf-raw.h"
919 @@ -1071,6 +1091,21 @@
920 tm_file="${tm_file} vms/vms.h alpha/vms.h"
921 tmake_file="${tmake_file} alpha/t-vms alpha/t-alpha"
924 + tm_file="${aros_tm_file} dbxelf.h elfos.h arm/elf.h arm/bpabi.h aros.h arm/aros.h arm/aout.h arm/arm.h"
925 + tm_file="${tm_file} ../../libgcc/config/arm/bpabi-lib.h"
926 + tmake_file="${tmake_file} arm/t-arm arm/t-arm-elf arm/t-arm-softfp arm/t-bpabi arm/t-aros t-aros"
927 + xm_file="xm-aros.h"
928 + # The BPABI long long divmod functions return a 128-bit value in
929 + # registers r0-r3. Correctly modeling that requires the use of
933 + tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1"
936 + need_64bit_hwint=yes
939 tm_file="arc/arc-arch.h dbxelf.h elfos.h newlib-stdint.h arc/elf.h ${tm_file}"
940 tmake_file="arc/t-multilib arc/t-arc"
941 @@ -1770,6 +1805,16 @@
943 TM_MULTILIB_CONFIG=`echo $TM_MULTILIB_CONFIG | sed 's/^,//'`
946 + tm_file="${tm_file} ${aros_tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h i386/i386elf.h aros.h i386/aros.h"
948 + tmake_file="${tmake_file} i386/t-i386elf t-aros"
951 + tm_file="${tm_file} ${aros_tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h i386/i386elf.h i386/x86-64.h aros.h i386/aros64.h"
952 + tmake_file="${tmake_file} i386/t-i386elf t-aros"
955 i[34567]86-pc-msdosdjgpp*)
956 xm_file=i386/xm-djgpp.h
957 tm_file="dbxcoff.h ${tm_file} i386/unix.h i386/bsd.h i386/gas.h i386/djgpp.h i386/djgpp-stdint.h"
958 @@ -2061,6 +2106,16 @@
963 + default_m68k_cpu=68000
964 + default_cf_cpu=5206
965 + tm_file="${tm_file} ${aros_tm_file} m68k/m68k-none.h m68k/m68kelf.h dbxelf.h elfos.h m68k/m68kemb.h m68k/m68020-elf.h"
966 + tm_file="${tm_file} aros.h"
967 + tm_defines="${tm_defines} MOTOROLA=1"
968 + tmake_file="${tmake_file} m68k/t-floatlib m68k/t-m68kbare m68k/t-m68kelf"
969 + tmake_file="${tmake_file} m68k/t-aros m68k/t-mlibs t-aros"
970 + extra_parts="crtbegin.o crtend.o"
972 m68k-*-elf* | fido-*-elf*)
975 @@ -2652,6 +2707,13 @@
976 extra_options="${extra_options} rs6000/sysv4.opt rs6000/linux64.opt"
977 tmake_file="${tmake_file} rs6000/t-fprules rs6000/t-rtems rs6000/t-ppccomm"
980 + tm_file="${tm_file} ${aros_tm_file} dbxelf.h elfos.h freebsd-spec.h rs6000/sysv4.h aros.h"
981 + extra_options="${extra_options} rs6000/sysv4.opt"
982 + tm_file="${tm_file} rs6000/aros.h"
984 + tmake_file="${tmake_file} t-aros"
987 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h freebsd-spec.h rs6000/sysv4.h"
988 extra_options="${extra_options} rs6000/sysv4.opt"
989 diff -ruN gcc-9-20190324/gcc/config.host gcc-9-20190324.aros/gcc/config.host
990 --- gcc-9-20190324/gcc/config.host 2019-01-01 12:31:55.000000000 +0000
991 +++ gcc-9-20190324.aros/gcc/config.host 2019-03-29 13:46:01.545416000 +0000
993 out_host_hook_obj=host-hpux.o
994 host_xmake_file="${host_xmake_file} x-hpux"
997 + host_can_use_collect2=no
998 + host_xm_file=xm-aros.h
1001 host_xm_file="vms/xm-vms.h"
1002 host_xmake_file=vms/x-vms
1003 diff -ruN gcc-9-20190324/gcc/ginclude/aros/types/null.h gcc-9-20190324.aros/gcc/ginclude/aros/types/null.h
1004 --- gcc-9-20190324/gcc/ginclude/aros/types/null.h 1970-01-01 00:00:00.000000000 +0000
1005 +++ gcc-9-20190324.aros/gcc/ginclude/aros/types/null.h 2019-03-29 13:46:01.550382200 +0000
1007 +/* Replace AROS' NULL definition with gcc's one */
1008 +#define __need_NULL
1009 +#include <stddef.h>
1010 diff -ruN gcc-9-20190324/gcc/ginclude/aros/types/ptrdiff_t.h gcc-9-20190324.aros/gcc/ginclude/aros/types/ptrdiff_t.h
1011 --- gcc-9-20190324/gcc/ginclude/aros/types/ptrdiff_t.h 1970-01-01 00:00:00.000000000 +0000
1012 +++ gcc-9-20190324.aros/gcc/ginclude/aros/types/ptrdiff_t.h 2019-03-29 13:46:01.555415300 +0000
1014 +/* Replace AROS' ptrdiff_t definition with gcc's one */
1015 +#define __need_ptrdiff_t
1016 +#include <stddef.h>
1017 diff -ruN gcc-9-20190324/gcc/ginclude/aros/types/size_t.h gcc-9-20190324.aros/gcc/ginclude/aros/types/size_t.h
1018 --- gcc-9-20190324/gcc/ginclude/aros/types/size_t.h 1970-01-01 00:00:00.000000000 +0000
1019 +++ gcc-9-20190324.aros/gcc/ginclude/aros/types/size_t.h 2019-03-29 13:46:01.559422800 +0000
1021 +/* Replace AROS' size_t definition with gcc's one */
1022 +#define __need_size_t
1023 +#include <stddef.h>
1024 diff -ruN gcc-9-20190324/gcc/ginclude/aros/types/wchar_t.h gcc-9-20190324.aros/gcc/ginclude/aros/types/wchar_t.h
1025 --- gcc-9-20190324/gcc/ginclude/aros/types/wchar_t.h 1970-01-01 00:00:00.000000000 +0000
1026 +++ gcc-9-20190324.aros/gcc/ginclude/aros/types/wchar_t.h 2019-03-29 13:46:01.564381700 +0000
1028 +/* Replace AROS' wchar_t definition with gcc's one */
1029 +#define __need_wchar_t
1030 +#include <stddef.h>
1031 diff -ruN gcc-9-20190324/gcc/ginclude/aros/types/wint_t.h gcc-9-20190324.aros/gcc/ginclude/aros/types/wint_t.h
1032 --- gcc-9-20190324/gcc/ginclude/aros/types/wint_t.h 1970-01-01 00:00:00.000000000 +0000
1033 +++ gcc-9-20190324.aros/gcc/ginclude/aros/types/wint_t.h 2019-03-29 13:46:01.567414800 +0000
1035 +/* Replace AROS' wint_t definition with gcc's one */
1036 +#define __need_wint_t
1037 +#include <stddef.h>
1038 diff -ruN gcc-9-20190324/gcc/ginclude/stddef.h gcc-9-20190324.aros/gcc/ginclude/stddef.h
1039 --- gcc-9-20190324/gcc/ginclude/stddef.h 2019-01-01 12:31:55.000000000 +0000
1040 +++ gcc-9-20190324.aros/gcc/ginclude/stddef.h 2019-03-29 13:46:01.574382500 +0000
1044 #ifndef _BSD_PTRDIFF_T_
1045 +#ifndef _AROS_TYPES_PTRDIFF_T_H
1046 #ifndef ___int_ptrdiff_t_h
1047 #ifndef _GCC_PTRDIFF_T
1048 #ifndef _PTRDIFF_T_DECLARED /* DragonFly */
1052 #define _BSD_PTRDIFF_T_
1053 +#define _AROS_TYPES_PTRDIFF_T_H
1054 #define ___int_ptrdiff_t_h
1055 #define _GCC_PTRDIFF_T
1056 #define _PTRDIFF_T_DECLARED
1058 #endif /* _PTRDIFF_T_DECLARED */
1059 #endif /* _GCC_PTRDIFF_T */
1060 #endif /* ___int_ptrdiff_t_h */
1061 +#endif /* _AROS_TYPES_PTRDIFF_T_H */
1062 #endif /* _BSD_PTRDIFF_T_ */
1063 #endif /* _PTRDIFF_T_ */
1064 #endif /* __PTRDIFF_T */
1068 #ifndef _BSD_SIZE_T_
1069 +#ifndef _AROS_TYPES_SIZE_T_H
1070 #ifndef _SIZE_T_DEFINED_
1071 #ifndef _SIZE_T_DEFINED
1072 #ifndef _BSD_SIZE_T_DEFINED_ /* Darwin */
1076 #define _BSD_SIZE_T_
1077 +#define _AROS_TYPES_SIZE_T_H
1078 #define _SIZE_T_DEFINED_
1079 #define _SIZE_T_DEFINED
1080 #define _BSD_SIZE_T_DEFINED_ /* Darwin */
1082 #endif /* _BSD_SIZE_T_DEFINED_ */
1083 #endif /* _SIZE_T_DEFINED */
1084 #endif /* _SIZE_T_DEFINED_ */
1085 +#endif /* _AROS_TYPES_SIZE_T_H */
1086 #endif /* _BSD_SIZE_T_ */
1087 #endif /* _SIZE_T_ */
1088 #endif /* __SIZE_T */
1089 diff -ruN gcc-9-20190324/include/filenames.h gcc-9-20190324.aros/include/filenames.h
1090 --- gcc-9-20190324/include/filenames.h 2019-01-01 12:31:55.000000000 +0000
1091 +++ gcc-9-20190324.aros/include/filenames.h 2019-03-29 13:46:01.705396000 +0000
1093 # define HAS_DRIVE_SPEC(f) HAS_DOS_DRIVE_SPEC (f)
1094 # define IS_DIR_SEPARATOR(c) IS_DOS_DIR_SEPARATOR (c)
1095 # define IS_ABSOLUTE_PATH(f) IS_DOS_ABSOLUTE_PATH (f)
1096 +#elif defined(__AROS__)
1097 +# ifndef HAVE_CASE_INSENSITIVE_FILE_SYSTEM
1098 +# define HAVE_CASE_INSENSITIVE_FILE_SYSTEM 1
1100 +# define HAS_DRIVE_SPEC(f) (0)
1101 +# define IS_DIR_SEPARATOR(c) ((c) == '/' || (c) == ':')
1102 +# define IS_ABSOLUTE_PATH(f) (IS_DIR_SEPARATOR((f)[0]) || (strchr((f), ':')))
1103 #else /* not DOSish */
1104 # if defined(__APPLE__)
1105 # ifndef HAVE_CASE_INSENSITIVE_FILE_SYSTEM
1106 diff -ruN gcc-9-20190324/libgcc/config.host gcc-9-20190324.aros/libgcc/config.host
1107 --- gcc-9-20190324/libgcc/config.host 2019-01-17 12:29:13.000000000 +0000
1108 +++ gcc-9-20190324.aros/libgcc/config.host 2019-03-29 13:46:01.724385100 +0000
1111 tmake_file="$tmake_file m32r/t-linux t-fdpbit"
1114 + tmake_file="$tmake_file m68k/t-floatlib"
1116 m68k-*-elf* | fido-*-elf)
1117 tmake_file="$tmake_file m68k/t-floatlib"
1119 @@ -1414,6 +1417,9 @@
1120 tmake_file="$tmake_file nvptx/t-nvptx"
1121 extra_parts="crt0.o"
1127 echo "*** Configuration ${host} not supported" 1>&2
1129 diff -ruN gcc-9-20190324/libgcc/gthr.h gcc-9-20190324.aros/libgcc/gthr.h
1130 --- gcc-9-20190324/libgcc/gthr.h 2019-01-01 12:31:55.000000000 +0000
1131 +++ gcc-9-20190324.aros/libgcc/gthr.h 2019-03-29 13:46:01.734437500 +0000
1132 @@ -141,6 +141,11 @@
1133 #define GTHREAD_USE_WEAK 0
1137 +#undef GTHREAD_USE_WEAK
1138 +#define GTHREAD_USE_WEAK 0
1141 #ifndef GTHREAD_USE_WEAK
1142 #define GTHREAD_USE_WEAK 1
1144 diff -ruN gcc-9-20190324/libgcc/unwind-dw2-fde.c gcc-9-20190324.aros/libgcc/unwind-dw2-fde.c
1145 --- gcc-9-20190324/libgcc/unwind-dw2-fde.c 2019-01-01 12:31:55.000000000 +0000
1146 +++ gcc-9-20190324.aros/libgcc/unwind-dw2-fde.c 2019-03-29 13:46:01.912384400 +0000
1147 @@ -100,8 +100,10 @@
1150 init_object_mutex_once ();
1151 +#ifndef __AROS__ /* This is called when SysBase is not yet set up */
1152 __gthread_mutex_lock (&object_mutex);
1156 ob->next = unseen_objects;
1157 unseen_objects = ob;
1158 #ifdef ATOMIC_FDE_FAST_PATH
1160 __atomic_store_n (&any_objects_registered, 1, __ATOMIC_RELAXED);
1164 __gthread_mutex_unlock (&object_mutex);
1169 diff -ruN gcc-9-20190324/libgcc/unwind-dw2.c gcc-9-20190324.aros/libgcc/unwind-dw2.c
1170 --- gcc-9-20190324/libgcc/unwind-dw2.c 2019-02-19 16:10:00.000000000 +0000
1171 +++ gcc-9-20190324.aros/libgcc/unwind-dw2.c 2019-03-29 13:46:01.918388000 +0000
1172 @@ -1563,7 +1563,9 @@
1174 init_dwarf_reg_size_table (void)
1176 +#ifdef MD_FALLBACK_FRAME_STATE_FOR
1177 __builtin_init_dwarf_reg_size_table (dwarf_reg_size_table);
1181 static void __attribute__((noinline))
1182 diff -ruN gcc-9-20190324/libiberty/filename_cmp.c gcc-9-20190324.aros/libiberty/filename_cmp.c
1183 --- gcc-9-20190324/libiberty/filename_cmp.c 2019-01-01 12:31:55.000000000 +0000
1184 +++ gcc-9-20190324.aros/libiberty/filename_cmp.c 2019-03-29 13:46:01.923417400 +0000
1187 filename_cmp (const char *s1, const char *s2)
1189 -#if !defined(HAVE_DOS_BASED_FILE_SYSTEM) \
1190 - && !defined(HAVE_CASE_INSENSITIVE_FILE_SYSTEM)
1191 +#if !defined(HAVE_DOS_BASED_FILE_SYSTEM)
1192 +#if defined(HAVE_CASE_INSENSITIVE_FILE_SYSTEM)
1193 + return strcasecmp(s1, s2);
1195 return strcmp(s1, s2);
1200 diff -ruN gcc-9-20190324/libobjc/configure gcc-9-20190324.aros/libobjc/configure
1201 --- gcc-9-20190324/libobjc/configure 2019-03-24 22:33:23.000000000 +0000
1202 +++ gcc-9-20190324.aros/libobjc/configure 2019-03-29 13:52:45.748395800 +0000
1203 @@ -11272,214 +11272,6 @@
1204 # Check if we have thread-local storage
1207 - # Check whether --enable-tls was given.
1208 -if test "${enable_tls+set}" = set; then :
1209 - enableval=$enable_tls;
1210 - case "$enableval" in
1212 - *) as_fn_error $? "Argument to enable/disable tls must be yes or no" "$LINENO" 5 ;;
1220 - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the target supports thread-local storage" >&5
1221 -$as_echo_n "checking whether the target supports thread-local storage... " >&6; }
1222 -if ${gcc_cv_have_tls+:} false; then :
1223 - $as_echo_n "(cached) " >&6
1226 - if test "$cross_compiling" = yes; then :
1227 - if test x$gcc_no_link = xyes; then
1228 - as_fn_error $? "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
1230 -cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1231 -/* end confdefs.h. */
1232 -__thread int a; int b; int main() { return a = b; }
1234 -if ac_fn_c_try_link "$LINENO"; then :
1235 - chktls_save_LDFLAGS="$LDFLAGS"
1238 - LDFLAGS="-shared -Wl,--no-undefined $LDFLAGS"
1241 - chktls_save_CFLAGS="$CFLAGS"
1242 - CFLAGS="-fPIC $CFLAGS"
1243 - if test x$gcc_no_link = xyes; then
1244 - as_fn_error $? "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
1246 -cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1247 -/* end confdefs.h. */
1248 -int f() { return 0; }
1250 -if ac_fn_c_try_link "$LINENO"; then :
1251 - if test x$gcc_no_link = xyes; then
1252 - as_fn_error $? "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
1254 -cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1255 -/* end confdefs.h. */
1256 -__thread int a; int b; int f() { return a = b; }
1258 -if ac_fn_c_try_link "$LINENO"; then :
1259 - gcc_cv_have_tls=yes
1261 - gcc_cv_have_tls=no
1263 -rm -f core conftest.err conftest.$ac_objext \
1264 - conftest$ac_exeext conftest.$ac_ext
1266 - gcc_cv_have_tls=yes
1268 -rm -f core conftest.err conftest.$ac_objext \
1269 - conftest$ac_exeext conftest.$ac_ext
1270 - CFLAGS="$chktls_save_CFLAGS"
1271 - LDFLAGS="$chktls_save_LDFLAGS"
1273 - gcc_cv_have_tls=no
1275 -rm -f core conftest.err conftest.$ac_objext \
1276 - conftest$ac_exeext conftest.$ac_ext
1280 - cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1281 -/* end confdefs.h. */
1282 -__thread int a; int b; int main() { return a = b; }
1284 -if ac_fn_c_try_run "$LINENO"; then :
1285 - chktls_save_LDFLAGS="$LDFLAGS"
1286 - LDFLAGS="-static $LDFLAGS"
1287 - if test x$gcc_no_link = xyes; then
1288 - as_fn_error $? "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
1290 -cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1291 -/* end confdefs.h. */
1292 -int main() { return 0; }
1294 -if ac_fn_c_try_link "$LINENO"; then :
1295 - if test "$cross_compiling" = yes; then :
1296 - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
1297 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
1298 -as_fn_error $? "cannot run test program while cross compiling
1299 -See \`config.log' for more details" "$LINENO" 5; }
1301 - cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1302 -/* end confdefs.h. */
1303 -__thread int a; int b; int main() { return a = b; }
1305 -if ac_fn_c_try_run "$LINENO"; then :
1306 - gcc_cv_have_tls=yes
1308 - gcc_cv_have_tls=no
1310 -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
1311 - conftest.$ac_objext conftest.beam conftest.$ac_ext
1315 - gcc_cv_have_tls=yes
1317 -rm -f core conftest.err conftest.$ac_objext \
1318 - conftest$ac_exeext conftest.$ac_ext
1319 - LDFLAGS="$chktls_save_LDFLAGS"
1320 - if test $gcc_cv_have_tls = yes; then
1321 - chktls_save_CFLAGS="$CFLAGS"
1322 - thread_CFLAGS=failed
1323 - for flag in '' '-pthread' '-lpthread'; do
1324 - CFLAGS="$flag $chktls_save_CFLAGS"
1325 - if test x$gcc_no_link = xyes; then
1326 - as_fn_error $? "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
1328 -cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1329 -/* end confdefs.h. */
1330 -#include <pthread.h>
1331 - void *g(void *d) { return NULL; }
1335 -pthread_t t; pthread_create(&t,NULL,g,NULL);
1340 -if ac_fn_c_try_link "$LINENO"; then :
1341 - thread_CFLAGS="$flag"
1343 -rm -f core conftest.err conftest.$ac_objext \
1344 - conftest$ac_exeext conftest.$ac_ext
1345 - if test "X$thread_CFLAGS" != Xfailed; then
1349 - CFLAGS="$chktls_save_CFLAGS"
1350 - if test "X$thread_CFLAGS" != Xfailed; then
1351 - CFLAGS="$thread_CFLAGS $chktls_save_CFLAGS"
1352 - if test "$cross_compiling" = yes; then :
1353 - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
1354 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
1355 -as_fn_error $? "cannot run test program while cross compiling
1356 -See \`config.log' for more details" "$LINENO" 5; }
1358 - cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1359 -/* end confdefs.h. */
1360 -#include <pthread.h>
1362 - static int *volatile a_in_other_thread;
1364 - thread_func (void *arg)
1366 - a_in_other_thread = &a;
1373 - void *thread_retval;
1374 - int *volatile a_in_main_thread;
1375 - a_in_main_thread = &a;
1376 - if (pthread_create (&thread, (pthread_attr_t *)0,
1377 - thread_func, (void *)0))
1379 - if (pthread_join (thread, &thread_retval))
1381 - return (a_in_other_thread == a_in_main_thread);
1386 -if ac_fn_c_try_run "$LINENO"; then :
1387 - gcc_cv_have_tls=yes
1389 - gcc_cv_have_tls=no
1391 -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
1392 - conftest.$ac_objext conftest.beam conftest.$ac_ext
1395 - CFLAGS="$chktls_save_CFLAGS"
1399 - gcc_cv_have_tls=no
1401 -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
1402 - conftest.$ac_objext conftest.beam conftest.$ac_ext
1406 -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_have_tls" >&5
1407 -$as_echo "$gcc_cv_have_tls" >&6; }
1408 - if test "$enable_tls $gcc_cv_have_tls" = "yes yes"; then
1410 -$as_echo "#define HAVE_TLS 1" >>confdefs.h
1415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the type of bitfields matters" >&5
1416 $as_echo_n "checking if the type of bitfields matters... " >&6; }
1417 if ${gt_cv_bitfield_type_matters+:} false; then :
1418 diff -ruN gcc-9-20190324/libobjc/configure.ac gcc-9-20190324.aros/libobjc/configure.ac
1419 --- gcc-9-20190324/libobjc/configure.ac 2019-01-01 12:31:55.000000000 +0000
1420 +++ gcc-9-20190324.aros/libobjc/configure.ac 2019-03-29 13:46:01.946414400 +0000
1424 # Check if we have thread-local storage
1428 gt_BITFIELD_TYPE_MATTERS
1430 diff -ruN gcc-9-20190324/libobjc/thr.c gcc-9-20190324.aros/libobjc/thr.c
1431 --- gcc-9-20190324/libobjc/thr.c 2019-01-01 12:31:55.000000000 +0000
1432 +++ gcc-9-20190324.aros/libobjc/thr.c 2019-03-29 13:46:01.952381100 +0000
1434 #include "objc/runtime.h"
1435 #include "objc-private/module-abi-8.h"
1436 #include "objc-private/runtime.h"
1437 +#define __typedef_BOOL /* Remove definition of BOOL */
1441 diff -ruN gcc-9-20190324/libstdc++-v3/config/os/aros/ctype_base.h gcc-9-20190324.aros/libstdc++-v3/config/os/aros/ctype_base.h
1442 --- gcc-9-20190324/libstdc++-v3/config/os/aros/ctype_base.h 1970-01-01 00:00:00.000000000 +0000
1443 +++ gcc-9-20190324.aros/libstdc++-v3/config/os/aros/ctype_base.h 2019-03-29 13:46:01.958384000 +0000
1445 +namespace std _GLIBCXX_VISIBILITY(default)
1447 +_GLIBCXX_BEGIN_NAMESPACE_VERSION
1449 +struct ctype_base {
1450 + /* Non-standard typedefs */
1451 + typedef int * __to_type;
1453 + /* NB: Offsets into ctype<char>::_M_table force a particular size
1454 + on the mask type. Because of this, we don't use an enum. */
1455 + typedef unsigned short int mask;
1457 + static const mask upper = _ISupper;
1458 + static const mask lower = _ISlower;
1459 + static const mask alpha = _ISalpha;
1460 + static const mask digit = _ISdigit;
1461 + static const mask xdigit = _ISxdigit;
1462 + static const mask space = _ISspace;
1463 + static const mask print = _ISprint;
1464 + static const mask graph = _ISgraph;
1465 + static const mask cntrl = _IScntrl;
1466 + static const mask punct = _ISpunct;
1467 + static const mask alnum = _ISalnum;
1468 +#if __cplusplus >= 201103L
1469 + static const mask blank = _ISblank;
1473 +_GLIBCXX_END_NAMESPACE_VERSION
1475 diff -ruN gcc-9-20190324/libstdc++-v3/config/os/aros/ctype_configure_char.cc gcc-9-20190324.aros/libstdc++-v3/config/os/aros/ctype_configure_char.cc
1476 --- gcc-9-20190324/libstdc++-v3/config/os/aros/ctype_configure_char.cc 1970-01-01 00:00:00.000000000 +0000
1477 +++ gcc-9-20190324.aros/libstdc++-v3/config/os/aros/ctype_configure_char.cc 2019-03-29 13:46:01.962417200 +0000
1479 +// Locale support -*- C++ -*-
1481 +// Copyright (C) 2011-2013 Free Software Foundation, Inc.
1483 +// This file is part of the GNU ISO C++ Library. This library is free
1484 +// software; you can redistribute it and/or modify it under the
1485 +// terms of the GNU General Public License as published by the
1486 +// Free Software Foundation; either version 3, or (at your option)
1487 +// any later version.
1489 +// This library is distributed in the hope that it will be useful,
1490 +// but WITHOUT ANY WARRANTY; without even the implied warranty of
1491 +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1492 +// GNU General Public License for more details.
1494 +// Under Section 7 of GPL version 3, you are granted additional
1495 +// permissions described in the GCC Runtime Library Exception, version
1496 +// 3.1, as published by the Free Software Foundation.
1498 +// You should have received a copy of the GNU General Public License and
1499 +// a copy of the GCC Runtime Library Exception along with this program;
1500 +// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
1501 +// <http://www.gnu.org/licenses/>.
1503 +/** @file ctype_configure_char.cc */
1506 +// ISO C++ 14882: 22.1 Locales
1513 +namespace std _GLIBCXX_VISIBILITY(default)
1515 +_GLIBCXX_BEGIN_NAMESPACE_VERSION
1517 +// Information as gleaned from /usr/include/ctype.h
1519 + const ctype_base::mask*
1520 + ctype<char>::classic_table() throw()
1523 + ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
1525 + : facet(__refs), _M_del(__table != 0 && __del),
1526 + _M_toupper(NULL), _M_tolower(NULL),
1527 + _M_table(__table ? __table : classic_table())
1529 + memset(_M_widen, 0, sizeof(_M_widen));
1531 + memset(_M_narrow, 0, sizeof(_M_narrow));
1535 + ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
1536 + : facet(__refs), _M_del(__table != 0 && __del),
1537 + _M_toupper(NULL), _M_tolower(NULL),
1538 + _M_table(__table ? __table : classic_table())
1540 + memset(_M_widen, 0, sizeof(_M_widen));
1542 + memset(_M_narrow, 0, sizeof(_M_narrow));
1547 + ctype<char>::do_toupper(char __c) const
1548 + { return ::toupper((int) __c); }
1551 + ctype<char>::do_toupper(char* __low, const char* __high) const
1553 + while (__low < __high)
1555 + *__low = ::toupper((int) *__low);
1562 + ctype<char>::do_tolower(char __c) const
1563 + { return ::tolower((int) __c); }
1566 + ctype<char>::do_tolower(char* __low, const char* __high) const
1568 + while (__low < __high)
1570 + *__low = ::tolower((int) *__low);
1576 +_GLIBCXX_END_NAMESPACE_VERSION
1578 diff -ruN gcc-9-20190324/libstdc++-v3/config/os/aros/ctype_inline.h gcc-9-20190324.aros/libstdc++-v3/config/os/aros/ctype_inline.h
1579 --- gcc-9-20190324/libstdc++-v3/config/os/aros/ctype_inline.h 1970-01-01 00:00:00.000000000 +0000
1580 +++ gcc-9-20190324.aros/libstdc++-v3/config/os/aros/ctype_inline.h 2019-03-29 13:46:02.010432600 +0000
1582 +// Locale support -*- C++ -*-
1584 +// Copyright (C) 2000, 2003 Free Software Foundation, Inc.
1586 +// This file is part of the GNU ISO C++ Library. This library is free
1587 +// software; you can redistribute it and/or modify it under the
1588 +// terms of the GNU General Public License as published by the
1589 +// Free Software Foundation; either version 2, or (at your option)
1590 +// any later version.
1592 +// This library is distributed in the hope that it will be useful,
1593 +// but WITHOUT ANY WARRANTY; without even the implied warranty of
1594 +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1595 +// GNU General Public License for more details.
1597 +// You should have received a copy of the GNU General Public License along
1598 +// with this library; see the file COPYING. If not, write to the Free
1599 +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
1602 +// As a special exception, you may use this file as part of a free software
1603 +// library without restriction. Specifically, if other files instantiate
1604 +// templates or use macros or inline functions from this file, or you compile
1605 +// this file and link it with other files to produce an executable, this
1606 +// file does not by itself cause the resulting executable to be covered by
1607 +// the GNU General Public License. This exception does not however
1608 +// invalidate any other reasons why the executable file might be covered by
1609 +// the GNU General Public License.
1611 +/** @file ctype_inline.h
1612 + * This is an internal header file, included by other library headers.
1613 + * You should not attempt to use it directly.
1617 +// ISO C++ 14882: 22.1 Locales
1620 +// ctype bits to be inlined go here. Non-inlinable (ie virtual do_*)
1621 +// functions go in ctype.cc
1623 +// The following definitions are portable, but insanely slow. If one
1624 +// cares at all about performance, then specialized ctype
1625 +// functionality should be added for the native os in question: see
1626 +// the config/os/bits/ctype_*.h files.
1628 +// Constructing a synthetic "C" table should be seriously considered...
1630 +namespace std _GLIBCXX_VISIBILITY(default)
1632 +_GLIBCXX_BEGIN_NAMESPACE_VERSION
1636 + is(mask __m, char __c) const
1639 + return _M_table[static_cast<unsigned char>(__c)] & __m;
1642 + bool __ret = false;
1643 + const size_t __bitmasksize = 15;
1644 + size_t __bitcur = 0; // Lowest bitmask in ctype_base == 0
1645 + for (; __bitcur <= __bitmasksize; ++__bitcur)
1647 + const mask __bit = static_cast<mask>(1 << __bitcur);
1654 + __testis = isspace(__c);
1657 + __testis = isprint(__c);
1660 + __testis = iscntrl(__c);
1663 + __testis = isupper(__c);
1666 + __testis = islower(__c);
1669 + __testis = isalpha(__c);
1672 + __testis = isdigit(__c);
1675 + __testis = ispunct(__c);
1678 + __testis = isxdigit(__c);
1681 + __testis = isalnum(__c);
1684 + __testis = isgraph(__c);
1690 + __ret |= __testis;
1699 + is(const char* __low, const char* __high, mask* __vec) const
1702 + while (__low < __high)
1703 + *__vec++ = _M_table[static_cast<unsigned char>(*__low++)];
1706 + // Highest bitmask in ctype_base == 10.
1707 + const size_t __bitmasksize = 15;
1708 + for (;__low < __high; ++__vec, ++__low)
1711 + // Lowest bitmask in ctype_base == 0
1713 + for (;__i <= __bitmasksize; ++__i)
1715 + const mask __bit = static_cast<mask>(1 << __i);
1716 + if (this->is(__bit, *__low))
1727 + scan_is(mask __m, const char* __low, const char* __high) const
1730 + while (__low < __high
1731 + && !(_M_table[static_cast<unsigned char>(*__low)] & __m))
1734 + while (__low < __high && !this->is(__m, *__low))
1741 + scan_not(mask __m, const char* __low, const char* __high) const
1744 + while (__low < __high
1745 + && (_M_table[static_cast<unsigned char>(*__low)] & __m) != 0)
1748 + while (__low < __high && this->is(__m, *__low) != 0)
1753 +_GLIBCXX_END_NAMESPACE_VERSION
1755 diff -ruN gcc-9-20190324/libstdc++-v3/config/os/aros/ctype_noninline.h gcc-9-20190324.aros/libstdc++-v3/config/os/aros/ctype_noninline.h
1756 --- gcc-9-20190324/libstdc++-v3/config/os/aros/ctype_noninline.h 1970-01-01 00:00:00.000000000 +0000
1757 +++ gcc-9-20190324.aros/libstdc++-v3/config/os/aros/ctype_noninline.h 2019-03-29 13:46:02.014384000 +0000
1759 + const ctype_base::mask*
1760 + ctype<char>::classic_table() throw()
1761 + { return *__ctype_b_ptr; }
1763 + ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
1765 + : facet(__refs), _M_del(__table != 0 && __del),
1766 + _M_toupper(NULL), _M_tolower(NULL),
1767 + _M_table(__table ? __table : classic_table())
1769 + memset(_M_widen, 0, sizeof(_M_widen));
1771 + memset(_M_narrow, 0, sizeof(_M_narrow));
1775 + ctype<char>::ctype(const mask* __table, bool __del, size_t __refs)
1776 + : facet(__refs), _M_del(__table != 0 && __del),
1777 + _M_toupper(NULL), _M_tolower(NULL),
1778 + _M_table(__table ? __table : classic_table())
1780 + memset(_M_widen, 0, sizeof(_M_widen));
1782 + memset(_M_narrow, 0, sizeof(_M_narrow));
1787 + ctype<char>::do_toupper(char __c) const
1788 + { return ::toupper((int) __c); }
1791 + ctype<char>::do_toupper(char* __low, const char* __high) const
1793 + while (__low < __high)
1795 + *__low = ::toupper((int) *__low);
1802 + ctype<char>::do_tolower(char __c) const
1803 + { return ::tolower((int) __c); }
1806 + ctype<char>::do_tolower(char* __low, const char* __high) const
1808 + while (__low < __high)
1810 + *__low = ::tolower((int) *__low);
1815 diff -ruN gcc-9-20190324/libstdc++-v3/config/os/aros/os_defines.h gcc-9-20190324.aros/libstdc++-v3/config/os/aros/os_defines.h
1816 --- gcc-9-20190324/libstdc++-v3/config/os/aros/os_defines.h 1970-01-01 00:00:00.000000000 +0000
1817 +++ gcc-9-20190324.aros/libstdc++-v3/config/os/aros/os_defines.h 2019-03-29 13:46:02.018433400 +0000
1819 +// Specific definitions for AROS -*- C++ -*-
1821 +#ifndef _GLIBCXX_OS_DEFINES
1822 +#define _GLIBCXX_OS_DEFINES
1824 +#define __off64_t off_t
1826 +// No support for referencing weak symbols without a definition.
1827 +#define _GLIBCXX_USE_WEAK_REF 0
1830 diff -ruN gcc-9-20190324/libstdc++-v3/configure gcc-9-20190324.aros/libstdc++-v3/configure
1831 --- gcc-9-20190324/libstdc++-v3/configure 2019-03-11 16:28:11.000000000 +0000
1832 +++ gcc-9-20190324.aros/libstdc++-v3/configure 2019-03-29 13:46:02.045413700 +0000
1833 @@ -5615,12 +5615,12 @@
1837 -if test "x${with_newlib}" != "xyes"; then
1843 +#if test "x${with_newlib}" != "xyes"; then
1844 +# AC_LIBTOOL_DLOPEN
1851 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
1852 @@ -8350,6 +8350,8 @@
1861 @@ -19951,6 +19953,7 @@
1863 struct iovec iov[2];
1865 +#error be sure to fail
1869 @@ -19973,6 +19976,7 @@
1871 struct iovec iov[2];
1873 +#error be sure to fail
1877 @@ -29301,6 +29305,58 @@
1879 # Base decisions on target environment.
1882 + for ac_header in nan.h ieeefp.h endian.h sys/isa_defs.h machine/endian.h \
1883 + machine/param.h sys/machine.h sys/types.h fp.h locale.h float.h inttypes.h
1885 + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
1886 +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
1887 +eval as_val=\$$as_ac_Header
1888 + if test "x$as_val" = x""yes; then :
1889 + cat >>confdefs.h <<_ACEOF
1890 +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
1898 + GLIBCXX_CHECK_COMPLEX_MATH_SUPPORT
1899 + GLIBCXX_CHECK_WCHAR_T_SUPPORT
1901 + $as_echo "#define HAVE_FINITE 1" >>confdefs.h
1903 + $as_echo "#define HAVE_FINITEF 1" >>confdefs.h
1905 + $as_echo "#define HAVE_FREXPF 1" >>confdefs.h
1907 + $as_echo "#define HAVE_HYPOTF 1" >>confdefs.h
1909 + $as_echo "#define HAVE_ISINF 1" >>confdefs.h
1911 + $as_echo "#define HAVE_ISINFF 1" >>confdefs.h
1913 + $as_echo "#define HAVE_ISNAN 1" >>confdefs.h
1915 + $as_echo "#define HAVE_ISNANF 1" >>confdefs.h
1917 + $as_echo "#define HAVE_SINCOS 1" >>confdefs.h
1919 + $as_echo "#define HAVE_SINCOSF 1" >>confdefs.h
1921 + if test x"long_double_math_on_this_cpu" = x"yes"; then
1922 + $as_echo "#define HAVE_FINITEL 1" >>confdefs.h
1924 + $as_echo "#define HAVE_HYPOTL 1" >>confdefs.h
1926 + $as_echo "#define HAVE_ISINFL 1" >>confdefs.h
1928 + $as_echo "#define HAVE_ISNANL 1" >>confdefs.h
1934 # This is a freestanding configuration; there is nothing to do here.
1936 diff -ruN gcc-9-20190324/libstdc++-v3/configure.ac gcc-9-20190324.aros/libstdc++-v3/configure.ac
1937 --- gcc-9-20190324/libstdc++-v3/configure.ac 2019-03-11 16:28:11.000000000 +0000
1938 +++ gcc-9-20190324.aros/libstdc++-v3/configure.ac 2019-03-29 13:46:02.051418000 +0000
1943 -if test "x${with_newlib}" != "xyes"; then
1946 +#if test "x${with_newlib}" != "xyes"; then
1947 +# AC_LIBTOOL_DLOPEN
1951 AC_SUBST(enable_shared)
1952 diff -ruN gcc-9-20190324/libstdc++-v3/configure.host gcc-9-20190324.aros/libstdc++-v3/configure.host
1953 --- gcc-9-20190324/libstdc++-v3/configure.host 2019-02-22 07:25:52.000000000 +0000
1954 +++ gcc-9-20190324.aros/libstdc++-v3/configure.host 2019-03-29 13:46:02.058417400 +0000
1956 os_include_dir="os/generic"
1957 atomicity_dir="cpu/generic"
1960 + os_include_dir="os/aros"
1963 # Plain BSD attempts to share FreeBSD files.
1964 os_include_dir="os/bsd/freebsd"
1965 diff -ruN gcc-9-20190324/libstdc++-v3/crossconfig.m4 gcc-9-20190324.aros/libstdc++-v3/crossconfig.m4
1966 --- gcc-9-20190324/libstdc++-v3/crossconfig.m4 2019-03-11 16:28:11.000000000 +0000
1967 +++ gcc-9-20190324.aros/libstdc++-v3/crossconfig.m4 2019-03-29 13:46:02.063417800 +0000
1969 AC_DEFUN([GLIBCXX_CROSSCONFIG],[
1970 # Base decisions on target environment.
1973 + AC_CHECK_HEADERS([nan.h ieeefp.h endian.h sys/isa_defs.h machine/endian.h \
1974 + machine/param.h sys/machine.h sys/types.h fp.h locale.h float.h inttypes.h])
1976 + GLIBCXX_CHECK_COMPLEX_MATH_SUPPORT
1977 + GLIBCXX_CHECK_WCHAR_T_SUPPORT
1979 + AC_DEFINE(HAVE_FINITE)
1980 + AC_DEFINE(HAVE_FINITEF)
1981 + AC_DEFINE(HAVE_FREXPF)
1982 + AC_DEFINE(HAVE_HYPOTF)
1983 + AC_DEFINE(HAVE_ISINF)
1984 + AC_DEFINE(HAVE_ISINFF)
1985 + AC_DEFINE(HAVE_ISNAN)
1986 + AC_DEFINE(HAVE_ISNANF)
1987 + AC_DEFINE(HAVE_SINCOS)
1988 + AC_DEFINE(HAVE_SINCOSF)
1989 + if test x"long_double_math_on_this_cpu" = x"yes"; then
1990 + AC_DEFINE(HAVE_FINITEL)
1991 + AC_DEFINE(HAVE_HYPOTL)
1992 + AC_DEFINE(HAVE_ISINFL)
1993 + AC_DEFINE(HAVE_ISNANL)
1998 # This is a freestanding configuration; there is nothing to do here.
2000 diff -ruN gcc-9-20190324/libstdc++-v3/include/Makefile.in gcc-9-20190324.aros/libstdc++-v3/include/Makefile.in
2001 --- gcc-9-20190324/libstdc++-v3/include/Makefile.in 2019-03-21 23:48:49.000000000 +0000
2002 +++ gcc-9-20190324.aros/libstdc++-v3/include/Makefile.in 2019-03-29 13:46:02.068386700 +0000
2003 @@ -1817,6 +1817,7 @@
2004 -e '/^#/s/\(${uppercase}${uppercase}*\)/_GLIBCXX_\1/g' \
2005 -e 's/_GLIBCXX_SUPPORTS_WEAK/__GXX_WEAK__/g' \
2006 -e 's/_GLIBCXX___MINGW32_GLIBCXX___/__MINGW32__/g' \
2007 + -e 's/_GLIBCXX___AROS__/__AROS__/g' \
2008 -e 's,^#include "\(.*\)",#include <bits/\1>,g' \
2011 diff -ruN gcc-9-20190324/libstdc++-v3/include/c_global/cstdint gcc-9-20190324.aros/libstdc++-v3/include/c_global/cstdint
2012 --- gcc-9-20190324/libstdc++-v3/include/c_global/cstdint 2019-01-01 12:31:55.000000000 +0000
2013 +++ gcc-9-20190324.aros/libstdc++-v3/include/c_global/cstdint 2019-03-29 13:46:02.075418700 +0000
2015 using ::uint_fast64_t;
2017 using ::uint_least8_t;
2018 +#if !defined (__UINT_LEAST16_TYPE__) || !defined(__UINT_LEAST32_TYPE__)
2019 using ::uint_least16_t;
2020 using ::uint_least32_t;
2022 using ::uint_least64_t;
2025 diff -ruN gcc-9-20190324/libstdc++-v3/include/std/ratio gcc-9-20190324.aros/libstdc++-v3/include/std/ratio
2026 --- gcc-9-20190324/libstdc++-v3/include/std/ratio 2019-01-01 12:31:55.000000000 +0000
2027 +++ gcc-9-20190324.aros/libstdc++-v3/include/std/ratio 2019-03-29 13:46:02.085415000 +0000
2028 @@ -209,10 +209,10 @@
2031 static_assert(__d != 0, "Internal library error");
2032 - static_assert(sizeof (uintmax_t) == sizeof (unsigned long long),
2033 - "This library calls __builtin_clzll on uintmax_t, which "
2034 - "is unsafe on your platform. Please complain to "
2035 - "http://gcc.gnu.org/bugzilla/");
2036 +// static_assert(sizeof (uintmax_t) == sizeof (unsigned long long),
2037 +// "This library calls __builtin_clzll on uintmax_t, which "
2038 +// "is unsafe on your platform. Please complain to "
2039 +// "http://gcc.gnu.org/bugzilla/");
2040 static constexpr int __shift = __builtin_clzll(__d);
2041 static constexpr int __coshift_ = sizeof(uintmax_t) * 8 - __shift;
2042 static constexpr int __coshift = (__shift != 0) ? __coshift_ : 0;