aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/libbtbb.rb
blob: 9ee99a8062c6b4020a18d4b1f0f4210b682c53c9 (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
31
32
33
34
35
36
require "formula"

class Libbtbb < Formula
  homepage "https://github.com/greatscottgadgets/libbtbb"
  url "https://github.com/greatscottgadgets/libbtbb/archive/2014-02-R3.tar.gz"
  sha1 "b42c19cd1965b18409661d765734adec9c1f7449"
  version "2014-02-R3"

  head "https://github.com/greatscottgadgets/libbtbb.git"

  bottle do
    cellar :any
    sha1 "9ce274e76c4e44bb9d5ff166b0f920ef2b6d7997" => :yosemite
    sha1 "c35dcd7c94a2ca00db402954b1eabba33f3bab7b" => :mavericks
    sha1 "3238e7c992e725806f3bea8b683638ab337978ab" => :mountain_lion
  end

  option :universal

  depends_on "cmake" => :build
  depends_on "python"

  def install
    args = std_cmake_args

    if build.universal?
      ENV.universal_binary
      args << "-DCMAKE_OSX_ARCHITECTURES=#{Hardware::CPU.universal_archs.as_cmake_arch_flags}"
    end

    mkdir "build" do
      system "cmake", "..", *args
      system "make", "install"
    end
  end
end