summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSlávek Banko <slavek.banko@axis.cz>2018-12-24 15:08:52 +0100
committerSlávek Banko <slavek.banko@axis.cz>2018-12-24 15:26:41 +0100
commit1fbbb6bb7a00e36d4e847a087f01b50c0c728125 (patch)
treee6de76b172f69b80bf16e223eec765365b0c25eb
parent83df9ef9555ea810992c6b65169da4d504da5681 (diff)
downloadgwenview-i18n-1fbbb6bb7a00e36d4e847a087f01b50c0c728125.tar.gz
gwenview-i18n-1fbbb6bb7a00e36d4e847a087f01b50c0c728125.zip
Conversion to the CMake building system.
Signed-off-by: Slávek Banko <slavek.banko@axis.cz> (cherry picked from commit 3b5c4c74473e99bee211d454d857fe325b4c55aa)
-rw-r--r--CMakeLists.txt65
-rw-r--r--ConfigureChecks.cmake27
-rw-r--r--da/CMakeLists.txt1
-rw-r--r--da/doc/CMakeLists.txt4
-rw-r--r--de/CMakeLists.txt1
-rw-r--r--de/doc/CMakeLists.txt4
-rw-r--r--es/CMakeLists.txt1
-rw-r--r--es/doc/CMakeLists.txt6
-rw-r--r--et/CMakeLists.txt1
-rw-r--r--et/doc/CMakeLists.txt4
-rw-r--r--fr/CMakeLists.txt1
-rw-r--r--fr/doc/CMakeLists.txt4
-rw-r--r--it/CMakeLists.txt1
-rw-r--r--it/doc/CMakeLists.txt4
-rw-r--r--nl/CMakeLists.txt1
-rw-r--r--nl/doc/CMakeLists.txt4
-rw-r--r--pl/CMakeLists.txt1
-rw-r--r--pl/doc/CMakeLists.txt4
-rw-r--r--pt/CMakeLists.txt1
-rw-r--r--pt/doc/CMakeLists.txt4
-rw-r--r--pt_BR/CMakeLists.txt1
-rw-r--r--pt_BR/doc/CMakeLists.txt4
-rw-r--r--ru/CMakeLists.txt1
-rw-r--r--ru/doc/CMakeLists.txt4
-rw-r--r--sv/CMakeLists.txt1
-rw-r--r--sv/doc/CMakeLists.txt4
26 files changed, 154 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
new file mode 100644
index 0000000..f71b1f9
--- /dev/null
+++ b/CMakeLists.txt
@@ -0,0 +1,65 @@
+#################################################
+#
+# (C) 2018 Slávek Banko
+# slavek.banko (AT) axis.cz
+#
+# Improvements and feedback are welcome
+#
+# This file is released under GPL >= 2
+#
+#################################################
+
+cmake_minimum_required( VERSION 2.8 )
+
+
+##### general package setup #####################
+
+project( gwenview-i18n )
+set( VERSION R14.1.0 )
+
+
+##### include essential cmake modules ###########
+
+include( FindPkgConfig )
+
+
+##### include our cmake modules #################
+
+set( CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/modules" )
+include( TDEMacros )
+
+
+##### setup install paths #######################
+
+include( TDESetupPaths )
+tde_setup_paths( )
+
+
+##### optional stuff ############################
+
+option( BUILD_ALL "Build all" ON )
+option( BUILD_DOC "Build documentation" ${BUILD_ALL} )
+option( BUILD_TRANSLATIONS "Build translations" ${BUILD_ALL} )
+
+
+##### configure checks
+
+include( ConfigureChecks.cmake )
+
+
+###### build translations for all languages #####
+
+if( BUILD_TRANSLATIONS )
+ file( GLOB_RECURSE po_files RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} */messages/*.po )
+
+ foreach( _po ${po_files} )
+ string( REPLACE "/" ";" _path "${_po}" )
+ list( GET _path 0 _lang )
+ tde_create_translation( FILES ${_po} LANG ${_lang} )
+ endforeach( )
+endif( )
+
+
+###### subdirectories ###########################
+
+tde_auto_add_subdirectories( )
diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake
new file mode 100644
index 0000000..7fff420
--- /dev/null
+++ b/ConfigureChecks.cmake
@@ -0,0 +1,27 @@
+###########################################
+# #
+# Improvements and feedback are welcome #
+# #
+# This file is released under GPL >= 3 #
+# #
+###########################################
+
+
+# required stuff
+find_package( TQt )
+find_package( TDE )
+
+
+##### gettext
+
+if( BUILD_TRANSLATIONS )
+ include( FindGettext )
+ if( GETTEXT_FOUND )
+ set( MSGFMT_EXECUTABLE ${GETTEXT_MSGFMT_EXECUTABLE}
+ CACHE FILEPATH "path to msgfmt executable" )
+ endif( GETTEXT_FOUND )
+
+ if( NOT MSGFMT_EXECUTABLE )
+ tde_message_fatal( "msgfmt is required but was not found on your system." )
+ endif( NOT MSGFMT_EXECUTABLE )
+endif( BUILD_TRANSLATIONS )
diff --git a/da/CMakeLists.txt b/da/CMakeLists.txt
new file mode 100644
index 0000000..ba78952
--- /dev/null
+++ b/da/CMakeLists.txt
@@ -0,0 +1 @@
+tde_conditional_add_subdirectory( BUILD_DOC doc )
diff --git a/da/doc/CMakeLists.txt b/da/doc/CMakeLists.txt
new file mode 100644
index 0000000..a01a3ce
--- /dev/null
+++ b/da/doc/CMakeLists.txt
@@ -0,0 +1,4 @@
+tde_create_handbook(
+ DESTINATION gwenview
+ LANG da
+)
diff --git a/de/CMakeLists.txt b/de/CMakeLists.txt
new file mode 100644
index 0000000..ba78952
--- /dev/null
+++ b/de/CMakeLists.txt
@@ -0,0 +1 @@
+tde_conditional_add_subdirectory( BUILD_DOC doc )
diff --git a/de/doc/CMakeLists.txt b/de/doc/CMakeLists.txt
new file mode 100644
index 0000000..d7616f6
--- /dev/null
+++ b/de/doc/CMakeLists.txt
@@ -0,0 +1,4 @@
+tde_create_handbook(
+ DESTINATION gwenview
+ LANG de
+)
diff --git a/es/CMakeLists.txt b/es/CMakeLists.txt
new file mode 100644
index 0000000..ba78952
--- /dev/null
+++ b/es/CMakeLists.txt
@@ -0,0 +1 @@
+tde_conditional_add_subdirectory( BUILD_DOC doc )
diff --git a/es/doc/CMakeLists.txt b/es/doc/CMakeLists.txt
new file mode 100644
index 0000000..8b27333
--- /dev/null
+++ b/es/doc/CMakeLists.txt
@@ -0,0 +1,6 @@
+###### the handbook seems incomplete - the index is missing
+
+# tde_create_handbook(
+# DESTINATION gwenview
+# LANG es
+# )
diff --git a/et/CMakeLists.txt b/et/CMakeLists.txt
new file mode 100644
index 0000000..ba78952
--- /dev/null
+++ b/et/CMakeLists.txt
@@ -0,0 +1 @@
+tde_conditional_add_subdirectory( BUILD_DOC doc )
diff --git a/et/doc/CMakeLists.txt b/et/doc/CMakeLists.txt
new file mode 100644
index 0000000..f4f5d1e
--- /dev/null
+++ b/et/doc/CMakeLists.txt
@@ -0,0 +1,4 @@
+tde_create_handbook(
+ DESTINATION gwenview
+ LANG et
+)
diff --git a/fr/CMakeLists.txt b/fr/CMakeLists.txt
new file mode 100644
index 0000000..ba78952
--- /dev/null
+++ b/fr/CMakeLists.txt
@@ -0,0 +1 @@
+tde_conditional_add_subdirectory( BUILD_DOC doc )
diff --git a/fr/doc/CMakeLists.txt b/fr/doc/CMakeLists.txt
new file mode 100644
index 0000000..268fdc3
--- /dev/null
+++ b/fr/doc/CMakeLists.txt
@@ -0,0 +1,4 @@
+tde_create_handbook(
+ DESTINATION gwenview
+ LANG fr
+)
diff --git a/it/CMakeLists.txt b/it/CMakeLists.txt
new file mode 100644
index 0000000..ba78952
--- /dev/null
+++ b/it/CMakeLists.txt
@@ -0,0 +1 @@
+tde_conditional_add_subdirectory( BUILD_DOC doc )
diff --git a/it/doc/CMakeLists.txt b/it/doc/CMakeLists.txt
new file mode 100644
index 0000000..b8635d7
--- /dev/null
+++ b/it/doc/CMakeLists.txt
@@ -0,0 +1,4 @@
+tde_create_handbook(
+ DESTINATION gwenview
+ LANG it
+)
diff --git a/nl/CMakeLists.txt b/nl/CMakeLists.txt
new file mode 100644
index 0000000..ba78952
--- /dev/null
+++ b/nl/CMakeLists.txt
@@ -0,0 +1 @@
+tde_conditional_add_subdirectory( BUILD_DOC doc )
diff --git a/nl/doc/CMakeLists.txt b/nl/doc/CMakeLists.txt
new file mode 100644
index 0000000..cc52e4a
--- /dev/null
+++ b/nl/doc/CMakeLists.txt
@@ -0,0 +1,4 @@
+tde_create_handbook(
+ DESTINATION gwenview
+ LANG nl
+)
diff --git a/pl/CMakeLists.txt b/pl/CMakeLists.txt
new file mode 100644
index 0000000..ba78952
--- /dev/null
+++ b/pl/CMakeLists.txt
@@ -0,0 +1 @@
+tde_conditional_add_subdirectory( BUILD_DOC doc )
diff --git a/pl/doc/CMakeLists.txt b/pl/doc/CMakeLists.txt
new file mode 100644
index 0000000..66f5211
--- /dev/null
+++ b/pl/doc/CMakeLists.txt
@@ -0,0 +1,4 @@
+tde_create_handbook(
+ DESTINATION gwenview
+ LANG pl
+)
diff --git a/pt/CMakeLists.txt b/pt/CMakeLists.txt
new file mode 100644
index 0000000..ba78952
--- /dev/null
+++ b/pt/CMakeLists.txt
@@ -0,0 +1 @@
+tde_conditional_add_subdirectory( BUILD_DOC doc )
diff --git a/pt/doc/CMakeLists.txt b/pt/doc/CMakeLists.txt
new file mode 100644
index 0000000..b6e609b
--- /dev/null
+++ b/pt/doc/CMakeLists.txt
@@ -0,0 +1,4 @@
+tde_create_handbook(
+ DESTINATION gwenview
+ LANG pt
+)
diff --git a/pt_BR/CMakeLists.txt b/pt_BR/CMakeLists.txt
new file mode 100644
index 0000000..ba78952
--- /dev/null
+++ b/pt_BR/CMakeLists.txt
@@ -0,0 +1 @@
+tde_conditional_add_subdirectory( BUILD_DOC doc )
diff --git a/pt_BR/doc/CMakeLists.txt b/pt_BR/doc/CMakeLists.txt
new file mode 100644
index 0000000..ec07bbc
--- /dev/null
+++ b/pt_BR/doc/CMakeLists.txt
@@ -0,0 +1,4 @@
+tde_create_handbook(
+ DESTINATION gwenview
+ LANG pt_BR
+)
diff --git a/ru/CMakeLists.txt b/ru/CMakeLists.txt
new file mode 100644
index 0000000..ba78952
--- /dev/null
+++ b/ru/CMakeLists.txt
@@ -0,0 +1 @@
+tde_conditional_add_subdirectory( BUILD_DOC doc )
diff --git a/ru/doc/CMakeLists.txt b/ru/doc/CMakeLists.txt
new file mode 100644
index 0000000..af1d996
--- /dev/null
+++ b/ru/doc/CMakeLists.txt
@@ -0,0 +1,4 @@
+tde_create_handbook(
+ DESTINATION gwenview
+ LANG ru
+)
diff --git a/sv/CMakeLists.txt b/sv/CMakeLists.txt
new file mode 100644
index 0000000..ba78952
--- /dev/null
+++ b/sv/CMakeLists.txt
@@ -0,0 +1 @@
+tde_conditional_add_subdirectory( BUILD_DOC doc )
diff --git a/sv/doc/CMakeLists.txt b/sv/doc/CMakeLists.txt
new file mode 100644
index 0000000..96dfe9b
--- /dev/null
+++ b/sv/doc/CMakeLists.txt
@@ -0,0 +1,4 @@
+tde_create_handbook(
+ DESTINATION gwenview
+ LANG sv
+)