Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/gcc9 cpp17 support #99

Merged
merged 10 commits into from
Apr 10, 2021
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 9511ecf6645337c5cdc31e5c61a1cfb132f16ba4 Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Tue, 17 Feb 2015 20:25:55 +0100
Subject: [PATCH 01/31] Changes for AmigaOS version of gcc.
Subject: [PATCH 01/32] Changes for AmigaOS version of gcc.

---
fixincludes/configure | 1 +
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 892a378d609a1b622e6fd6259078d3cfca9c9717 Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Fri, 14 Nov 2014 20:03:56 +0100
Subject: [PATCH 02/31] Added new function attribute "lineartags" and pragma
Subject: [PATCH 02/32] Added new function attribute "lineartags" and pragma
"amigaos tagtype".

Functions that have the lineartags attribute are assumed to be functions
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From f80203a95b03a0ccfa6212ff7cf5cc742782e571 Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Thu, 9 Jul 2015 06:54:37 +0200
Subject: [PATCH 03/31] Disable .machine directive generation.
Subject: [PATCH 03/32] Disable .machine directive generation.

It breaks manual args to the assembler with different flavor,
e.g., -Wa,-m440. This is probably not the right fix.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From f43ead8f261f824ad2f32a1115c206f4b6574e52 Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Wed, 2 Dec 2015 20:56:33 +0100
Subject: [PATCH 04/31] The default link mode is static for AmigaOS.
Subject: [PATCH 04/32] The default link mode is static for AmigaOS.

Changed the g++ driver to reflect this.
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 93b70f37543c86db068f00da18672cfdd96988b8 Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Wed, 2 Dec 2015 21:39:42 +0100
Subject: [PATCH 05/31] Disable the usage of /dev/urandom when compiling for
Subject: [PATCH 05/32] Disable the usage of /dev/urandom when compiling for
AmigaOS.

---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From d994439847182f153ca7a25f718e47eb9ecaa456 Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Sat, 5 Dec 2015 13:17:26 +0100
Subject: [PATCH 06/31] Expand arg zero on AmigaOS using the PROGDIR: assign.
Subject: [PATCH 06/32] Expand arg zero on AmigaOS using the PROGDIR: assign.

This should make sure that the proper relative paths are computed during
process_command().
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 8ba761c3761a87cdf6a5ece5b7fa5c225e001003 Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Thu, 21 Jan 2016 20:46:59 +0100
Subject: [PATCH 07/31] Some AmigaOS 4.x compability changes for posix thread
Subject: [PATCH 07/32] Some AmigaOS 4.x compability changes for posix thread
support.

---
Expand Down
2 changes: 1 addition & 1 deletion gcc/9/patches/0008-Added-libstc-support-for-AmigaOS.patch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From ad7ead8f8064e66ea8508f3dcba43f62a489a41b Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Fri, 22 Jan 2016 20:04:50 +0100
Subject: [PATCH 08/31] Added libstc++ support for AmigaOS.
Subject: [PATCH 08/32] Added libstc++ support for AmigaOS.

---
libstdc++-v3/config/os/amigaos/ctype_base.h | 59 +++++++
Expand Down
2 changes: 1 addition & 1 deletion gcc/9/patches/0009-Enable-libatomic-for-ppc-amigaos.patch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 330c0d98c44e822fbe5795bd7b203143358eefe1 Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Fri, 3 Mar 2017 08:52:48 +0100
Subject: [PATCH 09/31] Enable libatomic for ppc-amigaos.
Subject: [PATCH 09/32] Enable libatomic for ppc-amigaos.

It is not really finished yet.
---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From fb4f1673a62e828fd3fa74decd2771942ea709ac Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Wed, 23 May 2018 10:54:19 +0200
Subject: [PATCH 10/31] Implement libat_lock_n() and libat_unlock_n().
Subject: [PATCH 10/32] Implement libat_lock_n() and libat_unlock_n().

---
libatomic/config/amigaos/lock.c | 58 ++++++++++++++++++++++++++++++++---------
Expand Down
2 changes: 1 addition & 1 deletion gcc/9/patches/0011-Pretend-C99-compatibility.patch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 7ddd0aa30703bee23ed45739d8e7bf464e2f8fca Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Sat, 4 Mar 2017 07:39:21 +0100
Subject: [PATCH 11/31] Pretend C99 compatibility.
Subject: [PATCH 11/32] Pretend C99 compatibility.

At least newlib is not fully C99 compatible because it doesn't expose
various C99 function if __STRICT_ANSI__ is declared. Also it misses
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 32119abeec42cdc7617a8b4e13f3bd7d2d9532fa Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Tue, 3 Apr 2018 19:52:01 +0200
Subject: [PATCH 12/31] Add amigaos-stdint.h for libatomic.
Subject: [PATCH 12/32] Add amigaos-stdint.h for libatomic.

