diff options
| author | Misty De Meo | 2011-11-03 12:22:37 -0500 |
|---|---|---|
| committer | Jack Nagel | 2011-11-15 18:12:53 -0600 |
| commit | 9bc1915a48cc294f790012b57beb4abff00e735b (patch) | |
| tree | a95df49a748f13374cd02bad7e49ccd3c0abca63 /Library/Formula/gpac.rb | |
| parent | 0f5c0b729e0710f42cc4fadf38285f9f9b1ea3ab (diff) | |
| download | homebrew-9bc1915a48cc294f790012b57beb4abff00e735b.tar.bz2 | |
gpac: lowercase exec, add optional deps
Build gpac's executables with lowercase filenames (e.g. mp4box instead
of MP4Box) Also document optional dependencies and update treatment of
ffmpeg and openjpeg dependencies when building HEAD.
Closes #8432.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Diffstat (limited to 'Library/Formula/gpac.rb')
| -rw-r--r-- | Library/Formula/gpac.rb | 33 |
1 files changed, 28 insertions, 5 deletions
diff --git a/Library/Formula/gpac.rb b/Library/Formula/gpac.rb index 2eb8afe4d..cea9fb4dc 100644 --- a/Library/Formula/gpac.rb +++ b/Library/Formula/gpac.rb @@ -16,16 +16,39 @@ class Gpac < Formula md5 '755e8c438a48ebdb13525dd491f5b0d1' head 'https://gpac.svn.sourceforge.net/svnroot/gpac/trunk/gpac', :using => :svn + depends_on 'a52dec' => :optional + depends_on 'jpeg' => :optional + depends_on 'faad2' => :optional + depends_on 'libogg' => :optional + depends_on 'libvorbis' => :optional + depends_on 'mad' => :optional depends_on 'sdl' => :optional + depends_on 'theora' => :optional + + depends_on 'ffmpeg' => :optional if ARGV.build_head? + depends_on 'openjpeg' => :optional if ARGV.build_head? def install ENV.deparallelize + args = ["--disable-wx", + "--prefix=#{prefix}", + "--mandir=#{man}", + # Force detection of X libs on 64-bit kernel + "--extra-ldflags=-L/usr/X11/lib"] + args << "--use-ffmpeg=no" unless ARGV.build_head? + args << "--use-openjpeg=no" unless ARGV.build_head? + system "chmod +x configure" - system "./configure", "--disable-wx", "--use-ffmpeg=no", - "--prefix=#{prefix}", - "--mandir=#{man}", - # Force detection of X libs on 64-bit kernel - "--extra-ldflags=-L/usr/X11/lib" + system "./configure", *args + + system "chmod", "+rw", "Makefile" + ["MP4Box","MP4Client"].each do |name| + filename = "applications/#{name}/Makefile" + system "chmod", "+rw", filename + inreplace filename, name, name.downcase + inreplace "Makefile", name, name.downcase + end + system "make" system "make install" end |
