mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-05-29 07:16:33 +00:00
Merge pull request #10214 from OatmealDome/mvk-better-incremental
MoltenVK: Don't run fetchDependencies unnecessarily
This commit is contained in:
commit
676c500cdc
2 changed files with 24 additions and 2 deletions
6
Externals/MoltenVK/CMakeLists.txt
vendored
6
Externals/MoltenVK/CMakeLists.txt
vendored
|
@ -1,10 +1,12 @@
|
||||||
include(ExternalProject)
|
include(ExternalProject)
|
||||||
|
|
||||||
|
set(MOLTENVK_VERSION "v1.1.5")
|
||||||
|
|
||||||
ExternalProject_Add(MoltenVK
|
ExternalProject_Add(MoltenVK
|
||||||
GIT_REPOSITORY https://github.com/KhronosGroup/MoltenVK.git
|
GIT_REPOSITORY https://github.com/KhronosGroup/MoltenVK.git
|
||||||
GIT_TAG v1.1.5
|
GIT_TAG ${MOLTENVK_VERSION}
|
||||||
|
|
||||||
CONFIGURE_COMMAND <SOURCE_DIR>/fetchDependencies --macos
|
CONFIGURE_COMMAND ${CMAKE_CURRENT_LIST_DIR}/configure.sh <LOG_DIR> <SOURCE_DIR> ${MOLTENVK_VERSION}
|
||||||
|
|
||||||
BUILD_COMMAND make -C <SOURCE_DIR> macos
|
BUILD_COMMAND make -C <SOURCE_DIR> macos
|
||||||
BUILD_IN_SOURCE ON
|
BUILD_IN_SOURCE ON
|
||||||
|
|
20
Externals/MoltenVK/configure.sh
vendored
Executable file
20
Externals/MoltenVK/configure.sh
vendored
Executable file
|
@ -0,0 +1,20 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# To lower build times, we avoid running the fetchDependencies script if the MoltenVK
|
||||||
|
# version didn't change. The last-built MoltenVK version is stored inside a file in
|
||||||
|
# the timestamp directory. If the file doesn't exist or the file contains a different
|
||||||
|
# MoltenVK version, fetchDependencies is ran.
|
||||||
|
#
|
||||||
|
# Usage: configure.sh <timestamp directory> <source directory> <MoltenVK version>
|
||||||
|
#
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
VERSION_PATH="$1/MoltenVK-last-version.txt"
|
||||||
|
CURRENT_VERSION="$3"
|
||||||
|
LAST_VERSION=$(cat "$VERSION_PATH" || true)
|
||||||
|
|
||||||
|
if ! [ "$LAST_VERSION" = "$3" ]; then
|
||||||
|
$2/fetchDependencies --macos
|
||||||
|
echo $CURRENT_VERSION > $VERSION_PATH
|
||||||
|
fi
|
Loading…
Add table
Reference in a new issue