Files
AtTable/check_build.sh
jared 80de9fe057 Initial commit
AtTable iOS app with multipeer connectivity for mesh messaging.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 22:06:32 -05:00

32 lines
1012 B
Bash
Executable File

#!/bin/zsh
set -o pipefail # Fail if xcodebuild fails, even with xcbeautify
# --- Configuration ---
TARGET_NAME="AtTable"
DEVICE_NAME="iPhone 17 Pro"
BUILD_PATH="$(pwd)/build"
echo "🔍 Checking compilation for $TARGET_NAME..."
# Build Only (No Install/Launch)
# Uses -target instead of -scheme to bypass potential scheme misconfigurations
# Explicitly unsets CC/CXX/LIBCLANG_PATH to avoid environment pollution
# Also overrides them in xcodebuild arguments to ensure Xcode uses default toolchain
# Uses SYMROOT instead of -derivedDataPath because -derivedDataPath requires -scheme
env -u CC -u CXX -u LIBCLANG_PATH xcodebuild \
-target "$TARGET_NAME" \
-sdk iphonesimulator \
-destination "platform=iOS Simulator,name=$DEVICE_NAME" \
-configuration Debug \
SYMROOT="$BUILD_PATH" \
CC=clang CXX=clang++ LIBCLANG_PATH= \
build | xcbeautify
# Check exit code of the pipeline
if [ $? -eq 0 ]; then
echo "✅ Build Succeeded. No errors found."
else
echo "❌ Build Failed."
exit 1
fi