opt: windows build type & use generator expression

This commit is contained in:
Kingtous
2022-09-12 18:04:00 +08:00
parent a957f894b7
commit 74201b71b4
3 changed files with 8 additions and 20 deletions

View File

@@ -86,6 +86,13 @@ if(PLUGIN_BUNDLED_LIBRARIES)
COMPONENT Runtime)
endif()
# flutter_rust_bridge
set(RUSTDESK_LIB_BUILD_TYPE $<IF:$<CONFIG:Debug>,debug,release>)
message(STATUS "rustdesk lib build type: ${RUSTDESK_LIB_BUILD_TYPE}")
set(RUSTDESK_LIB "../../target/${RUSTDESK_LIB_BUILD_TYPE}/librustdesk.dll")
install(FILES "${RUSTDESK_LIB}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}"
COMPONENT Runtime RENAME librustdesk.dll)
# Fully re-copy the assets directory on each build to avoid having stale files
# from a previous install.
set(FLUTTER_ASSET_DIR_NAME "flutter_assets")