forked from qt-creator/qt-creator
CMake build/Linux: Fix location of separate plugins
We use GNUInstallDirs to define the location of plugins, libraries and
so on. If Qt Creator was configured with a specific set of locations,
we need to pass that on to separately built plugins even if
GNUInstallDirs would use different locations for them.
Otherwise Qt Creator cannot find these plugins.
Amends c81baf1a9c
Fixes: QTCREATORBUG-25266
Change-Id: Ib0da1428ec676fd54cb264b1aba4791b18b2c3bd
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
This commit is contained in:
@@ -39,6 +39,16 @@ file(WRITE ${CMAKE_BINARY_DIR}/cmake/QtCreatorConfig.cmake "
|
|||||||
\# add module path for special FindQt5.cmake that considers Qt6 too
|
\# add module path for special FindQt5.cmake that considers Qt6 too
|
||||||
list(APPEND CMAKE_MODULE_PATH \${CMAKE_CURRENT_LIST_DIR})
|
list(APPEND CMAKE_MODULE_PATH \${CMAKE_CURRENT_LIST_DIR})
|
||||||
|
|
||||||
|
\# force plugins to same path naming conventions as Qt Creator
|
||||||
|
\# otherwise plugins will not be found
|
||||||
|
if(UNIX AND NOT APPLE)
|
||||||
|
include(GNUInstallDirs)
|
||||||
|
set(CMAKE_INSTALL_BINDIR ${CMAKE_INSTALL_BINDIR})
|
||||||
|
set(CMAKE_INSTALL_LIBDIR ${CMAKE_INSTALL_LIBDIR})
|
||||||
|
set(CMAKE_INSTALL_LIBEXECDIR ${CMAKE_INSTALL_LIBEXECDIR})
|
||||||
|
set(CMAKE_INSTALL_DATAROOTDIR ${CMAKE_INSTALL_DATAROOTDIR})
|
||||||
|
endif()
|
||||||
|
|
||||||
include(CMakeFindDependencyMacro)
|
include(CMakeFindDependencyMacro)
|
||||||
find_dependency(Qt5 ${IDE_QT_VERSION_MIN}
|
find_dependency(Qt5 ${IDE_QT_VERSION_MIN}
|
||||||
COMPONENTS Concurrent Core Gui Widgets Core5Compat Network PrintSupport Qml Quick QuickWidgets Sql REQUIRED
|
COMPONENTS Concurrent Core Gui Widgets Core5Compat Network PrintSupport Qml Quick QuickWidgets Sql REQUIRED
|
||||||
|
Reference in New Issue
Block a user