Skip to content

Commit

Permalink
subsurface: 5.0.2 -> 5.0.10 (#202145)
Browse files Browse the repository at this point in the history
* subsurface: 5.0.2 -> 5.0.10

* override version detection

(cherry picked from commit 689f590)
  • Loading branch information
peterhoeg authored and schmittlauch committed Dec 2, 2022
1 parent 6f87491 commit db7a359
Show file tree
Hide file tree
Showing 2 changed files with 56 additions and 16 deletions.
70 changes: 55 additions & 15 deletions pkgs/applications/misc/subsurface/default.nix
Original file line number Diff line number Diff line change
@@ -1,17 +1,38 @@
{ lib, stdenv, fetchFromGitHub, autoreconfHook, cmake, wrapQtAppsHook, pkg-config, qmake
, curl, grantlee, libgit2, libusb-compat-0_1, libssh2, libxml2, libxslt, libzip, zlib
, qtbase, qtconnectivity, qtlocation, qtsvg, qttools, qtwebkit, libXcomposite
{ lib
, stdenv
, fetchFromGitHub
, autoreconfHook
, writeShellScriptBin
, cmake
, wrapQtAppsHook
, pkg-config
, qmake
, curl
, grantlee
, libgit2
, libssh2
, libxml2
, libxslt
, libzip
, zlib
, qtbase
, qtconnectivity
, qtlocation
, qtsvg
, qttools
, qtwebengine
, libXcomposite
, bluez
}:

let
version = "5.0.2";
version = "5.0.10";

subsurfaceSrc = (fetchFromGitHub {
owner = "Subsurface";
repo = "subsurface";
rev = "v${version}";
sha256 = "1yay06m8p9qp2ghrg8dxavdq55y09apcgdnb7rihgs3hq86k539n";
hash = "sha256-KzUBhFGvocaS1VrVT2stvKrj3uVxYka+dyYZUfkIoNs=";
fetchSubmodules = true;
});

Expand All @@ -21,7 +42,7 @@ let

src = subsurfaceSrc;

prePatch = "cd libdivecomputer";
sourceRoot = "source/libdivecomputer";

nativeBuildInputs = [ autoreconfHook ];

Expand All @@ -30,7 +51,7 @@ let
enableParallelBuilding = true;

meta = with lib; {
homepage = "http://www.libdivecomputer.org";
homepage = "https://www.libdivecomputer.org";
description = "A cross-platform and open source library for communication with dive computers from various manufacturers";
maintainers = with maintainers; [ mguentner ];
license = licenses.lgpl21;
Expand All @@ -40,14 +61,13 @@ let

googlemaps = stdenv.mkDerivation rec {
pname = "googlemaps";

version = "2021-03-19";
version = "0.0.0.2";

src = fetchFromGitHub {
owner = "vladest";
repo = "googlemaps";
rev = "8f7def10c203fd3faa5ef96c5010a7294dca0759";
sha256 = "1irz398g45hk6xizwzd07qcx1ln8f7l6bhjh15f56yc20waqpx1x";
rev = "v.${version}";
hash = "sha256-PfSLFQeCeVNcCVDCZehxyNLQGT6gff5jNxMW8lAaP8c=";
};

nativeBuildInputs = [ qmake ];
Expand All @@ -74,17 +94,37 @@ let
};
};

in stdenv.mkDerivation {
get-version = writeShellScriptBin "get-version" ''
echo -n ${version}
'';

in
stdenv.mkDerivation {
pname = "subsurface";
inherit version;

src = subsurfaceSrc;

postPatch = ''
install -m555 -t scripts ${lib.getExe get-version}
'';

buildInputs = [
libdc googlemaps
curl grantlee libgit2 libssh2 libusb-compat-0_1 libxml2 libxslt libzip
qtbase qtconnectivity qtsvg qttools qtwebkit
bluez
curl
googlemaps
grantlee
libdc
libgit2
libssh2
libxml2
libxslt
libzip
qtbase
qtconnectivity
qtsvg
qttools
qtwebengine
];

nativeBuildInputs = [ cmake wrapQtAppsHook pkg-config ];
Expand Down
2 changes: 1 addition & 1 deletion pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -11694,7 +11694,7 @@ with pkgs;

subgit = callPackage ../applications/version-management/git-and-tools/subgit { };

subsurface = libsForQt514.callPackage ../applications/misc/subsurface { };
subsurface = libsForQt5.callPackage ../applications/misc/subsurface { };

sudo = callPackage ../tools/security/sudo { };

Expand Down

0 comments on commit db7a359

Please sign in to comment.