From 3b325811eed1662abf42de4b098747aa72eabd3c Mon Sep 17 00:00:00 2001 From: Adrian Ho Date: Wed, 12 Feb 2025 20:05:46 +0800 Subject: [PATCH] btfs: update build process Closes #88. Signed-off-by: Adrian Ho <215702+gromgit@users.noreply.github.com> --- Formula/btfs-mac.rb | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/Formula/btfs-mac.rb b/Formula/btfs-mac.rb index 3a7aa5b..c0cde84 100644 --- a/Formula/btfs-mac.rb +++ b/Formula/btfs-mac.rb @@ -6,7 +6,8 @@ class BtfsMac < Formula url "https://github.com/johang/btfs/archive/refs/tags/v2.24.tar.gz" sha256 "d71ddefe3c572e05362542a0d9fd0240d8d4e1578ace55a8b3245176e7fd8935" license "GPL-3.0-only" - head "https://github.com/johang/btfs.git" + revision 1 + head "https://github.com/johang/btfs.git", branch: "master" bottle do root_url "https://github.com/gromgit/homebrew-fuse/releases/download/btfs-mac-2.24" @@ -19,21 +20,26 @@ class BtfsMac < Formula depends_on "autoconf" => :build depends_on "automake" => :build - depends_on "pkg-config" => :build + depends_on "pkgconf" => :build depends_on "libtorrent-rasterbar" depends_on MacfuseRequirement depends_on :macos def install setup_fuse - ENV.cxx11 - inreplace "configure.ac", "fuse >= 2.8.0", "fuse >= 2.7.3" system "autoreconf", "--force", "--install", "--verbose" system "./configure", *std_configure_args, "--disable-silent-rules" system "make", "install" end + def caveats + <<~EOS + Mounting a torrent is fairly quick, but unmounting takes a long time. + Be patient. + EOS + end + test do - system "#{bin}/btfs", "--help" + assert_match version.to_s, shell_output("#{bin}/btfs --version 2>&1") end end