---
gcc/config.gcc | 2 +-
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From f6986271e33195dc5448ba24c5acc88dd9244c1a Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Wed, 4 Apr 2018 22:48:33 +0200
Subject: [PATCH 13/31] Rerun make maint-deps in libiberty.
Subject: [PATCH 13/32] Rerun make maint-deps in libiberty.

---
libiberty/Makefile.in | 36 ++++++++++++++++++++++--------------
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From ac3c290c64a13ae833ae83c952d3eb4d437be46a Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Wed, 4 Apr 2018 23:50:48 +0200
Subject: [PATCH 14/31] Add custom implementation of various env-related
Subject: [PATCH 14/32] Add custom implementation of various env-related
functions.

No official clib does support unsetenv() but this is required by newer gcc.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 6e09fc8c45f87629dd31bcf61acae35afa0edee9 Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Thu, 5 Apr 2018 19:56:45 +0200
Subject: [PATCH 15/31] Define va_startlinear and va_getlinearva.
Subject: [PATCH 15/32] Define va_startlinear and va_getlinearva.

These were usually defined in the clibs' stdarg.h. As we have now
changed the include path order, clibs' stdarg.h is never included.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 30ecab0d0356aab11461e6eae0de522b649f67fd Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Tue, 17 Apr 2018 22:02:09 +0200
Subject: [PATCH 16/31] Fix r2 restoring in the epilog of baserel-restoring
Subject: [PATCH 16/32] Fix r2 restoring in the epilog of baserel-restoring
functions.

---
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 945d91a324e0201bfe89d0b261b416017d69d5ea Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Thu, 19 Apr 2018 21:00:30 +0200
Subject: [PATCH 17/31] Avoid section anchors in the baserel mode.
Subject: [PATCH 17/32] Avoid section anchors in the baserel mode.

---
gcc/config/rs6000/amigaos-protos.h | 1 +
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 468b1096ebe3abe0fbe27fc65463c97c0fc4ec03 Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Fri, 20 Apr 2018 20:04:30 +0200
Subject: [PATCH 18/31] Respect -nostdinc also for SDK includes.
Subject: [PATCH 18/32] Respect -nostdinc also for SDK includes.

---
gcc/config/rs6000/amigaos.h | 4 +---
Expand Down
2 changes: 1 addition & 1 deletion gcc/9/patches/0019-Add-_Static_warning.patch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 3d6faadb51e79eb97b4cd3273abb62648f0deb5c Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Tue, 24 Apr 2018 22:46:21 +0200
Subject: [PATCH 19/31] Add _Static_warning().
Subject: [PATCH 19/32] Add _Static_warning().

This acts very similar to _Static_assert() but produces a warning
rather than an compiler error.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 6d8c18fa473b71fed3819df0c600c4c191d234eb Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Tue, 24 Apr 2018 06:29:13 +0200
Subject: [PATCH 20/31] Add tagtype attribute that can be passed to enum
Subject: [PATCH 20/32] Add tagtype attribute that can be passed to enum
constants.

The tagtype attribute can be applied to enum constants in order to annotate
Expand Down
2 changes: 1 addition & 1 deletion gcc/9/patches/0021-Rename-lineartags-to-checktags.patch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 9a1d31fc7c22999393eba7b5e59169496007d982 Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Fri, 27 Apr 2018 22:48:18 +0200
Subject: [PATCH 21/31] Rename lineartags to checktags.
Subject: [PATCH 21/32] Rename lineartags to checktags.

The name lineartags would imply linearvarargs but this is not implemented
or necessary.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From f5757ee85e0e366086bc5c470bef669b4dd2871c Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Sat, 28 Apr 2018 08:09:58 +0200
Subject: [PATCH 22/31] Fix order of AmigaOS PPC sections in the documentation.
Subject: [PATCH 22/32] Fix order of AmigaOS PPC sections in the documentation.

---
gcc/doc/invoke.texi | 264 ++++++++++++++++++++++++++--------------------------
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 8a759fb742db32812c3c89550ee11bb1ee42232d Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Sun, 29 Apr 2018 00:08:22 +0200
Subject: [PATCH 23/31] Provide a documentation for checktags and tagtype
Subject: [PATCH 23/32] Provide a documentation for checktags and tagtype
attributes.

---
Expand Down
2 changes: 1 addition & 1 deletion gcc/9/patches/0024-Adapt-libssp-for-AmigaOS.patch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 8656b55b825bdeec1f3aaf9ceffbe5c5e5fda6bf Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Tue, 22 May 2018 23:14:01 +0200
Subject: [PATCH 24/31] Adapt libssp for AmigaOS.
Subject: [PATCH 24/32] Adapt libssp for AmigaOS.

