Permalink
Show file tree
Hide file tree
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Merge pull request #10214 from OatmealDome/mvk-better-incremental
MoltenVK: Don't run fetchDependencies unnecessarily
- Loading branch information
Showing
2 changed files
with
24 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -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 |