at 25.11-pre 550 B view raw
1{ 2 lib, 3 stdenv, 4 buildPythonPackage, 5 pkgs, 6}: 7 8buildPythonPackage { 9 inherit (pkgs.file) pname version src; 10 11 patchPhase = '' 12 substituteInPlace python/magic.py --replace "find_library('magic')" "'${pkgs.file}/lib/libmagic${stdenv.hostPlatform.extensions.sharedLibrary}'" 13 ''; 14 15 buildInputs = [ pkgs.file ]; 16 17 preConfigure = "cd python"; 18 19 # No test suite 20 doCheck = false; 21 22 meta = with lib; { 23 description = "Python wrapper around libmagic"; 24 homepage = "http://www.darwinsys.com/file/"; 25 license = licenses.lgpl2; 26 }; 27}