[libunwind] [libunwind] Add Unwind-wasm.c to CMakeLists.txt (PR #67770)

Heejin Ahn via cfe-commits cfe-commits at lists.llvm.org
Fri Sep 29 00:02:11 PDT 2023


https://github.com/aheejin updated https://github.com/llvm/llvm-project/pull/67770

>From 3277e2c8058c5d9b0afcc073d711646ebbf7ed62 Mon Sep 17 00:00:00 2001
From: Heejin Ahn <aheejin at gmail.com>
Date: Thu, 28 Sep 2023 23:43:26 -0700
Subject: [PATCH 1/2] [libunwind] Add Unwind-wasm.c to CMakeLists.txt

This was missing when the file was added.
---
 libunwind/src/CMakeLists.txt | 1 +
 libunwind/src/Unwind-wasm.c  | 3 ++-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/libunwind/src/CMakeLists.txt b/libunwind/src/CMakeLists.txt
index 452d988c3726b5e..abb019b88ebabd7 100644
--- a/libunwind/src/CMakeLists.txt
+++ b/libunwind/src/CMakeLists.txt
@@ -16,6 +16,7 @@ set(LIBUNWIND_C_SOURCES
     UnwindLevel1.c
     UnwindLevel1-gcc-ext.c
     Unwind-sjlj.c
+    Unwind-wasm.c
     )
 set_source_files_properties(${LIBUNWIND_C_SOURCES}
                             PROPERTIES
diff --git a/libunwind/src/Unwind-wasm.c b/libunwind/src/Unwind-wasm.c
index 35f2f9aeab08048..47c79b0d14d37b7 100644
--- a/libunwind/src/Unwind-wasm.c
+++ b/libunwind/src/Unwind-wasm.c
@@ -10,12 +10,13 @@
 //
 //===----------------------------------------------------------------------===//
 
+#ifdef __USING_WASM_EXCEPTIONS__
+
 #include "config.h"
 #include "unwind.h"
 #include <stdbool.h>
 #include <threads.h>
 
-#ifdef __USING_WASM_EXCEPTIONS__
 
 _Unwind_Reason_Code __gxx_personality_wasm0(int version, _Unwind_Action actions,
                                             uint64_t exceptionClass,

>From 784fd43b2a58b55d838afce420c04598e3e37efa Mon Sep 17 00:00:00 2001
From: Heejin Ahn <aheejin at gmail.com>
Date: Fri, 29 Sep 2023 00:01:54 -0700
Subject: [PATCH 2/2] Remove newline

---
 libunwind/src/Unwind-wasm.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/libunwind/src/Unwind-wasm.c b/libunwind/src/Unwind-wasm.c
index 47c79b0d14d37b7..96af603d666128a 100644
--- a/libunwind/src/Unwind-wasm.c
+++ b/libunwind/src/Unwind-wasm.c
@@ -17,7 +17,6 @@
 #include <stdbool.h>
 #include <threads.h>
 
-
 _Unwind_Reason_Code __gxx_personality_wasm0(int version, _Unwind_Action actions,
                                             uint64_t exceptionClass,
                                             _Unwind_Exception *unwind_exception,



More information about the cfe-commits mailing list