Errors of compiling NM-0.8.2-beta1
- From: cee1 <fykcee1 gmail com>
- To: networkmanager-list gnome org
- Cc: 孙海勇 <sunhy lemote com>
- Subject: Errors of compiling NM-0.8.2-beta1
- Date: Fri, 8 Oct 2010 17:21:42 +0800
Hi all,
I've checked out a source of 0.8.2-beta1, try to compile it, and encounter several problems. They can be classified as follows:
- Related to build system:
- To use "isblank" (src/nm-policy-hosts.c, src/nm-policy.c), needs to enable C99. (see "man blank")
- To use "isascii" (libnm-util/nm-setting-wireless-security.c, ...), needs to define _BSD_SOURCE. (see "man isascii")
- To use "kill" (src/nm-device.c, ...), needs to define _POSIX_SOURCE. (see "man 2 kill")
So (one way) to build 0.8.2-beta1 successfully, I need(before ./configure):
- export CFLAGS='-std=c99'
- export CPPFLAGS='-D_BSD_SOURCE -D_POSIX_SOURCE'
- Related to source code:
- To use "strcasecmp" (libnm-util/crypto.c), should include <strings.h>. (see "man strcasecmp")
- To use "struct ether_addr" (libnm-util/nm-setting-wireless.c), should include <net/ethernet.h>. (see "man ether_aton_r")
Apply "fix-headers.patch" in attachment will fix missed headers.
- Related to source code but has been fixed in master:
In src/dhcp-manager/nm-dhcp-dhclient.c, log_domain may have an undefined value.
If the compiler tells you "/usr/include/netlink/object.h:58: error: inline function ‘nl_object_priv’ declared but never defined", then need to replace "extern inline void * nl_object_priv(struct nl_object *obj);" in object.h with the following (according to newer version of libnl):
static inline void * nl_object_priv(struct nl_object *obj)
{
return obj;
}
Attachment:
fix-headers.patch
Description: Binary data
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]