[Olsr-dev] Error compiling 0.5.6 rc4
Puissance MaXximum Online
(spam-protected)
Thu Jul 17 21:46:35 CEST 2008
> Hi,
> if you expect proper error analysis: you need to provide good info. As a rule
> of thumb: rubbish in - rubbish out.
OK :). So let's try "rubbish in" method ;) (hopping I'll receive a rubbish out :p)
First of all, I've to mention that I've "quickly" read all the archives till 2004 and found some usefull tips but:
-english isn't my mother tongue (but I think you've noticed this small detail reading my mail ;) )
-even if I'm involved in computer's stuff, I didn't understand everything :)...
-I've not found the "OLSRD page for dummies" (i'll maybe write it 8) - think I could be helpfull...)
-however I've found a working implementation of olsrd (0.5.0) for windows mobile and successfully test it on mobile 2003, 2006 on different devices (mostly iPaqs & HTCs). It works well and I can communicate with PC and eeePC (running olsrd 0.5.5).
-my goal: compile the new version for win32 and wince to have the same version running on all devices. It seams to be the only way to have the new compiled version for wince cause I don't find it on the Web (let me know if I'm wrong). In fact, at this time, I'm just an "end-user" who wanna be "up-to-date" :)...
> As a guess: You try to compile for windows-ce - but haven't found the "make
> OS=xxx" switch? The ./make/Makefile.* do not work as top level makefiles...
I've found the "make OS=wince" and the "make OS=win32" but I had the following message under cygwin:
"make: *** No targets specified and no makefile found. Stop."
But It was before discovering that I've some parameters to put in the PATH... :/
So, now:
I've setup cygwin with ALL packages and especially all devel packages (hundreds of MB...I don't know what's necessary...).
I've also download Cegcc 0.51.0 (cygwin-cegcc-cegcc-0.51.0-1.tar.gz and cygwin-cegcc-mingw32ce-0.51.0-1.tar.gz) and setup it in the opt directory (c:\cygwin\opt). Finally, I've got 2 subdirectories in opt: cegcc and mingw32ce.
After that, I put the directories in my path (export PATH=$PATH:/opt/cegcc/bin:/opt/mingw32ce/bin).
Finally, I've unpacked olsrd 0.5.0 version in my home directory in cygwin (c:\cygwin\home\administrator).
With the following commands, I've obtained the binaries...
make OS=win32
make install OS=win32
But after a "make clean", when I've tried "make OS=wince", I've got the following error message:
$ make OS=wince
make -C src/cfgparser
make[1]: Entering directory `/home/Administrateur/src/cfgparser'
cc -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wsign-
compare -O2 -g -MD -Isrc -I../../src -Isrc/win32 -Isrc/win32/ce -DWIN32 -DWINCE
-DMAKELIB -c -o olsrd_conf.o olsrd_conf.c
In file included from ../../src/olsr_protocol.h:50,
from olsrd_conf.h:46,
from olsrd_conf.c:52:
../../src/olsr_types.h:97: error: field `v6' has incomplete type
In file included from olsrd_conf.h:46,
from olsrd_conf.c:52:
../../src/olsr_protocol.h:235: error: field `neigh_addr' has incomplete type
../../src/olsr_protocol.h:271: error: field `addr' has incomplete type
../../src/olsr_protocol.h:312: error: field `addr' has incomplete type
../../src/olsr_protocol.h:346: error: field `addr' has incomplete type
../../src/olsr_protocol.h:347: error: field `netmask' has incomplete type
../../src/olsr_protocol.h:392: error: field `originator' has incomplete type
In file included from ../../src/olsr_cfg.h:93,
from olsrd_conf.h:47,
from olsrd_conf.c:52:
../../src/interfaces.h:133: error: field `int6_addr' has incomplete type
../../src/interfaces.h:134: error: field `int6_multaddr' has incomplete type
olsrd_conf.c: In function `olsrd_sanity_check_cnf':
olsrd_conf.c:188: error: `AF_INET6' undeclared (first use in this function)
olsrd_conf.c:188: error: (Each undeclared identifier is reported only once
olsrd_conf.c:188: error: for each function it appears in.)
olsrd_conf.c: In function `get_default_if_config':
olsrd_conf.c:487: error: storage size of 'in6' isn't known
olsrd_conf.c:499: error: `AF_INET6' undeclared (first use in this function)
olsrd_conf.c:500: error: invalid application of `sizeof' to incomplete type `in6
_addr'
olsrd_conf.c:503: error: invalid application of `sizeof' to incomplete type `in6
_addr'
olsrd_conf.c:487: warning: unused variable `in6'
olsrd_conf.c: In function `olsrd_print_cnf':
olsrd_conf.c:544: error: `AF_INET6' undeclared (first use in this function)
make[1]: *** [olsrd_conf.o] Error 1
make[1]: Leaving directory `/home/Administrateur/src/cfgparser'
make: *** [cfgparser] Error 2
So, in my home directory, I've deleted all the files exepted .bash_profile and .bashrc.I've unpacked the 0.5.6-rc4 version and, after a new "make clean" (uselesss ???) tried again the commands with the following results:
Make OS=win32
....
/usr/bin/ccache gcc -Wall -Wextra -Wold-style-definition -Wdeclaration-after-statement -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wsign-compare -Waggregate-return -Wmissing-noreturn -Wmissing-format-attribute -Wno-multichar -Wno-deprecated-declarations -Wendif-labels -Wwrite-strings -Wbad-function-cast -Wpointer-arith -Wcast-qual -Wnested-externs -Winline -Wdisabled-optimization -finline-functions-called-once -fomit-frame-pointer -finline-limit=350 -mno-cygwin -Isrc -DUSE_FPM -DWIN32 -D_WIN32_WINNT=0x0600 -I./src/win32 -DNDEBUG -c -o src/tc_set.o src/tc_set.c
src/tc_set.c: In function `olsr_calculate_tc_border':
src/tc_set.c:752: error: structure has no member named `in6_u'
src/tc_set.c:754: error: structure has no member named `in6_u'
src/tc_set.c:756: error: structure has no member named `in6_u'
src/tc_set.c:768: error: structure has no member named `in6_u'
src/tc_set.c:770: error: structure has no member named `in6_u'
src/tc_set.c:772: error: structure has no member named `in6_u'
make: *** [src/tc_set.o] Error 1
make clean
make OS=wince
/usr/bin/ccache gcc -Wall -Wextra -Wold-style-definition -Wdeclaration-after-statement -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wsign-compare -Waggregate-return -Wmissing-noreturn -Wmissing-format-attribute -Wno-multichar -Wno-deprecated-declarations -Wendif-labels -Wwrite-strings -Wbad-function-cast -Wpointer-arith -Wcast-qual -Wnested-externs -Winline -Wdisabled-optimization -finline-functions-called-once -fomit-frame-pointer -finline-limit=350 -Isrc -DUSE_FPM -DWIN32 -DWINCE -Isrc/win32 -Isrc/win32/ce -DNDEBUG -c -o src/common/avl.o src/common/avl.c
In file included from src/win32/netinet/in.h:46,
from src/olsr_types.h:87,
from src/ipcalc.h:44,
from src/common/avl.c:47:
/usr/lib/gcc/i686-pc-cygwin/3.4.4/../../../../include/w32api/winsock2.h:103:2: warning: #warning "fd_set and associated macros have been defined in sys/types.
This may cause runtime problems with W32 sockets"
In file included from src/win32/netinet/in.h:47,
from src/olsr_types.h:87,
from src/ipcalc.h:44,
from src/common/avl.c:47:
src/win32/ce/ws2tcpip.h:24: error: redefinition of `struct sockaddr_storage'
In file included from src/defs.h:46,
from src/ipcalc.h:45,
from src/common/avl.c:47:
src/win32/sys/time.h:90: error: conflicting types for 'nanosleep'
/usr/include/time.h:171: error: previous declaration of 'nanosleep' was here
src/win32/sys/time.h:90: error: conflicting types for 'nanosleep'
/usr/include/time.h:171: error: previous declaration of 'nanosleep' was here
In file included from src/defs.h:53,
from src/ipcalc.h:45,
from src/common/avl.c:47:
src/win32/unistd.h:49: error: conflicting types for 'srandom'
/usr/include/cygwin/stdlib.h:28: error: previous declaration of 'srandom' was here
src/win32/unistd.h:49: error: conflicting types for 'srandom'
/usr/include/cygwin/stdlib.h:28: error: previous declaration of 'srandom' was here
src/win32/unistd.h:50: error: conflicting types for 'random'
/usr/include/cygwin/stdlib.h:27: error: previous declaration of 'random' was here
src/win32/unistd.h:50: error: conflicting types for 'random'
/usr/include/cygwin/stdlib.h:27: error: previous declaration of 'random' was here
In file included from src/common/avl.c:47:
src/ipcalc.h:51: error: `INET6_ADDRSTRLEN' undeclared here (not in a function)
src/ipcalc.h:51: error: `INET_ADDRSTRLEN' undeclared here (not in a function)
make: *** [src/common/avl.o] Error 1
And I've also tried with all the versions present on your website with differents results... Sometimes, with the Win32 argument, it works and I can do the make install...
With the source code modified by Denis Martin (version 0.5.0), I've an error too... (http://lists.olsr.org/pipermail/olsr-dev/2007-May/000997.html)
$ make OS=wince
make -C src/cfgparser
make[1]: Entering directory `/home/Administrateur/src/cfgparser'
arm-wince-cegcc-gcc -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-dec
larations -Wsign-compare -O2 -g -MD -Isrc -I../../src -Isrc/win32 -Isrc/win32/c
e -I../../src/win32 -DWIN32 -DWINCE -D_WIN32_WINNT=0x0501 -DMAKELIB -c -o olsr
d_conf.o olsrd_conf.c
In file included from ../../src/win32/netinet/in.h:47,
from olsrd_conf.c:49:
/opt/cegcc/lib/gcc/arm-wince-cegcc/4.1.0/../../../../arm-wince-cegcc/lib/../incl
ude/w32api/winsock2.h:65: error: redefinition of 'struct fd_set'
make[1]: *** [olsrd_conf.o] Error 1
make[1]: Leaving directory `/home/Administrateur/src/cfgparser'
make: *** [cfgparser] Error 2
So, I think I've a stupid problem with cygwin... As you can see I'm a real gurru with Linux like systems... :(
Denis uses a small wrapper-dll to provide some UNIX style compatibility but he doesn't precise witch one. And he also doesn't explain what kind of modifications he does in the source code. So I don't know what I've to change in the new source code to obtained binaries that works under CE...
In fact, after reading the archives, I don't know what to do: Dave speaks about toolchain and Mandrake 10, Bruno about openembedded which can be used to easily create distributions and cross-compile for the ipaq and other embedded targets, Thomas about version compiles with the CE cross compiler that used to be hosted at mamaich.kasone.com (I don't find it...), etc... Searching a solution, I've also found another product:
Minimalist GNU for Windows. But I don't managed to get it working...
So... What's the simpliest way for a dummy like me to solve this problem ?
Thx
PS: my bison and flex are ok...
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.olsr.org/pipermail/olsr-dev/attachments/20080717/01deaac2/attachment.html>
More information about the Olsr-dev
mailing list