aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPierre Ossman <ossman@cendio.se>2022-11-16 07:54:01 +0100
committerPierre Ossman <ossman@cendio.se>2023-01-10 19:41:13 +0100
commit6ff7f2e54b80794acd498931adb3fe4096b396bb (patch)
treeacbf1f4b5f8b5ebfad8d2aa13c00bb15ba4c97da
parentf2a89fbec8444681f5d36b2c0731ba0d74810135 (diff)
downloadtigervnc-6ff7f2e54b80794acd498931adb3fe4096b396bb.tar.gz
tigervnc-6ff7f2e54b80794acd498931adb3fe4096b396bb.zip
Make sure frameworks are included in .la files
We don't really use the .la files for macOS at the moment, but let's try to be prepared.
-rw-r--r--cmake/Modules/CMakeMacroLibtoolFile.cmake10
1 files changed, 9 insertions, 1 deletions
diff --git a/cmake/Modules/CMakeMacroLibtoolFile.cmake b/cmake/Modules/CMakeMacroLibtoolFile.cmake
index 9658bbac..423d3dfb 100644
--- a/cmake/Modules/CMakeMacroLibtoolFile.cmake
+++ b/cmake/Modules/CMakeMacroLibtoolFile.cmake
@@ -28,11 +28,19 @@ macro(libtool_create_control_file _target)
endforeach()
set(STATIC_MODE OFF)
+ set(FRAMEWORK OFF)
foreach(library ${target_libs})
+ if(FRAMEWORK)
+ set(_target_dependency_libs "${_target_dependency_libs} -framework ${library}")
+ set(FRAMEWORK OFF)
+ continue()
+ elseif(${library} STREQUAL "-framework")
+ set(FRAMEWORK ON)
+ continue()
# Assume all entries are shared libs if platform-specific static library
# extension is not matched.
- if(NOT "${library}" MATCHES ".+${CMAKE_STATIC_LIBRARY_SUFFIX}$")
+ elseif(NOT "${library}" MATCHES ".+${CMAKE_STATIC_LIBRARY_SUFFIX}$")
if("${library}" MATCHES ".+${CMAKE_SHARED_LIBRARY_SUFFIX}$")
# Shared library extension matched, so extract the path and library
# name, then add the result to the libtool dependency libs. This