NuSphere Forums Forum Index
NuSphere Forums
Reply to topic
Using dbgbase - is DbgSpawn.cpp posix-dependent?


Joined: 15 Sep 2004
Posts: 8
Reply with quote
Hi,

I'm trying to write my own dbg client. I'd like to use the dbgbase library for that. I'm writing it on Windows using VS.Net 2003; after correcting some compiler issues, I ran into a call to pipe() in spawn_process() which is only available on posix systems (well there is a _pipe() on windows but it takes more arguments, although it does roughly the same). Does dbgbase work on windows? I guess it does, dbglistener is build on it, right? If it does, how do I get it to work? Thanks.

cheers,

roel
View user's profileFind all posts by roel_vSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
yes, that code is suitable for unix platforms only and it is clearly marked on the download page. If you want to run under Windows you'd use DbgListener.exe (precompiled binary) and its COM interfaces in particular. An IDL file is available with this package.
View user's profileFind all posts by dmitriSend private messageVisit poster's website


Joined: 15 Sep 2004
Posts: 8
Reply with quote
Ok thanks. I thought that the only part that was for unix only was the actual client and that there was a common part that was also used to make the windows client. Does this mean there is no source available for the windows version? I'd like to run it under a debugger to see how things work and after that add some functionality that allows client to query the contents of a file to display in their debugger window. All clients at the moment require people to set a path to the files which in the case of remote debugging means that people have to have ftp or samba access to that remote server which is imo a hack. Is there a reason why a client can't request the contents of a page from the server-side debugger part?
View user's profileFind all posts by roel_vSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
Quote:
add some functionality that allows client to query the contents of a file to display in their debugger window

actually this functionality IS available in dbg since the very early days of this project. Mapping and other stuff appeared much later. But... I'd recommend you to think twice before using it. First of all, it's additional network traffic that happens every time you step in to a new file. It may slowdown. Secondly, in order to change any file you need to download it first then upload it back. In case of local files you only need to upload... Also no additional traffic can happen when debugging the files.
View user's profileFind all posts by dmitriSend private messageVisit poster's website


Joined: 15 Sep 2004
Posts: 8
Reply with quote
Aha thanks for this information. I see that I have been looking in the wrong places; I see now that it is implemented with the handler_add_source_reply handler in dbg_cmd.c. I think from looking at the IDL I should use the IPhpDbgRequestor3 and IPhpDbgDSrcEnum interfaces, but I'll have to look into that when I'm at home and have some more time.
As for the delay in downloading the file, I think it's not that bad; especially when you're running the web server on your local machine or on an intranet. I don't mind the download of a few kb everytime a breakpoint is hit or a step into a new file is made, but that's everyone's own preference I guess. It would indeed make a difference when the debugger is integrated into an editor, that would require upload functionality as well; but I don't want the debugger to integrated, the whole point is that I prefer separate editing/debugging environments.
Anyway, thanks for the help, and thanks for a great job on dbg.
View user's profileFind all posts by roel_vSend private message
Using dbgbase - is DbgSpawn.cpp posix-dependent?
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT - 5 Hours  
Page 1 of 1  

  
  
 Reply to topic