From f230fded753739294e08af26ce11de8fa153ba9c Mon Sep 17 00:00:00 2001 From: LongCatIsLooong <31859944+LongCatIsLooong@users.noreply.github.com> Date: Mon, 12 Oct 2020 08:12:02 -0700 Subject: [PATCH] Use buildroot clang for scenario app (#21690) --- testing/scenario_app/compile_ios_jit.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/testing/scenario_app/compile_ios_jit.sh b/testing/scenario_app/compile_ios_jit.sh index 6c072066bfa..ebd807b5c33 100755 --- a/testing/scenario_app/compile_ios_jit.sh +++ b/testing/scenario_app/compile_ios_jit.sh @@ -85,12 +85,15 @@ echo "Compiling JIT Snapshot..." cp "$DEVICE_TOOLS/../gen/flutter/lib/snapshot/vm_isolate_snapshot.bin" "$OUTDIR/App.framework/flutter_assets/vm_snapshot_data" +LLVM_BIN_PATH="${SCRIPT_DIR}/../../../buildtools/mac-x64/clang/bin" SYSROOT=$(xcrun --sdk iphonesimulator --show-sdk-path) echo "Using $SYSROOT as sysroot." echo "Creating stub App using $SYSROOT..." -echo "static const int Moo = 88;" | xcrun clang -x c \ +# Use buildroot clang so we can override the linker to use in our LUCI recipe. +# See: https://github.com/flutter/flutter/issues/65901 +echo "static const int Moo = 88;" | "$LLVM_BIN_PATH/clang" -x c \ -arch x86_64 \ -fembed-bitcode-marker \ -isysroot "$SYSROOT" \ @@ -110,4 +113,3 @@ rm -rf "$SCRIPT_DIR/ios/Scenarios/App.framework" rm -rf "$SCRIPT_DIR/ios/Scenarios/Flutter.framework" cp -R "$OUTDIR/App.framework" "$SCRIPT_DIR/ios/Scenarios" cp -R "$DEVICE_TOOLS/../Flutter.framework" "$SCRIPT_DIR/ios/Scenarios" -