After the recent change to building dynamic frameworks and dylibs as targets built by linking to a static library dependency, incremental builds do not correctly link the dynamic frameworks and dylibs to the rebuilt static library. - Delete dynamic target outputs during static target builds. - Run platform schemes sequentially in manual order. - Build the dynamic framework before the dylib. - Clean up Xcode Scheme organization. It is not entirely obvious what the dependency problem is, and why these particular changes work. A lot of trial-and-error was required. It's possible that Xcode dependency analysis does not correctly analyze the flow used in MoltenVK builds.
10 lines
396 B
Bash
Executable File
10 lines
396 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# Delete the dynamic components, to force them to be rebuilt.
|
|
# This, combined with forcing the Scheme to run sequentially, and building
|
|
# the dynamic framework before the dylib, avoids a problem where the dynamic
|
|
# components contain no static content after an incremental build.
|
|
|
|
rm -rf "${BUILT_PRODUCTS_DIR}/MoltenVK.framework"
|
|
rm -rf "${BUILT_PRODUCTS_DIR}/libMoltenVK.dylib"
|