File tree Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -1115,7 +1115,19 @@ if(MINGW)
1115
1115
if (DEPENDS )
1116
1116
set (ICU_LIBRARIES icuio icui18n icuuc icudata icutu iconv )
1117
1117
else ()
1118
- set (ICU_LIBRARIES icuio icuin icuuc icudt icutu iconv )
1118
+ # This is an extremely ugly hack to get around Boost not being built with static ICU.
1119
+ # We reported the issue, we are waiting for upstream to fix this issue: https://github.com/boostorg/boost/issues/1079#issue-3384962885
1120
+ # This hack links shared ICU libs to avoid linker errors we get in MSYS2 compilation (undefined symbols to ICU).
1121
+ set (OLD_LIB_SUFFIXES ${CMAKE_FIND_LIBRARY_SUFFIXES} )
1122
+ set (CMAKE_FIND_LIBRARY_SUFFIXES ".dll.a" )
1123
+ find_library (ICUIO_LIBRARIES NAMES icuio REQUIRED )
1124
+ find_library (ICUIN_LIBRARIES NAMES icuin REQUIRED )
1125
+ find_library (ICUUC_LIBRARIES NAMES icuuc REQUIRED )
1126
+ find_library (ICUDT_LIBRARIES NAMES icudt REQUIRED )
1127
+ find_library (ICUTU_LIBRARIES NAMES icutu REQUIRED )
1128
+ find_library (ICONV_LIBRARIES NAMES iconv REQUIRED )
1129
+ set (ICU_LIBRARIES ${ICUIO_LIBRARIES} ${ICUIN_LIBRARIES} ${ICUUC_LIBRARIES} ${ICUDT_LIBRARIES} ${ICUTU_LIBRARIES} ${ICONV_LIBRARIES} )
1130
+ set (CMAKE_FIND_LIBRARY_SUFFIXES ${OLD_LIB_SUFFIXES} )
1119
1131
endif ()
1120
1132
elseif (APPLE OR OPENBSD OR ANDROID )
1121
1133
set (EXTRA_LIBRARIES "" )
You can’t perform that action at this time.
0 commit comments