#1 cmake conversion

Merged
SlavekB merged 2 commits from feat/cmakeConv into master 10 months ago

+ 77
- 0
CMakeLists.txt View File

@@ -0,0 +1,77 @@
1
+############################################
2
+#                                          #
3
+#  Improvements and feedbacks are welcome  #
4
+#                                          #
5
+#  This file is released under GPL >= 3    #
6
+#                                          #
7
+############################################
8
+
9
+
10
+cmake_minimum_required( VERSION 2.8 )
11
+
12
+
13
+#### general package setup
14
+
15
+project( yakuake )
16
+set( VERSION R14.1.0 )
17
+
18
+
19
+#### include essential cmake modules
20
+
21
+include( FindPkgConfig          )
22
+include( CheckIncludeFile       )
23
+include( CheckLibraryExists     )
24
+include( CheckCSourceCompiles   )
25
+include( CheckCXXSourceCompiles )
26
+
27
+
28
+#### include our cmake modules
29
+
30
+set( CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/modules" )
31
+include( TDEMacros )
32
+
33
+
34
+##### setup install paths
35
+
36
+include( TDESetupPaths )
37
+tde_setup_paths( )
38
+
39
+
40
+##### optional stuff
41
+
42
+option( WITH_ALL_OPTIONS "Enable all optional support" OFF                                          )
43
+option( WITH_GCC_VISIBILITY "Enable fvisibility and fvisibility-inlines-hidden" ${WITH_ALL_OPTIONS} )
44
+
45
+
46
+##### user requested modules
47
+
48
+option( BUILD_ALL "Build all" ON                             )
49
+option( BUILD_DOC "Build documentation" ${BUILD_ALL}         )
50
+option( BUILD_TRANSLATIONS "Build translations" ${BUILD_ALL} )
51
+
52
+
53
+##### configure checks
54
+
55
+include( ConfigureChecks.cmake )
56
+
57
+
58
+###### global compiler settings
59
+
60
+add_definitions( -DHAVE_CONFIG_H )
61
+
62
+set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${TQT_CXX_FLAGS}" )
63
+set( CMAKE_SHARED_LINKER_FLAGS "-Wl,--no-undefined" )
64
+set( CMAKE_MODULE_LINKER_FLAGS "-Wl,--no-undefined" )
65
+
66
+
67
+##### directories
68
+
69
+add_subdirectory( yakuake )
70
+tde_conditional_add_subdirectory( BUILD_DOC doc         )
71
+tde_conditional_add_subdirectory( BUILD_TRANSLATIONS po ) 
72
+
73
+
74
+
75
+##### write configure files
76
+
77
+configure_file( config.h.cmake config.h @ONLY )

+ 45
- 0
ConfigureChecks.cmake View File

@@ -0,0 +1,45 @@
1
+###########################################
2
+#                                         #
3
+#  Improvements and feedback are welcome  #
4
+#                                         #
5
+#  This file is released under GPL >= 3   #
6
+#                                         #
7
+###########################################
8
+
9
+
10
+# required stuff
11
+find_package( TQt )
12
+find_package( TDE )
13
+
14
+tde_setup_architecture_flags( )
15
+
16
+include(TestBigEndian)
17
+test_big_endian(WORDS_BIGENDIAN)
18
+
19
+
20
+##### check for gcc visibility support
21
+
22
+if( WITH_GCC_VISIBILITY )
23
+  if( NOT UNIX )
24
+    tde_message_fatal( "gcc visibility support was requested, but your system is not *NIX" )
25
+  endif( NOT UNIX )
26
+  set( __KDE_HAVE_GCC_VISIBILITY 1 )
27
+  set( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fvisibility=hidden -fvisibility-inlines-hidden")
28
+  set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility=hidden -fvisibility-inlines-hidden")
29
+endif( WITH_GCC_VISIBILITY )
30
+
31
+
32
+##### gettext
33
+
34
+if( BUILD_TRANSLATIONS )
35
+  include( FindGettext )
36
+  if( GETTEXT_FOUND )
37
+    set( MSGFMT_EXECUTABLE ${GETTEXT_MSGFMT_EXECUTABLE} 
38
+      CACHE FILEPATH "path to msgfmt executable" )
39
+  endif( GETTEXT_FOUND )
40
+  
41
+  if( NOT MSGFMT_EXECUTABLE )
42
+    tde_message_fatal( "msgfmt is required but was not found on your system." )
43
+  endif( NOT MSGFMT_EXECUTABLE )
44
+endif( BUILD_TRANSLATIONS )
45
+

+ 8
- 0
config.h.cmake View File

@@ -0,0 +1,8 @@
1
+#define VERSION "@VERSION@"
2
+
3
+// Defined if you have fvisibility and fvisibility-inlines-hidden support.
4
+#cmakedefine __KDE_HAVE_GCC_VISIBILITY 1
5
+
6
+/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most
7
+   significant byte first (like Motorola and SPARC, unlike Intel). */
8
+#cmakedefine WORDS_BIGENDIAN @WORDS_BIGENDIAN@

+ 1
- 0
doc/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_auto_add_subdirectories( )

+ 1
- 0
doc/en/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_handbook( DESTINATION ${PROJECT_NAME} )

+ 5
- 0
doc/man/CMakeLists.txt View File

@@ -0,0 +1,5 @@
1
+INSTALL(
2
+    FILES ${PROJECT_NAME}.1
3
+    DESTINATION ${MAN_INSTALL_DIR}/man1
4
+    COMPONENT doc
5
+)

+ 50
- 0
doc/man/yakuake.1 View File

@@ -0,0 +1,50 @@
1
+.TH YaKuake 1 "Oct 2005" "" ""
2
+.SH NAME
3
+YaKuake \- a Quake-style terminal emulator based on TDE Konsole technology.
4
+.SH SYNOPSIS
5
+.B YaKuake 
6
+[Qt\-options] [TDE\-options]
7
+.SH DESCRIPTION
8
+YaKuake is inspired from the terminal in the Quake game: when you press a key
9
+(by default F12, but that can be changed) a terminal window slides down from
10
+the top of the screen. Press the key again, and the terminal slides back.
11
+
12
+It is faster than a keyboard shortcut because it is already loaded into memory
13
+and as such is very useful to anyone who frequently finds themselves switching
14
+in and out of terminal sessions.
15
+.SH OPTIONS
16
+YaKuake has no application-specific options.
17
+
18
+Generic options:
19
+.TP
20
+.B  \-\-help
21
+Show help about options
22
+.TP
23
+.B  \-\-help\-qt  
24
+Show Qt specific options
25
+.TP
26
+.B  \-\-help\-tde  
27
+Show TDE specific options
28
+.TP
29
+.B  \-\-help\-all  
30
+Show all options
31
+.TP
32
+.B  \-\-author  
33
+Show author information
34
+.TP
35
+.B \-v,  \-\-version  
36
+Show version information
37
+.TP
38
+.B  \-\-license  
39
+Show license information
40
+.TP
41
+.B  \-\-  
42
+End of options
43
+.SH SEE ALSO
44
+YaKuake Homepage: http://extragear.kde.org/apps/yakuake/
45
+.SH AUTHOR
46
+YaKuake was written by Francois Chazal <neptune3k@free.fr>.
47
+YaKuake is currently maintained by Eike Hein <sho@eikehein.com>.
48
+.SH OTHER
49
+This manual page was written by Ana Beatriz Guerrero Lopez <ana@ekaia.org>,
50
+for the Debian project (but may be used by others).

+ 1
- 0
po/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_auto_add_subdirectories( )

+ 1
- 0
po/de/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG de )

+ 1
- 0
po/el/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG el )

