Skip to content

Commit

Permalink
fix: Qtest was added as a file instead of a dependency.
Browse files Browse the repository at this point in the history
  • Loading branch information
BartSte committed Feb 15, 2024
1 parent f5a8259 commit 5040b15
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 14 deletions.
7 changes: 7 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,10 @@ if(BUILD_TESTING)
enable_testing()
add_subdirectory(tests)
endif()


set(CPACK_PACKAGE_NAME ${PROJECT_NAME})
set(CPACK_PACKAGE_VERSION ${PROJECT_VERSION_FULL})
set(CPACK_GENERATOR "TGZ")

include(CPack)
12 changes: 3 additions & 9 deletions app/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ install(
".*libdbm\\.so.*"
".*libpthread\\.so.*")

# Copy the entrypoint to the install directory.
install(PROGRAMS ${CMAKE_SOURCE_DIR}/scripts/run_snapshot DESTINATION .)

# When Qt is built as a shared library, the platform plugins must be installed
# alongside the application in the platforms directory.
if(QT6_LIB_TYPE STREQUAL "SHARED_LIBRARY")
Expand Down Expand Up @@ -74,12 +77,3 @@ if(QT6_LIB_TYPE STREQUAL "SHARED_LIBRARY")
PATTERN "libqxcb-.*-integration\\.*")

endif()

# Copy the entrypoint to the install directory.
install(PROGRAMS ${CMAKE_SOURCE_DIR}/scripts/run_snapshot DESTINATION .)

set(CPACK_PACKAGE_NAME ${PROJECT_NAME})
set(CPACK_PACKAGE_VERSION ${PROJECT_VERSION_FULL})
set(CPACK_GENERATOR "TGZ")

include(CPack)
19 changes: 14 additions & 5 deletions tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,17 @@ set_tests_properties(tests_bin PROPERTIES ENVIRONMENT
install(TARGETS tests_bin DESTINATION .)
install(PROGRAMS ${CMAKE_SOURCE_DIR}/scripts/run_tests DESTINATION .)
install(DIRECTORY static DESTINATION .)

# When Qt is built as a shared library, the Qt6::Test must be added as well.
if(QT6_LIB_TYPE STREQUAL "SHARED_LIBRARY")
install(FILES $<TARGET_FILE:Qt6::Test> DESTINATION .)
endif()
install(
TARGETS tests_bin
DESTINATION .
RUNTIME_DEPENDENCIES
DIRECTORIES
${FFMPEG_LIBRARY_DIRS}
POST_EXCLUDE_REGEXES
# Compatability with standard C libraries across linux distributions is
# assumed.
".*ld-linux.*\\.so.*"
".*libc\\.so.*"
".*libm\\.so.*"
".*libdbm\\.so.*"
".*libpthread\\.so.*")

0 comments on commit 5040b15

Please sign in to comment.