Skip to content

Commit

Permalink
gexiv2 0.10.2 (new formula)
Browse files Browse the repository at this point in the history
gexiv2 is a GObject wrapper around the Exiv2 photo metadata library. It
allows for GNOME applications to easily inspect and update EXIF, IPTC,
and XMP metadata in photo files of various formats. A dependency of
things like Shotwell.

Closes Homebrew/legacy-homebrew#37944.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
  • Loading branch information
alistairmcmillan authored and MikeMcQuaid committed Mar 23, 2015
1 parent a9cced5 commit 14e9aa1
Showing 1 changed file with 37 additions and 0 deletions.
37 changes: 37 additions & 0 deletions Formula/gexiv2.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
class Gexiv2 < Formula
homepage "https://wiki.gnome.org/Projects/gexiv2"
url "https://download.gnome.org/sources/gexiv2/0.10/gexiv2-0.10.2.tar.xz"
sha256 "2fd21f0ed5125e51d02226e7f41be751cfa8ae411a8ed1a651e16b06d79047b2"

depends_on "pkg-config" => :build
depends_on "glib"
depends_on "exiv2"

def install
system "./configure", "--disable-debug",
"--disable-dependency-tracking",
"--disable-silent-rules",
"--prefix=#{prefix}"
system "make", "install"
end

test do
(testpath/"test.c").write <<-EOS.undent
#include <gexiv2/gexiv2.h>
int main() {
GExiv2Metadata *metadata = gexiv2_metadata_new();
return 0;
}
EOS

flags = [
"-I#{HOMEBREW_PREFIX}/include/glib-2.0",
"-I#{HOMEBREW_PREFIX}/lib/glib-2.0/include",
"-L#{lib}",
"-lgexiv2",
]

system ENV.cc, "test.c", "-o", "test", *flags
system "./test"
end
end

0 comments on commit 14e9aa1

Please sign in to comment.