[Tinyos-help] linking problem in Tossim
Matteo Andretto
andretto at dei.unipd.it
Fri Jan 26 02:49:50 PST 2007
Hi all,
I have a problem when I try to compile an application for Tossim
in TinyOs 2.
In linking phase I get this error message:
linking into shared object ./_TOSSIMmodule.so
g++ -shared -fPIC build/telosb/pytossim.o build/telosb/sim.o
build/telosb/tossim.o build/telosb/c-support.o -lstdc++ -o
_TOSSIMmodule.so
/usr/bin/ld: build/telosb/sim.o: Relocations in generic ELF (EM: 105)
build/telosb/sim.o: could not read symbols: File in wrong format
collect2: ld returned 1 exit status
make: *** [sim-exe] Error 1
I read lesson 11 of tutorial and Troubleshooting TOSSIM compilation,
but I can not solve this problem.
I use Python 2.4.3
Anyone has some ideas?
Thanks in advance
Matteo
P.S. I report all compilation output for completeness
bash-3.00$ make telosb sim
mkdir -p build/telosb
placing object files in build/telosb
writing XML schema to app.xml
compiling BlinkAppC to object file sim.o
ncc -c -shared -fPIC -o build/telosb/sim.o -g -O0 -O -tossim
-fnesc-nido-tosnodes=1000 -fnesc-simulate
-fnesc-nido-motenumber=sim_node\(\) -mdisable-hwmul -Wall -Wshadow
-DDEF_TOS_AM_GROUP=0xDA -Wnesc-all -target=telosb
-fnesc-cfile=build/telosb/app.c -board= -Wno-nesc-data-race
BlinkAppC.nc -fnesc-dump=components -fnesc-dump=variables
-fnesc-dump=constants -fnesc-dump=typedefs -fnesc-dump=interfacedefs
-fnesc-dump=tags -fnesc-dumpfile=app.xml
/opt/tinyos-2.x/tos/lib/timer/TransformCounterC.nc: In function
`TransformCounterC$0$CounterFrom$overflow':
/opt/tinyos-2.x/tos/lib/timer/TransformCounterC.nc:126: warning:
implicit declaration of function `sim_node'
/opt/tinyos-2.x/tos/lib/timer/VirtualizeTimerC.nc: In function
`__nesc_nido_resolve':
/opt/tinyos-2.x/tos/lib/timer/VirtualizeTimerC.nc:158: warning:
implicit declaration of function `strcmp'
/opt/tinyos-2.x/tos/chips/msp430/McuSleepC.nc: In function
`__nesc_nido_initialise':
/opt/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:228: warning: passing
arg 1 of `memset' discards qualifiers from pointer target type
/opt/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:229: warning: passing
arg 1 of `memset' discards qualifiers from pointer target type
/opt/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:230: warning: passing
arg 1 of `memset' discards qualifiers from pointer target type
/opt/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:231: warning: passing
arg 1 of `memset' discards qualifiers from pointer target type
/opt/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:232: warning: passing
arg 1 of `memset' discards qualifiers from pointer target type
/opt/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:266: warning: passing
arg 1 of `memset' discards qualifiers from pointer target type
/opt/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:267: warning: passing
arg 1 of `memset' discards qualifiers from pointer target type
/opt/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:273: warning: implicit
declaration of function `memcpy'
/opt/tinyos-2.x/tos/interfaces/Scheduler.nc: At top level:
/opt/tinyos-2.x/tos/lib/timer/VirtualizeTimerC.nc:152: warning:
`__nesc_nido_resolve' defined but not used
/opt/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:222: warning:
`__nesc_nido_initialise' defined but not used
compiling Python support and C libraries into pytossim.o, tossim.o,
and c-support.o
g++ -c -shared -fPIC -o build/telosb/pytossim.o -g -O0 -O
/opt/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx
-I/usr/include/python2.4 -I/opt/tinyos-2.x/tos/lib/tossim
-DHAVE_CONFIG_H
g++ -c -shared -fPIC -o build/telosb/tossim.o -g -O0 -O
/opt/tinyos-2.x/tos/lib/tossim/tossim.c -I/usr/include/python2.4
-I/opt/tinyos-2.x/tos/lib/tossim
g++ -c -shared -fPIC -o build/telosb/c-support.o -g -O0 -O
/opt/tinyos-2.x/tos/lib/tossim/hashtable.c -I/usr/include/python2.4
-I/opt/tinyos-2.x/tos/lib/tossim
linking into shared object ./_TOSSIMmodule.so
g++ -shared -fPIC build/telosb/pytossim.o build/telosb/sim.o
build/telosb/tossim.o build/telosb/c-support.o -lstdc++ -o
_TOSSIMmodule.so
/usr/bin/ld: build/telosb/sim.o: Relocations in generic ELF (EM: 105)
build/telosb/sim.o: could not read symbols: File in wrong format
collect2: ld returned 1 exit status
make: *** [sim-exe] Error 1
bash-3.00$
More information about the Tinyos-help
mailing list