youtube-dl: clean up the expression and document the pandoc situation
This patch resolves https://github.com/NixOS/nixpkgs/pull/8184.
This commit is contained in:
parent
86a511a398
commit
c1c4ca08de
@ -1,9 +1,11 @@
|
|||||||
{ manuals ? true
|
{ stdenv, fetchurl, makeWrapper, python, zip, ffmpeg, pandoc ? null }:
|
||||||
, stdenv, fetchurl, makeWrapper, python, zip,
|
|
||||||
pandoc ? null
|
|
||||||
, ffmpeg }:
|
|
||||||
|
|
||||||
assert manuals -> pandoc != null;
|
# Pandoc is required to build the package's man page. Release tarballs
|
||||||
|
# contain a formatted man page already, though, so it's fine to pass
|
||||||
|
# "pandoc = null" to this derivation; the man page will still be
|
||||||
|
# installed. We keep the pandoc argument and build input in place in
|
||||||
|
# case someone wants to use this derivation to build a Git version of
|
||||||
|
# the tool that doesn't have the formatted man page included.
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
name = "youtube-dl-${version}";
|
name = "youtube-dl-${version}";
|
||||||
@ -14,14 +16,9 @@ stdenv.mkDerivation rec {
|
|||||||
sha256 = "0lgxir2i5ipplg57wk8gnbbsdrk7szqnyb1bxr97f3h0rbm4dfij";
|
sha256 = "0lgxir2i5ipplg57wk8gnbbsdrk7szqnyb1bxr97f3h0rbm4dfij";
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = [ ]
|
buildInputs = [ python makeWrapper zip pandoc ];
|
||||||
++ stdenv.lib.optional manuals pandoc;
|
|
||||||
|
|
||||||
buildInputs = [ python makeWrapper zip ];
|
patchPhase = "rm youtube-dl";
|
||||||
|
|
||||||
patchPhase = ''
|
|
||||||
rm youtube-dl
|
|
||||||
'';
|
|
||||||
|
|
||||||
configurePhase = ''
|
configurePhase = ''
|
||||||
makeFlagsArray=( PREFIX=$out SYSCONFDIR=$out/etc PYTHON=${python}/bin/python )
|
makeFlagsArray=( PREFIX=$out SYSCONFDIR=$out/etc PYTHON=${python}/bin/python )
|
||||||
|
@ -3385,7 +3385,9 @@ let
|
|||||||
yi = callPackage ../applications/editors/yi/wrapper.nix { };
|
yi = callPackage ../applications/editors/yi/wrapper.nix { };
|
||||||
|
|
||||||
youtube-dl = callPackage ../tools/misc/youtube-dl {
|
youtube-dl = callPackage ../tools/misc/youtube-dl {
|
||||||
manuals = false;
|
# Release versions don't need pandoc because the formatted man page
|
||||||
|
# is included in the tarball.
|
||||||
|
pandoc = null;
|
||||||
};
|
};
|
||||||
|
|
||||||
zbar = callPackage ../tools/graphics/zbar {
|
zbar = callPackage ../tools/graphics/zbar {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user