I'm ccing this back to the list because
I'm currently incompetent with Linux...

Presumeably /usr/bin/java is a link to
  /usr/lib/jvm/java-6-sun/jre/bin/java?

The point of the exercise is to validate that the java you run
is the one that TOS thinks it has installed, and that the libs
are actually usable. I don't see any listing in your jre/bin for
the JNI libs, which are conveniently unnamed in the error message:
  .... Possibly TOSComm.so and getenv.so ....

It's also possible that there is a separate JRE or JDK/bin (Widows
seems to like to install TWO of the same thing just to keep any
remotely sophisticated user on h{is,er} toes).

Beyond that I am out of suggestions.
MS



Sarah Greenberg wrote:
> here's type java:
> 
> sa...@sarah-laptop:~$ type java
> java is /usr/bin/java
> 
> 
> here's java -version:
> 
> sa...@sarah-laptop:~$ java -version
> java version "1.6.0_14"
> Java(TM) SE Runtime Environment (build 1.6.0_14-b08)
> Java HotSpot(TM) Client VM (build 14.0-b16, mixed mode, sharing)
> 
> here's ls -la on /usr/lib/jvm/java-6-sun/jre/bin:
> 
> sa...@sarah-laptop:/usr/lib/jvm/java-6-sun/jre/bin$ ls -la
> ...
> -rwxr-xr-x 1 root root      8 2009-08-21 05:25 java
> ...
> 
> Thanks MS, I hadn't thought of these tips yet. I should have included this 
> info in my original email.
> 
> -s
> 
> 
> --- On Fri, 8/21/09, Michael Schippling <[email protected]> wrote:
> 
>> From: Michael Schippling <[email protected]>
>> Subject: Re: [Tinyos-help] TOS 2.1 install java tools question
>> To: "Sarah Greenberg" <[email protected]>
>> Cc: [email protected]
>> Date: Friday, August 21, 2009, 11:24 AM
>> Try "type java" to see if you are
>> executing the Java version
>> in which you have installed the JNI libs. Also I think the
>> libs need to be executable so check their permissions.
>>
>> MS
>>
>> Sarah Greenberg wrote:
>>> Hello,
>>>
>>> I've just installed TinyOS 2.1 on Hardy Linux. I'm
>> trying to do the printf tutorial, but when I use:
>>> $java net.tinyos.tools.PrintfClient -comm
>> serial@/dev/ttyUSB0:telosb
>>> I get the error:
>>>
>>> Thread[Thread-1,5,main]The toscomm JNI library was not
>> found.
>>> Check that your tinyos-tools package is installed and
>> try
>>> rerunning tos-install-jni.
>>> Aborting.
>>>
>>> I have done:
>>>
>>> $sudo tos-install-jni
>>> [sudo] password for sarah: Installing 32-bit Java JNI
>> code in /usr/lib/jvm/java-1.5.0-sun/jre/lib/i386 ... done.
>>> But I still receive the same "try rerunning
>> tos-install-jni" notification when trying to use tools
>> (Listen, PrintfClient).
>>>
>>> I have installed the sun-java6-jre package, and
>> changed the link in /etc/alternatives/java to
>> usr/lib/jvm/java-6-sun/jre/bin/java
>>> Here's the ls -la of that directory:
>>>
>>> sa...@sarah-laptop:/etc/alternatives$ls -la
>>> ....
>>> lrwxrwxrwx   1 root root   
>> 36 2009-08-21 01:12 java ->
>> /usr/lib/jvm/java-6-sun/jre/bin/java
>>> ....
>>>
>>>
>>> I also have libtoscomm-32.so libtoscomm.so
>> libgetenv-32.so and libgetenv.so
>>>   in /usr/lib/jvm/java-1.5.0-sun/jre/lib/i386
>>>
>>>
>> sa...@sarah-laptop:/usr/lib/jvm/java-1.5.0-sun/jre/lib/i386$
>> ls
>>> ....
>>> libgetenv-32.so
>>> libgetenv.so
>>> ....
>>> libtosscom-32.so
>>> listosscom.so
>>> .....
>>>
>>>
>>> Here is my CLASSPATH:
>>>
>>> sa...@sarah-laptop:~$ echo $CLASSPATH
>>>
>> :/opt/tinyos-2.1.0/support/sdk/java:/opt/tinyos-2.1.0/support/sdk/java/tinyos.jar:/usr/lib/jvm/java-1.5.0-sun/bin:/usr/lib/jvm/java-1.5.0-sun/jre/lib/i386:.:/opt/tinyos-2.1.0/support/sdk/java:/opt/tinyos-2.1.0/support/sdk/java/tinyos.jar:/usr/lib/jvm/java-1.5.0-sun/bin:/usr/lib/jvm/java-1.5.0-sun/jre/lib/i386:.
>>> I think the duplication comes from running the
>> tos-install-jni, because I also export those four
>> directories in my .bashrc
>>> I feel like I've exhausted all search efforts looking
>> through the very helpful tinyOS help lists, and any more
>> help is greatly appreciated.
>>> Thanks,
>>>
>>> -sarah
>>>
>>>
>>>        
>>> _______________________________________________
>>> Tinyos-help mailing list
>>> [email protected]
>>> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
> 
> 
>       
> 
_______________________________________________
Tinyos-help mailing list
[email protected]
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to