aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/CMakeLists.txt
diff options
context:
space:
mode:
authorGravatar Hoa V. DINH <dinh.viet.hoa@gmail.com>2014-10-26 20:47:34 -0700
committerGravatar Hoa V. DINH <dinh.viet.hoa@gmail.com>2014-10-26 20:47:34 -0700
commit78b187921c9bdd3278098847d37fb807110bacf7 (patch)
tree2839d83b8c9e60518d899171c8c2ee63e54e5234 /src/CMakeLists.txt
parenta11686316c2da049246d7697be8b335e52dd1ced (diff)
Use ICU on Linux
Diffstat (limited to 'src/CMakeLists.txt')
-rw-r--r--src/CMakeLists.txt21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 2e1db1bb..51b047d5 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -69,6 +69,27 @@ else()
message(STATUS "Found uchardet")
endif()
+if(NOT APPLE)
+
+ # detect icu
+
+ find_path(ICU4C_INCLUDE_DIR
+ NAMES unicode/utf8.h
+ PATHS ${additional_includes}
+ )
+ find_library(ICU_LIBRARY
+ NAMES icuuc
+ PATHS ${additional_lib_searchpath}
+ )
+
+ if(NOT ICU4C_INCLUDE_DIR OR NOT ICU4C_LIBRARY)
+ message(FATAL_ERROR "ERROR: Could not find icu4c")
+ else()
+ message(STATUS "Found icu4c")
+ endif()
+
+endif()
+
# detect libetpan
find_path(LIBETPAN_INCLUDE_DIR