libdbusmenu: require glib-2.0 in pkg-config

libdbusmenu-glib has headers which include <glib.h>, but does not
declare glib as a dependency. This causes include errors if you try to
build with just libdbusmenu-glib.
This commit is contained in:
ralismark 2023-04-03 15:04:38 +10:00
parent 471eeab9dd
commit 3fe4a8820c
2 changed files with 15 additions and 0 deletions

View file

@ -27,6 +27,10 @@ stdenv.mkDerivation (finalAttrs: {
"3" = gtk3;
}.${gtkVersion} or (throw "unknown GTK version ${gtkVersion}");
patches = [
./requires-glib.patch
];
postPatch = ''
for f in {configure,ltmain.sh,m4/libtool.m4}; do
substituteInPlace $f \

View file

@ -0,0 +1,11 @@
--- a/libdbusmenu-glib/dbusmenu-glib-0.4.pc.in
+++ b/libdbusmenu-glib/dbusmenu-glib-0.4.pc.in
@@ -5,7 +5,7 @@
includedir=@includedir@
Cflags: -I${includedir}/libdbusmenu-glib-0.4
-Requires:
+Requires: glib-2.0
Libs: -L${libdir} -ldbusmenu-glib
Name: libdbusmenu-glib