Compile error

Edmond Chu edmond25 at gmail.com
Wed Jul 8 02:35:20 PDT 2015


#if (defined(__linux__) && !defined(IPV6_PATHMTU))
/* for IPV6_PATHMTU */
# include <linux/in6.h>
#endif

syntax should be this? however, some error come out

   CC       worker-vpn.o
In file included from worker-vpn.c:51:
/usr/include/linux/in6.h:31: error: redefinition of ‘struct in6_addr’
/usr/include/linux/in6.h:48: error: redefinition of ‘struct sockaddr_in6’
/usr/include/linux/in6.h:56: error: redefinition of ‘struct ipv6_mreq’
make[4]: *** [worker-vpn.o] Error 1
make[4]: Leaving directory `/root/ocserv-0.10.6/src'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/root/ocserv-0.10.6/src'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/root/ocserv-0.10.6/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/root/ocserv-0.10.6'
make: *** [all] Error 2

2015-07-08 17:16 GMT+08:00 Edmond Chu <edmond25 at gmail.com>:
>   CC       worker-vpn.o
> worker-vpn.c:49:25: error: operator '&&' has no right operand
> make[4]: *** [worker-vpn.o] Error 1
> make[4]: Leaving directory `/root/ocserv-0.10.6/src'
> make[3]: *** [all-recursive] Error 1
> make[3]: Leaving directory `/root/ocserv-0.10.6/src'
> make[2]: *** [all] Error 2
> make[2]: Leaving directory `/root/ocserv-0.10.6/src'
> make[1]: *** [all-recursive] Error 1
> make[1]: Leaving directory `/root/ocserv-0.10.6'
> make: *** [all] Error 2
>
> I copy and paste you new amendment to worker-vpn.c. it prompts above
>
> 2015-07-08 17:01 GMT+08:00 Nikos Mavrogiannopoulos
> <n.mavrogiannopoulos at gmail.com>:
>> On Wed, Jul 8, 2015 at 3:58 AM, Edmond Chu <edmond25 at gmail.com> wrote:
>>> Hi,
>>> When I try to update OCSERV to lastest version 0.10.6 from 0.10.1, it
>>> prompts error as following:
>>
>> I realized the is a conflict in some versions of glibc. If you change
>> in worker-vpn.c the following
>>
>> #ifdef __linux__
>> /* for IPV6_PATHMTU */
>> # include <linux/in6.h>
>> #endif
>>
>> with
>>
>> #if defined(__linux__) && !defined(IPV6_PATHMTU)
>> /* for IPV6_PATHMTU */
>> # include <linux/in6.h>
>> #endif
>>
>> does it avoid the compilation error?



More information about the openconnect-devel mailing list