summary refs log tree commit diff
path: root/pkgs/development/libraries/gstreamer/legacy/gst-ffmpeg/default.nix
blob: 89b6e73e6b6d5073d101038959d269ab7115f8e3 (plain) (blame)
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
{ fetchurl, stdenv, pkgconfig, gst_plugins_base, bzip2, yasm, orc
, useInternalFfmpeg ? false, ffmpeg ? null }:

stdenv.mkDerivation rec {
  name = "gst-ffmpeg-0.10.13";

  src = fetchurl {
    urls = [
      "http://gstreamer.freedesktop.org/src/gst-ffmpeg/${name}.tar.bz2"
      "mirror://gentoo/distfiles/${name}.tar.bz2"
      ];
    sha256 = "0qmvgwcfybci78sd73mhvm4bsb7l0xsk9yljrgik80g011ds1z3n";
  };

  # Upstream strongly recommends against using --with-system-ffmpeg,
  # but we do it anyway because we're so hardcore (and we don't want
  # multiple copies of ffmpeg).
  configureFlags = stdenv.lib.optionalString (!useInternalFfmpeg) "--with-system-ffmpeg";

  buildInputs =
    [ pkgconfig bzip2 gst_plugins_base orc ]
    ++ (if useInternalFfmpeg then [ yasm ] else [ ffmpeg ]);

  meta = {
    homepage = "http://gstreamer.freedesktop.org/releases/gst-ffmpeg";
    description = "GStreamer's plug-in using FFmpeg";
    license = stdenv.lib.licenses.gpl2Plus;
  };
}