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
199
200
201
|
# desktop/remmina - The GTK+ Remote Desktop Client
#
# Copyright (C) 2011 Marc-Andre Moreau
# Copyright (C) 2014-2015 Antenore Gatta, Fabio Castelli, Giovanni Panozzo
# Copyright (C) 2016-2023 Antenore Gatta, Giovanni Panozzo
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor,
# Boston, MA 02110-1301, USA.
#
# In addition, as a special exception, the copyright holders give
# permission to link the code of portions of this program with the
# OpenSSL library under certain conditions as described in each
# individual source file, and distribute linked combinations
# including the two.
# You must obey the GNU General Public License in all respects
# for all of the code used other than OpenSSL. If you modify
# file(s) with this exception, you may extend this exception to your
# version of the file(s), but you are not obligated to do so. If you
# do not wish to do so, delete this exception statement from your
# version. If you delete this exception statement from all source
# files in the program, then also delete it here.
set(REMMINA_ICON ${REMMINA_APP_ID})
set(ICON16_DIR "${REMMINA_DATADIR}/icons/hicolor/16x16/apps")
set(ICON22_DIR "${REMMINA_DATADIR}/icons/hicolor/22x22/apps")
set(ICON24_DIR "${REMMINA_DATADIR}/icons/hicolor/24x24/apps")
set(ICON32_DIR "${REMMINA_DATADIR}/icons/hicolor/32x32/apps")
set(ICON48_DIR "${REMMINA_DATADIR}/icons/hicolor/48x48/apps")
set(ICON64_DIR "${REMMINA_DATADIR}/icons/hicolor/64x64/apps")
set(ICON72_DIR "${REMMINA_DATADIR}/icons/hicolor/72x72/apps")
set(ICON96_DIR "${REMMINA_DATADIR}/icons/hicolor/96x96/apps")
set(ICON128_DIR "${REMMINA_DATADIR}/icons/hicolor/128x128/apps")
set(ICON256_DIR "${REMMINA_DATADIR}/icons/hicolor/256x256/apps")
set(ICON512_DIR "${REMMINA_DATADIR}/icons/hicolor/512x512/apps")
set(STATUS16_DIR "${REMMINA_DATADIR}/icons/hicolor/16x16/status")
set(STATUS22_DIR "${REMMINA_DATADIR}/icons/hicolor/22x22/status")
set(STATUS24_DIR "${REMMINA_DATADIR}/icons/hicolor/24x24/status")
set(STATUS32_DIR "${REMMINA_DATADIR}/icons/hicolor/32x32/status")
set(STATUS48_DIR "${REMMINA_DATADIR}/icons/hicolor/48x48/status")
set(STATUS64_DIR "${REMMINA_DATADIR}/icons/hicolor/64x64/status")
set(ICONSVG_DIR "${REMMINA_DATADIR}/icons/hicolor/scalable/apps")
set(ICONSYM_DIR "${REMMINA_DATADIR}/icons/hicolor/symbolic/apps")
set(ICONAPPS_DIR "${REMMINA_DATADIR}/icons/hicolor/apps")
set(ICON16_DATA 16x16/apps/${REMMINA_ICON}.png)
set(ICON22_DATA 22x22/apps/${REMMINA_ICON}.png)
set(ICON24_DATA 24x24/apps/${REMMINA_ICON}.png)
set(ICON32_DATA 32x32/apps/${REMMINA_ICON}.png)
set(ICON48_DATA 48x48/apps/${REMMINA_ICON}.png)
set(ICON64_DATA 64x64/apps/${REMMINA_ICON}.png)
set(ICON72_DATA 72x72/apps/${REMMINA_ICON}.png)
set(ICON96_DATA 96x96/apps/${REMMINA_ICON}.png)
set(ICON128_DATA 128x128/apps/${REMMINA_ICON}.png)
set(ICON256_DATA 256x256/apps/${REMMINA_ICON}.png)
set(ICON512_DATA 512x512/apps/${REMMINA_ICON}.png)
set(STATUS16_DATA 16x16/status/org.remmina.Remmina-status.svg)
set(STATUS22_DATA 22x22/status/org.remmina.Remmina-status.svg)
set(STATUS24_DATA 24x24/status/org.remmina.Remmina-status.svg)
set(STATUS32_DATA 32x32/status/org.remmina.Remmina-status.svg)
set(STATUS48_DATA 48x48/status/org.remmina.Remmina-status.svg)
set(STATUS64_DATA 64x64/status/org.remmina.Remmina-status.svg)
set(ICONSVG_DATA scalable/apps/${REMMINA_ICON}.svg)
set(ICONSVG_RM_DATA scalable/apps/remmina-symbolic.svg)
set(ICONSVG_ORG_DATA scalable/apps/${REMMINA_ICON}-symbolic.svg)
set(ICONSYM_ORG_DATA scalable/apps/${REMMINA_ICON}-symbolic.svg)
install(FILES ${ICON16_DATA} DESTINATION ${ICON16_DIR})
install(FILES ${ICON22_DATA} DESTINATION ${ICON22_DIR})
install(FILES ${ICON24_DATA} DESTINATION ${ICON24_DIR})
install(FILES ${ICON32_DATA} DESTINATION ${ICON32_DIR})
install(FILES ${ICON48_DATA} DESTINATION ${ICON48_DIR})
install(FILES ${ICON64_DATA} DESTINATION ${ICON64_DIR})
install(FILES ${ICON72_DATA} DESTINATION ${ICON72_DIR})
install(FILES ${ICON96_DATA} DESTINATION ${ICON96_DIR})
install(FILES ${ICON128_DATA} DESTINATION ${ICON128_DIR})
install(FILES ${ICON256_DATA} DESTINATION ${ICON256_DIR})
install(FILES ${ICON512_DATA} DESTINATION ${ICON512_DIR})
install(FILES ${ICONSVG_DATA} DESTINATION ${ICONSVG_DIR})
install(FILES ${ICONSYM_DATA} DESTINATION ${ICONSYM_DIR})
install(FILES ${STATUS16_DATA} DESTINATION ${STATUS16_DIR})
install(FILES ${STATUS22_DATA} DESTINATION ${STATUS22_DIR})
install(FILES ${STATUS24_DATA} DESTINATION ${STATUS24_DIR})
install(FILES ${STATUS32_DATA} DESTINATION ${STATUS32_DIR})
install(FILES ${STATUS48_DATA} DESTINATION ${STATUS48_DIR})
install(FILES ${STATUS64_DATA} DESTINATION ${STATUS64_DIR})
install(FILES ${ICONSVG_RM_DATA} DESTINATION ${ICONAPPS_DIR})
install(FILES ${ICONSVG_ORG_DATA} DESTINATION ${ICONAPPS_DIR})
install(FILES ${ICONSVG_ORG_DATA} DESTINATION ${ICONSVG_DIR})
set(REMMINA_BINARY_PATH ${CMAKE_INSTALL_FULL_BINDIR}/remmina)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/${REMMINA_APP_ID}.desktop.in
${CMAKE_CURRENT_BINARY_DIR}/${REMMINA_APP_ID}.desktop @ONLY)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/org.remmina.Remmina-file.desktop.in
${CMAKE_CURRENT_BINARY_DIR}/org.remmina.Remmina-file.desktop @ONLY)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/remmina-file-wrapper.in
${CMAKE_CURRENT_BINARY_DIR}/remmina-file-wrapper @ONLY)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${REMMINA_APP_ID}.desktop
DESTINATION "${REMMINA_DATADIR}/applications")
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/org.remmina.Remmina-file.desktop
DESTINATION "${REMMINA_DATADIR}/applications")
install(FILES ${REMMINA_APP_ID}.appdata.xml
DESTINATION "${REMMINA_DATADIR}/metainfo")
install(
FILES ${CMAKE_CURRENT_BINARY_DIR}/remmina-file-wrapper
DESTINATION "${CMAKE_INSTALL_FULL_BINDIR}"
PERMISSIONS OWNER_EXECUTE OWNER_WRITE OWNER_READ GROUP_EXECUTE GROUP_READ WORLD_READ WORLD_EXECUTE
)
if(WITH_MANPAGES)
install(
FILES remmina-file-wrapper.1
DESTINATION ${CMAKE_INSTALL_FULL_MANDIR}/man1
)
endif()
# Kiosk Session Files
option(WITH_KIOSK_SESSION "Enable Kiosk desktop session files" OFF)
if(WITH_KIOSK_SESSION)
message(STATUS "Kiosk desktop session files will be installed")
install(
FILES remmina-gnome-xsession.desktop
DESTINATION ${REMMINA_DATADIR}/xsessions
RENAME remmina-gnome.desktop
PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ
)
install(
FILES remmina-gnome.desktop
DESTINATION ${REMMINA_DATADIR}/applications
RENAME remmina-gnome.desktop
PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ
)
install(
FILES remmina-gnome.session
DESTINATION ${REMMINA_DATADIR}/gnome-session/sessions
RENAME remmina-gnome.session
PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ
)
install(
FILES remmina-gnome
DESTINATION ${CMAKE_INSTALL_PREFIX}/bin
RENAME remmina-gnome
PERMISSIONS OWNER_EXECUTE OWNER_WRITE OWNER_READ GROUP_EXECUTE GROUP_READ
WORLD_EXECUTE WORLD_READ
)
install(
FILES gnome-session-remmina
DESTINATION ${CMAKE_INSTALL_PREFIX}/bin
RENAME gnome-session-remmina
PERMISSIONS OWNER_EXECUTE OWNER_WRITE OWNER_READ GROUP_EXECUTE GROUP_READ
WORLD_EXECUTE WORLD_READ
)
if(WITH_MANPAGES)
install(
FILES remmina-gnome.1
DESTINATION ${CMAKE_INSTALL_FULL_MANDIR}/man1
)
install(
FILES gnome-session-remmina.1
DESTINATION ${CMAKE_INSTALL_FULL_MANDIR}/man1
)
endif()
else()
message(STATUS "Kiosk desktop session files won't be installed")
endif()
# XML mime types
set( SHARED_MIME_INFO_MINIMUM_VERSION "0.30" )
set( XDG_MIME_INSTALL_DIR "${REMMINA_DATADIR}/mime/packages" )
find_package( SharedMimeInfo )
if( SHARED_MIME_INFO_FOUND )
install( FILES org.remmina.Remmina-mime.xml DESTINATION ${XDG_MIME_INSTALL_DIR} )
update_xdg_mimetypes( ${XDG_MIME_INSTALL_DIR} )
endif()
if(WITH_ICON_CACHE)
gtk_update_icon_cache("${REMMINA_DATADIR}/icons/hicolor")
endif()
if(WITH_UPDATE_DESKTOP_DB)
find_program(PROG_UPDATE_DESKTOP_DATABASE update-desktop-database)
if( PROG_UPDATE_DESKTOP_DATABASE )
install(
CODE
"message(STATUS \"Updating desktop file database\")"
CODE
"execute_process(COMMAND ${PROG_UPDATE_DESKTOP_DATABASE}
-q ${CMAKE_INSTALL_PREFIX}/share/applications)"
)
endif()
endif()
|