编译libpcap报错 error: 'DBUS_ERROR_INIT' undeclared (first use in this function)

| No Comments | No TrackBacks

在老版本centos上用pcap4j,需要libpcap > 1.0.0, 系统pcap版本是0.9.x

编译libpcap的时候提示 error: 'DBUS_ERROR_INIT' undeclared (first use in this function)

查阅dbus源码之后直接在pcap-dbus.c头部增加一行

#define DBUS_ERROR_INIT { NULL, NULL, TRUE, 0, 0, 0, 0, NULL }

就可以编译通过了

make install 之后建议执行

dbus-uuidgen > /var/lib/dbus/machine-id

No TrackBacks

TrackBack URL: http://blog.suchasplus.com/mt/mt-tb.cgi/353

Leave a comment

About this Entry

This page contains a single entry by suchasplus published on May 13, 2016 8:40 PM.

MegaCli基本操作 was the previous entry in this blog.

推荐两款编程字体 is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.

Pages

OpenID accepted here Learn more about OpenID
Powered by Movable Type 5.2.7