diff options
author | Shamrock Lee <44064051+ShamrockLee@users.noreply.github.com> | 2022-12-05 05:15:53 +0800 |
---|---|---|
committer | Shamrock Lee <44064051+ShamrockLee@users.noreply.github.com> | 2022-12-08 14:04:31 +0000 |
commit | f7860c59a374653b84d8403be06735cd3c6dc5f0 (patch) | |
tree | 1703cbaeee70f28ceef635ed4b10271a1bd71206 /pkgs/applications/video | |
parent | bd2a5f009a87fcfd33797b31407b4dfe2aee269b (diff) |
losslesscut-bin: 3.46.2 -> 3.48.2 and add aarch64-darwin support
Diffstat (limited to 'pkgs/applications/video')
-rw-r--r-- | pkgs/applications/video/losslesscut-bin/build-from-dmg.nix | 5 | ||||
-rw-r--r-- | pkgs/applications/video/losslesscut-bin/default.nix | 20 |
2 files changed, 17 insertions, 8 deletions
diff --git a/pkgs/applications/video/losslesscut-bin/build-from-dmg.nix b/pkgs/applications/video/losslesscut-bin/build-from-dmg.nix index dac04e779e2b9..b9913867b198a 100644 --- a/pkgs/applications/video/losslesscut-bin/build-from-dmg.nix +++ b/pkgs/applications/video/losslesscut-bin/build-from-dmg.nix @@ -5,13 +5,14 @@ , pname , version , hash +, isAarch64 , metaCommon ? { } }: let pname = "losslesscut"; src = fetchurl { - url = "https://github.com/mifi/lossless-cut/releases/download/v${version}/LosslessCut-mac-x64.dmg"; + url = "https://github.com/mifi/lossless-cut/releases/download/v${version}/LosslessCut-mac-${if isAarch64 then "arm64" else "x64"}.dmg"; inherit hash; }; in @@ -30,7 +31,7 @@ stdenvNoCC.mkDerivation { ''; meta = metaCommon // (with lib; { - platforms = platforms.darwin; + platforms = singleton (if isAarch64 then "aarch64-darwin" else "x86_64-darwin"); mainProgram = "losslesscut"; }); } diff --git a/pkgs/applications/video/losslesscut-bin/default.nix b/pkgs/applications/video/losslesscut-bin/default.nix index 7d5f8fe1ddeae..267393ad0548d 100644 --- a/pkgs/applications/video/losslesscut-bin/default.nix +++ b/pkgs/applications/video/losslesscut-bin/default.nix @@ -6,7 +6,7 @@ let pname = "losslesscut"; - version = "3.46.2"; + version = "3.48.2"; metaCommon = with lib; { description = "The swiss army knife of lossless video/audio editing"; homepage = "https://mifi.no/losslesscut/"; @@ -15,31 +15,39 @@ let }; x86_64-appimage = callPackage ./build-from-appimage.nix { inherit pname version metaCommon; - hash = "sha256-p+HscYsChR90JHdYjurY4OOHgveGXbJomz1klBCsF2Q="; + hash = "sha256-5T5+eBVbyOI89YA9NMLWweHagD09RB3P03HFvaDAOZ8="; inherit (buildPackages) makeWrapper; }; x86_64-dmg = callPackage ./build-from-dmg.nix { inherit pname version metaCommon; - hash = "sha256-350MHWwyjCdvIv6W6lX6Hr6PLDiAwO/e+KW0yKi/Yoc="; + hash = "sha256-PzjE0oJOuPG0S+mA7pgNU3MRgaE2jAPxWEN9J4PfqMQ="; + isAarch64 = false; + }; + aarch64-dmg = callPackage ./build-from-dmg.nix { + inherit pname version metaCommon; + hash = "sha256-927CSczgFJcbBJm2cYXucFRidkGAtcowoLMlm2GTafc="; + isAarch64 = true; }; x86_64-windows = callPackage ./build-from-windows.nix { inherit pname version metaCommon; - hash = "sha256-48ifhvIWSPmmnBnW8tP7NeWPIWJYWNqGP925O50CAwQ="; + hash = "sha256-+isxkGKxW7H+IjuA5G4yXuvDmX+4UlsD8sXwoHxgLM8="; }; in ( - if hostPlatform.isDarwin then x86_64-dmg + if hostPlatform.system == "aarch64-darwin" then aarch64-dmg + else if hostPlatform.isDarwin then x86_64-dmg else if hostPlatform.isCygwin then x86_64-windows else x86_64-appimage ).overrideAttrs (oldAttrs: { passthru = (oldAttrs.passthru or { }) // { - inherit x86_64-appimage x86_64-dmg x86_64-windows; + inherit x86_64-appimage x86_64-dmg aarch64-dmg x86_64-windows; }; meta = oldAttrs.meta // { platforms = lib.unique ( x86_64-appimage.meta.platforms ++ x86_64-dmg.meta.platforms + ++ aarch64-dmg.meta.platforms ++ x86_64-windows.meta.platforms ); }; |