Re: use of bool in exported headers?

Previous thread: net-next-2.6 plans... by David Miller on Thursday, July 17, 2008 - 9:32 pm. (1 message)

Next thread: Re: wierd networking problem on 2.6.26 with e1000 by David Miller on Friday, July 18, 2008 - 12:12 am. (1 message)
From: Kumar Gala
Date: Thursday, July 17, 2008 - 11:28 pm

What's the rule with regards to use of 'bool' in a header exposed to  
user space apps?

We are getting the following compile error w/iptables because of bool  
in include/linux/netfilter/xt_sctp.h:

In file included from extensions/libip6t_sctp.c:24:
/home/seh/ltib_bsps/head/rootfs//usr/src/linux/include/linux/netfilter/ 
xt_sctp.h:68: error: expected '=', ',', ';', 'asm' or '__attribute__'  
before '__sctp_chunkmap_is_clear'
/home/seh/ltib_bsps/head/rootfs//usr/src/linux/include/linux/netfilter/ 
xt_sctp.h:80: error: expected '=', ',', ';', 'asm' or '__attribute__'  
before '__sctp_chunkmap_is_all_set'
extensions/libip6t_sctp.c: In function 'print_chunks':
extensions/libip6t_sctp.c:427: warning: implicit declaration of  
function '__sctp_chunkmap_is_clear'
extensions/libip6t_sctp.c:432: warning: implicit declaration of  
function '__sctp_chunkmap_is_all_set'
make: *** [extensions/libip6t_sctp_sh.o] Error 1
error: Bad exit status from /home/seh/ltib_bsps/head/tmp/rpm-tmp.23551  
(%build)

- k
--

From: Jan Engelhardt
Date: Friday, July 18, 2008 - 2:07 am

Use #include <stdbool.h> in userspace.
--

Previous thread: net-next-2.6 plans... by David Miller on Thursday, July 17, 2008 - 9:32 pm. (1 message)

Next thread: Re: wierd networking problem on 2.6.26 with e1000 by David Miller on Friday, July 18, 2008 - 12:12 am. (1 message)