libheif 1.2.0 (new formula)
Closes #26960. Signed-off-by: ilovezfs <ilovezfs@icloud.com>
This commit is contained in:
parent
c3852e8b07
commit
359e103ff5
1 changed files with 30 additions and 0 deletions
30
Formula/libheif.rb
Normal file
30
Formula/libheif.rb
Normal file
|
@ -0,0 +1,30 @@
|
|||
class Libheif < Formula
|
||||
desc "ISO/IEC 23008-12:2017 HEIF file format decoder and encoder"
|
||||
homepage "http://www.libheif.org"
|
||||
url "https://github.com/strukturag/libheif/releases/download/v1.2.0/libheif-1.2.0.tar.gz"
|
||||
sha256 "2e7d40f81d1bbe6089b1e0f27800b97cf6a195e093ef86199edfb6e59e2fa8fa"
|
||||
|
||||
depends_on "pkg-config" => :build
|
||||
depends_on "jpeg"
|
||||
depends_on "libde265"
|
||||
depends_on "libpng"
|
||||
depends_on "x265"
|
||||
|
||||
def install
|
||||
system "./configure", "--disable-dependency-tracking",
|
||||
"--disable-silent-rules",
|
||||
"--prefix=#{prefix}"
|
||||
system "make", "install"
|
||||
pkgshare.install "examples/example.heic"
|
||||
end
|
||||
|
||||
test do
|
||||
output = "File contains 2 images"
|
||||
example = pkgshare/"example.heic"
|
||||
exout = testpath/"example.jpg"
|
||||
|
||||
assert_match output, shell_output("#{bin}/heif-convert #{example} #{exout}")
|
||||
assert_predicate testpath/"example-1.jpg", :exist?
|
||||
assert_predicate testpath/"example-2.jpg", :exist?
|
||||
end
|
||||
end
|
Loading…
Reference in a new issue