depot/third_party/nixpkgs/pkgs/development/python-modules/libsixel/default.nix
Default email b450903751 Project import generated by Copybara.
GitOrigin-RevId: 74a1793c659d09d7cf738005308b1f86c90cb59b
2022-09-09 16:08:57 +02:00

30 lines
681 B
Nix

{ buildPythonPackage
, lib
, libsixel
}:
buildPythonPackage rec {
version = libsixel.version;
pname = "libsixel";
src = libsixel.src;
sourceRoot = "${src.name}/python";
prePatch = ''
substituteInPlace libsixel/__init__.py --replace \
'from ctypes.util import find_library' \
'find_library = lambda _x: "${lib.getLib libsixel}/lib/libsixel.so"'
'';
# no tests
doCheck = false;
pythonImportsCheck = [ "libsixel" ];
meta = with lib; {
description = "SIXEL graphics encoder/decoder implementation";
homepage = "https://github.com/libsixel/libsixel";
license = licenses.mit;
maintainers = with maintainers; [ rmcgibbo ];
};
}