When built with Autotools, dbus installs a .pc file for libdbus into ${libdir}/pkg-config. It should ideally do the same in CMake builds, although if Windows people have never needed this functionality, that's far from being a high priority. The code would look something like this (part of a patch by Руслан Ижбулатов on Bug #75858): configure_file(${CMAKE_SOURCE_DIR}/../dbus-1.pc.in ${CMAKE_BINARY_DIR}/../dbus-1.pc @ONLY) install(FILES ${CMAKE_BINARY_DIR}/../dbus-1.pc DESTINATION ${EXPANDED_LIBDIR}/pkgconfig) Expanding all the variables in the .pc correctly would additionally require something like this: # Following Autotools naming, for substitution into *.pc, since we share # Autotools' *.pc.in files. set(bindir ${exec_prefix}/bin) set(datarootdir ${prefix}/${DATAROOTDIR}) set(datadir ${prefix}/${DATADIR}) set(sysconfdir ${prefix}/etc) set(dbus_daemondir ${bindir}) I have not tested the above, but maybe it already works. For bonus points you could let pkg-config perform the variable expansion so that the .pc file is relocatable, like it is on Autotools after fixing Bug #75858.
(In reply to Simon McVittie from comment #0) > When built with Autotools, dbus installs a .pc file for libdbus into > ${libdir}/pkg-config. It should ideally do the same in CMake builds ... and now it does. Fixed in 1.11.12 as part of #99721.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.