Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 35995ef

Browse files
committedMar 30, 2023
Yet another shot at solving linking on macOS
1 parent 01f52a8 commit 35995ef

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed
 

‎patches/swift/04-allow-plugging-in-observer.patch

+6-7
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ index 184e6196918..ef5c3eafe69 100644
5858
// progress.
5959
};
6060
diff --git a/lib/AST/CMakeLists.txt b/lib/AST/CMakeLists.txt
61-
index ec3fa2c853b..7ea1a1763b9 100644
61+
index ec3fa2c853b..dcd3e95c5ae 100644
6262
--- a/lib/AST/CMakeLists.txt
6363
+++ b/lib/AST/CMakeLists.txt
6464
@@ -58,7 +58,6 @@ add_swift_host_library(swiftAST STATIC
@@ -69,22 +69,21 @@ index ec3fa2c853b..7ea1a1763b9 100644
6969
ImportCache.cpp
7070
IndexSubset.cpp
7171
InlinableText.cpp
72-
@@ -122,6 +121,14 @@ add_swift_host_library(swiftAST STATIC
72+
@@ -122,6 +121,13 @@ add_swift_host_library(swiftAST STATIC
7373
${SWIFTAST_LLVM_LINK_COMPONENTS}
7474
)
7575

7676
+add_swift_host_library(swiftIdentifier SHARED
7777
+ Identifier.cpp
78-
+ )
78+
+ LLVM_LINK_COMPONENTS
79+
+ core support)
7980
+
80-
+if(${SWIFT_HOST_VARIANT_SDK} IN_LIST SWIFT_DARWIN_PLATFORMS)
81-
+ target_link_options(swiftIdentifier PRIVATE "LINKER:-undefined,dynamic_lookup")
82-
+endif()
81+
+target_link_libraries(swiftIdentifier PUBLIC clangBasic)
8382
+
8483
if(SWIFT_FORCE_OPTIMIZED_TYPECHECKER)
8584
if(CMAKE_CXX_COMPILER_ID STREQUAL MSVC OR CMAKE_CXX_SIMULATE_ID STREQUAL MSVC)
8685
target_compile_options(swiftAST PRIVATE /O2 /Ob2)
87-
@@ -152,7 +159,7 @@ if(NOT SWIFT_BUILD_ONLY_SYNTAXPARSERLIB)
86+
@@ -152,7 +158,7 @@ if(NOT SWIFT_BUILD_ONLY_SYNTAXPARSERLIB)
8887
endif()
8988

9089
target_link_libraries(swiftAST

0 commit comments

Comments
 (0)
Please sign in to comment.