-
-
Notifications
You must be signed in to change notification settings - Fork 122
/
Readme-dev-cmake-en.txt
198 lines (156 loc) · 8.64 KB
/
Readme-dev-cmake-en.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
This file contains the CMake files description
(useful for developers)
./CMakeLists.txt - root file (the main script):
contains a list of general options;
determines the program type Psi/Psi+;
determines chatlog type Basic/Webkit/Webengine;
contains general compile definitions;
enables ccache, mxe;
adds iris, 3rdparty, src, plugins subdirectories;
in case of only plugins build - enables plugins;
if plugins/generic/psimedia directory exists and BUILD_PSIMEDIA flag is
enabled - builds psimedia library.
./icondef.xml.in - template-file to generate icondef.xml file
./iconsets.qrc.in - template-file to generate iconsets.qrc file
./3rdparty/CMakeLists.txt - builds qhttp static library
./3rdparty/qite/libqite/libqite.cmake - contains qite project file list
./cmake/modules - directory contains modules for searching libraries, for determining a
program version, for work with sources and generation of additional targets and files.
./cmake/modules/COPYING-CMAKE-SCRIPTS - license file (to solve problems with mainaining)
./cmake/modules/FindLibGpgError.cmake - finds libgpg-error library [moved to the OTR plugin sources]
./cmake/modules/FindEnchant.cmake - finds enchant library
./cmake/modules/FindLibOtr.cmake - finds otr library [moved to the OTR plugin sources]
./cmake/modules/FindHunspell.cmake - finds hunspell library
./cmake/modules/FindLibTidy.cmake - finds tidy or html-tidy library [moved to the OTR plugin sources]
./cmake/modules/FindSparkle.cmake - finds sparkle (not yet tested)
./cmake/modules/FindMINIZIP.cmake - finds minizip library
./cmake/modules/FindXCB.cmake - finds xcb library
./cmake/modules/FindLibGcrypt.cmake - finds libgctypt or libgcrypt2 library [moved to the OTR plugin sources]
./cmake/modules/FindQca.cmake - finds qca-qt library
./cmake/modules/FindPsiPluginsApi.cmake - module to search files useful at build plugins
./cmake/modules/get-version.cmake - determines clien version using git utility or by parsing
a ../version file
./cmake/modules/win32-prepare-deps.cmake - generates a list of files to install
with make prepare-bin-libs command, which install dependency libraries
into output build directory. Or using windeployqt utility if available
with make windeploy command
./cmake/modules/generate_desktopfile.cmake - generates .desktop file
./cmake/modules/fix-codestyle.cmake - module for codestyle fix using clang-format
./cmake/modules/win32_definitions.cmake - provides the next features:
determines PSI_SDK and GSTREAMER_SDK pathes
determines the MinGW or MSVC compilation flags
contains the main definitions for OS Windows
./cmake/modules/psi-cmake-functions.cmake - contains useful functions that can be run anywhere in the project
./cmake/modules/qtkeychain-bundled - module to compile qtkeychain library together with psi as static library
./cmake/modules/policyRules.cmake - contains default policy rules definitions
./iris/CMakeLists.txt - builds iris library:
contains options for the iris library (duplicated in a main script)
enables qjdns (if option enabled)
adds src/irisnet and src/xmpp subdirectories
/***
./iris - this directory contains an additional files to build iris library outside of the Psi
project. This functionality is partially realized. Needs reworking.
***/
./iris/cmake/modules - modules for libraries searching (copies of Psi modules)
./iris/src/irisnet/CMakeLists.txt - builds irisnet static library
./iris/src/xmpp/CMakeLists.txt - builds iris static library
./src/CMakeLists.txt - builds and installs the Psi/Psi+ project files:
adds ../translations directory (if exists) and compiles translations files
finds an additional libraries and static libraries and adds them to project
sets the main program name based on the main script data
generates config.h file based on the config.h.in template file
generates psi_win.rc based on the ../win32/psi_win.rc.in template file and
compiles psi_win.o file
adds src.cmake file
adds ../3rdparty/qite/libqite/libqite.cmake file
adds irisprotocol/irisprotocol.cmake file
adds protocol/protocol.cmake file
adds ../plugins/plugins.cmake file
adds AutoUpdater, options, tabs, privacy, Certificates, avcall, psimedia,
contactmanager, tools, libpsi/dialogs, libpsi/tools, widgets, sxe,
whiteboarding subdirectories
substitutes the output program name with an extended name (if enabled)
generates description files for default iconsets
if name is extended generates the .desktop file using generate_desktopfile.cmake module
creates an installation rules
if DEV_MODE option is enabled generates an installation rules for dependency
libraries to install into binary output directory using win32-prepare-deps.cmake
module
./src/config.h.in - template-file for config.h file creation
./src/src.cmake:
contains the default compile definitions;
contains a lists with the main source files:
FORMS list - contains ui files;
HEADERS list - contains C/C++ header files
SOURCES list - contains C/C++ source files
./src/AutoUpdater/CMakeLists.txt - builds AutoUpdater static library
./src/avcall/CMakeLists.txt - builds avcall static library
./src/Certificates/CMakeLists.txt - builds Certificates static library
./src/contactmanager/CMakeLists.txt - builds contactmanager static library
./src/irisprotocol/irisprotocol.cmake - a list of source files which will be added into
the main sources list
./src/libpsi/dialogs/CMakeLists.txt - builds libpsi_dialogs static library
./src/libpsi/tools/CMakeLists.txt - builds libpsi_tools static library:
adds zip subdirectory
./src/libpsi/tools/zip/CMakeLists.txt - builds zip static library
./src/options/CMakeLists.txt - builds options static library
./src/privacy/CMakeLists.txt - builds privacy static library
./src/protocol/protocol.cmake - a list of source files which will be added into
the main sources list
./src/psimedia/CMakeLists.txt - build psimedia static library
./src/sxe/CMakeLists.txt - builds sxe static library
./src/tabs/CMakeLists.txt - build tabs static library
./src/tools/CMakeLists.txt - builds tools static library
./src/whiteboarding/CMakeLists.txt - builds whiteboarding static library
./src/widgets/CMakeLists.txt - builds widgets static library
./plugins/plugins.cmake - a list of header files which will be added into
the main headers list
./plugins/variables.cmake.in - template-file, contains the main variables useful
to build plugins, general for all plugins
./plugins/pluginsconf.pri.cmake.in - template-file to generate pluginsconf.pri file
./plugins/CMakeLists.txt - main script to rule the plugins
contains the main build rules for all plugins
adds generic, unix, dev subdirectories
./plugins/generic/CMakeLists.txt:
adds subrirectory for each plugin, if BUILD_PLUGINS variable is set it adds only
plugins from BUILD_PLUGINS list (or exclude plugins)
./plugins/dev/CMakeLists.txt:
adds subrirectory for each plugin, if BUILD_PLUGINS variable is set it adds only
plugins from BUILD_PLUGINS list (or exclude plugins)
./plugins/unix/CMakeLists.txt:
adds subrirectory for each plugin, if BUILD_PLUGINS variable is set it adds only
plugins from BUILD_PLUGINS list (or exclude plugins)
./plugins/*TYPE*/*PLUGIN*/CMakeLists.txt - builds and installs a plugin
whit "*TYPE*" type and "*PLUGIN*" name. The structure of these files are mostly
the same
./win32/psi_win.rc.in - template-file to generate psi_win.rc file
/***
USEFUL TIPS
***/
/***
For a comfortable plugins packages creation and to aviod downloading all the Psi
sources or copying of these sources if INSTALL_PLUGINS_SDK flag is enabled
while installing Psi using CMake-scripts could be installed an additional files
together with the main program files such as:
Plugins API (includes, *.pri files, variables.cmake)
(path $prefix/share/name_of_program/plugins)
And also could be installed Plugins API search module
FindPsiPluginsApi.cmake
(path $prefix/share/cmake/Modules)
In this case the variables.cmake generates at Psi build and contains:
- path to the plugins install directory
- path to the psi/psi+ data directory
- name of a program (psi or psi-plus)
- plugins defenitions
Also the CMake-script generates *.pri files, needed to build plugins using qmake utility
***/
/***
If there is a plugin debug necessity in OS Linux you can do next:
- download psi-plus-snapshots repository
- open CMakeLists.txt from root directory using qtcreator
- choose profile and build type
- enable both ENABLE_PLUGINS and DEV_MODE flags
- clean CMake cache if needed and run CMake (using qtcreator build menu)
- build project
That's all. You can debug plugin with the psi/psi+ program.
***/