-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rollup merge of #41397 - alexcrichton:beta-next, r=aidanhs
[beta] travis: Use upstream LLVM repositories for Fuchsia This is a backport of #41130 which... Closes #41396
- Loading branch information
Showing
3 changed files
with
64 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
diff --git a/lib/builtins/CMakeLists.txt b/lib/builtins/CMakeLists.txt | ||
index fc4384af2..b442264c0 100644 | ||
--- a/lib/builtins/CMakeLists.txt | ||
+++ b/lib/builtins/CMakeLists.txt | ||
@@ -194,6 +194,12 @@ if(APPLE) | ||
atomic_thread_fence.c) | ||
endif() | ||
|
||
+if(FUCHSIA) | ||
+ set(GENERIC_SOURCES | ||
+ ${GENERIC_SOURCES} | ||
+ dso_handle.c) | ||
+endif() | ||
+ | ||
if(NOT WIN32 OR MINGW) | ||
set(GENERIC_SOURCES | ||
${GENERIC_SOURCES} | ||
diff --git a/lib/builtins/dso_handle.c b/lib/builtins/dso_handle.c | ||
new file mode 100644 | ||
index 000000000..7766cd0aa | ||
--- /dev/null | ||
+++ b/lib/builtins/dso_handle.c | ||
@@ -0,0 +1,18 @@ | ||
+/* ===-- dso_handle.c - Provide __dso_handle -------------------------------=== | ||
+ * | ||
+ * The LLVM Compiler Infrastructure | ||
+ * | ||
+ * This file is dual licensed under the MIT and the University of Illinois Open | ||
+ * Source Licenses. See LICENSE.TXT for details. | ||
+ * | ||
+ * ===----------------------------------------------------------------------=== | ||
+ */ | ||
+ | ||
+/* __dso_handle symbol is mandated by C++ ABI with a value which is an address | ||
+ * in one of the object's segments, and as such this symbol has to be included | ||
+ * statically and cannot be a part of a shared library. Traditionally, it has | ||
+ * been defined in crtbegin.o but there's no principled reason for it to be | ||
+ * there. We defined this symbol in the builtin library which is built as a | ||
+ * static library and always included in the final link. | ||
+ */ | ||
+__attribute__((visibility("hidden"))) void *const __dso_handle; |