Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/Remmina/Remmina.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CMakeLists.txt1
-rw-r--r--cmake/GtkUpdateIconCache.cmake36
-rw-r--r--data/desktop/CMakeLists.txt2
-rw-r--r--data/icons/CMakeLists.txt1
-rw-r--r--plugins/nx/CMakeLists.txt2
-rw-r--r--plugins/rdp/CMakeLists.txt2
-rw-r--r--plugins/spice/CMakeLists.txt2
-rw-r--r--plugins/st/CMakeLists.txt2
-rw-r--r--plugins/vnc/CMakeLists.txt2
-rw-r--r--plugins/xdmcp/CMakeLists.txt2
10 files changed, 52 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index edc51f767..7a3ee4c9f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -50,6 +50,7 @@ set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/)
include(FindOptionalPackage)
include(ConfigOptions)
+include(GtkUpdateIconCache)
if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE "Release")
diff --git a/cmake/GtkUpdateIconCache.cmake b/cmake/GtkUpdateIconCache.cmake
new file mode 100644
index 000000000..7a284fb58
--- /dev/null
+++ b/cmake/GtkUpdateIconCache.cmake
@@ -0,0 +1,36 @@
+# Copyright 2015 Volker Krause <vkrause@kde.org>
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# 1. Redistributions of source code must retain the copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# 3. The name of the author may not be used to endorse or promote products
+# derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+find_program(GTK_UPDATE_ICON_CACHE_EXEC NAMES gtk-update-icon-cache)
+macro(gtk_update_icon_cache _dir)
+ if (GTK_UPDATE_ICON_CACHE_EXEC)
+ install(CODE "
+ set(DESTDIR_VALUE \"\$ENV{DESTDIR}\")
+ if (NOT DESTDIR_VALUE)
+ execute_process(COMMAND ${GTK_UPDATE_ICON_CACHE_EXEC} -qfit ${_dir})
+ endif()
+ ")
+ endif()
+endmacro()
diff --git a/data/desktop/CMakeLists.txt b/data/desktop/CMakeLists.txt
index 2d7f9b819..499a4e84d 100644
--- a/data/desktop/CMakeLists.txt
+++ b/data/desktop/CMakeLists.txt
@@ -84,6 +84,8 @@ install(FILES ${ICON128_DATA} DESTINATION ${ICON128_DIR})
install(FILES ${ICON256_DATA} DESTINATION ${ICON256_DIR})
install(FILES ${ICONSVG_DATA} DESTINATION ${ICONSVG_DIR})
+gtk_update_icon_cache("${REMMINA_DATADIR}/icons/hicolor")
+
set(REMMINA_BINARY_PATH ${CMAKE_INSTALL_FULL_BINDIR}/remmina)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/${REMMINA_APP_ID}.desktop.in
diff --git a/data/icons/CMakeLists.txt b/data/icons/CMakeLists.txt
index 7b1f681d3..7fa27846f 100644
--- a/data/icons/CMakeLists.txt
+++ b/data/icons/CMakeLists.txt
@@ -67,3 +67,4 @@ set(APPICONSCALE_EMBLEMS_DATA
install(FILES ${APPICONSCALE_ACTIONS_DATA} DESTINATION ${APPICONSCALE_ACTIONS_DIR})
install(FILES ${APPICONSCALE_EMBLEMS_DATA} DESTINATION ${APPICONSCALE_EMBLEMS_DIR})
+gtk_update_icon_cache("${REMMINA_DATADIR}/icons/hicolor")
diff --git a/plugins/nx/CMakeLists.txt b/plugins/nx/CMakeLists.txt
index 7d073a3a5..9f89baffb 100644
--- a/plugins/nx/CMakeLists.txt
+++ b/plugins/nx/CMakeLists.txt
@@ -60,3 +60,5 @@ install(TARGETS remmina-plugin-nx DESTINATION ${REMMINA_PLUGINDIR})
install(FILES
scalable/emblems/remmina-nx-symbolic.svg
DESTINATION ${APPICONSCALE_EMBLEMS_DIR})
+
+gtk_update_icon_cache("${REMMINA_DATADIR}/icons/hicolor")
diff --git a/plugins/rdp/CMakeLists.txt b/plugins/rdp/CMakeLists.txt
index 179df2ae7..ec20640f4 100644
--- a/plugins/rdp/CMakeLists.txt
+++ b/plugins/rdp/CMakeLists.txt
@@ -72,3 +72,5 @@ install(FILES
scalable/emblems/remmina-rdp-ssh-symbolic.svg
scalable/emblems/remmina-rdp-symbolic.svg
DESTINATION ${APPICONSCALE_EMBLEMS_DIR})
+
+gtk_update_icon_cache("${REMMINA_DATADIR}/icons/hicolor")
diff --git a/plugins/spice/CMakeLists.txt b/plugins/spice/CMakeLists.txt
index 19849d9fc..e7c96a836 100644
--- a/plugins/spice/CMakeLists.txt
+++ b/plugins/spice/CMakeLists.txt
@@ -49,3 +49,5 @@ install(FILES
scalable/emblems/remmina-spice-ssh-symbolic.svg
scalable/emblems/remmina-spice-symbolic.svg
DESTINATION ${APPICONSCALE_EMBLEMS_DIR})
+
+gtk_update_icon_cache("${REMMINA_DATADIR}/icons/hicolor")
diff --git a/plugins/st/CMakeLists.txt b/plugins/st/CMakeLists.txt
index 5d6e238fc..e3e0c3e5e 100644
--- a/plugins/st/CMakeLists.txt
+++ b/plugins/st/CMakeLists.txt
@@ -49,3 +49,5 @@ install(TARGETS remmina-plugin-st DESTINATION ${REMMINA_PLUGINDIR})
install(FILES
scalable/emblems/remmina-tool-symbolic.svg
DESTINATION ${APPICONSCALE_EMBLEMS_DIR})
+
+gtk_update_icon_cache("${REMMINA_DATADIR}/icons/hicolor")
diff --git a/plugins/vnc/CMakeLists.txt b/plugins/vnc/CMakeLists.txt
index f32ec87a6..4a8c68943 100644
--- a/plugins/vnc/CMakeLists.txt
+++ b/plugins/vnc/CMakeLists.txt
@@ -50,3 +50,5 @@ install(FILES
scalable/emblems/remmina-vnc-ssh-symbolic.svg
scalable/emblems/remmina-vnc-symbolic.svg
DESTINATION ${APPICONSCALE_EMBLEMS_DIR})
+
+gtk_update_icon_cache("${REMMINA_DATADIR}/icons/hicolor")
diff --git a/plugins/xdmcp/CMakeLists.txt b/plugins/xdmcp/CMakeLists.txt
index 590c3b88d..6c4449b39 100644
--- a/plugins/xdmcp/CMakeLists.txt
+++ b/plugins/xdmcp/CMakeLists.txt
@@ -48,3 +48,5 @@ install(FILES
scalable/emblems/remmina-xdmcp-ssh-symbolic.svg
scalable/emblems/remmina-xdmcp-symbolic.svg
DESTINATION ${APPICONSCALE_EMBLEMS_DIR})
+
+gtk_update_icon_cache("${REMMINA_DATADIR}/icons/hicolor")