summaryrefslogtreecommitdiff
path: root/indra/cmake/Hunspell.cmake
diff options
context:
space:
mode:
authorAndrey Lihatskiy <alihatskiy@productengine.com>2023-04-07 00:20:59 +0300
committerAndrey Lihatskiy <alihatskiy@productengine.com>2023-04-07 00:20:59 +0300
commitf1095d78315818642e62b7f4af9984557e176b5d (patch)
tree3606970e28e1101befbc7b42ccd6033cfd839e7b /indra/cmake/Hunspell.cmake
parent4042ed9701fcfa42c03fc285a757aa348f800e33 (diff)
parentc7053a6928fd5eafdc935453742e92951ae4e0c1 (diff)
Merge branch 'main' into marchcat/main-contrib-merge
# Conflicts: # indra/cmake/CMakeLists.txt # indra/llcommon/llsdserialize.cpp # indra/llcommon/llsdserialize.h # indra/llcommon/tests/llleap_test.cpp # indra/newview/llfilepicker.h # indra/newview/llfilepicker_mac.h # indra/newview/llfilepicker_mac.mm # indra/newview/skins/default/xui/en/strings.xml
Diffstat (limited to 'indra/cmake/Hunspell.cmake')
-rw-r--r--indra/cmake/Hunspell.cmake31
1 files changed, 13 insertions, 18 deletions
diff --git a/indra/cmake/Hunspell.cmake b/indra/cmake/Hunspell.cmake
index 06227b3fe2..bb037c0237 100644
--- a/indra/cmake/Hunspell.cmake
+++ b/indra/cmake/Hunspell.cmake
@@ -1,22 +1,17 @@
# -*- cmake -*-
include(Prebuilt)
-set(HUNSPELL_FIND_QUIETLY ON)
-set(HUNSPELL_FIND_REQUIRED ON)
+include_guard()
+use_prebuilt_binary(dictionaries)
-if (USESYSTEMLIBS)
- include(FindHUNSPELL)
-else (USESYSTEMLIBS)
- use_prebuilt_binary(libhunspell)
- if (WINDOWS)
- set(HUNSPELL_LIBRARY libhunspell)
- elseif(DARWIN)
- set(HUNSPELL_LIBRARY hunspell-1.3)
- elseif(LINUX)
- set(HUNSPELL_LIBRARY hunspell-1.3)
- else()
- message(FATAL_ERROR "Invalid platform")
- endif()
- set(HUNSPELL_INCLUDE_DIRS ${LIBS_PREBUILT_DIR}/include/hunspell)
- use_prebuilt_binary(dictionaries)
-endif (USESYSTEMLIBS)
+add_library( ll::hunspell INTERFACE IMPORTED )
+use_system_binary(hunspell)
+use_prebuilt_binary(libhunspell)
+if (WINDOWS)
+ target_link_libraries( ll::hunspell INTERFACE libhunspell)
+elseif(DARWIN)
+ target_link_libraries( ll::hunspell INTERFACE hunspell-1.3)
+elseif(LINUX)
+ target_link_libraries( ll::hunspell INTERFACE hunspell-1.3)
+endif()
+target_include_directories( ll::hunspell SYSTEM INTERFACE ${LIBS_PREBUILT_DIR}/include/hunspell)