2013-12-23 07:36:37 -08:00
|
|
|
{ stdenv, fetchurl, pkgconfig, python, gst-plugins-base, orc
|
2014-04-07 06:37:02 -07:00
|
|
|
, faacSupport ? false, faac ? null
|
2017-06-30 19:47:32 -07:00
|
|
|
, gtkSupport ? false, gtk3 ? null
|
2014-04-07 06:37:02 -07:00
|
|
|
, faad2, libass, libkate, libmms
|
2014-08-30 02:23:50 -07:00
|
|
|
, libmodplug, mpeg2dec, mpg123
|
2013-12-23 07:36:37 -08:00
|
|
|
, openjpeg, libopus, librsvg
|
2014-04-29 02:15:10 -07:00
|
|
|
, wildmidi, fluidsynth, libvdpau, wayland
|
2016-04-21 07:13:05 -07:00
|
|
|
, libwebp, xvidcore, gnutls, mjpegtools
|
2018-02-24 05:12:44 -08:00
|
|
|
, libGLU_combined, libintlOrEmpty, libgme
|
2016-09-04 12:44:15 -07:00
|
|
|
, openssl, x265, libxml2
|
2013-12-23 07:36:37 -08:00
|
|
|
}:
|
|
|
|
|
2014-04-07 06:37:02 -07:00
|
|
|
assert faacSupport -> faac != null;
|
2017-06-30 19:47:32 -07:00
|
|
|
assert gtkSupport -> gtk3 != null;
|
2014-04-07 06:37:02 -07:00
|
|
|
|
2015-04-08 18:54:51 -07:00
|
|
|
let
|
|
|
|
inherit (stdenv.lib) optional optionalString;
|
2017-11-19 22:48:40 -08:00
|
|
|
|
|
|
|
# OpenJPEG version is hardcoded in package source
|
|
|
|
openJpegVersion = with stdenv;
|
|
|
|
lib.concatStringsSep "." (lib.lists.take 2
|
|
|
|
(lib.splitString "." (lib.getVersion openjpeg)));
|
|
|
|
|
2015-04-08 18:54:51 -07:00
|
|
|
in
|
2013-12-23 07:36:37 -08:00
|
|
|
stdenv.mkDerivation rec {
|
2017-12-07 05:03:36 -08:00
|
|
|
name = "gst-plugins-bad-1.12.3";
|
2013-12-23 07:36:37 -08:00
|
|
|
|
2014-03-17 06:31:45 -07:00
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Gstreamer Bad Plugins";
|
2017-09-16 12:28:31 -07:00
|
|
|
homepage = "https://gstreamer.freedesktop.org";
|
2014-03-17 06:31:45 -07:00
|
|
|
longDescription = ''
|
|
|
|
a set of plug-ins that aren't up to par compared to the
|
|
|
|
rest. They might be close to being good quality, but they're missing
|
|
|
|
something - be it a good code review, some documentation, a set of tests,
|
|
|
|
a real live maintainer, or some actual wide use.
|
|
|
|
'';
|
|
|
|
license = licenses.lgpl2Plus;
|
2018-02-23 10:34:26 -08:00
|
|
|
platforms = platforms.linux ++ platforms.darwin;
|
2013-12-23 07:36:37 -08:00
|
|
|
};
|
|
|
|
|
2018-02-23 10:34:26 -08:00
|
|
|
# TODO: Fix Cocoa build. The problem was ARC, which might be related to too
|
|
|
|
# old version of Apple SDK's.
|
|
|
|
configureFlags = optional stdenv.isDarwin "--disable-cocoa";
|
|
|
|
|
2017-11-19 22:48:40 -08:00
|
|
|
patchPhase = ''
|
2017-12-07 05:03:36 -08:00
|
|
|
sed -i 's/openjpeg-2.2/openjpeg-${openJpegVersion}/' ext/openjpeg/*
|
2017-11-19 22:48:40 -08:00
|
|
|
'';
|
|
|
|
|
2013-12-23 07:36:37 -08:00
|
|
|
src = fetchurl {
|
|
|
|
url = "${meta.homepage}/src/gst-plugins-bad/${name}.tar.xz";
|
2017-12-07 05:03:36 -08:00
|
|
|
sha256 = "1v5z3i5ha20gmbb3r9dwsaaspv5fm1jfzlzwlzqx1gjj31v5kl1n";
|
2013-12-23 07:36:37 -08:00
|
|
|
};
|
|
|
|
|
2016-08-28 17:30:01 -07:00
|
|
|
outputs = [ "out" "dev" ];
|
2016-04-24 05:39:30 -07:00
|
|
|
|
2013-12-23 07:36:37 -08:00
|
|
|
nativeBuildInputs = [ pkgconfig python ];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
gst-plugins-base orc
|
2017-06-30 19:47:32 -07:00
|
|
|
faad2 gtk3 libass libkate libmms
|
2014-11-01 08:38:06 -07:00
|
|
|
libmodplug mpeg2dec mpg123
|
2013-12-23 07:36:37 -08:00
|
|
|
openjpeg libopus librsvg
|
2015-04-08 18:54:51 -07:00
|
|
|
fluidsynth libvdpau
|
2018-02-24 05:12:44 -08:00
|
|
|
libwebp xvidcore gnutls libGLU_combined
|
2018-02-23 10:34:26 -08:00
|
|
|
libgme openssl x265 libxml2
|
2015-04-08 18:54:51 -07:00
|
|
|
]
|
|
|
|
++ libintlOrEmpty
|
|
|
|
++ optional faacSupport faac
|
2017-06-30 19:47:32 -07:00
|
|
|
# for gtksink
|
|
|
|
++ optional gtkSupport gtk3
|
2015-04-08 18:54:51 -07:00
|
|
|
++ optional stdenv.isLinux wayland
|
|
|
|
# wildmidi requires apple's OpenAL
|
|
|
|
# TODO: package apple's OpenAL, fix wildmidi, include on Darwin
|
2018-02-23 10:34:26 -08:00
|
|
|
++ optional (!stdenv.isDarwin) wildmidi
|
|
|
|
# TODO: mjpegtools uint64_t is not compatible with guint64 on Darwin
|
|
|
|
++ optional (!stdenv.isDarwin) mjpegtools;
|
2015-04-08 18:54:51 -07:00
|
|
|
|
|
|
|
LDFLAGS = optionalString stdenv.isDarwin "-lintl";
|
2017-12-05 22:54:33 -08:00
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
2013-12-23 07:36:37 -08:00
|
|
|
}
|