+ 1
- 0
po/es/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG es )

+ 1
- 0
po/et/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG et )

+ 1
- 0
po/fr/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG fr )

+ 1
- 0
po/hu/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG hu )

+ 1
- 0
po/it/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG it )

+ 1
- 0
po/ja/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG ja )

+ 1
- 0
po/nl/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG nl )

+ 1
- 0
po/pl/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG pl )

+ 1
- 0
po/pt/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG pt )

+ 1
- 0
po/pt_BR/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG pt_BR )

+ 1
- 0
po/ru/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG ru )

+ 1
- 0
po/sv/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG sv )

+ 1
- 0
po/tr/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_create_translation( LANG tr )

+ 2
- 0
yakuake/CMakeLists.txt View File

@@ -0,0 +1,2 @@
1
+add_subdirectory( src )
2
+add_subdirectory( skins )

+ 1
- 0
yakuake/skins/CMakeLists.txt View File

@@ -0,0 +1 @@
1
+tde_auto_add_subdirectories( )

+ 8
- 0
yakuake/skins/default/CMakeLists.txt View File

@@ -0,0 +1,8 @@
1
+add_subdirectory( title )
2
+add_subdirectory( tabs )
3
+
4
+
5
+install(
6
+    FILES tabs.skin title.skin icon.png
7
+    DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/default
8
+)

