mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-27 09:23:01 +00:00
foxtrotgps: 1.2.2 -> 1.2.2+326
This commit is contained in:
parent
f5f1fe152e
commit
d2527ed7da
@ -1,16 +1,32 @@
|
||||
{ fetchurl, stdenv, pkg-config, wrapGAppsHook, curl, gnome2, gpsd, gtk2
|
||||
{ stdenv, fetchbzr, autoreconfHook, texinfo, help2man, imagemagick, pkg-config
|
||||
, curl, gnome2, gpsd, gtk2, wrapGAppsHook
|
||||
, intltool, libexif, python3Packages, sqlite }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "foxtrotgps";
|
||||
version = "1.2.2";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.foxtrotgps.org/releases/foxtrotgps-${version}.tar.xz";
|
||||
sha256 = "0grn35j5kwc286dxx18fv32qa330xmalqliwy6zirxmj6dffvrkg";
|
||||
let
|
||||
srcs = {
|
||||
foxtrot = fetchbzr {
|
||||
url = "lp:foxtrotgps";
|
||||
rev = "326";
|
||||
sha256 = "191pgcy5rng8djy22a5z9s8gssc73f9p5hm4ig52ra189cb48d8k";
|
||||
};
|
||||
screenshots = fetchbzr {
|
||||
url = "lp:foxtrotgps/screenshots";
|
||||
rev = "2";
|
||||
sha256 = "1sgysn3dhfhrv7rj7wf8f2119vmhc1s1zzsp4r3nlrr45d20wmsv";
|
||||
};
|
||||
};
|
||||
in stdenv.mkDerivation rec {
|
||||
pname = "foxtrotgps";
|
||||
version = "1.2.2+326";
|
||||
|
||||
nativeBuildInputs = [ pkg-config wrapGAppsHook ];
|
||||
# Pull directly from bzr because gpsd API version 9 is not supported on latest release
|
||||
src = srcs.foxtrot;
|
||||
|
||||
patches = [
|
||||
./gps-status-fix.patch
|
||||
];
|
||||
|
||||
nativeBuildInputs = [ pkg-config autoreconfHook texinfo help2man imagemagick wrapGAppsHook ];
|
||||
|
||||
buildInputs = [
|
||||
curl.dev
|
||||
@ -22,7 +38,16 @@ stdenv.mkDerivation rec {
|
||||
sqlite.dev
|
||||
(python3Packages.python.withPackages (pythonPackages: with python3Packages;
|
||||
[ beautifulsoup4 feedparser sqlalchemy ]))
|
||||
];
|
||||
];
|
||||
|
||||
postUnpack = ''
|
||||
cp -R ${srcs.screenshots} $sourceRoot/doc/screenshots
|
||||
chmod -R u+w $sourceRoot/doc/screenshots
|
||||
'';
|
||||
|
||||
preConfigure = ''
|
||||
intltoolize --automake --copy --force
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "GPS/GIS application optimized for small screens";
|
||||
|
14
pkgs/applications/misc/foxtrotgps/gps-status-fix.patch
Normal file
14
pkgs/applications/misc/foxtrotgps/gps-status-fix.patch
Normal file
@ -0,0 +1,14 @@
|
||||
--- foxtrot/src/gps_functions.c.orig 2020-12-04 15:02:22.290163204 -0600
|
||||
+++ foxtrot/src/gps_functions.c 2020-12-04 15:04:54.470648534 -0600
|
||||
@@ -762,7 +762,11 @@
|
||||
{
|
||||
gpsdata->fix.time = (time_t) 0;
|
||||
}
|
||||
+#if GPSD_API_MAJOR_VERSION >= 9
|
||||
+ gpsdata->valid = (libgps_gpsdata.fix.status != STATUS_NO_FIX);
|
||||
+#else
|
||||
gpsdata->valid = (libgps_gpsdata.status != STATUS_NO_FIX);
|
||||
+#endif
|
||||
if (gpsdata->valid)
|
||||
{
|
||||
gpsdata->seen_valid = TRUE;
|
Loading…
Reference in New Issue
Block a user