Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix afsctool for High Sierra #20898

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 21 additions & 1 deletion Formula/afsctool.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,17 @@ class Afsctool < Formula
url "https://docs.google.com/uc?export=download&id=0BwQlnXqL939ZQjBQNEhRQUo0aUk"
version "1.6.4"
sha256 "bb6a84370526af6ec1cee2c1a7199134806e691d1093f4aef060df080cd3866d"
revision 1
revision 2

# Fixes Sierra "Unable to compress" issue; reported upstream on 24 July 2017
patch do
url "https://github.com/vfx01j/afsctool/commit/26293a3809c9ad1db5f9bff9dffaefb8e201a089.diff?full_index=1"
sha256 "a541526679eb5d2471b3f257dab6103300d950f7b2f9d49bbfeb9f27dfc48542"
end

# Fixes High Sierra "Expecting f_type of 17 or 23. f_type is 24" issue
patch :DATA

bottle do
cellar :any_skip_relocation
sha256 "8f1d0020beff7bcfd80530f69d29ca7f6bf053623c84a9957ef7dd5cd4fa3536" => :high_sierra
Expand All @@ -35,3 +38,20 @@ def install
system "#{bin}/afsctool", "-v", path
end
end

__END__
diff --git a/afsctool_34/afsctool.c b/afsctool_34/afsctool.c
index 8713407fa673f216e69dfc36152c39bc1dea4fe7..7038859f43e035be44c9b8cfbb1bb76a93e26e0a 100644
--- a/afsctool_34/afsctool.c
+++ b/afsctool_34/afsctool.c
@@ -104,8 +104,8 @@ void compressFile(const char *inFile, struct stat *inFileInfo, long long int max

if (statfs(inFile, &fsInfo) < 0)
return;
- if (fsInfo.f_type != 17 && fsInfo.f_type != 23) {
- printf("Expecting f_type of 17 or 23. f_type is %i.\n", fsInfo.f_type);
+ if (fsInfo.f_type != 17 && fsInfo.f_type != 23 && fsInfo.f_type != 24) {
+ printf("Expecting f_type of 17, 23 or 24. f_type is %i.\n", fsInfo.f_type);
return;
}
if (!S_ISREG(inFileInfo->st_mode))