55 lines
1.5 KiB
Ruby
55 lines
1.5 KiB
Ruby
class SimpleMtpfs < Formula
|
|
desc "Simple MTP fuse filesystem driver"
|
|
homepage "https://github.com/phatina/simple-mtpfs"
|
|
url "https://github.com/phatina/simple-mtpfs/archive/v0.4.0.tar.gz"
|
|
sha256 "1d011df3fa09ad0a5c09d48d84c03e6cddf86390af9eb4e0c178193f32f0e2fc"
|
|
license "GPL-2.0"
|
|
|
|
bottle do
|
|
rebuild 1
|
|
sha256 cellar: :any_skip_relocation, x86_64_linux: "bb452a3c993c8330c578d255ce7d67c430eb802fae476c341415a7feea05bcfd"
|
|
end
|
|
|
|
depends_on "autoconf" => :build
|
|
depends_on "autoconf-archive" => :build # required for AX_CXX_COMPILE_STDCXX_17
|
|
depends_on "automake" => :build
|
|
depends_on "pkg-config" => :build
|
|
depends_on "libmtp"
|
|
|
|
on_macos do
|
|
disable! date: "2021-04-08", because: "requires closed-source macFUSE"
|
|
end
|
|
|
|
on_linux do
|
|
depends_on "gcc"
|
|
depends_on "libfuse@2"
|
|
end
|
|
|
|
fails_with gcc: "5"
|
|
|
|
def install
|
|
system "./autogen.sh"
|
|
system "./configure", "--prefix=#{prefix}",
|
|
"CPPFLAGS=-I/usr/local/include/osxfuse -I/usr/local/include/osxfuse/fuse",
|
|
"LDFLAGS=-L/usr/local/include/osxfuse"
|
|
system "make"
|
|
system "make", "install"
|
|
end
|
|
|
|
def caveats
|
|
on_macos do
|
|
<<~EOS
|
|
The reasons for disabling this formula can be found here:
|
|
https://github.com/Homebrew/homebrew-core/pull/64491
|
|
|
|
An external tap may provide a replacement formula. See:
|
|
https://docs.brew.sh/Interesting-Taps-and-Forks
|
|
EOS
|
|
end
|
|
end
|
|
|
|
test do
|
|
system bin/"simple-mtpfs", "-h"
|
|
end
|
|
end
|