Skip to content

Commit 73a1353

Browse files
committed
Infer a reasonable build subdirectory when building a toolchain
build-script-impl effectively ignores the `install_destdir` provided to it by build-toolchain, and uses something based on the build subdir instead. But build-script products do follow `install_destdir`, so make `build-toolchain` provide something closer to correct.
1 parent 0573f1e commit 73a1353

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

utils/build-toolchain

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,10 +56,12 @@ case $(uname -s) in
5656
Darwin)
5757
SWIFT_PACKAGE=buildbot_osx_package,no_test
5858
OS_SUFFIX=osx
59+
BUILD_SUBDIR=buildbot_osx
5960
;;
6061
Linux)
6162
SWIFT_PACKAGE=buildbot_linux,no_test
6263
OS_SUFFIX=linux
64+
BUILD_SUBDIR=buildbot_linux
6365
;;
6466
*)
6567
echo "Unrecognised platform $(uname -s)"
@@ -77,8 +79,10 @@ while [ $# -ne 0 ]; do
7779
-t|--test)
7880
if [ "$(uname -s)" == "Linux" ]; then
7981
SWIFT_PACKAGE=buildbot_linux
82+
BUILD_SUBDIR=buildbot_linux
8083
else
8184
SWIFT_PACKAGE=buildbot_osx_package
85+
BUILD_SUBDIR=buildbot_osx
8286
fi
8387
;;
8488
--distcc)
@@ -137,7 +141,7 @@ DISPLAY_NAME_SHORT="Local Swift Development Snapshot"
137141
DISPLAY_NAME="${DISPLAY_NAME_SHORT} ${YEAR}-${MONTH}-${DAY}"
138142

139143
SWIFT_INSTALLABLE_PACKAGE="${RESULT_DIR}/${ARCHIVE}"
140-
SWIFT_INSTALL_DIR="${RESULT_DIR}/swift-nightly-install"
144+
SWIFT_INSTALL_DIR="${RESULT_DIR}/${BUILD_SUBDIR}"
141145
SWIFT_INSTALL_SYMROOT="${RESULT_DIR}/swift-nightly-symroot"
142146
SWIFT_TOOLCHAIN_DIR="/Library/Developer/Toolchains/${TOOLCHAIN_NAME}.xctoolchain"
143147
SYMBOLS_PACKAGE="${RESULT_DIR}/${SYM_ARCHIVE}"

0 commit comments

Comments
 (0)