at 23.05-pre 41 lines 1.3 kB view raw
1{ lib, stdenv, fetchFromGitHub, qmake, qtbase, protobuf }: 2 3stdenv.mkDerivation rec { 4 pname = "qtpbfimageplugin"; 5 version = "2.3"; 6 7 src = fetchFromGitHub { 8 owner = "tumic0"; 9 repo = "QtPBFImagePlugin"; 10 rev = version; 11 sha256 = "063agzcrcihasqqk2yqxqxg9xknjs99y6vx3n1v7md7dqnfv4iva"; 12 }; 13 14 nativeBuildInputs = [ qmake ]; 15 buildInputs = [ qtbase protobuf ]; 16 17 dontWrapQtApps = true; 18 19 postPatch = '' 20 # Fix plugin dir 21 substituteInPlace pbfplugin.pro \ 22 --replace "\$\$[QT_INSTALL_PLUGINS]" "$out/$qtPluginPrefix" 23 '' + lib.optionalString stdenv.isDarwin '' 24 # Fix darwin build 25 substituteInPlace pbfplugin.pro \ 26 --replace '$$PROTOBUF/lib/libprotobuf-lite.a' '${protobuf}/lib/libprotobuf-lite.dylib' 27 ''; 28 29 meta = with lib; { 30 description = "Qt image plugin for displaying Mapbox vector tiles"; 31 longDescription = '' 32 QtPBFImagePlugin is a Qt image plugin that enables applications capable of 33 displaying raster MBTiles maps or raster XYZ online maps to also display PBF 34 vector tiles without (almost) any application modifications. 35 ''; 36 homepage = "https://github.com/tumic0/QtPBFImagePlugin"; 37 license = licenses.lgpl3Only; 38 maintainers = with maintainers; [ sikmir ]; 39 platforms = platforms.unix; 40 }; 41}