From 073206c8e017533f76418ba180db35021a46d6f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Sun, 27 Mar 2022 15:19:27 +0200 Subject: [PATCH 1/4] libgpod: reduce propagated libraries, cleanup --- .../development/libraries/libgpod/default.nix | 51 ++++++++++++++----- 1 file changed, 37 insertions(+), 14 deletions(-) diff --git a/pkgs/development/libraries/libgpod/default.nix b/pkgs/development/libraries/libgpod/default.nix index e56e512931a0..590aaf27c5f0 100644 --- a/pkgs/development/libraries/libgpod/default.nix +++ b/pkgs/development/libraries/libgpod/default.nix @@ -1,10 +1,23 @@ -{ stdenv, lib, fetchurl, perlPackages, intltool, autoreconfHook, - pkg-config, glib, libxml2, sqlite, zlib, sg3_utils, gdk-pixbuf, taglib, - libimobiledevice, - monoSupport ? false, mono, gtk-sharp-2_0 +{ stdenv +, lib +, fetchurl +, perlPackages +, intltool +, autoreconfHook +, pkg-config +, glib +, libxml2 +, sqlite +, zlib +, sg3_utils +, gdk-pixbuf +, taglib +, libimobiledevice +, monoSupport ? false +, mono +, gtk-sharp-2_0 }: - stdenv.mkDerivation rec { pname = "libgpod"; version = "0.8.3"; @@ -27,20 +40,30 @@ stdenv.mkDerivation rec { "--with-udev-dir=${placeholder "out"}/lib/udev" ] ++ lib.optionals monoSupport [ "--with-mono" ]; - dontStrip = true; - - propagatedBuildInputs = [ glib libxml2 sqlite zlib sg3_utils - gdk-pixbuf taglib libimobiledevice ]; + dontStrip = monoSupport; nativeBuildInputs = [ autoreconfHook intltool pkg-config ] ++ (with perlPackages; [ perl XMLParser ]) - ++ lib.optionals monoSupport [ mono gtk-sharp-2_0 ]; + ++ lib.optional monoSupport mono; - meta = { - homepage = "https://gtkpod.sourceforge.net/"; + buildInputs = [ + libxml2 + sg3_utils + sqlite + taglib + ] ++ lib.optional monoSupport gtk-sharp-2_0; + + propagatedBuildInputs = [ + gdk-pixbuf + glib + libimobiledevice + ]; + + meta = with lib; { + homepage = "https://sourceforge.net/projects/gtkpod/"; description = "Library used by gtkpod to access the contents of an ipod"; - license = "LGPL"; - platforms = lib.platforms.gnu ++ lib.platforms.linux; + license = licenses.lgpl21Plus; + platforms = platforms.linux; maintainers = [ ]; }; } From a9ab92ee1271b41369a0cc58fa8af5685042b7ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Sun, 27 Mar 2022 15:19:42 +0200 Subject: [PATCH 2/4] gtkpod: fix build --- pkgs/applications/audio/gtkpod/default.nix | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/audio/gtkpod/default.nix b/pkgs/applications/audio/gtkpod/default.nix index 61484bc2fbb1..e741f6fe2982 100644 --- a/pkgs/applications/audio/gtkpod/default.nix +++ b/pkgs/applications/audio/gtkpod/default.nix @@ -1,6 +1,7 @@ -{ lib, stdenv, fetchurl, pkg-config, wrapGAppsHook, intltool, libgpod, curl, flac, - gnome, gtk3, gettext, perlPackages, flex, libid3tag, gdl, - libvorbis, gdk-pixbuf }: +{ lib, stdenv, fetchurl, pkg-config, wrapGAppsHook, intltool, libgpod, libxml2, curl, flac +, gnome, gtk3, gettext, perlPackages, flex, libid3tag, gdl +, libvorbis, gdk-pixbuf +}: stdenv.mkDerivation rec { version = "2.1.5"; @@ -14,7 +15,7 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ pkg-config wrapGAppsHook intltool ]; buildInputs = [ curl gettext - flex libgpod libid3tag flac libvorbis gtk3 gdk-pixbuf + flex libgpod libid3tag flac libvorbis libxml2 gtk3 gdk-pixbuf gdl gnome.adwaita-icon-theme gnome.anjuta ] ++ (with perlPackages; [ perl XMLParser ]); From 8e0f6609c3086522314b967218005a7c7fc7b923 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Sun, 27 Mar 2022 15:20:05 +0200 Subject: [PATCH 3/4] libgda: remove `? null` from inputs --- pkgs/development/libraries/libgda/default.nix | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/pkgs/development/libraries/libgda/default.nix b/pkgs/development/libraries/libgda/default.nix index a9993b7255a9..59d1f0830bc3 100644 --- a/pkgs/development/libraries/libgda/default.nix +++ b/pkgs/development/libraries/libgda/default.nix @@ -17,14 +17,11 @@ , autoconf-archive , yelp-tools , mysqlSupport ? false -, libmysqlclient ? null +, libmysqlclient , postgresSupport ? false -, postgresql ? null +, postgresql }: -assert mysqlSupport -> libmysqlclient != null; -assert postgresSupport -> postgresql != null; - stdenv.mkDerivation rec { pname = "libgda"; version = "5.2.10"; From 9f034e5d188ca856c6d84e1dfecefc455da6fd02 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Sun, 27 Mar 2022 15:20:18 +0200 Subject: [PATCH 4/4] libgda: propagate libxml2 --- pkgs/development/libraries/libgda/default.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkgs/development/libraries/libgda/default.nix b/pkgs/development/libraries/libgda/default.nix index 59d1f0830bc3..e29482a34d4e 100644 --- a/pkgs/development/libraries/libgda/default.nix +++ b/pkgs/development/libraries/libgda/default.nix @@ -43,7 +43,6 @@ stdenv.mkDerivation rec { pkg-config intltool itstool - libxml2 gobject-introspection vala autoreconfHook @@ -62,6 +61,10 @@ stdenv.mkDerivation rec { postgresql ]; + propagatedBuildInputs = [ + libxml2 + ]; + configureFlags = [ "--with-mysql=${if mysqlSupport then "yes" else "no"}" "--with-postgres=${if postgresSupport then "yes" else "no"}"