summaryrefslogtreecommitdiff
path: root/indra/cmake/Hunspell.cmake
diff options
context:
space:
mode:
authorSignal Linden <signal@lindenlab.com>2022-10-10 10:01:10 -0700
committerSignal Linden <signal@lindenlab.com>2022-10-10 10:01:10 -0700
commit977d7e9ea0c6b04b085704a4a7b64244522e770c (patch)
tree80849436f1961ea58839808366dd1b3e2d07928f /indra/cmake/Hunspell.cmake
parentf2f9b32e753972d83087b9201a0073e208a0dd75 (diff)
parent7018deb7f8bc22bdbab7be29896c92ec648a3f2f (diff)
Merge remote-tracking branch 'bb/DRTVWR-568' into actions
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)