Skip to content

Commit

Permalink
Support Qt6 when packaging MacOS
Browse files Browse the repository at this point in the history
  • Loading branch information
bartkessels committed Oct 14, 2022
1 parent a2c8f56 commit 20d6418
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion packaging/macos/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,12 @@ set_target_properties(${CMAKE_PROJECT_NAME} PROPERTIES MACOSX_BUNDLE_INFO_STRING
set_target_properties(${CMAKE_PROJECT_NAME} PROPERTIES MACOSX_BUNDLE_LONG_VERSION_STRING ${CMAKE_PROJECT_VERSION})
set_target_properties(${CMAKE_PROJECT_NAME} PROPERTIES MACOSX_BUNDLE_SHORT_VERSION_STRING ${CMAKE_PROJECT_VERSION_MAJOR})

get_target_property(qmake_executable Qt5::qmake IMPORTED_LOCATION)
if (use_qt6)
get_target_property(qmake_executable Qt::qmake IMPORTED_LOCATION)
else()
get_target_property(qmake_executable Qt5::qmake IMPORTED_LOCATION)
endif()

get_filename_component(_qt_bin_dir "${qmake_executable}" DIRECTORY)
find_program(MACDEPLOYQT_BIN macdeployqt HINT "${_qt_bin_dir}")

Expand Down

0 comments on commit 20d6418

Please sign in to comment.