vips: import from homebrew/science
Closes #14300. Signed-off-by: ilovezfs <ilovezfs@icloud.com>
This commit is contained in:
parent
512039077b
commit
22e56c3b59
1 changed files with 52 additions and 0 deletions
52
Formula/vips.rb
Normal file
52
Formula/vips.rb
Normal file
|
@ -0,0 +1,52 @@
|
|||
class Vips < Formula
|
||||
desc "Image processing library"
|
||||
homepage "https://github.com/jcupitt/libvips"
|
||||
url "https://github.com/jcupitt/libvips/releases/download/v8.5.5/vips-8.5.5.tar.gz"
|
||||
sha256 "0891af4531d6f951a16ca6d03020b73796522d5fcf7c6247f2f04c896ecded28"
|
||||
|
||||
depends_on "pkg-config" => :build
|
||||
depends_on "fftw"
|
||||
depends_on "fontconfig"
|
||||
depends_on "gettext"
|
||||
depends_on "giflib"
|
||||
depends_on "glib"
|
||||
depends_on "gobject-introspection"
|
||||
depends_on "jpeg"
|
||||
depends_on "libexif"
|
||||
depends_on "libgsf"
|
||||
depends_on "libpng"
|
||||
depends_on "librsvg"
|
||||
depends_on "libtiff"
|
||||
depends_on "little-cms2"
|
||||
depends_on "orc"
|
||||
depends_on "pango"
|
||||
depends_on "poppler"
|
||||
depends_on "pygobject3"
|
||||
depends_on "graphicsmagick" => :optional
|
||||
depends_on "imagemagick" => :optional
|
||||
depends_on "jpeg-turbo" => :optional
|
||||
depends_on "mozjpeg" => :optional
|
||||
depends_on "openexr" => :optional
|
||||
depends_on "openslide" => :optional
|
||||
depends_on "webp" => :optional
|
||||
|
||||
def install
|
||||
args = %W[
|
||||
--disable-dependency-tracking
|
||||
--prefix=#{prefix}
|
||||
]
|
||||
|
||||
if build.with? "graphicsmagick"
|
||||
args << "--with-magick" << "--with-magickpackage=GraphicsMagick"
|
||||
end
|
||||
|
||||
system "./configure", *args
|
||||
system "make", "install"
|
||||
end
|
||||
|
||||
test do
|
||||
system "#{bin}/vips", "-l"
|
||||
cmd = "#{bin}/vipsheader -f width #{test_fixtures("test.png")}"
|
||||
assert_equal "8", shell_output(cmd).chomp
|
||||
end
|
||||
end
|
Loading…
Reference in a new issue