2017-04-01 02:10:32 +02:00
|
|
|
{ fetchurl, stdenv, intltool, libintlOrEmpty, pkgconfig, glib, json_glib, libsoup, geoip
|
2015-12-12 14:26:46 +01:00
|
|
|
, dbus, dbus_glib, modemmanager, avahi
|
2013-10-29 16:23:24 +01:00
|
|
|
}:
|
|
|
|
|
2017-04-01 02:10:32 +02:00
|
|
|
with stdenv.lib;
|
|
|
|
|
2013-10-29 16:23:24 +01:00
|
|
|
stdenv.mkDerivation rec {
|
2016-04-11 19:40:03 +02:00
|
|
|
name = "geoclue-2.4.3";
|
2013-10-29 16:23:24 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
2015-12-12 14:26:46 +01:00
|
|
|
url = "http://www.freedesktop.org/software/geoclue/releases/2.4/${name}.tar.xz";
|
2016-04-11 19:40:03 +02:00
|
|
|
sha256 = "0pk07k65dlw37nz8z5spksivsv5nh96xmbi336rf2yfxf2ldpadd";
|
2013-10-29 16:23:24 +01:00
|
|
|
};
|
|
|
|
|
2017-09-22 05:23:52 +02:00
|
|
|
nativeBuildInputs = [
|
|
|
|
pkgconfig
|
|
|
|
];
|
|
|
|
|
2017-04-01 02:10:32 +02:00
|
|
|
buildInputs = libintlOrEmpty ++
|
2017-09-22 05:23:52 +02:00
|
|
|
[ intltool glib json_glib libsoup geoip
|
2017-04-01 02:10:32 +02:00
|
|
|
dbus dbus_glib avahi
|
|
|
|
] ++ optionals (!stdenv.isDarwin) [ modemmanager ];
|
2013-10-29 16:23:24 +01:00
|
|
|
|
|
|
|
preConfigure = ''
|
|
|
|
substituteInPlace configure --replace "-Werror" ""
|
|
|
|
'';
|
|
|
|
|
2017-04-01 02:10:32 +02:00
|
|
|
configureFlags = [ "--with-systemdsystemunitdir=$(out)/etc/systemd/system" ] ++
|
|
|
|
optionals stdenv.isDarwin [
|
|
|
|
"--disable-silent-rules"
|
|
|
|
"--disable-3g-source"
|
|
|
|
"--disable-cdma-source"
|
|
|
|
"--disable-modem-gps-source"
|
|
|
|
"--disable-nmea-source" ];
|
|
|
|
|
|
|
|
NIX_CFLAGS_COMPILE = optionalString stdenv.isDarwin " -lintl";
|
2015-04-10 17:02:57 +02:00
|
|
|
|
2013-10-29 16:23:24 +01:00
|
|
|
propagatedBuildInputs = [ dbus dbus_glib glib ];
|
|
|
|
|
2016-03-09 04:17:17 +01:00
|
|
|
meta = with stdenv.lib; {
|
2013-10-29 16:23:24 +01:00
|
|
|
description = "Geolocation framework and some data providers";
|
2016-03-09 04:17:17 +01:00
|
|
|
maintainers = with maintainers; [ raskin garbas ];
|
2017-04-01 02:10:32 +02:00
|
|
|
platforms = with platforms; linux ++ darwin;
|
2016-03-09 04:17:17 +01:00
|
|
|
license = licenses.lgpl2;
|
2013-10-29 16:23:24 +01:00
|
|
|
};
|
|
|
|
}
|