1 |
Today I have tried to merge openswan-2.4-14 into my ~x86 system. The |
2 |
compilation failed because of a name clash: |
3 |
|
4 |
cc -I. -I/home/ta/tmp/openswan-2.4.14.orig/linux/net/ipsec |
5 |
-I/home/ta/tmp/openswan-2.4.14.orig/linux/include |
6 |
-I/home/ta/tmp/openswan-2.4.14.orig -DDEBUG -DWITH_UDPFROMTO |
7 |
-DHAVE_IP_PKTINFO -I/home/ta/tmp/openswan-2.4.14.orig/include -g -O3 |
8 |
-DDISABLE_UDP_CHECKSUM -Wall -Wpointer-arith -Wcast-qual |
9 |
-Wstrict-prototypes -Wbad-function-cast -DNAT_TRAVERSAL -c -o |
10 |
optionsfrom.o optionsfrom.c |
11 |
optionsfrom.c:34: error: conflicting types for 'getline' |
12 |
/usr/include/stdio.h:651: error: previous declaration of 'getline' was here |
13 |
make[2]: *** [optionsfrom.o] Error 1 |
14 |
make[2]: Leaving directory |
15 |
`/home/ta/tmp/openswan-2.4.14.orig/lib/libopenswan' |
16 |
make[1]: *** [programs] Error 1 |
17 |
make[1]: Leaving directory `/home/ta/tmp/openswan-2.4.14.orig/lib' |
18 |
make: *** [programs] Error 1 |
19 |
|
20 |
The getline function is implemented in the optionsfrom.c source file in |
21 |
the openswan distribution. But the same function is implemented in glibc |
22 |
as well, but has a different signature and return code. It seems it is |
23 |
best to rename the getline function to something else to resolve this. |
24 |
Attached is a patch that renames all insances of getline to osw_getline. |
25 |
|
26 |
-- |
27 |
Timur |