From c4009cf979ec97a10cf6e9c7ccd792674c711878 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Sat, 26 Oct 2024 19:53:56 -0700 Subject: [PATCH] libsForQt5.mapbox-gl-qml: 2.1.1 -> 3.0.0 Diff: https://github.com/rinigus/mapbox-gl-qml/compare/2.1.1...3.0.0 Changelog: https://github.com/rinigus/mapbox-gl-qml/releases/tag/3.0.0 --- .../libraries/mapbox-gl-qml/default.nix | 58 +++++++++++-------- 1 file changed, 34 insertions(+), 24 deletions(-) diff --git a/pkgs/development/libraries/mapbox-gl-qml/default.nix b/pkgs/development/libraries/mapbox-gl-qml/default.nix index 1d068a90d3b3..ae5e06151d3a 100644 --- a/pkgs/development/libraries/mapbox-gl-qml/default.nix +++ b/pkgs/development/libraries/mapbox-gl-qml/default.nix @@ -1,38 +1,48 @@ -{ lib -, mkDerivation -, fetchFromGitHub -, cmake -, pkg-config -, curl -, qtbase -, qtlocation -, maplibre-gl-native +{ + cmake, + fetchFromGitHub, + lib, + maplibre-native-qt, + qtbase, + qtpositioning, + stdenv, }: -mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "mapbox-gl-qml"; - version = "2.1.1"; + version = "3.0.0"; src = fetchFromGitHub { owner = "rinigus"; repo = "mapbox-gl-qml"; - rev = version; - hash = "sha256-zZcD85nOZZ067FRvSuzE8lr2gyuVxpcZGp44D4ayc3Q="; + rev = "refs/tags/${finalAttrs.version}"; + hash = "sha256-csk3Uo+AdP1R/T/9gWyWmYFIKuen2jy8wYN3GJznyRE="; }; - nativeBuildInputs = [ cmake pkg-config ]; - buildInputs = [ curl qtlocation maplibre-gl-native ]; + nativeBuildInputs = [ + cmake + ]; - postPatch = '' - substituteInPlace src/CMakeLists.txt \ - --replace ' ''${QT_INSTALL_QML}' " $out/${qtbase.qtQmlPrefix}" - ''; + cmakeFlags = [ + (lib.cmakeFeature "QT_INSTALL_QML" "${placeholder "out"}/${qtbase.qtQmlPrefix}") + ]; - meta = with lib; { + buildInputs = [ + maplibre-native-qt + qtpositioning + ]; + + dontWrapQtApps = true; # library only + + meta = { + changelog = "https://github.com/rinigus/mapbox-gl-qml/releases/tag/${lib.removePrefix "refs/tags/" finalAttrs.src.rev}"; description = "Unofficial Mapbox GL Native bindings for Qt QML"; homepage = "https://github.com/rinigus/mapbox-gl-qml"; - license = licenses.lgpl3Only; - maintainers = with maintainers; [ Thra11 dotlambda ]; - platforms = platforms.linux; + license = lib.licenses.lgpl3Only; + maintainers = with lib.maintainers; [ + Thra11 + dotlambda + ]; + platforms = lib.platforms.linux; }; -} +})