blob: be79cb53f15b16941f6fae0f6366661a038e2997 [file] [log] [blame]
Andrew Geissler82c905d2020-04-13 13:39:40 -05001From b6732f68848ecc8ff01054bf7aea70a241c37116 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Fri, 10 Apr 2020 11:23:39 -0700
4Subject: [PATCH] Remove using .end directive with clang
5
6Clang does not support this asm directive
7Fixes Issue #19
8
9Upstream-Status: Submitted [https://github.com/kaniini/libucontext/pull/20]
10Signed-off-by: Khem Raj <raj.khem@gmail.com>
11---
12 arch/common/common-defs.h | 5 ++++-
13 1 file changed, 4 insertions(+), 1 deletion(-)
14
15diff --git a/arch/common/common-defs.h b/arch/common/common-defs.h
16index bf2fb8c..618116b 100644
17--- a/arch/common/common-defs.h
18+++ b/arch/common/common-defs.h
19@@ -28,10 +28,13 @@
20 ENT(__proc) \
21 __proc: \
22 SETUP_FRAME(__proc)
23-
24+#ifdef __clang__
25+#define END(__proc)
26+#else
27 #define END(__proc) \
28 .end __proc; \
29 .size __proc,.-__proc;
30+#endif
31
32 #define ALIAS(__alias, __real) \
33 .weak __alias; \
34--
352.26.0
36