summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Tojnar <jtojnar@gmail.com>2025-03-01 19:37:09 +0100
committerJan Tojnar <jtojnar@gmail.com>2026-01-19 01:21:10 +0100
commit7b66a35a142664d3b5080415efe90366bd107032 (patch)
treee5726fddc68ba5adc958029da228bd398ecba04a
parentf82cda2388c1a47a72d4ea44ff04086d7b241d2d (diff)
dbus: Reorder attributes
Move `postPatch` to the bottom and `outputs` to the top as per https://github.com/jtojnar/nixpkgs-hammering/blob/main/explanations/attribute-ordering.md
-rw-r--r--pkgs/by-name/db/dbus/package.nix48
1 files changed, 25 insertions, 23 deletions
diff --git a/pkgs/by-name/db/dbus/package.nix b/pkgs/by-name/db/dbus/package.nix
index 637f22a3ab5b..5bdb41a9b955 100644
--- a/pkgs/by-name/db/dbus/package.nix
+++ b/pkgs/by-name/db/dbus/package.nix
@@ -22,29 +22,6 @@ stdenv.mkDerivation rec {
pname = "dbus";
version = "1.14.10";
- src = fetchurl {
- url = "https://dbus.freedesktop.org/releases/dbus/dbus-${version}.tar.xz";
- sha256 = "sha256-uh8h0r2dM52i1KqHgMCd8y/qh5mLc9ok9Jq53x42pQ8=";
- };
-
- patches = lib.optional stdenv.hostPlatform.isSunOS ./implement-getgrouplist.patch;
-
- postPatch = ''
- substituteInPlace bus/Makefile.am \
- --replace 'install-data-hook:' 'disabled:' \
- --replace '$(mkinstalldirs) $(DESTDIR)$(localstatedir)/run/dbus' ':'
- substituteInPlace tools/Makefile.am \
- --replace 'install-data-local:' 'disabled:' \
- --replace 'installcheck-local:' 'disabled:'
- ''
- # cleanup of runtime references
- + ''
- substituteInPlace ./dbus/dbus-sysdeps-unix.c \
- --replace 'DBUS_BINDIR "/dbus-launch"' "\"$lib/bin/dbus-launch\""
- substituteInPlace ./tools/dbus-launch.c \
- --replace 'DBUS_DAEMONDIR"/dbus-daemon"' '"/run/current-system/sw/bin/dbus-daemon"'
- '';
-
outputs = [
"out"
"dev"
@@ -52,9 +29,18 @@ stdenv.mkDerivation rec {
"doc"
"man"
];
+
separateDebugInfo = true;
+ src = fetchurl {
+ url = "https://dbus.freedesktop.org/releases/dbus/dbus-${version}.tar.xz";
+ sha256 = "sha256-uh8h0r2dM52i1KqHgMCd8y/qh5mLc9ok9Jq53x42pQ8=";
+ };
+
+ patches = lib.optional stdenv.hostPlatform.isSunOS ./implement-getgrouplist.patch;
+
strictDeps = true;
+
nativeBuildInputs = [
autoreconfHook
autoconf-archive
@@ -121,6 +107,22 @@ stdenv.mkDerivation rec {
"datadir=${placeholder "out"}/share"
];
+ postPatch = ''
+ substituteInPlace bus/Makefile.am \
+ --replace 'install-data-hook:' 'disabled:' \
+ --replace '$(mkinstalldirs) $(DESTDIR)$(localstatedir)/run/dbus' ':'
+ substituteInPlace tools/Makefile.am \
+ --replace 'install-data-local:' 'disabled:' \
+ --replace 'installcheck-local:' 'disabled:'
+ ''
+ # cleanup of runtime references
+ + ''
+ substituteInPlace ./dbus/dbus-sysdeps-unix.c \
+ --replace 'DBUS_BINDIR "/dbus-launch"' "\"$lib/bin/dbus-launch\""
+ substituteInPlace ./tools/dbus-launch.c \
+ --replace 'DBUS_DAEMONDIR"/dbus-daemon"' '"/run/current-system/sw/bin/dbus-daemon"'
+ '';
+
# it's executed from $lib by absolute path
postFixup = ''
moveToOutput bin/dbus-launch "$lib"