[Olsr-dev] patches for FreeBSD
John Hay
(spam-protected)
Mon Jan 7 21:27:24 CET 2008
On Mon, Jan 07, 2008 at 09:11:43PM +0100, Bernd Petrovitsch wrote:
> On Mon, 2008-01-07 at 21:51 +0200, John Hay wrote:
> [...]
> > The latest code in cvs do not want to compile on FreeBSD. On FreeBSD
> > system include files are not necessarily self contained. So the order
>
> Well, I pushed the olsrd ones to become self contained. And the only way
> to force this is to put $file.h at the top of the #include list in
> $file.c.
> So one of the include files between the "+" and the "-" line (or one
> included by them) is not self contained. Should be trivial to figure it
> out from the compile error - even remotely.
>
> > might be important. This patch make things compile again.
>
> Yes, the order of the system's include files.
Well the compile messages looks like this:
gcc -O2 -fno-strict-aliasing -pipe -Isrc -DOLSRD_GLOBAL_CONF_FILE=\"/usr/local/etc/olsrd.conf\" -DNDEBUG -c -o src/routing_table.o src/routing_table.c
In file included from src/routing_table.h:45,
from src/routing_table.c:42:
/usr/include/net/route.h:50: error: field 'ro_dst' has incomplete type
/usr/include/net/route.h:58: error: expected specifier-qualifier-list before 'u_long'
/usr/include/net/route.h:64: error: expected specifier-qualifier-list before 'u_long'
In file included from /usr/include/net/route.h:99,
from src/routing_table.h:45,
from src/routing_table.c:42:
/usr/include/net/radix.h:54: error: expected specifier-qualifier-list before 'u_char'
/usr/include/net/radix.h:91: error: expected specifier-qualifier-list before 'u_char'
In file included from src/routing_table.h:45,
from src/routing_table.c:42:
/usr/include/net/route.h:111: error: expected specifier-qualifier-list before 'u_long'
/usr/include/net/route.h:131: error: expected specifier-qualifier-list before 'u_long'
/usr/include/net/route.h:191: error: expected specifier-qualifier-list before 'u_short'
gmake: *** [src/routing_table.o] Error 1
gcc -O2 -fno-strict-aliasing -pipe -Isrc -DOLSRD_GLOBAL_CONF_FILE=\"/usr/local/etc/olsrd.conf\" -DNDEBUG -c -o src/unix/ifnet.o src/unix/ifnet.c
In file included from src/ifnet.h:51,
from src/unix/ifnet.c:46:
/usr/include/net/if.h:284: error: field 'ifru_addr' has incomplete type
/usr/include/net/if.h:285: error: field 'ifru_dstaddr' has incomplete type
/usr/include/net/if.h:286: error: field 'ifru_broadaddr' has incomplete type
/usr/include/net/if.h:318: error: field 'ifra_addr' has incomplete type
/usr/include/net/if.h:319: error: field 'ifra_broadaddr' has incomplete type
/usr/include/net/if.h:320: error: field 'ifra_mask' has incomplete type
/usr/include/net/if.h:418: error: field 'addr' has incomplete type
/usr/include/net/if.h:419: error: field 'dstaddr' has incomplete type
gmake: *** [src/unix/ifnet.o] Error 1
John
--
John Hay -- (spam-protected) / (spam-protected)
More information about the Olsr-dev
mailing list