librsvg 2.40.9

version bump
brew audit --strict compliance

Closes Homebrew/homebrew#39583.

Signed-off-by: Xu Cheng <xucheng@me.com>
This commit is contained in:
Tom Schoonjans 2015-05-11 11:36:15 +02:00 committed by Xu Cheng
parent 3722f77ef4
commit 9d7042aefc

View file

@ -1,7 +1,7 @@
class Librsvg < Formula class Librsvg < Formula
homepage "https://live.gnome.org/LibRsvg" homepage "https://live.gnome.org/LibRsvg"
url "https://download.gnome.org/sources/librsvg/2.40/librsvg-2.40.5.tar.xz" url "https://download.gnome.org/sources/librsvg/2.40/librsvg-2.40.9.tar.xz"
sha256 "d14d7b3e25023ce34302022fd7c9b3a468629c94dff6c177874629686bfc71a7" sha256 "13964c5d35357552b47d365c34215eee0a63bf0e6059b689f048648c6bf5f43a"
bottle do bottle do
sha256 "f7ca7f815635467444ffeb8b2ec27411ed565ecbd7e6761bee033b2b26b531d8" => :yosemite sha256 "f7ca7f815635467444ffeb8b2ec27411ed565ecbd7e6761bee033b2b26b531d8" => :yosemite
@ -42,4 +42,52 @@ class Librsvg < Formula
ENV["GDK_PIXBUF_MODULEDIR"] = "#{HOMEBREW_PREFIX}/lib/gdk-pixbuf-2.0/2.10.0/loaders" ENV["GDK_PIXBUF_MODULEDIR"] = "#{HOMEBREW_PREFIX}/lib/gdk-pixbuf-2.0/2.10.0/loaders"
system "#{Formula["gdk-pixbuf"].opt_bin}/gdk-pixbuf-query-loaders", "--update-cache" system "#{Formula["gdk-pixbuf"].opt_bin}/gdk-pixbuf-query-loaders", "--update-cache"
end end
test do
(testpath/"test.c").write <<-EOS.undent
#include <librsvg/rsvg.h>
int main(int argc, char *argv[]) {
RsvgHandle *handle = rsvg_handle_new();
return 0;
}
EOS
cairo = Formula["cairo"]
fontconfig = Formula["fontconfig"]
freetype = Formula["freetype"]
gdk_pixbuf = Formula["gdk-pixbuf"]
gettext = Formula["gettext"]
glib = Formula["glib"]
libpng = Formula["libpng"]
pixman = Formula["pixman"]
flags = (ENV.cflags || "").split + (ENV.cppflags || "").split + (ENV.ldflags || "").split
flags += %W[
-I#{cairo.opt_include}/cairo
-I#{fontconfig.opt_include}
-I#{freetype.opt_include}/freetype2
-I#{gdk_pixbuf.opt_include}/gdk-pixbuf-2.0
-I#{gettext.opt_include}
-I#{glib.opt_include}/glib-2.0
-I#{glib.opt_lib}/glib-2.0/include
-I#{include}/librsvg-2.0
-I#{libpng.opt_include}/libpng16
-I#{pixman.opt_include}/pixman-1
-D_REENTRANT
-L#{cairo.opt_lib}
-L#{gdk_pixbuf.opt_lib}
-L#{gettext.opt_lib}
-L#{glib.opt_lib}
-L#{lib}
-lcairo
-lgdk_pixbuf-2.0
-lgio-2.0
-lglib-2.0
-lgobject-2.0
-lintl
-lm
-lrsvg-2
]
system ENV.cc, "test.c", "-o", "test", *flags
system "./test"
end
end end