summaryrefslogtreecommitdiff
path: root/pkg/elftoolchain/patch/0003-Prevent-empty-top-level-declarations.patch
diff options
context:
space:
mode:
authorMichael Forney <mforney@mforney.org>2019-07-02 23:29:36 -0700
committerMichael Forney <mforney@mforney.org>2019-07-03 02:43:39 -0700
commitde8c2a826cef2d5f9dcbdeef478e72877b4fe86a (patch)
tree9d66e08aef7874bcc5d7471302d9575315b21aad /pkg/elftoolchain/patch/0003-Prevent-empty-top-level-declarations.patch
parente53001730fab49192ea194824309e1c662b9e586 (diff)
elftoolchain: Fix a few portability issues
Diffstat (limited to 'pkg/elftoolchain/patch/0003-Prevent-empty-top-level-declarations.patch')
-rw-r--r--pkg/elftoolchain/patch/0003-Prevent-empty-top-level-declarations.patch48
1 files changed, 48 insertions, 0 deletions
diff --git a/pkg/elftoolchain/patch/0003-Prevent-empty-top-level-declarations.patch b/pkg/elftoolchain/patch/0003-Prevent-empty-top-level-declarations.patch
new file mode 100644
index 00000000..9a5c45e2
--- /dev/null
+++ b/pkg/elftoolchain/patch/0003-Prevent-empty-top-level-declarations.patch
@@ -0,0 +1,48 @@
+From 9f83cd2e4af19212d26cdacf07d4b86262106383 Mon Sep 17 00:00:00 2001
+From: Michael Forney <mforney@mforney.org>
+Date: Tue, 2 Jul 2019 23:49:18 -0700
+Subject: [PATCH] Prevent empty top-level declarations
+
+---
+ common/_elftc.h | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/common/_elftc.h b/common/_elftc.h
+index c3df36cb..f0da3d00 100644
+--- a/common/_elftc.h
++++ b/common/_elftc.h
+@@ -299,7 +299,7 @@ struct name { \
+ #if defined(__GNUC__)
+ #define ELFTC_VCSID(ID) __asm__(".ident\t\"" ID "\"")
+ #else
+-#define ELFTC_VCSID(ID) /**/
++#define ELFTC_VCSID(ID) _Static_assert(1, "")
+ #endif
+ #endif
+
+@@ -307,19 +307,19 @@ struct name { \
+ #if defined(__GNUC__)
+ #define ELFTC_VCSID(ID) __asm__(".ident\t\"" ID "\"")
+ #else
+-#define ELFTC_VCSID(ID) /**/
++#define ELFTC_VCSID(ID) _Static_assert(1, "")
+ #endif /* __GNU__ */
+ #endif
+
+ #if defined(__NetBSD__)
+-#define ELFTC_VCSID(ID) __RCSID(ID)
++#define ELFTC_VCSID(ID) _Static_assert(1, "")
+ #endif
+
+ #if defined(__OpenBSD__)
+ #if defined(__GNUC__)
+ #define ELFTC_VCSID(ID) __asm__(".ident\t\"" ID "\"")
+ #else
+-#define ELFTC_VCSID(ID) /**/
++#define ELFTC_VCSID(ID) _Static_assert(1, "")
+ #endif /* __GNUC__ */
+ #endif
+
+--
+2.22.0
+