homebrew-core/Formula/gstreamer.rb
2017-06-29 04:06:27 -07:00

60 lines
1.8 KiB
Ruby

class Gstreamer < Formula
desc "Development framework for multimedia applications"
homepage "https://gstreamer.freedesktop.org/"
url "https://gstreamer.freedesktop.org/src/gstreamer/gstreamer-1.12.1.tar.xz"
sha256 "9044b9d8b3ff44457fa9e36faa59c56684b587b34dee449bfe15ec0c32a3a6d2"
bottle do
sha256 "ad6cf580a3f5d68b8c37e01e8db5b1cf16aa5c4d072416f6305ab63d75e05b9a" => :sierra
sha256 "ddb14f2c108456c858c134d69e4252464d3519401ad37a6872ce40b27e06a216" => :el_capitan
sha256 "5d40c43a9d0b8a901aa4dda568ca0bf29c08752e68ce659db22906a9c768e0b3" => :yosemite
end
head do
url "https://anongit.freedesktop.org/git/gstreamer/gstreamer.git"
depends_on "autoconf" => :build
depends_on "automake" => :build
depends_on "libtool" => :build
end
depends_on "pkg-config" => :build
depends_on "gobject-introspection"
depends_on "gettext"
depends_on "glib"
depends_on "bison"
def install
args = %W[
--prefix=#{prefix}
--disable-debug
--disable-dependency-tracking
--disable-gtk-doc
--enable-introspection=yes
]
if build.head?
ENV["NOCONFIGURE"] = "yes"
system "./autogen.sh"
# Ban trying to chown to root.
# https://bugzilla.gnome.org/show_bug.cgi?id=750367
args << "--with-ptp-helper-permissions=none"
end
# Look for plugins in HOMEBREW_PREFIX/lib/gstreamer-1.0 instead of
# HOMEBREW_PREFIX/Cellar/gstreamer/1.0/lib/gstreamer-1.0, so we'll find
# plugins installed by other packages without setting GST_PLUGIN_PATH in
# the environment.
inreplace "configure", 'PLUGINDIR="$full_var"',
"PLUGINDIR=\"#{HOMEBREW_PREFIX}/lib/gstreamer-1.0\""
system "./configure", *args
system "make"
system "make", "install"
end
test do
system bin/"gst-inspect-1.0"
end
end