Skip to content

Commit

Permalink
Fixes by cmake-format
Browse files Browse the repository at this point in the history
  • Loading branch information
magnesj authored and github-actions[bot] committed Sep 5, 2024
1 parent 0a94dea commit c4e2a6c
Showing 1 changed file with 20 additions and 15 deletions.
35 changes: 20 additions & 15 deletions ApplicationExeCode/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -487,26 +487,31 @@ if(RESINSIGHT_PRIVATE_INSTALL)
install(TARGETS ResInsight DESTINATION ${RESINSIGHT_INSTALL_FOLDER})
install(FILES ${RESINSIGHT_FILES} DESTINATION ${RESINSIGHT_INSTALL_FOLDER})

# Add a post-build command to run windeployqt. This makes it possible to debug the binary from a debugger without any manual steps. This also
# fixes an issue related to the Install() command and usage of windeployqt as part of installation. The installation tried to use windeployqt on the
# executable in the build directory, which did not find the Qt libraries.
# Add a post-build command to run windeployqt. This makes it possible to debug
# the binary from a debugger without any manual steps. This also fixes an
# issue related to the Install() command and usage of windeployqt as part of
# installation. The installation tried to use windeployqt on the executable in
# the build directory, which did not find the Qt libraries.
#
# TODO: This command copies all required dlls, so we should probably not use the Install() command to copy external dlls dependencies.
# TODO: This command copies all required dlls, so we should probably not use
# the Install() command to copy external dlls dependencies.
#
if(WIN32 AND WINDEPLOYQT_EXECUTABLE)
add_custom_command(TARGET ResInsight POST_BUILD
COMMAND ${WINDEPLOYQT_EXECUTABLE} $<TARGET_FILE:ResInsight> --release --no-translations
COMMENT "Running windeployqt to deploy Qt dependencies"
add_custom_command(
TARGET ResInsight
POST_BUILD
COMMAND ${WINDEPLOYQT_EXECUTABLE} $<TARGET_FILE:ResInsight> --release
--no-translations
COMMENT "Running windeployqt to deploy Qt dependencies"
)

install(
TARGETS ResInsight
DESTINATION ${RESINSIGHT_INSTALL_FOLDER}
RUNTIME_DEPENDENCIES PRE_EXCLUDE_REGEXES "api-ms-" "ext-ms-"
POST_EXCLUDE_REGEXES ".*system32/.*\\.dll"
)
endif()

install(
TARGETS ResInsight
DESTINATION ${RESINSIGHT_INSTALL_FOLDER}
RUNTIME_DEPENDENCIES PRE_EXCLUDE_REGEXES "api-ms-" "ext-ms-"
POST_EXCLUDE_REGEXES ".*system32/.*\\.dll"
)
endif()

if(${CMAKE_SYSTEM_NAME} MATCHES "Linux")
install(
Expand Down

0 comments on commit c4e2a6c

Please sign in to comment.