On Dec 14, 2006, at 6:24 AM, preeti k wrote:
Finally i think i figured that the problem is of compilation
happening for linux when i am actually using cygwin.
So i hard coded OSTYPE=cygwin in the sim.extra file. Now it has
stopped throwing undefined reference errors but i am still not done
since now i get the following error
*****************************************************
linking into shared object ./_TOSSIM.dll
g++ -fpic -W1,--enabled-auto-image-base build/micaz/pytossim.o
build/micaz/sim
.o build/micaz/tossim.o build/micaz/c-support.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
******************************************************
I referered to the tinyos-help thread which talks about the same
problem but i cud not find a solution. To rectify the problem i
changed
PLATFORM_LIB_FLAGS in sim.extra file as follows
Initially it was
PLATFORM_LIB_FLAGS = -L$(PYDIR)/config .dll -lstdc++ -lpython$
(PYTHON_VERSION)
I changed it to PLATFORM_LIB_FLAGS = -L$(PYDIR)/config /bin/
libpython2.3.dll -lstdc++
I thus deleted the '-lpython$(PYTHON_VERSION) ' and added /bin/
libpython2.3.dll (to -L option), since that is the location of my
python library file.I do not know how correct this is but
apparently the -lpython not found error is gone but now i get the
following error
********************************************
linking into shared object ./_TOSSIM.dll
g++ -fpic -W1,--enabled-auto-image-base build/micaz/pytossim.o
build/micaz/sim
.o build/micaz/tossim.o build/micaz/c-support.o -L/usr/include/
python2.3/config
/bin/libpython2.3.dll -lstdc++ -o _TOSSIM.dll
/usr/lib/gcc-lib/i686-pc-cygwin/3.3.3/../../../libcygwin.a
(libcmain.o)(.text+0x7
c): undefined reference to [EMAIL PROTECTED]'
collect2: ld returned 1 exit status
make: *** [sim-exe] Error 1
********************************************
Now I am completely at a loss here as to whats going wrong. Can
someone please help me out?
Preeti
You've entered a level of Cygwin details that I have to admit I know
nothing about.
My only guess is that for some reason the g++ invocation is not
creating a shared library. An undefined reference to Main seems strange.
Phil
_______________________________________________
Tinyos-help mailing list
[email protected]
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help