构建Qt 4.8支持QtDBus

问题描述:

我尝试从源代码编译Qt,除了dbus部分外,一切正常(或多或少)。构建Qt 4.8支持QtDBus

./configure -v -opensource -dbus-linked -arch i386

配置显示了这个错误:

1 error generated. make: * [dbus.o] Error 1 D-Bus disabled. The QtDBus module cannot be enabled because libdbus-1 version 0.93 was not found. Turn on verbose messaging (-v) to ./configure to see the final report. If you believe this message is in error you may use the continue switch (-continue) to ./configure to continue.

我安装DBUS 1.6与自制,但配置工具无法看到它。 Lib和头文件位于/usr/local/Cellar/d-bus/1.6.18。如何将配置指向此位置?

平台是OS X.

好这个问题似乎是,它没有找到DBUS库。

设置库的路径,当你配置,这样的事情包括,假设你的DBUS库和包括在 /usr/local/Cellar/d-bus/1.6.18

./configure -v -opensource -arch i386 -dbus-linked -L/usr/local/Cellar/d-bus/1.6.18/lib -I/usr/local/Cellar/d-bus/1.6.18/include

其中-I将告诉qmake包含来自该路径的头文件和-L以链接到dbus库。