Hi Jiakang,

thank you for write. I get this:

Juan [EMAIL PROTECTED] ~
$ tos-locate-jre --java
Juan [EMAIL PROTECTED] ~
$ tos-locate-jre --javac
Juan [EMAIL PROTECTED] ~
$ tos-locate-jre --jni
1/bin/java: not found
Juan [EMAIL PROTECTED] ~
$

I found the script tos-locate-jre in C:\cygwin\bin but i not know
how "modify the script of tos-jre-locate and manually set the java-home
variable." I look in older messages with "tos-locate-jre" but i not solve my
problem. Can you give me more help?

Thanks,
Juan Antonio



2007/3/11, Jiakang Lu <[EMAIL PROTECTED]>:

Juan Antonio López Riquelme wrote:
> *Hi,*
> **
> *i have install TinyOS-2.x. If i type tos-check-env. At the end i can
> read tos-check-env completed without error.*
> **
> *I try lesson 4. The aplication compile without problems, but with
> java aplication get errors. I type:*
>
> Juan [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
> /opt/tinyos-2.x/apps/tests/TestSerial
> $ motelist
> Reference  CommPort   Description
> ---------- ---------- ----------------------------------------
> M4ADJ9XO   COM3       tmote sky
>
> Juan [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
> /opt/tinyos-2.x/apps/tests/TestSerial
> $ java TestSerial -comm [EMAIL PROTECTED]:telosb <mailto:[EMAIL 
PROTECTED]:telosb>
> The toscomm JNI library was not found.
> Check that your tinyos-tools package is installed and try
> rerunning tos-install-jni.
> Aborting.
>
> *I try solve with the section Cannot find JNI error of the same
> tutorial. I use the commands (make, make install, ./Bootstrap ...) is
> the folders:*
>
> *C:\cygwin\opt\tinyos-2.x\support\sdk\java\net\tinyos\tools*
>
> *C:\cygwin\opt\tinyos-2.x\support\sdk\java\net\tinyos*
>
> *C:\cygwin\opt\tinyos-2.x\support\sdk\java\net*
>
> *C:\cygwin\opt\tinyos-2.x\support\sdk\java*
>
> *With make always get something but with make install nothing:*
>
> Juan [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
> /opt/tinyos-2.x/support/sdk/java
> $ make
> ... /opt/tinyos-2.x/support/sdk/java
> make[1]: Entering directory `/opt/tinyos-2.x/support/sdk/java/net'
> ... /opt/tinyos-2.x/support/sdk/java/net
> make[2]: Entering directory `/opt/tinyos-2.x
/support/sdk/java/net/tinyos'
> ... /opt/tinyos-2.x/support/sdk/java/net/tinyos
> make[3]: Entering directory `/opt/tinyos-
> 2.x/support/sdk/java/net/tinyos/packet'
>
> ... /opt/tinyos-2.x/support/sdk/java/net/tinyos/packet
> ncg -o Serial.java -java-classname=net.tinyos.packet.Serial java
> /opt/tinyos-2.x
> /tos/lib/serial/Serial.h Serial.h
> javac Serial.java
> make[3]: Leaving directory `/opt/tinyos-
> 2.x/support/sdk/java/net/tinyos/packet'
> make[3]: Entering directory
> `/opt/tinyos-2.x/support/sdk/java/net/tinyos/message
> '
> ... /opt/tinyos-2.x/support/sdk/java/net/tinyos/message
> make[3]: Leaving directory `/opt/tinyos-
> 2.x/support/sdk/java/net/tinyos/message'
>
> make[3]: Entering directory
> `/opt/tinyos-2.x/support/sdk/java/net/tinyos/sf'
> ... /opt/tinyos-2.x/support/sdk/java/net/tinyos/sf
> make[3]: Leaving directory
> `/opt/tinyos-2.x/support/sdk/java/net/tinyos/sf'
> make[3]: Entering directory
> `/opt/tinyos-2.x/support/sdk/java/net/tinyos/comm'
> ... /opt/tinyos-2.x/support/sdk/java/net/tinyos/comm
> make[3]: Leaving directory
> `/opt/tinyos-2.x/support/sdk/java/net/tinyos/comm'
> make[3]: Entering directory
> `/opt/tinyos-2.x/support/sdk/java/net/tinyos/mviz'
> ... /opt/tinyos-2.x/support/sdk/java/net/tinyos/mviz
> make[3]: Leaving directory
> `/opt/tinyos-2.x/support/sdk/java/net/tinyos/mviz'
> make[3]: Entering directory
> `/opt/tinyos-2.x/support/sdk/java/net/tinyos/sim'
> ... /opt/tinyos-2.x/support/sdk/java/net/tinyos/sim
> make[3]: Leaving directory
> `/opt/tinyos-2.x/support/sdk/java/net/tinyos/sim'
> make[3]: Entering directory
> `/opt/tinyos-2.x/support/sdk/java/net/tinyos/tools'
> ... /opt/tinyos-2.x/support/sdk/java/net/tinyos/tools
> make[3]: Leaving directory
> `/opt/tinyos-2.x/support/sdk/java/net/tinyos/tools'
> make[3]: Entering directory
> `/opt/tinyos-2.x/support/sdk/java/net/tinyos/util'
> ... /opt/tinyos-2.x/support/sdk/java/net/tinyos/util
> make[3]: Leaving directory
> `/opt/tinyos-2.x/support/sdk/java/net/tinyos/util'
> make[2]: Leaving directory `/opt/tinyos-2.x/support/sdk/java/net/tinyos'
> make[1]: Leaving directory `/opt/tinyos-2.x/support/sdk/java/net'
>
> Juan [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
> /opt/tinyos-2.x/support/sdk/java
> $ make install
>
> Juan [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
> /opt/tinyos-2.x/support/sdk/java
> $
>
> *And if i type tos-install-jni always get nothing:*
>
> Juan [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
> /opt/tinyos-2.x/support/sdk/java
> $ tos-install-jni
> 1/bin/java: not found
> Java not found, not installing JNI code
>
> Juan [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
> /opt/tinyos-2.x/support/sdk/java
> $
>
> *My version of java an environment variables:*
>
> Juan [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
> /opt/tinyos-2.x/support/sdk/java
> $ java -version
> java version "1.5.0_11"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_11-b03)
> Java HotSpot(TM) Client VM (build 1.5.0_11-b03, mixed mode, sharing)
>
> Juan [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
> /opt/tinyos-2.x/support/sdk/java
> $ env | grep tiny
> CLASSPATH=C:\cygwin\opt\tinyos-2.x\support\sdk\java\tinyos.jar;.
> MAKERULES=/opt/tinyos- 2.x/support/make/Makerules
> OLDPWD=/opt/tinyos-2.x/support/sdk
> PWD=/opt/tinyos-2.x/support/sdk/java
> TOSDIR=/opt/tinyos-2.x/tos
> TOSROOT=/opt/tinyos-2.x
>
> Juan [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
> /opt/tinyos-2.x/support/sdk/java
> $
>
> *I read older messages but i not get solve this problem.*
>
> *Thanks for advance,*
>
> *Juan Antonio.*
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Tinyos-help mailing list
> [email protected]
>
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
Hi Juan,

Make sure that your "tos-jre-locate" command can locate the java
installation directory correctly:
$tos-jre-locate --java
$tos-jre-locate --javac
$tos-jre-locate --jni

Then, you can run tos-install-jni.

If the tos-jre-locate cannot find your java correctly, the way I solve
this problem is modify the script of tos-jre-locate and manually set the
java-home variable.

Good luck.
Jiakang





_______________________________________________
Tinyos-help mailing list
[email protected]
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to