nixpkgs/pkgs/tools/graphics/gifski/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

54 lines
1.2 KiB
Nix
Raw Normal View History

{ lib
, rustPlatform
, fetchFromGitHub
, stdenv
, pkg-config
2023-06-20 13:14:00 +00:00
, ffmpeg
}:
2019-03-03 16:02:27 +00:00
rustPlatform.buildRustPackage rec {
2019-08-31 11:41:23 +00:00
pname = "gifski";
version = "1.11.0";
2019-03-03 16:02:27 +00:00
src = fetchFromGitHub {
owner = "ImageOptim";
repo = "gifski";
rev = version;
sha256 = "sha256-sPsq/hntNqOdPJcoob1jrDUrLLiBEnfRoDANyFUjOuM=";
2019-03-03 16:02:27 +00:00
};
cargoLock = {
lockFile = ./Cargo.lock;
outputHashes = {
"ffmpeg-sys-next-6.0.1" = "sha256-/KxW57lt9/qKqNUUZqJucsP0cKvZ1m/FdGCsZxBlxYc=";
};
};
2023-06-20 13:14:00 +00:00
nativeBuildInputs = [
pkg-config
rustPlatform.bindgenHook
];
buildInputs = [
ffmpeg
];
buildFeatures = [ "video" ];
# error: the crate `gifski` is compiled with the panic strategy `abort` which is incompatible with this crate's strategy of `unwind`
doCheck = !stdenv.isDarwin;
2019-03-03 16:02:27 +00:00
# error: linker `/usr/bin/x86_64-linux-gnu-gcc` not found
postPatch = ''
rm .cargo/config.toml;
'';
meta = with lib; {
2019-03-03 16:02:27 +00:00
description = "GIF encoder based on libimagequant (pngquant)";
2020-02-21 23:59:26 +00:00
homepage = "https://gif.ski/";
changelog = "https://github.com/ImageOptim/gifski/releases/tag/${src.rev}";
license = licenses.agpl3Plus;
maintainers = with maintainers; [ figsoda marsam ];
2019-03-03 16:02:27 +00:00
};
}