sfk 1.8.9

Closes #21529.

Signed-off-by: ilovezfs <ilovezfs@icloud.com>
This commit is contained in:
ilovezfs 2017-12-10 05:34:22 -08:00
parent b04d8e49ee
commit cd29709e73

View file

@ -1,20 +1,8 @@
# The tarball is not APFS friendly
# "Can't create 'sfk-1.8.8/testfiles/Formats/22-umlauts-???-name.txt'"
# Reported 24 Nov 2017 https://sourceforge.net/p/swissfileknife/bugs/50/
class SfkDownloadStrategy < CurlDownloadStrategy
def stage
exclude = "#{name}-#{version}/testfiles/Formats"
safe_system "tar", "xf", cached_location, "--exclude", exclude
chdir
end
end
class Sfk < Formula
desc "Command-line tools collection"
homepage "http://stahlworks.com/dev/swiss-file-knife.html"
url "https://downloads.sourceforge.net/project/swissfileknife/1-swissfileknife/1.8.8/sfk-1.8.8.tar.gz",
:using => SfkDownloadStrategy
sha256 "b139998e3aca294fe74ad2a6f0527e81cbd11eddfb5e8a81f6067a79d26c97ed"
url "https://downloads.sourceforge.net/project/swissfileknife/1-swissfileknife/1.8.9.0/sfk-1.8.9.tar.gz"
sha256 "0f974f491d28bf5442d94f9ddeb983bfc69ead96842965ad55152969381fcd8e"
bottle do
cellar :any_skip_relocation
@ -26,14 +14,6 @@ class Sfk < Formula
def install
ENV.libstdcxx
# Fix "error: ordered comparison between pointer and zero"
# Reported 24 Nov 2017 https://sourceforge.net/p/swissfileknife/bugs/51/
if DevelopmentTools.clang_build_version >= 900
inreplace "sfk.cpp",
"if (fgets(szLineBuf, MAX_LINE_LEN, stdin) <= 0)",
"if (fgets(szLineBuf, MAX_LINE_LEN, stdin) <= (void *)0)"
end
system "./configure", "--prefix=#{prefix}"
system "make"
system "make", "install"