Phil, I double checked that I only installed the cygwin packages, not the Linux one. Here is a list of the RPM's that I installed:

[EMAIL PROTECTED] /opt/tinyos-2.x/apps/Blink$ ls /cygdrive/c/temp/Cygwin-Downloads/TinyOS/

avarice-2.4-1.cygwin.i386.rpm
avr-binutils-2.15tinyos-3.cygwin.i386.rpm
avr-gcc-3.4.3-1.cygwin.i386.rpm
avr-insight-6.3-1.cygwin.i386.rpm
avr-libc-1.2.3-1.cygwin.i386.rpm
msp430tools-base-0.1-20050607.cygwin.i386.rpm
msp430tools-binutils-2.16-20050607.cygwin.i386.rpm
msp430tools-gcc-3.2.3-20050607.cygwin.i386.rpm
msp430tools-libc-20050308cvs-20050608.cygwin.i386.rpm
msp430tools-python-tools-1.0-1.cygwin.noarch.rpm
nesc-1.2.7b-1.cygwin.i386.rpm
tinyos-2.0.0beta2-3.cygwin.noarch.rpm
tinyos-tools-1.2.2-1.cygwin.i386.rpm


Trying the command "OSTYPE=cygwin make micaz sim" did make things a little better. (It seems that OSTYPE is not set at all on my machine for some reason; when I printenv OSTYPE I get nothing back. It is a pure TinyOS cygwin that I installed from the tar.gz on the TinyOS web site, not from cygwin.com.)


[EMAIL PROTECTED] /opt/tinyos-2.x/apps/Blink
$ OSTYPE=cygwin make micaz sim
mkdir -p build/micaz
 placing object files in build/micaz
 writing XML schema to app.xml
 compiling BlinkAppC to object file sim.o
ncc -c -DUSE_DL_IMPORT -fpic -o build/micaz/sim.o -g -O0 -tossim -fnesc-nido-tos...

...

g++ -fpic -W1,--enabled-auto-image-base build/micaz/pytossim.o build/micaz/sim .o build/micaz/tossim.o -L//usr/include/python2.3/config -lstdc++ -lpython2.3 -o
_TOSSIM.dll
/usr/lib/gcc-lib/i686-pc-cygwin/3.3.3/../../../../i686-pc-cygwin/bin/ld: cannot
find -lpython2.3
collect2: ld returned 1 exit status
make: *** [sim-exe] Error 1


So it's failing to find the python library. I think that it is indeed not installed and that it was not included in the cygwin installation on the TinyOS web site. Here is the output of the commands that search for this library (it's not on my system) and that enumerate the python-related cygwin packages; it only includes the python base package. So perhaps something like python-devel or something similar is missing from the installation. I'll try to find a compatible python developement package.


Thanks a lot. Sivan


Philip Levis wrote:

On Oct 7, 2006, at 12:02 PM, Sivan Toledo wrote:

I'm using tinyos-2.0.0beta2-3.cygwin.noarch.rpm which is what the TinyOS installation page specifies. <http://www.tinyos.net/dist-2.0.0/tinyos/windows/tinyos-2.0.0beta2-3.cygwin.noarch.rpm>


I don't think the problem is with the version of python. The command that fails is


g++ -shared -fPIC build/micaz/pytossim.o build/micaz/sim.o build/micaz/tossim.o -lstdc++ -o _TOSSIMmodule.so


The unresolved references are in pytossim.o, and they seem to refer to some Python-related library (symbols like _PyString_FromString and __imp__PyExc_NameError). I don't see on this command line the library from which they should come. They are not in tossim.o (I checked with nm).


The instructions in the TOSSIM tutorial seem pretty similar to the one in the first tutorial, it basically just say to run "make micaz sim" in apps/Blink.


Hm. This is weird. -fPIC suggests that it thinks it's compiling for Linux, not Cygwin. The default sim.extra tries to figure out which OS you are with the OSTYPE environment variable. If it is "cygwin", it compiles for Cygwin, if "darwin" it compiles for Mac OSX, otherwise Linux.

What is this environment variable on your machine? Can you try

OSTYPE=cygwin make micaz sim

and see what happens?

The other possibility is that you don't have the Python development libraries. I had though that this was standard on most Cygwins, but... did you install the one linked on the TinyOS site?

Phil

+++++++++++++++++++++++++++++++++++++++++++
This Mail Was Scanned By Mail-seCure System
at the Tel-Aviv University CC.

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

Reply via email to