rom-properties/xdg/CMakeLists.txt
David Korth d514f63a1e [xdg] CMakeLists.txt: Fix installation of rp-config.desktop.
Need to use RENAME to rename the file, not INSTALL. Using INSTALL ends up
creating a subdirectory instead of renaming the file.

Fixes #367: "rp-config.desktop" file error
Reported by @Amnesia1000.
2022-10-19 20:44:08 -04:00

34 lines
831 B
CMake

PROJECT(doc)
#################
# Installation. #
#################
INCLUDE(DirInstallPaths)
# XDG files are only installed on XDG systems,
# so check that the XDG paths are valid before
# installing the files.
# Desktop file
IF(DIR_INSTALL_XDG_DESKTOP)
INSTALL(FILES rp-config.desktop
RENAME com.gerbilsoft.rom-properties.rp-config.desktop
DESTINATION "${DIR_INSTALL_XDG_DESKTOP}"
COMPONENT "xdg")
ENDIF(DIR_INSTALL_XDG_DESKTOP)
# XDG MIME type package
IF(DIR_INSTALL_XDG_MIME)
INSTALL(FILES rom-properties.xml
DESTINATION "${DIR_INSTALL_XDG_MIME}/packages"
COMPONENT "xdg")
ENDIF(DIR_INSTALL_XDG_MIME)
# AppStream metainfo XML
IF(DIR_INSTALL_XDG_APPSTREAM)
INSTALL(FILES com.gerbilsoft.rom-properties.metainfo.xml
DESTINATION "${DIR_INSTALL_XDG_APPSTREAM}"
COMPONENT "xdg")
ENDIF(DIR_INSTALL_XDG_APPSTREAM)