+ 20
- 0
yakuake/skins/default/tabs/CMakeLists.txt View File

@@ -0,0 +1,20 @@
1
+install(
2
+
3
+    FILES
4
+        back_image.png
5
+        left_corner.png
6
+        minus_down.png
7
+        minus_over.png
8
+        minus_up.png
9
+        plus_down.png
10
+        plus_over.png
11
+        plus.png plus_up.png
12
+        right_corner.png
13
+        selected_back.png
14
+        selected_left.png
15
+        selected_right.png 
16
+        unselected_back.png
17
+        separator.png
18
+  
19
+  DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/default/tabs
20
+)

+ 1
- 1
yakuake/skins/default/title.skin View File

@@ -16,7 +16,7 @@ y=14
16 16
 red=40
17 17
 green=60
18 18
 blue=80
19
-text=KDE Terminal Emulator
19
+text=TDE Terminal Emulator
20 20
 
21 21
 [Background]
22 22
 back_image=/title/back.png

+ 18
- 0
yakuake/skins/default/title/CMakeLists.txt View File

@@ -0,0 +1,18 @@
1
+install(
2
+
3
+    FILES
4
+        back.png
5
+        config_down.png
6
+        config_over.png
7
+        config_up.png
8
+        focus_down.png
9
+        focus_over.png
10
+        focus_up.png
11
+        left.png
12
+        quit_down.png
13
+        quit_over.png
14
+        quit_up.png
15
+        right.png
16
+        
17
+  DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/default/title
18
+)

+ 8
- 0
yakuake/skins/plastik_dark/CMakeLists.txt View File

@@ -0,0 +1,8 @@
1
+add_subdirectory( title )
2
+add_subdirectory( tabs )
3
+
4
+
5
+install(
6
+    FILES tabs.skin title.skin icon.png
7
+    DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/plastik_dark
8
+)

+ 20
- 0
yakuake/skins/plastik_dark/tabs/CMakeLists.txt View File

@@ -0,0 +1,20 @@
1
+install(
2
+    
3
+    FILES
4
+        back_image.png
5
+        left_corner.png
6
+        minus_down.png
7
+        minus_over.png
8
+        minus_up.png
9
+        plus_down.png
10
+        plus_over.png
11
+        plus_up.png
12
+        right_corner.png
13
+        selected_back.png
14
+        selected_left.png
15
+        selected_right.png
16
+        unselected_back.png
17
+        separator.png
18
+    
19
+    DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/plastik_dark/tabs
20
+)

+ 18
- 0
yakuake/skins/plastik_dark/title/CMakeLists.txt View File

