diff --git a/desktop-ui/cmake/os-linux.cmake b/desktop-ui/cmake/os-linux.cmake index 6e6a74da1..b5a4d31ea 100644 --- a/desktop-ui/cmake/os-linux.cmake +++ b/desktop-ui/cmake/os-linux.cmake @@ -4,18 +4,18 @@ mark_as_advanced(ARES_BUNDLE_SHADERS) # Stage and install slang shaders if(ARES_ENABLE_LIBRASHADER) if(TARGET libretro::slang_shaders) - add_custom_command( - OUTPUT "${ARES_BUILD_OUTPUT_DIR}/${ARES_INSTALL_DATA_DESTINATION}/Shaders/bilinear.slangp" POST_BUILD - COMMAND "${CMAKE_COMMAND}" -E make_directory "${ARES_BUILD_OUTPUT_DIR}/${ARES_INSTALL_DATA_DESTINATION}/Shaders" - COMMAND cp -R "${slang_shaders_LOCATION}/." "${ARES_BUILD_OUTPUT_DIR}/${ARES_INSTALL_DATA_DESTINATION}/Shaders" - COMMENT "Copying slang shaders to staging directory" - ) - add_custom_target( - bundled_shaders - DEPENDS "${ARES_BUILD_OUTPUT_DIR}/${ARES_INSTALL_DATA_DESTINATION}/Shaders/bilinear.slangp" - ) - add_dependencies(desktop-ui bundled_shaders) if(ARES_BUNDLE_SHADERS) + add_custom_command( + OUTPUT "${ARES_BUILD_OUTPUT_DIR}/${ARES_INSTALL_DATA_DESTINATION}/Shaders/bilinear.slangp" POST_BUILD + COMMAND "${CMAKE_COMMAND}" -E make_directory "${ARES_BUILD_OUTPUT_DIR}/${ARES_INSTALL_DATA_DESTINATION}/Shaders" + COMMAND cp -R "${slang_shaders_LOCATION}/." "${ARES_BUILD_OUTPUT_DIR}/${ARES_INSTALL_DATA_DESTINATION}/Shaders" + COMMENT "Copying slang shaders to staging directory" + ) + add_custom_target( + bundled_shaders + DEPENDS "${ARES_BUILD_OUTPUT_DIR}/${ARES_INSTALL_DATA_DESTINATION}/Shaders/bilinear.slangp" + ) + add_dependencies(desktop-ui bundled_shaders) install( DIRECTORY "${slang_shaders_LOCATION}" DESTINATION "${ARES_INSTALL_DATA_DESTINATION}/Shaders"