aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/mjpegtools.rb
blob: db65323b93ede3635162390a6b9fb9a4805e0588 (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
require 'formula'

class Mjpegtools < Formula
  homepage 'http://mjpeg.sourceforge.net/'
  url 'http://downloads.sourceforge.net/project/mjpeg/mjpegtools/2.0.0/mjpegtools-2.0.0.tar.gz'
  md5 '903e1e3b967eebcc5fe5626d7517dc46'

  option "without-x", "Build without X support"

  depends_on 'pkg-config' => :build
  depends_on 'jpeg'
  depends_on :x11
  depends_on 'libquicktime' => :optional
  depends_on 'libdv' => :optional
  depends_on 'gtk+' => :optional
  depends_on 'sdl_gfx' => :optional

  fails_with :clang do
    build 318
    cause <<-EOS.undent
      In file included from newdenoise.cc:19:
      ./MotionSearcher.hh:2199:3: error: use of undeclared identifier 'DeleteRegion'
    EOS
  end

  def install
    args = ["--disable-dependency-tracking",
            "--enable-simd-accel",
            "--prefix=#{prefix}"]
    args << "--without-x" if build.include? "without-x"

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