---
libssp/ssp.c | 8 +++++---
Expand Down
8 changes: 6 additions & 2 deletions gcc/9/patches/0025-Add-amigaos-thread-model.patch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 8e7a06d914e05861cf8e03a2a822a5d0bc6ae4c0 Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Fri, 4 May 2018 18:22:24 +0200
Subject: [PATCH 25/31] Add amigaos thread model.
Subject: [PATCH 25/32] Add amigaos thread model.

It is work in progress.
---
Expand Down Expand Up @@ -298,7 +298,7 @@ new file mode 100644
index 0000000000000000000000000000000000000000..41adbdc3324156bee31731da8f0da92e819ffdd8
--- /dev/null
+++ b/libgcc/gthr-amigaos-native.c
@@ -0,0 +1,1013 @@
@@ -0,0 +1,1017 @@
+/**
+ * This is the native implementation of gcc threads abstraction. The advantage
+ * over the pthreads one is that no pthreads.library is needed.
Expand Down Expand Up @@ -729,6 +729,7 @@ index 0000000000000000000000000000000000000000..41adbdc3324156bee31731da8f0da92e
+ iexec->ReleaseSemaphore (&mx->u.i.sem);
+ return EBUSY;
+ }
+ mx->u.i.acquired++;
+ return 0;
+ }
+ return EBUSY;
Expand Down Expand Up @@ -996,6 +997,9 @@ index 0000000000000000000000000000000000000000..41adbdc3324156bee31731da8f0da92e
+ /* Initialize libs */
+ __gthread_once (&libs_once, init_libs);
+
+ /* Initialize our private threadstore, but only once */
+ __gthread_once (&threadstore_once, init_threadstore);
+
+ task = iexec->FindTask(NULL);
+ iexec->ObtainSemaphoreShared (&threadstore->sem);
+ if ((thr = find_threadentry_by_process ((struct Process *)task)))
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 78501d5d0a714a1616e53e6f19ed6ea28a3b5a87 Mon Sep 17 00:00:00 2001
From: Sebastian Bauer <[email protected]>
Date: Sat, 27 Oct 2018 08:06:21 +0200
Subject: [PATCH 26/31] Add aregparam attribute for functions for the m68k
Subject: [PATCH 26/32] Add aregparam attribute for functions for the m68k
backend.

These can be used to pass arguments to directly named registers.
Expand Down
2 changes: 1 addition & 1 deletion gcc/9/patches/0027-gcc9-Don-t-use-poisoned-define.patch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 5b3765448ca16c222d070007932e8ae0512c277e Mon Sep 17 00:00:00 2001
From: "[email protected]" <[email protected]>
Date: Tue, 29 Dec 2020 21:19:57 +0100
Subject: [PATCH 27/31] gcc9: Don't use poisoned define.
Subject: [PATCH 27/32] gcc9: Don't use poisoned define.

---
gcc/config/rs6000/amigaos.h | 3 ---
Expand Down
2 changes: 1 addition & 1 deletion gcc/9/patches/0028-gcc9-Fix-unused-value.patch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From e904a6ed5ffaf63151307171bad9b94530e065dd Mon Sep 17 00:00:00 2001
From: "[email protected]" <[email protected]>
Date: Tue, 29 Dec 2020 21:24:26 +0100
Subject: [PATCH 28/31] gcc9: Fix unused value.
Subject: [PATCH 28/32] gcc9: Fix unused value.

---
gcc/c/c-parser.c | 2 +-
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 5c22aeb4ca116e2b41badac7f53190b448e3723d Mon Sep 17 00:00:00 2001
From: "[email protected]" <[email protected]>
Date: Tue, 29 Dec 2020 21:28:04 +0100
Subject: [PATCH 29/31] gcc9: Correct documentation section order / naming.
Subject: [PATCH 29/32] gcc9: Correct documentation section order / naming.

---
gcc/doc/extend.texi | 4 +--
Expand Down
2 changes: 1 addition & 1 deletion gcc/9/patches/0030-gcc9-Define-CC1_SPEC.patch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 379d4088453768dc7a3cd04c1f2bae0ab07fb09f Mon Sep 17 00:00:00 2001
From: "[email protected]" <[email protected]>
Date: Tue, 29 Dec 2020 21:47:26 +0100
Subject: [PATCH 30/31] gcc9: Define CC1_SPEC.
Subject: [PATCH 30/32] gcc9: Define CC1_SPEC.

---
gcc/config/rs6000/amigaos.h | 13 +++++++++++++
Expand Down
Loading