PyS60 1.9.3 compilation problem (in order to compile modules)
Hi,
I wanted to compile my modules wlantools and elocation for PyS60 1.9.3 but I'm facing a problem and it blocks me for 2 days...
I need to compile the core Python lib to build then my modules, I created a subst drive w: with C:\Symbian\9.2\S60_3rd_FP1.
I moved the PyS60 sources in \PyS60-1.9.3\ (or C:\Symbian\9.2\S60_3rd_FP1\PyS60-1.9.3\)
I set EPOCROOT to "\"
Then I configure the build : setup.py configure -s 30armv5 -k selfsigned
(I'm not taking care of the capabilities at this point)
but then, python setup.py build fails.
I get :
[CODE]make -s -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\_TYPES\WINSCW\_TYPES.WINSCW" RESOURCEUDEB
make -s -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\THREAD\WINSCW\THREAD.WINSCW" RESOURCEUDEB
make -s -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\_SSL\WINSCW\_SSL.WINSCW" RESOURCEUDEB
make -s -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\_TESTCAPI\WINSCW\_TESTCAPI.WINSCW" RESOURCEUDEB
make -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\WINSCW.make" TARGET CFG=UDEB VERBOSE=-s
process_begin: CreateProcess((null), mwccsym2.exe -g -O0 -inline off -wchar_t off -align 4 -warnings on -w nohidevirtual,nounusedexpr -msgstyle gcc -enum int -str pool -exc ms -trigraphs on -nostdinc -d _DEBUG -d _UNICODE -d __SYMBIAN32__ -d __SERIES60_31__ -d __SERIES60_3X__ -d __CW32__ -d __WINS__ -d __WINSCW__ -d __
DLL__ -d Py_BUILD_CORE -d __SUPPORT_CPP_EXCEPTIONS__ -cwd source -i- -i \PyS60-1.9.3\newcore\symbian\inc -i \EPOC32\include\python25 -i \EPOC32\include\stdapis -i \EPOC32\include -i \epoc32\include\variant -i "\epoc32\include\variant\ " -include Symbian_OS_v9.2.hrh -o \EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\PYTHON25\WINSCW\UDEB\_sre.o -c \PyS60-1.9.3\newcore\Modules\_sre.c, ...) failed.
make (e=2): The system cannot find the file specified.
make[1]: *** [\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\PYTHON25\WINSCW\UDEB\_sre.o] Error 2
make: *** [TARGETPYTHON25] Error 2
make -s -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\PYTHON25\WINSCW\PYTHON25.WINSCW" UDEB_sre.c
make -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\WINSCW.make" FINAL CFG=UDEB VERBOSE=-s
*** BUILD FAILED ***
[/CODE]
Do you know what I am doing wrong ?
Is there any step I missed to prepare the build environment ?
Thanks
Christophe
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
[QUOTE=bergerc;574579]Hi,
I wanted to compile my modules wlantools and elocation for PyS60 1.9.3 but I'm facing a problem and it blocks me for 2 days...
I need to compile the core Python lib to build then my modules, I created a subst drive w: with C:\Symbian\9.2\S60_3rd_FP1.
I moved the PyS60 sources in \PyS60-1.9.3\ (or C:\Symbian\9.2\S60_3rd_FP1\PyS60-1.9.3\)
I set EPOCROOT to "\"
Then I configure the build : setup.py configure -s 30armv5 -k selfsigned
(I'm not taking care of the capabilities at this point)
but then, python setup.py build fails.
I get :
[CODE]make -s -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\_TYPES\WINSCW\_TYPES.WINSCW" RESOURCEUDEB
make -s -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\THREAD\WINSCW\THREAD.WINSCW" RESOURCEUDEB
make -s -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\_SSL\WINSCW\_SSL.WINSCW" RESOURCEUDEB
make -s -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\_TESTCAPI\WINSCW\_TESTCAPI.WINSCW" RESOURCEUDEB
make -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\WINSCW.make" TARGET CFG=UDEB VERBOSE=-s
process_begin: CreateProcess((null), mwccsym2.exe -g -O0 -inline off -wchar_t off -align 4 -warnings on -w nohidevirtual,nounusedexpr -msgstyle gcc -enum int -str pool -exc ms -trigraphs on -nostdinc -d _DEBUG -d _UNICODE -d __SYMBIAN32__ -d __SERIES60_31__ -d __SERIES60_3X__ -d __CW32__ -d __WINS__ -d __WINSCW__ -d __
DLL__ -d Py_BUILD_CORE -d __SUPPORT_CPP_EXCEPTIONS__ -cwd source -i- -i \PyS60-1.9.3\newcore\symbian\inc -i \EPOC32\include\python25 -i \EPOC32\include\stdapis -i \EPOC32\include -i \epoc32\include\variant -i "\epoc32\include\variant\ " -include Symbian_OS_v9.2.hrh -o \EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\PYTHON25\WINSCW\UDEB\_sre.o -c \PyS60-1.9.3\newcore\Modules\_sre.c, ...) failed.
make (e=2): The system cannot find the file specified.
make[1]: *** [\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\PYTHON25\WINSCW\UDEB\_sre.o] Error 2
make: *** [TARGETPYTHON25] Error 2
make -s -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\PYTHON25\WINSCW\PYTHON25.WINSCW" UDEB_sre.c
make -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\WINSCW.make" FINAL CFG=UDEB VERBOSE=-s
*** BUILD FAILED ***
[/CODE]
Do you know what I am doing wrong ?
Is there any step I missed to prepare the build environment ?
Thanks
Christophe[/QUOTE]
Anybody compiled a module on PyS60 1.9.3 ?
Did you do something special ?
I will reinstall my development environment to see if I did something wrong.
Thanks for any help
Regards,
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
Did you make the changes mentioned in the section "6.2 Porting existing native extensions to PyS60 1.9.x" in Python src\PyS60_1_9_x_README.txt ?
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
Also, take a look at the example module, elemlist present under src\extras
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
[QUOTE=mahesh.sayibabu;575391]Also, take a look at the example module, elemlist present under src\extras[/QUOTE]
The modules do not enter in this problem, I want first to compile Python, then I will compile the modules, sorry I wanted to give the context when I spoke of the modules.
I need Python25.dso to link my modules, I cannot finish the compile of the modules without building at first PyS60.
and elemlist does not compile because Python25.dso does not exist
I looked more precisely at the error messages :
[CODE] make -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\WINSCW.make" TARGET CFG=UDEB VERBOSE=-s
Errors caused tool to abort.
make[1]: *** [\EPOC32\RELEASE\WINSCW\UDEB\python25.dll] Error 1
make: *** [TARGETPYTHON25] Error 2
make -s -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\PYTHON25\WINSCW\PYTHON25.WINSCW" UDEB
mwldsym2.exe: Undefined symbol: '__stack_alloc'
mwldsym2.exe: referenced from '_file_readlines' in fileobject.c:1382
mwldsym2.exe: referenced from '_PyMarshal_ReadLastObjectFromFile' in marshal.c:1046
mwldsym2.exe: Undefined symbol: '___CxxFrameHandler'
mwldsym2.exe: referenced from 'CPyThreadRoot::CPyThreadRoot(int (*)(void *) &, void *) (??0CPyThreadRoot@@QAE@AAP6AHPAX@Z0@Z)' in thread_symbian.cpp:35
mwldsym2.exe: referenced from 'void invokeTable(void (* *)(void), void (* *)(void)) (?invokeTable@@YAXPAP6AXXZ0@Z)' in win32crt.h:121 (EDLL.LIB)
mwldsym2.exe: referenced from 'void * operator new(unsigned int) (??2@YAPAXI@Z)' in win32crt.h:154 (EDLL.LIB)
mwldsym2.exe: referenced from 'void operator delete(void *) (??3@YAXPAX@Z)' in win32crt.h:176 (EDLL.LIB)
mwldsym2.exe: referenced from '__E32Dll' in uc_dll.cpp:41 (EDLL.LIB)
mwldsym2.exe: referenced from '_launchpad' in thread_symbian.cpp:88
mwldsym2.exe: Undefined symbol: '___destroy_new_array'
mwldsym2.exe: referenced from 'CPyThreadRoot::~CPyThreadRoot(unsigned int) (??_ECPyThreadRoot@@UAE@I@Z)' in thread_symbian.o
mwldsym2.exe: Undefined symbol: '__stdcall(16) _rt_divs64 (__rt_divs64@16)'
mwldsym2.exe: referenced from '_epoch_to_datetime' in symbian_python_ext_util.cpp:310
mwldsym2.exe: Undefined symbol: '___unexpected'
mwldsym2.exe: referenced from 'void operator delete(void *) (??3@YAXPAX@Z)' in win32crt.h:176 (EDLL.LIB)
make -r -f "\EPOC32\BUILD\PyS60-1.9.3\newcore\symbian\group\WINSCW.make" FINAL CFG=UDEB VERBOSE=-s[/CODE]
Any idea ?
Thank you very much
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
[QUOTE=bergerc;575706]The modules do not enter in this problem, I want first to compile Python, then I will compile the modules, sorry I wanted to give the context when I spoke of the modules.
I need Python25.dso to link my modules, I cannot finish the compile of the modules without building at first PyS60.
and elemlist does not compile because Python25.dso does not exist
[/QUOTE]
python25.dso is part of the Python SDK zip. You can extract the correct SDK zip to your Symbian SDK and then compile your module directly. There is no need to build Python for S60 source.
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
[QUOTE=ashwinurao;575730]python25.dso is part of the Python SDK zip. You can extract the correct SDK zip to your Symbian SDK and then compile your module directly. There is no need to build Python for S60 source.[/QUOTE]
Oh, that's a good thing, I didn't even check what was in this zip. Thanks I will try
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
has anyone managed to recompile wlantools for 1.9.x? if not does anyone know of another way to scan for 802.11 devices without user interaction?
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
[QUOTE=Spud_Gun31;583846]has anyone managed to recompile wlantools for 1.9.x? if not does anyone know of another way to scan for 802.11 devices without user interaction?[/QUOTE]
Hi,
I still cannot compile anything under 1.9.x, even not the example module elemlist.
As soon as I manage it, I will provide a version of wlantools.
I will look at it next week, I did not have time to investigate further.
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
[QUOTE=bergerc;584091]I still cannot compile anything under 1.9.x, even not the example module elemlist.As soon as I manage it, I will provide a version of wlantools.[/QUOTE]
I'm waiting for wlantools for 1.9/2.0, it is currently most important "3rd party" module I am using.
Let us know when we can try the new module. I have at least 3rd FP0, FP1 and FP2 devices on my hands.
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
[QUOTE=bergerc;584091]Hi,
I still cannot compile anything under 1.9.x, even not the example module elemlist.
[/QUOTE]
Can you tell what is the exact problem you are facing, may be we can help :)
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
hi everyone,
I'm a fan of the elocation module and set about trying to port the module myself. I partially succeeded ([url]http://sites.google.com/site/mrhtailor/Home/elocation-for-py195_unsigned.sis?attredirects=0[/url]) ! however, only one error occurs at this line:
[CODE]PyThread_AtExit(location_mod_cleanup);[/CODE]
- error: Each undeclared identifier is reported only once for each function it appears in
- error: "PyThread_AtExit" undeclared (first use this function)
If I comment out the line, the SIS builds successfully. I sign it, install onto my mobi phone, import it into Python Shell, then test it as follows:
[CODE]
>> import elocation
>> elocation.extended_gsm_location()
.
.
.//continuous lines of errors referring to ret=elocation.extended_gsm_location()
.
MemoryError: Stack overflow
>>
[/CODE]
any insight into this would be appreciated :)
btw, i'm compiling for 1.9.5
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
[QUOTE=the86hitman;611776]hi everyone,
I'm a fan of the elocation module and set about trying to port the module myself. I partially succeeded ([url]http://sites.google.com/site/mrhtailor/Home/elocation-for-py195_unsigned.sis?attredirects=0[/url]) ! however, only one error occurs at this line:
[CODE]PyThread_AtExit(location_mod_cleanup);[/CODE]
- error: Each undeclared identifier is reported only once for each function it appears in
- error: "PyThread_AtExit" undeclared (first use this function)
[/QUOTE]
Is "pythread.h" included?
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
ashwinurao, thanks your for your help. the extension compiles perfectly now!
however, the looping error isnt resolved:confused: I dont see any loops, so I dont know how/where this error arises from..
[CODE]
File "c:\resource\python25\elocation.py", line
37, in extended_gsm_location
ret = elocation.extended_gsm_location()
File "c:\resource\python25\elocation.py", line
37, in extended_gsm_location
ret = elocation.extended_gsm_location()
.
.
.
.
File "c:\resource\python25\elocation.py", line
37, in extended_gsm_location
ret = elocation.extended_gsm_location()
File "c:\resource\python25\elocation.py", line
37, in extended_gsm_location
ret = elocation.extended_gsm_location()
File "c:\resource\python25\elocation.py", line
36, in extended_gsm_location
if e32.s60_version_info>=(3,0):
MemoryError: Stack overflow
[/CODE]
Re: PyS60 1.9.3 compilation problem (in order to compile modules)
[QUOTE=the86hitman;612057]ashwinurao, thanks your for your help. the extension compiles perfectly now!
however, the looping error isnt resolved:confused: I dont see any loops, so I dont know how/where this error arises from..
[/QUOTE]
Hi,
For now I did not have time to setup my development environment, it still doesn't work but I may help you about the code, I developed this extension.
Can you test to call directly the extension without the header script ?
If you didn't change the way it works, the extension module should be _extended_gsm_location. then try to call the functions directly.
There is also debug statements, if you create a directory called c:\Log the logfile should be created.
Let me know,
Christophe