[mapserver-dev] Debugger for Mapserver

Mauricio Herrera georazor at gmail.com
Fri Feb 13 03:54:04 EST 2009


*First thank you for to be too patient Alan!*

Sorry, I had confused,because in the mapfile(.map) exist a DEBUG MODE
(1...5). But ok.
I had done  this --enable-debug when I installed mapserver on my pc..
I followed your tips: I installed GDB and I added a graphical interface
(KDbg and DDD) on my linux distribution. Today, I am debugging the MapServer
executable, thanks a lot!


*I do not want to abuse your kindness but I have two other questions related
to the topic**. *(I think they are very easy  questions for you,but for me
are complicated)

*Question one:*

Do you know if the  files of mapserver(source code) have a function for to
add the mapfile (.map) like  input data?  What do I want?  only read data
values from my (.MAP)  with my GDB
(with the aim of testing). Is it   possible to do ?. Do I need to modify any
file? or I need to configure GDB for to get input data from my
mapfile(.MAP)..

Example ( a function of mapserver):  readmapfile("/usr/local/data.map");
//like default input  test

*Question two:*

If I want to debug mapfile.c for to see its operation in real time with
input data (.MAP) , is it  necessary to load the  mapserv's executable  on
the GDB?

I asked this because I did some test with KDbg and DDD.. And I insert
several breakpoints in the mapfile.c . And never stopped... Only entered in
the next files: cgiutil.c,mapio.c and obviolsly mapserv.c



*
thanks Alan.. I appreciate your help*


Mauricio


*------------------
*comment for expert developer community

Finally a short comment to the expert developer community (maybe I will send
in a new mail)

Well I think that for new developers like me, would be great that the
website (http://mapserver.org/) have tutorials.

About. Developing source code of Mapserver  with any open source IDE.
I think, there is not enough information in the development section.. Maybe
there are  a lot people like me that they would like to develop on mapserver
and they don't know how to begin..



Thank you again!










2009/2/12 Alan Boudreault <aboudreault at mapgears.com>

>
> To debug a software, it is fundamental to build it in "DEBUG" mode. When
> you
> build a software normally, the compiler uses the "RELEASE" mode. The debug
> mode means that the compiler will write all symbols and needed informations
> for the debuggers. Without these informations, you cannot debug the
> software
> properly. To build Mapserver in debug mode, use the switch "--enable-debug"
> when you configure the build (see "./configure --help" for more infos).
>
> Alan
>
> On February 12, 2009 01:04:34 am you wrote:
> > Hi Alan
> >
> > Thanks for answering!
> >
> >  Ok. I will get your tips...I will install GDB on my linux...
> >
> > Sorry, I did not understand very well this: "You only need to build
> > Mapserver in debug mode" .. How can I do that? or where?  can you explain
> > me a little more??..pleaseee..
> >
> > I am a little newbie, but I am a lot interested to develop source code
> for
> > Mapserver!!! =P
> >
> >
> > Mauricio
> >
> >
> > 2009/2/11 Alan Boudreault <aboudreault at mapgears.com>
> >
> > > Hi,
> > >
> > > You should be able to debug Mapserver with the most of debuggers. You
> > > only need to build Mapserver in debug mode. I use GDB and it works like
> a
> > > charm.
> > >
> > > Alan
> > >
> > > On February 11, 2009 04:56:27 am Mauricio Herrera wrote:
> > > > Hi developer list
> > > >
> > > > Im looking for some kind of debugger for mapserver? could you help
> me?
> > > >
> > > > Mainly I need to debug the next files: mapfile.c, mapfile.h
> mapfile.dtd
> > > > mapserv.c, mapserv.h...Because I want to modify and add some new
> > > > functions.. I have tried to debug with Builder c++ (graphical mode),
> > > > but
> > >
> > > I
> > >
> > > > could not do that! when i try to debug they show me a lot errors ..I
> > > > want to know, how the developers did for developing the source code
> for
> > > > mapserver? I can not to (compile,run or debug) the  source code of
> > > > mapserver with the Builder c++
> > > >
> > > > Pleeeeease help me
> > > >
> > > > Thanks
> > > >
> > > > Mauricio Herrera
> > >
> > > _______________________________________________
> > > mapserver-dev mailing list
> > > mapserver-dev at lists.osgeo.org
> > > http://lists.osgeo.org/mailman/listinfo/mapserver-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/mapserver-dev/attachments/20090213/15eb99d8/attachment-0001.html


More information about the mapserver-dev mailing list