Install also multimedia and print support plugins for OS X (#4212)
* Install also multimedia and print support plugins for OS X * cosmetics
This commit is contained in:
committed by
Bertrand Songis
parent
651f7b3f93
commit
707b000111
@@ -469,10 +469,18 @@ IF(APPLE)
|
|||||||
# menu file
|
# menu file
|
||||||
install(DIRECTORY ${PROJECT_SOURCE_DIR}/companion/targets/mac/qt_menu.nib DESTINATION "${companion_res_dir}" COMPONENT Runtime)
|
install(DIRECTORY ${PROJECT_SOURCE_DIR}/companion/targets/mac/qt_menu.nib DESTINATION "${companion_res_dir}" COMPONENT Runtime)
|
||||||
|
|
||||||
# manually add the cocoa plugin
|
# manually add the required plugins
|
||||||
get_target_property(QPA_PLUGIN Qt5::QCocoaIntegrationPlugin LOCATION)
|
foreach (plugin ${Qt5Multimedia_PLUGINS} ${Qt5PrintSupport_PLUGINS} ${Qt5Gui_PLUGINS})
|
||||||
install(FILES ${QPA_PLUGIN} DESTINATION "${plugin_dest_dir}/platforms/" COMPONENT Runtime)
|
get_target_property(QPA_PLUGIN ${plugin} LOCATION)
|
||||||
set(bundle_qt_libs "\${CMAKE_INSTALL_PREFIX}/${plugin_dest_dir}/platforms/libqcocoa.dylib")
|
get_filename_component(QPA_PLUGIN_FILENAME ${QPA_PLUGIN} NAME)
|
||||||
|
# Todo is there a nicer way to get the QT Plugin directory name?!
|
||||||
|
get_filename_component(QPA_PLUGIN_DIRECTORY ${QPA_PLUGIN} DIRECTORY)
|
||||||
|
get_filename_component(QPA_PLUGIN_DIRECTORY ${QPA_PLUGIN_DIRECTORY} NAME)
|
||||||
|
|
||||||
|
install(FILES ${QPA_PLUGIN} DESTINATION "${plugin_dest_dir}/${QPA_PLUGIN_DIRECTORY}/" COMPONENT Runtime)
|
||||||
|
|
||||||
|
list(APPEND bundle_qt_libs "\${CMAKE_INSTALL_PREFIX}/${plugin_dest_dir}/${QPA_PLUGIN_DIRECTORY}/${QPA_PLUGIN_FILENAME}")
|
||||||
|
endforeach()
|
||||||
|
|
||||||
# Add icon
|
# Add icon
|
||||||
set(MACOSX_BUNDLE_ICON_FILE iconmac.icns)
|
set(MACOSX_BUNDLE_ICON_FILE iconmac.icns)
|
||||||
@@ -494,7 +502,7 @@ IF(APPLE)
|
|||||||
|
|
||||||
# Include depencies (adding frameworks, fixing the embbeded libraries)
|
# Include depencies (adding frameworks, fixing the embbeded libraries)
|
||||||
# I get write errors without setting BU_CHMOD_BUNDLE_ITEMS even though it is
|
# I get write errors without setting BU_CHMOD_BUNDLE_ITEMS even though it is
|
||||||
# technically a hack (that is already is in the Bundle library ....)
|
# technically a hack (that is already is in the Bundle library ...)
|
||||||
install(CODE "
|
install(CODE "
|
||||||
include(BundleUtilities)
|
include(BundleUtilities)
|
||||||
file(GLOB bundle_simulator_libs \"\${CMAKE_INSTALL_PREFIX}/${companion_res_dir}/libopentx-*${CMAKE_SHARED_LIBRARY_SUFFIX}\")
|
file(GLOB bundle_simulator_libs \"\${CMAKE_INSTALL_PREFIX}/${companion_res_dir}/libopentx-*${CMAKE_SHARED_LIBRARY_SUFFIX}\")
|
||||||
|
|||||||
Reference in New Issue
Block a user