40 lines
1.1 KiB
Diff
40 lines
1.1 KiB
Diff
--- a/CMakeLists.txt
|
|
+++ b/CMakeLists.txt
|
|
@@ -459,6 +459,10 @@ IF (WIN32)
|
|
endif()
|
|
endif (WIN32)
|
|
|
|
+# Find libexecinfo and libintl for musl
|
|
+find_library(EXECINFO_LIBRARY NAMES execinfo)
|
|
+find_library(INTL_LIBRARY NAMES intl)
|
|
+
|
|
# on BSD this must be explicitly linked
|
|
if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "OpenBSD")
|
|
# Not needed on Debian GNU/kFreeBSD..
|
|
--- a/cmake/WlFunctions.cmake
|
|
+++ b/cmake/WlFunctions.cmake
|
|
@@ -184,6 +184,10 @@
|
|
endif()
|
|
endif()
|
|
|
|
+ if (INTL_LIBRARY)
|
|
+ target_link_libraries(${NAME} ${INTL_LIBRARY})
|
|
+ endif()
|
|
+
|
|
if (ARG_USES_INTL)
|
|
# libintl is not used on all systems, so only include it, when we actually
|
|
# found it.
|
|
--- a/src/CMakeLists.txt
|
|
+++ b/src/CMakeLists.txt
|
|
@@ -161,6 +161,10 @@
|
|
USES_SDL2
|
|
)
|
|
|
|
+if (EXECINFO_LIBRARY)
|
|
+ target_link_libraries(widelands_ball_of_mud ${EXECINFO_LIBRARY})
|
|
+endif()
|
|
+
|
|
if (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "OpenBSD")
|
|
target_link_libraries(widelands_ball_of_mud ${EXECINFO_LIBRARY})
|
|
endif (CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR CMAKE_SYSTEM_NAME MATCHES "OpenBSD")
|