nextcloud-desktop/shell_integration/icons/CMakeLists.txt
Jocelyn Turcotte 85938ab1f1 shell_i: Remove the ICON_PATH socket API message #2340
It was only used on OS X and couldn't be used by the FinderSync
extension since that one runs in a sandbox. So use the same system
to load images in the legacy extension by shipping them in the
extension bundle instead of the owncloud.app bundle.

This is also given that the legacy extension needs padded icons
while the FinderSync one needs unpadded icons.
2015-06-17 17:15:50 +02:00

15 lines
588 B
CMake

if( UNIX AND NOT APPLE )
SET(ICON_DIR ${DATADIR}/icons/hicolor)
FOREACH(size 128x128 16x16 256x256 32x32 48x48 64x64 72x72)
file(GLOB files "${size}/*.png")
FOREACH( file ${files} )
# the GLOB returns a absolute path. Make it relative by replacing the current src dir by nothing
STRING(REPLACE "${CMAKE_CURRENT_SOURCE_DIR}/${size}/" "" shortFile ${file})
STRING(REPLACE "oC" ${APPLICATION_NAME} brandedName ${shortFile})
install(FILES ${file} DESTINATION ${ICON_DIR}/${size}/apps RENAME ${brandedName})
ENDFOREACH(file)
ENDFOREACH(size)
endif()