From a3477d689acb338a51a16cfbcabe37930672d13a Mon Sep 17 00:00:00 2001 From: Snaipe Date: Sat, 31 Oct 2015 12:43:55 +0100 Subject: [PATCH] Added i18n cmake option --- CMakeLists.txt | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index f3b6e5d..3a93462 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -70,12 +70,16 @@ endif() # Find dependencies -find_package(Gettext) -find_package(Libintl) -if (GETTEXT_FOUND AND LIBINTL_LIB_FOUND) - include(GettextTranslate) - add_subdirectory(po) - set(ENABLE_NLS 1) +option(I18N "Turn on internationalization" ON) + +if (I18N) + find_package(Gettext) + find_package(Libintl) + if (GETTEXT_FOUND AND LIBINTL_LIB_FOUND) + include(GettextTranslate) + add_subdirectory(po) + set(ENABLE_NLS 1) + endif () endif () include(CheckLibraryExists)