about summary refs log tree commit diff
diff options
context:
space:
mode:
authorJan Tojnar <jtojnar@gmail.com>2018-07-22 00:41:45 +0200
committerGitHub <noreply@github.com>2018-07-22 00:41:45 +0200
commit710d4e76dd63b59707b7747cf8e9e970ae8bad8e (patch)
tree619a9cc5e8d0c41b43cebf687458d83b973d9348
parentbc4c0c4f4d5e6ec52a8001443c3fe6ce00220697 (diff)
parenta6dab86ada516b09096a77ff24b3b3291e80ef50 (diff)
downloadnixlib-710d4e76dd63b59707b7747cf8e9e970ae8bad8e.tar
nixlib-710d4e76dd63b59707b7747cf8e9e970ae8bad8e.tar.gz
nixlib-710d4e76dd63b59707b7747cf8e9e970ae8bad8e.tar.bz2
nixlib-710d4e76dd63b59707b7747cf8e9e970ae8bad8e.tar.lz
nixlib-710d4e76dd63b59707b7747cf8e9e970ae8bad8e.tar.xz
nixlib-710d4e76dd63b59707b7747cf8e9e970ae8bad8e.tar.zst
nixlib-710d4e76dd63b59707b7747cf8e9e970ae8bad8e.zip
Merge pull request #43868 from jtojnar/drop-geoclue1
Drop geoclue1 & geoclue2: 2.4.8 → 2.4.10
-rw-r--r--pkgs/development/libraries/geoclue/2.0.nix50
-rw-r--r--pkgs/development/libraries/geoclue/default.nix68
-rw-r--r--pkgs/top-level/all-packages.nix4
3 files changed, 45 insertions, 77 deletions
diff --git a/pkgs/development/libraries/geoclue/2.0.nix b/pkgs/development/libraries/geoclue/2.0.nix
deleted file mode 100644
index eb7a6d6aaf21..000000000000
--- a/pkgs/development/libraries/geoclue/2.0.nix
+++ /dev/null
@@ -1,50 +0,0 @@
-{ fetchurl, stdenv, intltool, pkgconfig, glib, json-glib, libsoup, geoip
-, dbus, dbus-glib, modemmanager, avahi, glib-networking, wrapGAppsHook, gobjectIntrospection
-}:
-
-with stdenv.lib;
-
-stdenv.mkDerivation rec {
-  name = "geoclue-2.4.8";
-
-  src = fetchurl {
-    url = "https://www.freedesktop.org/software/geoclue/releases/2.4/${name}.tar.xz";
-    sha256 = "08yg1r7m0n9hwyvcy769qkmkf8lslqwv69cjfffwnc3zm5km25qj";
-  };
-
-  outputs = [ "out" "dev" ];
-
-  nativeBuildInputs = [
-    pkgconfig intltool wrapGAppsHook gobjectIntrospection
-  ];
-
-  buildInputs = [ glib json-glib libsoup geoip
-     dbus dbus-glib avahi
-   ] ++ optionals (!stdenv.isDarwin) [ modemmanager ];
-
-  propagatedBuildInputs = [ dbus dbus-glib glib glib-networking ];
-
-  preConfigure = ''
-     substituteInPlace configure --replace "-Werror" ""
-  '';
-
-  configureFlags = [ "--with-systemdsystemunitdir=$(out)/etc/systemd/system" "--enable-introspection" ] ++
-                   optionals stdenv.isDarwin [
-                       "--disable-silent-rules"
-                       "--disable-3g-source"
-                       "--disable-cdma-source"
-                       "--disable-modem-gps-source"
-                       "--disable-nmea-source" ];
-
-  postInstall = ''
-    sed -i $dev/lib/pkgconfig/libgeoclue-2.0.pc -e "s|includedir=.*|includedir=$dev/include|"
-  '';
-
-  meta = with stdenv.lib; {
-    description = "Geolocation framework and some data providers";
-    homepage = https://freedesktop.org/wiki/Software/GeoClue/;
-    maintainers = with maintainers; [ raskin garbas ];
-    platforms = with platforms; linux ++ darwin;
-    license = licenses.lgpl2;
-  };
-}
diff --git a/pkgs/development/libraries/geoclue/default.nix b/pkgs/development/libraries/geoclue/default.nix
index bf0af502d017..2588d7f3d547 100644
--- a/pkgs/development/libraries/geoclue/default.nix
+++ b/pkgs/development/libraries/geoclue/default.nix
@@ -1,36 +1,56 @@
-{ stdenv, fetchurl, dbus, dbus-glib, glib, pkgconfig, libxml2, gnome2,
-  libxslt, glib-networking }:
+{ fetchurl, stdenv, intltool, pkgconfig, gtk-doc, docbook_xsl, docbook_xml_dtd_412, glib, json-glib, libsoup, libnotify, gdk_pixbuf
+, modemmanager, avahi, glib-networking, wrapGAppsHook, gobjectIntrospection
+, withDemoAgent ? false
+}:
+
+with stdenv.lib;
 
 stdenv.mkDerivation rec {
-  name = "geoclue-0.12.0";
+  name = "geoclue-${version}";
+  version = "2.4.10";
+
   src = fetchurl {
-    url = "https://launchpad.net/geoclue/trunk/0.12/+download/${name}.tar.gz";
-    sha256 = "15j619kvmdgj2hpma92mkxbzjvgn8147a7500zl3bap9g8bkylqg";
+    url = "https://www.freedesktop.org/software/geoclue/releases/${stdenv.lib.versions.majorMinor version}/${name}.tar.xz";
+    sha256 = "0h4n8jf7w457sglfdhghkyf8n4v4a5jrx8dgdy5zn35nbscx24l4";
   };
 
-  outputs = [ "out" "dev" ];
-
-  nativeBuildInputs = [ pkgconfig ];
-  buildInputs = [ libxml2 gnome2.GConf libxslt glib-networking ];
-
-  propagatedBuildInputs = [dbus glib dbus-glib];
-
-  hardeningDisable = [ "format" ];
-
-  preConfigure = ''
-    sed -e '/-Werror/d' -i configure
+  outputs = [ "out" "dev" "devdoc" ];
+
+  nativeBuildInputs = [
+    pkgconfig intltool gtk-doc docbook_xsl docbook_xml_dtd_412 wrapGAppsHook gobjectIntrospection
+  ];
+
+  buildInputs = [
+    glib json-glib libsoup avahi
+  ] ++ optionals withDemoAgent [
+    libnotify gdk_pixbuf
+  ] ++ optionals (!stdenv.isDarwin) [ modemmanager ];
+
+  propagatedBuildInputs = [ glib glib-networking ];
+
+  configureFlags = [
+    "--with-systemdsystemunitdir=$(out)/etc/systemd/system"
+    "--enable-introspection"
+    "--enable-gtk-doc"
+    "--enable-demo-agent=${if withDemoAgent then "yes" else "no"}"
+  ] ++ optionals stdenv.isDarwin [
+    "--disable-silent-rules"
+    "--disable-3g-source"
+    "--disable-cdma-source"
+    "--disable-modem-gps-source"
+    "--disable-nmea-source"
+  ];
+
+  # https://gitlab.freedesktop.org/geoclue/geoclue/issues/73
+  postInstall = ''
+    sed -i $dev/lib/pkgconfig/libgeoclue-2.0.pc -e "s|includedir=.*|includedir=$dev/include|"
   '';
 
   meta = with stdenv.lib; {
     description = "Geolocation framework and some data providers";
-    maintainers = with maintainers; [ raskin ];
-    platforms = platforms.linux;
+    homepage = https://gitlab.freedesktop.org/geoclue/geoclue/wikis/home;
+    maintainers = with maintainers; [ raskin garbas ];
+    platforms = with platforms; linux ++ darwin;
     license = licenses.lgpl2;
   };
-
-  passthru = {
-    updateInfo = {
-      downloadPage = "http://folks.o-hand.com/jku/geoclue-releases/";
-    };
-  };
 }
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index 81c4df8bdecd..2912dada4e99 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -9260,9 +9260,7 @@ with pkgs;
     gtk = self.gtk2;
   };
 
-  geoclue = callPackage ../development/libraries/geoclue {};
-
-  geoclue2 = callPackage ../development/libraries/geoclue/2.0.nix {};
+  geoclue2 = callPackage ../development/libraries/geoclue {};
 
   geoipWithDatabase = makeOverridable (callPackage ../development/libraries/geoip) {
     drvName = "geoip-tools";