Unverified Commit b53b848b authored by Alex James's avatar Alex James
Browse files

python3Packages.yt-dlp: exclude secretstorage dependency on Darwin

secretstorage is used as an optional dependency to decrypt cookies from
browsers that use the D-Bus Secret Service, such as Chromium on Linux.
Exclude secretstorage by default on Darwin as it not needed to decrypt
browser cookies. This also avoids bringing in various D-Bus dependencies
which are currently broken on Darwin (see #493775).
parent 5a22af77
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
{
  lib,
  stdenvNoCC,
  python3Packages,
  atomicparsley,
  deno,
@@ -13,6 +14,7 @@
  javascriptSupport ? true,
  rtmpSupport ? true,
  withAlias ? false, # Provides bin/youtube-dl for backcompat
  withSecretStorage ? !stdenvNoCC.hostPlatform.isDarwin,
  nix-update-script,
}:

@@ -51,7 +53,10 @@ python3Packages.buildPythonApplication rec {
  ];

  # expose optional-dependencies, but provide all features
  dependencies = lib.concatAttrValues optional-dependencies;
  dependencies =
    optional-dependencies.default
    ++ optional-dependencies.curl-cffi
    ++ lib.optionals withSecretStorage optional-dependencies.secretstorage;

  optional-dependencies = {
    default = with python3Packages; [