1{ 2 lib, 3 stdenv, 4 boost, 5 buildPythonPackage, 6 exiv2, 7 fetchPypi, 8 pythonOlder, 9}: 10 11buildPythonPackage rec { 12 pname = "py3exiv2"; 13 version = "0.12.0"; 14 format = "setuptools"; 15 16 disabled = pythonOlder "3.7"; 17 18 src = fetchPypi { 19 inherit pname version; 20 hash = "sha256-crI+X3YMRzPPmpGNsI2U+9bZgwcR0qTowJuPNFY/Ooo="; 21 }; 22 23 buildInputs = [ 24 boost 25 exiv2 26 ]; 27 28 # Work around Python distutils compiling C++ with $CC (see issue #26709) 29 env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.hostPlatform.isDarwin "-I${lib.getInclude stdenv.cc.libcxx}/include/c++/v1"; 30 31 pythonImportsCheck = [ "pyexiv2" ]; 32 33 # Tests are not shipped 34 doCheck = false; 35 36 meta = with lib; { 37 broken = stdenv.hostPlatform.isDarwin; 38 description = "Python binding to the library exiv2"; 39 homepage = "https://launchpad.net/py3exiv2"; 40 license = licenses.gpl3Plus; 41 maintainers = with maintainers; [ vinymeuh ]; 42 platforms = with platforms; linux ++ darwin; 43 }; 44}