diff options
author | lat9nq <22451773+lat9nq@users.noreply.github.com> | 2021-05-19 17:18:33 -0400 |
---|---|---|
committer | lat9nq <22451773+lat9nq@users.noreply.github.com> | 2021-05-26 15:29:45 -0400 |
commit | 52cc25ccbf5faf3ae0ee33e9e28e998440f5c424 (patch) | |
tree | c390fd461611f32a69274fbb53f45da4d18fa697 /src | |
parent | 3394f24728050368086afae4beae81e5bd21d9f1 (diff) |
cmake: Download Qt binaries on Linux if needed
If the local version of Qt is older than the minimum version required by
yuzu, download a pre-built binary package from yuzu-emu/ext-linux-bin
and build yuzu with it, instead.
This also requires linking yuzu to the correct libraries after building
it, and copying over the required binaries when building yuzu.
This sets the Qt requirement to 5.12, which is intentionally behind the
versions used by our toolchains since they are not all updated yet to
5.15.
Diffstat (limited to 'src')
-rw-r--r-- | src/yuzu/CMakeLists.txt | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/src/yuzu/CMakeLists.txt b/src/yuzu/CMakeLists.txt index cc0790e07..634fe66a5 100644 --- a/src/yuzu/CMakeLists.txt +++ b/src/yuzu/CMakeLists.txt @@ -4,6 +4,12 @@ set(CMAKE_AUTOUIC ON) set(CMAKE_INCLUDE_CURRENT_DIR ON) set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${PROJECT_SOURCE_DIR}/CMakeModules) +# Set the RPATH for Qt Libraries +# This must be done before the `yuzu` target is created +if (YUZU_USE_BUNDLED_QT AND (${CMAKE_SYSTEM_NAME} STREQUAL "Linux")) + set(CMAKE_BUILD_RPATH "${CMAKE_BINARY_DIR}/bin/lib/") +endif() + add_executable(yuzu Info.plist about_dialog.cpp @@ -278,11 +284,14 @@ if(UNIX AND NOT APPLE) install(TARGETS yuzu RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}/bin") endif() -if (MSVC) +if (YUZU_USE_BUNDLED_QT) include(CopyYuzuQt5Deps) + copy_yuzu_Qt5_deps(yuzu) +endif() + +if (MSVC) include(CopyYuzuSDLDeps) include(CopyYuzuFFmpegDeps) - copy_yuzu_Qt5_deps(yuzu) copy_yuzu_SDL_deps(yuzu) copy_yuzu_FFmpeg_deps(yuzu) endif() |