Skip to content

Commit e593c02

Browse files
committed
build: correct the DT_SONAME
When ninja is invoked from a subdirectory it will convert the path to a relative path, and that resulted in incorrect test results. This ensures that we get the correct soname.
1 parent 93a24b3 commit e593c02

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: cmake/modules/SwiftSupport.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ function(add_swift_target target)
136136
if(CMAKE_SYSTEM_NAME STREQUAL Windows OR CMAKE_SYSTEM_NAME STREQUAL Darwin)
137137
set(emit_library -emit-library)
138138
else()
139-
set(emit_library -emit-library -Xlinker -soname -Xlinker ${AST_OUTPUT})
139+
set(emit_library -emit-library -Xlinker -soname -Xlinker ${CMAKE_SHARED_LIBRARY_PREFIX}${target}${CMAKE_SHARED_LIBRARY_SUFFIX})
140140
endif()
141141
endif()
142142
if(NOT AST_LIBRARY OR library_kind STREQUAL SHARED)

0 commit comments

Comments
 (0)