fa5436e0a7
GitOrigin-RevId: e8057b67ebf307f01bdcc8fba94d94f75039d1f6
51 lines
1 KiB
Nix
51 lines
1 KiB
Nix
{
|
|
lib,
|
|
buildPythonPackage,
|
|
fetchPypi,
|
|
pefile,
|
|
pillow,
|
|
pythonOlder,
|
|
setuptools,
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "icoextract";
|
|
version = "0.1.5";
|
|
pyproject = true;
|
|
|
|
disabled = pythonOlder "3.8";
|
|
|
|
src = fetchPypi {
|
|
inherit pname version;
|
|
extension = "tar.gz";
|
|
hash = "sha256-/UxnWNyRNtwI4Rxx97i5QyjeMrUr5Sq+TfLTmU0xWyc=";
|
|
};
|
|
|
|
build-system = [ setuptools ];
|
|
|
|
dependencies = [
|
|
pefile
|
|
pillow
|
|
];
|
|
|
|
# tests expect mingw and multiarch
|
|
doCheck = false;
|
|
|
|
pythonImportsCheck = [ "icoextract" ];
|
|
|
|
postInstall = ''
|
|
mkdir -p $out/share/thumbnailers
|
|
substituteAll ${./exe-thumbnailer.thumbnailer} $out/share/thumbnailers/exe-thumbnailer.thumbnailer
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Extract icons from Windows PE files";
|
|
homepage = "https://github.com/jlu5/icoextract";
|
|
changelog = "https://github.com/jlu5/icoextract/blob/${version}/CHANGELOG.md";
|
|
license = licenses.mit;
|
|
maintainers = with maintainers; [
|
|
bryanasdev000
|
|
donovanglover
|
|
];
|
|
};
|
|
}
|