khanat-opennel-code/patch/libicuuc.patch

22 lines
782 B
Diff

diff --git a/code/CMakeLists.txt b/code/CMakeLists.txt
index 4e422c0b5..e76be35f1 100644
--- a/code/CMakeLists.txt
+++ b/code/CMakeLists.txt
@@ -153,6 +153,17 @@ IF(WITH_STATIC)
IF(LIBLZMA_LIBRARIES)
SET(LIBXML2_LIBRARIES ${LIBXML2_LIBRARIES} ${LIBLZMA_LIBRARIES})
ENDIF()
+ # under Linux, recent libxml2 versions are linked without libicuuc & libicudata
+ IF(WITH_STATIC_EXTERNAL)
+ find_library (LIBICUUC_LIBRARY NAMES icuuc)
+ IF(LIBICUUC_LIBRARY)
+ SET(LIBXML2_LIBRARIES ${LIBXML2_LIBRARIES} ${LIBICUUC_LIBRARY})
+ ENDIF()
+ find_library (LIBICUDATA_LIBRARY NAMES icudata)
+ IF(LIBICUDATA_LIBRARY)
+ SET(LIBXML2_LIBRARIES ${LIBXML2_LIBRARIES} ${LIBICUDATA_LIBRARY})
+ ENDIF()
+ ENDIF()
ENDIF()
ENDIF()