diff --git a/CMakeLists.txt b/CMakeLists.txt index 8fcebae6e..10f314856 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -455,14 +455,6 @@ list( SORT CALAMARES_TRANSLATION_LANGUAGES ) add_subdirectory( lang ) # i18n tools -if ( INSTALL_COMPLETION ) - if( NOT CMAKE_INSTALL_BASHCOMPLETIONDIR ) - set( CMAKE_INSTALL_BASHCOMPLETIONDIR "${CMAKE_INSTALL_DATADIR}/bash-completion/completions" ) - endif() - - install( FILES ${CMAKE_SOURCE_DIR}/data/completion/bash/calamares DESTINATION "${CMAKE_INSTALL_BASHCOMPLETIONDIR}" ) -endif() - ### Example Distro # # For testing purposes Calamares includes a very, very, limited sample @@ -652,6 +644,14 @@ if( INSTALL_POLKIT ) ) endif() +if ( INSTALL_COMPLETION ) + if( NOT CMAKE_INSTALL_BASHCOMPLETIONDIR ) + set( CMAKE_INSTALL_BASHCOMPLETIONDIR "${CMAKE_INSTALL_DATADIR}/bash-completion/completions" ) + endif() + + install( FILES ${CMAKE_SOURCE_DIR}/data/completion/bash/calamares DESTINATION "${CMAKE_INSTALL_BASHCOMPLETIONDIR}" ) +endif() + install( FILES calamares.desktop DESTINATION ${CMAKE_INSTALL_DATADIR}/applications