fix(mobile/ios): enable Debug compilation condition

Co-authored-by: Tom Brow <tomb@block.xyz>
Signed-off-by: Tom Brow <tomb@block.xyz>
This commit is contained in:
npub12wpjffj7q5qjsky5jvk4ldwlxmse5xll3d8gytk4wqd0c5y7jvwspg37n6
2026-08-01 15:32:53 -07:00
co-authored by Tom Brow
parent c5f6770572
commit aea7821412
2 changed files with 26 additions and 0 deletions
+1
View File
@@ -1,5 +1,6 @@
#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
#include "Generated.xcconfig"
SWIFT_ACTIVE_COMPILATION_CONDITIONS = $(inherited) DEBUG
// Default app bundle identifier. Internal/custom builds can override this
// without patching tracked files by writing
+25
View File
@@ -206,6 +206,31 @@ for key in BUNDLE_IDENTIFIER BUZZ_KEYCHAIN_ACCESS_GROUP BUZZ_IOS_PUSH_ENVIRONMEN
assert_single_xcconfig_declaration "$release_xcconfig" "$key" "Release"
done
# SWIFT_ACTIVE_COMPILATION_CONDITIONS is checked separately from the closed
# identity census above. This is a tracked-source assertion only; resolved Xcode
# build settings are intentionally outside this Linux-compatible test.
assert_xcconfig_value "$debug_xcconfig" \
'^SWIFT_ACTIVE_COMPILATION_CONDITIONS = \$\(inherited\) DEBUG$' \
"Debug Swift compilation conditions inherit DEBUG"
debug_swift_condition_count=$(grep -cE \
'^[[:space:]]*SWIFT_ACTIVE_COMPILATION_CONDITIONS([[:space:]]*\[[^]]*\])*[[:space:]]*=' \
"$debug_xcconfig" || true)
if [[ "$debug_swift_condition_count" -eq 1 ]]; then
pass "Debug SWIFT_ACTIVE_COMPILATION_CONDITIONS has one tracked declaration site"
else
fail "Debug SWIFT_ACTIVE_COMPILATION_CONDITIONS has $debug_swift_condition_count tracked declaration sites; expected exactly one"
fi
release_swift_condition_count=$(grep -cE \
'^[[:space:]]*SWIFT_ACTIVE_COMPILATION_CONDITIONS([[:space:]]*\[[^]]*\])*[[:space:]]*=' \
"$release_xcconfig" || true)
if [[ "$release_swift_condition_count" -eq 0 ]]; then
pass "Release SWIFT_ACTIVE_COMPILATION_CONDITIONS has no tracked declaration sites"
else
fail "Release SWIFT_ACTIVE_COMPILATION_CONDITIONS has $release_swift_condition_count tracked declaration sites; expected zero"
fi
# Split the retired identifiers so the regression test does not match itself.
retired_bundle_id='com.buzz.buzz'"Mobile"
if git -C "$repo_root" grep -q -F "$retired_bundle_id"; then