mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
added the build breaks. There's already a tool to get proper dependencies, `utils/find-overlay-dependencies.sh`, so this patch allows that tool to update the `CMakeLists.txt` files in-place. Also it adds a line to the `CMakeLists.txt` files for each SDK so that the tool works.
34 lines
979 B
Bash
Executable File
34 lines
979 B
Bash
Executable File
#!/bin/bash
|
|
#===--- find-overlay-dependencies-loop.sh - driver for find-overlay-dependency.sh---===#
|
|
#
|
|
## This source file is part of the Swift.org open source project
|
|
##
|
|
## Copyright (c) 2016 Apple Inc. and the Swift project authors
|
|
## Licensed under Apache License v2.0 with Runtime Library Exception
|
|
##
|
|
## See http://swift.org/LICENSE.txt for license information
|
|
## See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
|
|
#
|
|
#===------------------------------------------------------------------------===#
|
|
|
|
SCRIPT="$(dirname "$0")/find-overlay-dependencies.sh"
|
|
|
|
# `update` edits the cmake file in-place; `print` just prints to console
|
|
function usage() {
|
|
echo 'usage:' $0 'update|print' >&2
|
|
exit 1
|
|
}
|
|
|
|
case $# in
|
|
1) if [[ $1 != 'update' && $1 != 'print' ]]; then
|
|
usage
|
|
fi ;;
|
|
*)
|
|
usage ;;
|
|
esac
|
|
|
|
# Don't update XCTest
|
|
for overlay in $(find ./stdlib/public/SDK/ -depth 1 -type d ! -name XCTest -exec basename \{\} \;); do
|
|
$SCRIPT $overlay $1
|
|
done
|