gcsfuse 2.4.0

Closes #106.

Signed-off-by: Adrian Ho <215702+gromgit@users.noreply.github.com>
This commit is contained in:
Adrian Ho 2025-03-07 16:58:27 +08:00 committed by Adrian Ho
parent 3bc3e569c2
commit 2046849f69

View file

@ -3,14 +3,14 @@ require_relative "../require/macfuse"
class GcsfuseMac < Formula class GcsfuseMac < Formula
desc "User-space file system for interacting with Google Cloud" desc "User-space file system for interacting with Google Cloud"
homepage "https://github.com/googlecloudplatform/gcsfuse" homepage "https://github.com/googlecloudplatform/gcsfuse"
url "https://github.com/GoogleCloudPlatform/gcsfuse/archive/refs/tags/v0.42.5.tar.gz" url "https://github.com/GoogleCloudPlatform/gcsfuse/archive/refs/tags/v2.4.0.tar.gz"
sha256 "272ad522ebbbfe3da87ee00aeff5fe347d25a4a49499c254e482a59bbed5c692" sha256 "44a9e9da84f04be59ef736d283624c116ec90d103c0f87c874b8ce5e51d5df85"
license "Apache-2.0" license "Apache-2.0"
head "https://github.com/GoogleCloudPlatform/gcsfuse.git" head "https://github.com/GoogleCloudPlatform/gcsfuse.git"
livecheck do livecheck do
url :stable url :stable
regex(/^v?(\d+(?:\.\d+)+)$/i) strategy :github_latest
end end
bottle do bottle do
@ -20,17 +20,11 @@ class GcsfuseMac < Formula
sha256 cellar: :any_skip_relocation, big_sur: "7aae298075c4ab1a56635d3bec54360e6986c59596b66a132fcc2cdba8633a14" sha256 cellar: :any_skip_relocation, big_sur: "7aae298075c4ab1a56635d3bec54360e6986c59596b66a132fcc2cdba8633a14"
end end
deprecate! date: "2025-02-11", because: :does_not_build
depends_on "go" => :build depends_on "go" => :build
depends_on MacfuseRequirement depends_on MacfuseRequirement
depends_on :macos depends_on :macos
# Review for removal on next release patch :DATA
patch do
url "https://github.com/GoogleCloudPlatform/gcsfuse/commit/c2abca911ff03b84ab64214b6717d8d7cc74c10f.patch?full_index=1"
sha256 "62930a0ae8322a071d489b1dd386206742b962123312b1368589c731867945b4"
end
def install def install
setup_fuse setup_fuse
@ -40,20 +34,36 @@ class GcsfuseMac < Formula
system "go", "build", "./tools/build_gcsfuse" system "go", "build", "./tools/build_gcsfuse"
# Use that tool to build gcsfuse itself. # Use that tool to build gcsfuse itself.
gcsfuse_version = build.head? ? Utils.git_short_head : version gcsfuse_version = build.head? ? Utils.git_short_head : version.to_s
system "./build_gcsfuse", buildpath, prefix, gcsfuse_version, "-buildvcs=false" system "./build_gcsfuse", buildpath, prefix, gcsfuse_version
end end
def caveats def caveats
<<~EOS <<~EOS
Upstream doesn't officially support macOS (https://github.com/GoogleCloudPlatform/gcsfuse/issues/1299) Upstream hasn't decided whether to support macOS (https://github.com/GoogleCloudPlatform/gcsfuse/issues/1299)
and current versions don't build at all on macOS. and versions after v2.4.0 don't build at all on macOS.
This formula will not be updated until macOS is officially supported. This formula will not be updated until macOS is officially supported.
EOS EOS
end end
test do test do
system "#{bin}/gcsfuse", "--help" system bin/"gcsfuse", "--help"
system "#{sbin}/mount_gcsfuse", "--help" system "#{sbin}/mount_gcsfuse", "--help"
end end
end end
__END__
diff --git a/tools/build_gcsfuse/main.go b/tools/build_gcsfuse/main.go
index b1a4022..678f747 100644
--- a/tools/build_gcsfuse/main.go
+++ b/tools/build_gcsfuse/main.go
@@ -134,8 +134,6 @@ func buildBinaries(dstDir, srcDir, version string, buildArgs []string) (err erro
cmd := exec.Command(
"go",
"build",
- "-C",
- srcDir,
"-o",
path.Join(dstDir, bin.outputPath))