@@ -0,0 +1,18 @@
1
+install(
2
+
3
+    FILES
4
+        back.png
5
+        config_down.png
6
+        config_over.png
7
+        config_up.png
8
+        focus_down.png
9
+        focus_over.png
10
+        focus_up.png
11
+        left.png
12
+        quit_down.png
13
+        quit_over.png
14
+        quit_up.png
15
+        right.png
16
+        
17
+    DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/plastik_dark/title
18
+)

+ 8
- 0
yakuake/skins/plastik_light/CMakeLists.txt View File

@@ -0,0 +1,8 @@
1
+add_subdirectory( title )
2
+add_subdirectory( tabs )
3
+
4
+
5
+install(
6
+    FILES tabs.skin title.skin icon.png
7
+    DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/plastik_light
8
+)

+ 19
- 0
yakuake/skins/plastik_light/tabs/CMakeLists.txt View File

@@ -0,0 +1,19 @@
1
+install(
2
+    FILES
3
+        back_image.png
4
+        left_corner.png
5
+        minus_down.png
6
+        minus_over.png
7
+        minus_up.png
8
+        plus_down.png
9
+        plus_over.png
10
+        plus_up.png
11
+        right_corner.png
12
+        selected_back.png
13
+        selected_left.png
14
+        selected_right.png
15
+        unselected_back.png
16
+        separator.png
17
+        
18
+    DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/plastik_light/tabs
19
+)

+ 18
- 0
yakuake/skins/plastik_light/title/CMakeLists.txt View File

@@ -0,0 +1,18 @@
1
+install(
2
+
3
+    FILES
4
+        back.png
5
+        config_down.png
6
+        config_over.png
7
+        config_up.png
8
+        focus_down.png
9
+        focus_over.png
10
+        focus_up.png
11
+        left.png
12
+        quit_down.png
13
+        quit_over.png
14
+        quit_up.png
15
+        right.png
16
+        
17
+    DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/plastik_light/title
18
+)

+ 64
- 0
yakuake/src/CMakeLists.txt View File

@@ -0,0 +1,64 @@
1
+include_directories(
2
+  ${CMAKE_BINARY_DIR}
3
+  ${CMAKE_CURRENT_BINARY_DIR}
4
+  ${CMAKE_CURRENT_SOURCE_DIR}
5
+  ${TDE_INCLUDE_DIR}
6
+  ${TQT_INCLUDE_DIRS}
7
+)
8
+
9
+link_directories(
10
+  ${TQT_LIBRARY_DIRS}
11
+  ${TDE_LIB_DIR}
12
+)
13
+
14
+
15
+##### yakuake (executable)
16
+
17
+tde_add_executable( ${PROJECT_NAME} AUTOMOC
18
+
19
+  SOURCES
20
+        dcop_interface.skel
21
+        first_run_dialog.cpp
22
+        first_run_dialog_ui.ui
23
+        general_settings.cpp
24
+        general_settings_ui.ui
25
+        image_button.cpp
26
+        main.cpp
27
+        main_window.cpp
28
+        session.cpp
29
+        settings.kcfgc
30
+        skin_list_item.cpp
31
+        skin_settings.cpp
32
+        skin_settings_ui.ui
33
+        tabbed_widget.cpp
34
+        tab_bar.cpp
35
+        terminal.cpp
36
+        terminal_focus_watcher.cpp
37
+        terminal_splitter.cpp
38
+        title_bar.cpp
39
+        translucent_widget.cpp
40
+  LINK
41
+     tdecore-shared
42
+     tdeui-shared
43
+     tdeio-shared
44
+     
45
+  DESTINATION ${BIN_INSTALL_DIR}
46
+)
47
+
48
+
49
+##### icons
50
+
51
+tde_install_icons( )
52
+
53
+
54
+##### other data
55
+
56
+install(
57
+    FILES ${PROJECT_NAME}.desktop
58
+    DESTINATION ${XDG_APPS_INSTALL_DIR}
59
+)
60
+
61
+install(
62
+    FILES ${PROJECT_NAME}.kcfg
63
+    DESTINATION ${KCFG_INSTALL_DIR}
64
+)

Loading…
Cancel
Save