aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/cairo.rb
blob: ce3a389707bd1f67bb3d7954eb2628e2392e6eeb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
require 'formula'

class Cairo < Formula
  homepage 'http://cairographics.org/'
  url 'http://www.cairographics.org/releases/cairo-1.10.2.tar.gz'
  sha1 'ccce5ae03f99c505db97c286a0c9a90a926d3c6e'

  depends_on 'pkg-config' => :build
  depends_on 'pixman'

  keg_only :provided_by_osx,
            "The Cairo provided by Leopard is too old for newer software to link against."

  fails_with :llvm do
    build 2336
    cause "Throws an 'lto could not merge' error during build."
  end

  def install
    args = %W[
      --disable-dependency-tracking
      --prefix=#{prefix}
      --with-x
    ]
    args << '--enable-xcb' unless MacOS.leopard?

    system "./configure", *args
    system "make install"
  end
end