From 700848e195c48970a973be6456c9b4f184599afc Mon Sep 17 00:00:00 2001 From: Erik Gomez Date: Tue, 12 May 2026 10:00:56 -0500 Subject: [PATCH] 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) --- build_python_framework_pkgs.zsh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/build_python_framework_pkgs.zsh b/build_python_framework_pkgs.zsh index 0d185c6..ab8ded5 100755 --- a/build_python_framework_pkgs.zsh +++ b/build_python_framework_pkgs.zsh @@ -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