Force writable perms on existing FRAMEWORKDIR

mkdir -m 777 only applies the mode to newly created directories.
If /Library/ManagedFrameworks/Python already exists from a prior
install with stricter perms, the un-sudo'd relocatable-python
tool fails with 'Permission denied' when writing the framework.
Add an explicit chmod after mkdir.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Erik Gomez
2026-05-12 12:21:26 -05:00
co-authored by Claude Opus 4.7
parent 73f524e279
commit 700848e195
+3 -1
View File
@@ -96,7 +96,9 @@ prepare_ci_env() {
}
prepare_build_dirs() {
/usr/bin/sudo /bin/mkdir -m 777 -p "$FRAMEWORKDIR"
/usr/bin/sudo /bin/mkdir -p "$FRAMEWORKDIR"
# mkdir -m only applies to newly created dirs; ensure existing dirs are writable.
/usr/bin/sudo /bin/chmod 777 "$FRAMEWORKDIR"
if [[ -d "$FRAMEWORKDIR/Python.framework" ]]; then
/usr/bin/sudo /bin/rm -rf "$FRAMEWORKDIR/Python.framework"
fi