[Tinyos-help] can't Blink with 'make micaz sim '

Mr. Jonathan A. Gomez jon.gomez.04 at cnu.edu
Mon Dec 11 08:16:49 PST 2006


Hmm... I don't know anything about compiling TOSSIM, but I do understand some of the meaning of 
your error messages:

You got a lot of lines like

>build/micaz/sim.o(.text+0x2f86): In function `sim_log_add_channel':
>/opt/tinyos-2.x/tos/lib/tossim/sim_log.c:166: undefined reference to
>`_hashtable_search'

In other words, there is a dependency in sim.o, which uses but doesn't define the 
hashtable_search function.  It's not linking because it is missing the hashtable function.  In 
my copy of the TinyOS-2.x cvs, there is a file called hashtable.c in the tos/lib/tossim 
directory which defines these.  I don't know if you have such a file in your version.  At any 
rate, looking at the command being passed to g++, it doesn't seem that this file is being 
included.

This was the command which generated your errors (all the rest just spit out warnings):

g++ -fpic -shared -W1,--enable-auto-image-base  build/micaz/pytossim.o build/micaz/sim.o 
build/micaz/tossim.o -L/usr/lib/python2.3/config -lpython2.3-lstdc++ -o _TOSSIM.dll

I hesitate to say that this will help, since I haven't even tried to compile the program myself, 
but it might help to insert 'hashtable.c' in the arguments if you have the file, right before 
the first 'build/...'.  Perhaps?

I might try to do the compilation, just to see if I can't reproduce your problem.  Then I might 
be able to be more helpful.


Now the Java problem:

>$ $CLASSPATH
>bash: C:\tinyos\cyg\opt\tinyos-2.x\support\sdk\java\tinyos.jar;.:
>command not found

It thinks you're trying to run the classpath as a command.  When you want to change the 
classpath for Java, at least Sun Java, you can do something such as
  java -cp $CLASSPATH program
In which case, java is the command, -cp means set the classpath, etc.


-- Jon.


More information about the Tinyos-help mailing list