vlc: 2.2.8 -> 3.0.1
This commit is contained in:
parent
b05ca2d84d
commit
a0dd9713e3
@ -1,86 +1,81 @@
|
|||||||
{ stdenv, fetchurl, xz, bzip2, perl, xorg, libdvdnav, libbluray
|
{ stdenv, fetchurl, autoreconfHook
|
||||||
|
, libarchive, perl, xorg, libdvdnav, libbluray
|
||||||
, zlib, a52dec, libmad, faad2, ffmpeg, alsaLib
|
, zlib, a52dec, libmad, faad2, ffmpeg, alsaLib
|
||||||
, pkgconfig, dbus, fribidi, freefont_ttf, libebml, libmatroska
|
, pkgconfig, dbus, fribidi, freefont_ttf, libebml, libmatroska
|
||||||
, libvorbis, libtheora, speex, lua5, libgcrypt, libupnp
|
, libvorbis, libtheora, speex, lua5, libgcrypt, libgpgerror, libupnp
|
||||||
, libcaca, libpulseaudio, flac, schroedinger, libxml2, librsvg
|
, libcaca, libpulseaudio, flac, schroedinger, libxml2, librsvg
|
||||||
, mpeg2dec, udev, gnutls, avahi, libcddb, libjack2, SDL, SDL_image
|
, mpeg2dec, systemd, gnutls, avahi, libcddb, libjack2, SDL, SDL_image
|
||||||
, libmtp, unzip, taglib, libkate, libtiger, libv4l, samba, liboggz
|
, libmtp, unzip, taglib, libkate, libtiger, libv4l, samba, liboggz
|
||||||
, libass, libva, libdvbpsi, libdc1394, libraw1394, libopus
|
, libass, libva-full, libdvbpsi, libdc1394, libraw1394, libopus
|
||||||
, libvdpau, libsamplerate, live555, fluidsynth
|
, libvdpau, libsamplerate, live555, fluidsynth, wayland, wayland-protocols
|
||||||
, qt4 ? null
|
, onlyLibVLC ? false
|
||||||
, withQt5 ? false, qtbase ? null, qtx11extras ? null
|
, withQt5 ? true, qtbase ? null, qtsvg ? null, qtx11extras ? null
|
||||||
, jackSupport ? false
|
, jackSupport ? false
|
||||||
, fetchpatch
|
, fetchpatch
|
||||||
}:
|
}:
|
||||||
|
|
||||||
with stdenv.lib;
|
with stdenv.lib;
|
||||||
|
|
||||||
assert (withQt5 -> qtbase != null && qtx11extras != null);
|
assert (withQt5 -> qtbase != null && qtsvg != null && qtx11extras != null);
|
||||||
assert (!withQt5 -> qt4 != null);
|
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
name = "vlc-${version}";
|
name = "vlc-${version}";
|
||||||
version = "2.2.8";
|
version = "3.0.1";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "http://get.videolan.org/vlc/${version}/${name}.tar.xz";
|
url = "http://get.videolan.org/vlc/${version}/${name}.tar.xz";
|
||||||
sha256 = "1v32snw46rkgbdqdy3dssl2y13i8p2cr1cw1i18r6vdmiy24dw4v";
|
sha256 = "008krfhykm9447wc1kkw82bsw3f6ikljgrqyb1sinwlxnkghqw6f";
|
||||||
};
|
};
|
||||||
|
|
||||||
# Comment-out the Qt 5.5 version check, as we do apply the relevant patch.
|
# VLC uses a *ton* of libraries for various pieces of functionality, many of
|
||||||
# https://trac.videolan.org/vlc/ticket/16497
|
# which are not included here for no other reason that nobody has mentioned
|
||||||
postPatch = if (!withQt5) then null else
|
# needing them
|
||||||
"sed '/I78ef29975181ee22429c9bd4b11d96d9e68b7a9c/s/^/: #/' -i configure";
|
buildInputs = [
|
||||||
|
zlib a52dec libmad faad2 ffmpeg alsaLib libdvdnav libdvdnav.libdvdread
|
||||||
buildInputs =
|
libbluray dbus fribidi libvorbis libtheora speex lua5 libgcrypt libgpgerror
|
||||||
[ xz bzip2 perl zlib a52dec libmad faad2 ffmpeg alsaLib libdvdnav libdvdnav.libdvdread
|
libupnp libcaca libpulseaudio flac schroedinger libxml2 librsvg mpeg2dec
|
||||||
libbluray dbus fribidi libvorbis libtheora speex lua5 libgcrypt
|
systemd gnutls avahi libcddb SDL SDL_image libmtp unzip taglib libarchive
|
||||||
libupnp libcaca libpulseaudio flac schroedinger libxml2 librsvg mpeg2dec
|
libkate libtiger libv4l samba liboggz libass libdvbpsi libva-full
|
||||||
udev gnutls avahi libcddb SDL SDL_image libmtp unzip taglib
|
xorg.xlibsWrapper xorg.libXv xorg.libXvMC xorg.libXpm xorg.xcbutilkeysyms
|
||||||
libkate libtiger libv4l samba liboggz libass libdvbpsi libva
|
libdc1394 libraw1394 libopus libebml libmatroska libvdpau libsamplerate live555
|
||||||
xorg.xlibsWrapper xorg.libXv xorg.libXvMC xorg.libXpm xorg.xcbutilkeysyms
|
fluidsynth wayland wayland-protocols
|
||||||
libdc1394 libraw1394 libopus libebml libmatroska libvdpau libsamplerate live555
|
] ++ optionals withQt5 [ qtbase qtsvg qtx11extras ]
|
||||||
fluidsynth
|
|
||||||
]
|
|
||||||
++ [(if withQt5 then qtbase else qt4)]
|
|
||||||
++ optional withQt5 qtx11extras
|
|
||||||
++ optional jackSupport libjack2;
|
++ optional jackSupport libjack2;
|
||||||
|
|
||||||
nativeBuildInputs = [ pkgconfig ];
|
nativeBuildInputs = [ autoreconfHook perl pkgconfig ];
|
||||||
|
|
||||||
LIVE555_PREFIX = live555;
|
|
||||||
|
|
||||||
preConfigure = ''
|
|
||||||
sed -e "s@/bin/echo@echo@g" -i configure
|
|
||||||
'' + optionalString withQt5 ''
|
|
||||||
# Make sure we only *add* "-std=c++11" to CXXFLAGS instead of overriding the
|
|
||||||
# values figured out by configure (for example "-g -O2").
|
|
||||||
sed -i -re '/^ *CXXFLAGS=("[^$"]+")? *$/s/CXXFLAGS="?/&-std=c++11 /' \
|
|
||||||
configure
|
|
||||||
'';
|
|
||||||
|
|
||||||
configureFlags =
|
|
||||||
[ "--enable-alsa"
|
|
||||||
"--with-kde-solid=$out/share/apps/solid/actions"
|
|
||||||
"--enable-dc1394"
|
|
||||||
"--enable-ncurses"
|
|
||||||
"--enable-vdpau"
|
|
||||||
"--enable-dvdnav"
|
|
||||||
"--enable-samplerate"
|
|
||||||
];
|
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
enableParallelBuilding = true;
|
||||||
|
|
||||||
preBuild = ''
|
LIVE555_PREFIX = live555;
|
||||||
substituteInPlace modules/text_renderer/freetype.c --replace \
|
|
||||||
/usr/share/fonts/truetype/freefont/FreeSerifBold.ttf \
|
# vlc depends on a c11-gcc wrapper script which we don't have so we need to
|
||||||
${freefont_ttf}/share/fonts/truetype/FreeSerifBold.ttf
|
# set the path to the compiler
|
||||||
|
BUILDCC = "${stdenv.cc}/bin/gcc";
|
||||||
|
|
||||||
|
postPatch = ''
|
||||||
|
substituteInPlace configure \
|
||||||
|
--replace /bin/echo echo
|
||||||
|
|
||||||
|
substituteInPlace modules/text_renderer/freetype/platform_fonts.h --replace \
|
||||||
|
/usr/share/fonts/truetype/freefont ${freefont_ttf}/share/fonts/truetype
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
# https://github.com/NixOS/nixpkgs/pull/35124#issuecomment-370552830
|
||||||
|
postFixup = ''
|
||||||
|
find $out/lib/vlc/plugins -exec touch -d @1 '{}' ';'
|
||||||
|
$out/lib/vlc/vlc-cache-gen $out/vlc/plugins
|
||||||
|
'';
|
||||||
|
|
||||||
|
# Most of the libraries are auto-detected so we don't need to set a bunch of
|
||||||
|
# "--enable-foo" flags here
|
||||||
|
configureFlags = [
|
||||||
|
"--with-kde-solid=$out/share/apps/solid/actions"
|
||||||
|
] ++ optional onlyLibVLC "--disable-vlc";
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
description = "Cross-platform media player and streaming server";
|
description = "Cross-platform media player and streaming server";
|
||||||
homepage = http://www.videolan.org/vlc/;
|
homepage = http://www.videolan.org/vlc/;
|
||||||
platforms = platforms.linux;
|
|
||||||
license = licenses.lgpl21Plus;
|
license = licenses.lgpl21Plus;
|
||||||
|
platforms = platforms.linux;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -11159,9 +11159,7 @@ with pkgs;
|
|||||||
withQt5 = true;
|
withQt5 = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
phonon-backend-vlc = callPackage ../development/libraries/phonon/backends/vlc.nix {
|
phonon-backend-vlc = callPackage ../development/libraries/phonon/backends/vlc.nix { };
|
||||||
withQt5 = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
polkit-qt = callPackage ../development/libraries/polkit-qt-1/qt-5.nix { };
|
polkit-qt = callPackage ../development/libraries/polkit-qt-1/qt-5.nix { };
|
||||||
|
|
||||||
@ -11196,11 +11194,7 @@ with pkgs;
|
|||||||
|
|
||||||
telepathy = callPackage ../development/libraries/telepathy/qt { };
|
telepathy = callPackage ../development/libraries/telepathy/qt { };
|
||||||
|
|
||||||
vlc = lowPrio (callPackage ../applications/video/vlc {
|
vlc = callPackage ../applications/video/vlc {};
|
||||||
qt4 = null;
|
|
||||||
withQt5 = true;
|
|
||||||
ffmpeg = ffmpeg_2;
|
|
||||||
});
|
|
||||||
|
|
||||||
qtwebkit-plugins = callPackage ../development/libraries/qtwebkit-plugins { };
|
qtwebkit-plugins = callPackage ../development/libraries/qtwebkit-plugins { };
|
||||||
|
|
||||||
@ -18188,16 +18182,13 @@ with pkgs;
|
|||||||
|
|
||||||
vkeybd = callPackage ../applications/audio/vkeybd {};
|
vkeybd = callPackage ../applications/audio/vkeybd {};
|
||||||
|
|
||||||
vlc = callPackage ../applications/video/vlc {
|
vlc = libsForQt5.vlc;
|
||||||
ffmpeg = ffmpeg_2;
|
vlc_qt5 = vlc;
|
||||||
};
|
|
||||||
|
|
||||||
vlc_npapi = callPackage ../applications/video/vlc/plugin.nix {
|
vlc_npapi = callPackage ../applications/video/vlc/plugin.nix {
|
||||||
gtk = gtk2;
|
gtk = gtk2;
|
||||||
};
|
};
|
||||||
|
|
||||||
vlc_qt5 = libsForQt5.vlc;
|
|
||||||
|
|
||||||
vmpk = callPackage ../applications/audio/vmpk { };
|
vmpk = callPackage ../applications/audio/vmpk { };
|
||||||
|
|
||||||
vnstat = callPackage ../applications/networking/vnstat { };
|
vnstat = callPackage ../applications/networking/vnstat { };
|
||||||
|
Loading…
Reference in New Issue
Block a user