Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » Koneki » Debugging issue with standalone interpreter
Debugging issue with standalone interpreter [message #1416987] Sat, 19 October 2013 08:37
Eclipse UserFriend
Hi,

I have been trying to use LDT1.0 for my lua script debugging, but facing issue with debug window. In debug window, when I step into my script, it shows following error on console.

DEBUGGER ERROR Command context_get caused: (998) ....osgi\bundles\173\1\.cp\script\external\debugger.lua:187: attempt to call field 'encode' (a nil value)
stack traceback:
....osgi\bundles\173\1\.cp\script\external\debugger.lua:187: in function 'b64'
....osgi\bundles\173\1\.cp\script\external\debugger.lua:1439: in function <....osgi\bundles\173\1\.cp\script\external\debugger.lua:1423>
(tail call): ?
....osgi\bundles\173\1\.cp\script\external\debugger.lua:636: in function <....osgi\bundles\173\1\.cp\script\external\debugger.lua:625>
(tail call): ?
[C]: in function 'xpcall'
....osgi\bundles\173\1\.cp\script\external\debugger.lua:2548: in function <....osgi\bundles\173\1\.cp\script\external\debugger.lua:2518>
[C]: in function 'pcall'
....osgi\bundles\173\1\.cp\script\external\debugger.lua:2603: in function 'line_hook'
....osgi\bundles\173\1\.cp\script\external\debugger.lua:2627: in function <....osgi\bundles\173\1\.cp\script\external\debugger.lua:2615>



Background:
I created "My custom lua interpreter" in following manner:
1. I downloaded lua 5.1.5 source code(.c/.h) from lua.org/ftp/lua-5.1.5.tar.gz to C:\Source (= SRC)
2. I added some c functions (which will be accessed from my script) in new files my_libc.c. Added necessary changes in lua source files [SRC]to include these c libraries. Then, copied these files to SRC folder
3. Then, downloaded luasocket 2.0.2 source code from
files.luaforge.net/releases/luasocket/luasocket/luasocket-2.0.2
4. Copied all .c/.h from luasocket source folder ( excluding usocket.c, unix.c) (including mime.c) to SRC folder
5. Then added
{"socket.core",luaopen_socket_core},
{"mime.core",luaopen_mime_core},
in lua init.c file in "static const luaL_Reg lualibs[]" table
6.Then build this source project in Visual Studio to generate executable ( my_lua.exe)
Please note, I needed one output file, so I built it statically.

7. Then, I added socket.lua, mime.lua , lnt12.lua from original luasocket folder to my SCRIPT folder,

8. Opened LDT1.0, in debug config, I added my_lua.exe as interpreter and started stepping through, I see stepping through going file. That is script is loaded correctly, but not able to see anything in variable window, variables values are not seen because of aforementioned Error.

Can anyone let me know, where is the issue? How can I see variables used in script.

Thanks,
A lua newbee
Previous Topic:Unable to connect OMA-DM simulator with funambol dm server 3.7
Next Topic:LDT with an external library (winapi.dll)
Goto Forum:
  


Current Time: Thu Apr 25 08:15:22 GMT 2024

Powered by FUDForum. Page generated in 0.03061 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top