From 8c028cf61cf9edc45c98c593218452cb2e982a30 Mon Sep 17 00:00:00 2001 From: Max Date: Thu, 9 Jul 2026 09:09:31 -0500 Subject: [PATCH] fix permissions actually this time i swear --- distribution/macos/create_macos_build_ava.sh | 12 ++++++------ distribution/macos/create_macos_pr_build_ava.sh | 12 ++++++------ 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/distribution/macos/create_macos_build_ava.sh b/distribution/macos/create_macos_build_ava.sh index bb0458e6e..92ee0a542 100755 --- a/distribution/macos/create_macos_build_ava.sh +++ b/distribution/macos/create_macos_build_ava.sh @@ -153,21 +153,21 @@ TOTAL_SIZE=$((STAGING_SIZE + PADDING)) dd if=/dev/zero of="$UNCOMPRESSED_DMG" bs=1 count=0 seek="$TOTAL_SIZE" status=none mkfs.hfsplus -v "Ryujinx" "$UNCOMPRESSED_DMG" +find "$DMG_FOLDER" -type d -exec chmod 0755 {} + +find "$DMG_FOLDER" -type f -exec chmod 0644 {} + + # Make all the folders first, because libdmg-hfsplus won't make non-existent directories. find "$DMG_FOLDER" -mindepth 1 -type d | sort | while IFS= read -r src; do dst="/${src#"$DMG_FOLDER"/}" dmg-hfsplus "$UNCOMPRESSED_DMG" mkdir "$dst" - dmg-hfsplus "$UNCOMPRESSED_DMG" chmod "$dst" 0755 done -# Copy the files over, setting correct permissions. +# Copy the files over, setting correct permissions on the executable. find "$DMG_FOLDER" -mindepth 1 -type f | while IFS= read -r src; do dst="/${src#"$DMG_FOLDER"/}" - dmg-hfsplus "$UNCOMPRESSED_DMG" add "$src" "$dst" if file "$src" | grep -Fqi "Mach-O"; then - dmg-hfsplus "$UNCOMPRESSED_DMG" chmod "$dst" 0755 - else - dmg-hfsplus "$UNCOMPRESSED_DMG" chmod "$dst" 0644 + chmod 0755 "$src" fi + dmg-hfsplus "$UNCOMPRESSED_DMG" add "$src" "$dst" done # Copy the symlink into a folder, then copy the folder over with symlink permissions. diff --git a/distribution/macos/create_macos_pr_build_ava.sh b/distribution/macos/create_macos_pr_build_ava.sh index d47ff61a2..9b30b6461 100644 --- a/distribution/macos/create_macos_pr_build_ava.sh +++ b/distribution/macos/create_macos_pr_build_ava.sh @@ -149,21 +149,21 @@ TOTAL_SIZE=$((STAGING_SIZE + PADDING)) dd if=/dev/zero of="$UNCOMPRESSED_DMG" bs=1 count=0 seek="$TOTAL_SIZE" status=none mkfs.hfsplus -v "Ryujinx" "$UNCOMPRESSED_DMG" +find "$DMG_FOLDER" -type d -exec chmod 0755 {} + +find "$DMG_FOLDER" -type f -exec chmod 0644 {} + + # Make all the folders first, because libdmg-hfsplus won't make non-existent directories. find "$DMG_FOLDER" -mindepth 1 -type d | sort | while IFS= read -r src; do dst="/${src#"$DMG_FOLDER"/}" dmg-hfsplus "$UNCOMPRESSED_DMG" mkdir "$dst" - dmg-hfsplus "$UNCOMPRESSED_DMG" chmod "$dst" 0755 done -# Copy the files over, setting correct permissions. +# Copy the files over, setting correct permissions on the executable. find "$DMG_FOLDER" -mindepth 1 -type f | while IFS= read -r src; do dst="/${src#"$DMG_FOLDER"/}" - dmg-hfsplus "$UNCOMPRESSED_DMG" add "$src" "$dst" if file "$src" | grep -Fqi "Mach-O"; then - dmg-hfsplus "$UNCOMPRESSED_DMG" chmod "$dst" 0755 - else - dmg-hfsplus "$UNCOMPRESSED_DMG" chmod "$dst" 0644 + chmod 0755 "$src" fi + dmg-hfsplus "$UNCOMPRESSED_DMG" add "$src" "$dst" done # Copy the symlink into a folder, then copy the folder over with symlink permissions.