homebrew-core/Formula/zint.rb
2019-09-07 10:52:28 +02:00

31 lines
1 KiB
Ruby

class Zint < Formula
desc "Barcode encoding library supporting over 50 symbologies"
homepage "http://www.zint.org.uk/"
url "https://downloads.sourceforge.net/project/zint/zint/2.6.5/zint-2.6.5.tar.gz"
sha256 "006c0cfa277ed10bdbb24ec98d787ac14bab701de17a7269e45b1ee5ccb97926"
head "https://git.code.sf.net/p/zint/code.git"
bottle do
cellar :any
sha256 "cb5636c433b062d562207afac08d7200bea18e26aafc9840955df3ea7aae51b6" => :mojave
sha256 "f74d7d1b72fe284fc2a980e1a2ccf5cc0559e004064d451eeae7147dcbe9256f" => :high_sierra
sha256 "c9183fbd6c0f0cbe7b4fce3091608691b843e089411e072b053662af9f512905" => :sierra
end
depends_on "cmake" => :build
depends_on "libpng"
def install
# Sandbox fix: install FindZint.cmake in zint's prefix, not cmake's.
inreplace "CMakeLists.txt", "${CMAKE_ROOT}", "#{share}/cmake"
mkdir "zint-build" do
system "cmake", "..", *std_cmake_args
system "make", "install"
end
end
test do
system "#{bin}/zint", "-o", "test-zing.png", "-d", "This Text"
end
end