|
发表于 2010-8-25 17:32:29
|
显示全部楼层
Of course, yes I have read the wicki.
Luckly for me, I have a WM 6.1 up and running since some time.
The shared folder is C:\\EMULATORS
When I build a prokject in Lazarus I simply do
xcopy c:\\lazarus\\my.exe c:\\emulaotrs, and run it (on the (cradled emulator).
Now I want to use a debugger, becaus Access Viol and other errors
(on WinCE but not on the Win32 version) do not help me much.
So I read on wichi
"Copy that file with File Explorer program in your emulator to \\gdb directory.If it is your first time running emulator you have to create a gdb directory in 'My Pocket PC' folder which is your root(\\) folder.(To make things even faster for your each build,with file explorer go to your shared folder,press ctrl+c in your exe file,go to \\gdb folder and each time before you try to debug your application just press ctrl+v) "
Beside the fact that 'that file' is quite a guess (which file?), I cannot use the ctrl+v method since my forms ar full screen and hide everything else, once the apps tarts.
So i created c:\\emulators\\gdb\\
In it i put : arm-wince-pe-stub.exe
test.exe (my WINCE program )
gdb.exe
In Lazarus I have Debugger Options:
C:\\emulators\\gdb\\gdb.exe
whe ni try
gdb --tui test.exe
I get a No Source Avalaibe error.
Could someone help explaining the steps and the commands I should run to use debugger, given the setup I have shown above?
Also, I have NO IDEA of how the gdb console would interact with
the emulator. gdb seems to be a DOS window, so what will I do? run the emulator GUI program or what else? or wouldthe debugger be in the background and when I get an error in the emulator, i can check where (and what ) happened? If so, how ton synchronize the launching of the program in the emulator with the lanching of the
gdb?
I would really appreciate some help, as I am lost in the woods.
It looks as if I am out of the woods (well... of this wood).
I post this to help others newbies (to lazarus, not to programming).
Hope actual examples and brevity help more than lengthy if/where/depending explanation.
I have this setup
1. The emulator is cradled and works: uses activesync to connect
Mine is a WM 6.1 classic
In File -> Configure -> Share Folders i have:
C:\\EMULATORS\\GDB
2. In C:\\EMULATORS\\GDB I have
arm-wince-pe-stub.exe
gdb.exe
I unzipped them directly from my desktop to C:\\EMULATORS\\GDB
(from the zip file downloaded from http://ftp://ftp.freepascal.org/pub/fpc
/contrib/cross/gdb-6.4-win32-arm-wince.zip)
3. In my Lazarus project (C:\\LAZARUS\\CF\\TEST.LPR) I set
Environment -> Options -> Debugger -> General
C:\\emulators\\gdb\\gdb.exe (second line below 'Debugger type and
path')
4. I do Build All, then Run (from the Lazarus IDE), and the program
runs (well.. until it crashes, BUT for some error in MY code)
in the cradled and runnig emulator.
If some (real) expert sees something wrong in this, please advice.
In either case I hope others may benefit |
|