You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openoffice.apache.org by Damjan Jovanovic <da...@gmail.com> on 2012/10/30 18:44:06 UTC
[DISCUSS] IDE, comment translation, debugging, documentation and
other development issues
Hi
AOO is by far the biggest and most complex code I have ever hacked on,
and I have many questions...
What IDE do you guys use to develop AOO? Eclipse CDT runs out of
memory indexing the code :-(.
Many comments are in German. Are translations to English welcome or
should we leave them as is?
Debugging is such a pain. Why do binaries get stripped when the tar.gz
is built even though debugging has been enabled (build debug=true
dbglevel=2 --all)?
The layout of the source code tree is incredibly complex, with eg.
confusing duplication of CSV parsing between binfilter/ and sc/. Is
there somewhere I should document the structure of various modules?
http://wiki.openoffice.org/wiki/Source_code_directories seems like a
good place to start but I would add a lot more detail.
Searching with grep takes forever. I've tried indexing the source tree
with Lucene, but it doesn't find everything. Is there a better tool?
Thank you
Damjan
Re: [DISCUSS] IDE, comment translation, debugging, documentation and other development issues
Posted by Pedro Giffuni <pf...@apache.org>.
Hi Damjan;
>________________________________
> From: Damjan Jovanovic
...
>Hi
>
>AOO is by far the biggest and most complex code I have ever hacked on,
>and I have many questions...
>
It is indeed big and hairy. I have only done rather simple tasks like
updating modules.
>
>Searching with grep takes forever. I've tried indexing the source tree
>with Lucene, but it doesn't find everything. Is there a better tool?
>
OpenGrok helps a lot.
Another good way of walking through the code and finding errors is with
Coverity scans. Apache committers have access to it just by asking, or
even less as you are about to notice ;-).
cheers,
Pedro.
Re: [DISCUSS] IDE, comment translation, debugging, documentation
and other development issues
Posted by Andre Fischer <aw...@gmail.com>.
On 30.10.2012 18:44, Damjan Jovanovic wrote:
> Hi
>
> AOO is by far the biggest and most complex code I have ever hacked on,
> and I have many questions...
Welcome Damjan,
>
> What IDE do you guys use to develop AOO? Eclipse CDT runs out of
> memory indexing the code :-(.
I have once been able to check out AOO from SVN directly in Eclipse and
even the code indexing worked. However, I have not been able to repeat
that. But it would be really great to find a reliable way to use
Eclipse for AOO development.
I personally use Emacs as IDE :-)
I have scripts that start the compiler from the editor on a keystroke
and copy the generated libraries back into the installed office.
For debugging I use MS Visual Studio Express 2010. Best debugger I have
seen so far.
>
> Many comments are in German. Are translations to English welcome or
> should we leave them as is?
Translate them, please, or write new ones.
>
> Debugging is such a pain. Why do binaries get stripped when the tar.gz
> is built even though debugging has been enabled (build debug=true
> dbglevel=2 --all)?
I use a different approach.
Build office once and do a local install (by calling "setup.exe -a").
Then I build the modules I am interested in separately again but this
time with debugging symbols and copy the new libraries over the old
ones of the installed office.
You have to repeat this step anyway, after you have made changes to the
code.
>
> The layout of the source code tree is incredibly complex, with eg.
> confusing duplication of CSV parsing between binfilter/ and sc/. Is
> there somewhere I should document the structure of various modules?
> http://wiki.openoffice.org/wiki/Source_code_directories seems like a
> good place to start but I would add a lot more detail.
More detail sounds good. Please go ahead.
One lesson that probably every developer learns when starting to work on
OpenOffice code is that the reason why you find it complex or why you
don't understand the code is not that you are stupid but because the
code is complex, huge, old, and often badly designed.
Any little contribution to improve it is welcome.
>
> Searching with grep takes forever. I've tried indexing the source tree
> with Lucene, but it doesn't find everything. Is there a better tool?
>
> Thank you
> Damjan
Best regards,
Andre
Re: [DISCUSS] IDE, comment translation, debugging, documentation
and other development issues
Posted by Jürgen Schmidt <jo...@gmail.com>.
On 10/31/12 12:14 AM, Ariel Constenla-Haile wrote:
> Hi Damjan,
>
> On Tue, Oct 30, 2012 at 07:44:06PM +0200, Damjan Jovanovic wrote:
>> Hi
>>
>> AOO is by far the biggest and most complex code I have ever hacked on,
>> and I have many questions...
>
> true, but you managed to get your first patch out of it! Congratulations
> :)
nothing to add here, welcome on board
>
>> What IDE do you guys use to develop AOO? Eclipse CDT runs out of
>> memory indexing the code :-(.
>
> I guess you cannot index the whole source tree with an IDE. It may work
> to just index the modules you are working with, no need to add all the
> dependencies, if a module depends on trunk/main/foo, simply add to the
> parser path trunk/main/foo/inc, and for the offapi/offuh header, you can
> point the parser to an SDK installation, or even point it to the solver
> include dir (but this might be too consuming). I used this approach with
> some IDEs and worked.
emacs ;-)
>
>
>> Many comments are in German. Are translations to English welcome or
>> should we leave them as is?
>
> Of course they are welcome. Better if done by a native speaker or
> someone in the know (not google translate).
>
>> Debugging is such a pain. Why do binaries get stripped when the tar.gz
>> is built even though debugging has been enabled (build debug=true
>> dbglevel=2 --all)?
>
> they are striped when delivered to the solver. You have to configure
> with --disable-strip-solver.
>
> I'm not sure a dbglevel=2 is good for all the modules, you will get too
> much debug output may be missing what you want to catch.
>
> An interesting switch when developing is --enable-dbgutil that build
> a NON-PRO build http://wiki.openoffice.org/wiki/Non_Product_Build
>
the best tool for debugging is of course MS Visual Studio. I used XCode
as well but we have first to do some work to enable XCode4.
gdb in emacs works as well but is not so comfortable like the MS Visual
Studio.
I never have tried other gdb frontends.
Juergen
>> The layout of the source code tree is incredibly complex, with eg.
>> confusing duplication of CSV parsing between binfilter/ and sc/.
>
> binfilter is dead code, soon to be removed when trunk is in AOO4
>
>> there somewhere I should document the structure of various modules?
>> http://wiki.openoffice.org/wiki/Source_code_directories seems like a
>> good place to start but I would add a lot more detail.
>>
>> Searching with grep takes forever. I've tried indexing the source tree
>> with Lucene, but it doesn't find everything. Is there a better tool?
>
> Use opengrok from adfinis http://opengrok.adfinis-sygroup.org
>
>
> Regards
>
Re: [DISCUSS] IDE, comment translation, debugging, documentation and
other development issues
Posted by Ariel Constenla-Haile <ar...@apache.org>.
Hi Damjan,
On Tue, Oct 30, 2012 at 07:44:06PM +0200, Damjan Jovanovic wrote:
> Hi
>
> AOO is by far the biggest and most complex code I have ever hacked on,
> and I have many questions...
true, but you managed to get your first patch out of it! Congratulations
:)
> What IDE do you guys use to develop AOO? Eclipse CDT runs out of
> memory indexing the code :-(.
I guess you cannot index the whole source tree with an IDE. It may work
to just index the modules you are working with, no need to add all the
dependencies, if a module depends on trunk/main/foo, simply add to the
parser path trunk/main/foo/inc, and for the offapi/offuh header, you can
point the parser to an SDK installation, or even point it to the solver
include dir (but this might be too consuming). I used this approach with
some IDEs and worked.
> Many comments are in German. Are translations to English welcome or
> should we leave them as is?
Of course they are welcome. Better if done by a native speaker or
someone in the know (not google translate).
> Debugging is such a pain. Why do binaries get stripped when the tar.gz
> is built even though debugging has been enabled (build debug=true
> dbglevel=2 --all)?
they are striped when delivered to the solver. You have to configure
with --disable-strip-solver.
I'm not sure a dbglevel=2 is good for all the modules, you will get too
much debug output may be missing what you want to catch.
An interesting switch when developing is --enable-dbgutil that build
a NON-PRO build http://wiki.openoffice.org/wiki/Non_Product_Build
> The layout of the source code tree is incredibly complex, with eg.
> confusing duplication of CSV parsing between binfilter/ and sc/.
binfilter is dead code, soon to be removed when trunk is in AOO4
> there somewhere I should document the structure of various modules?
> http://wiki.openoffice.org/wiki/Source_code_directories seems like a
> good place to start but I would add a lot more detail.
>
> Searching with grep takes forever. I've tried indexing the source tree
> with Lucene, but it doesn't find everything. Is there a better tool?
Use opengrok from adfinis http://opengrok.adfinis-sygroup.org
Regards
--
Ariel Constenla-Haile
La Plata, Argentina
Re: [DISCUSS] IDE, comment translation, debugging, documentation
and other development issues
Posted by Raphael Bircher <rb...@apache.org>.
Am 30.10.12 18:44, schrieb Damjan Jovanovic:
> Hi
>
> AOO is by far the biggest and most complex code I have ever hacked on,
> and I have many questions...
>
> What IDE do you guys use to develop AOO? Eclipse CDT runs out of
> memory indexing the code :-(.
>
> Many comments are in German. Are translations to English welcome or
> should we leave them as is?
>
> Debugging is such a pain. Why do binaries get stripped when the tar.gz
> is built even though debugging has been enabled (build debug=true
> dbglevel=2 --all)?
>
> The layout of the source code tree is incredibly complex, with eg.
> confusing duplication of CSV parsing between binfilter/ and sc/. Is
> there somewhere I should document the structure of various modules?
> http://wiki.openoffice.org/wiki/Source_code_directories seems like a
> good place to start but I would add a lot more detail.
>
> Searching with grep takes forever. I've tried indexing the source tree
> with Lucene, but it doesn't find everything. Is there a better tool?
http://opengrok.adfinis-sygroup.org/source/
use this one for search.
>
> Thank you
> Damjan
Re: [DISCUSS] IDE, comment translation, debugging, documentation
and other development issues
Posted by Joost Andrae <Jo...@gmx.de>.
Hi Andrea,
>
> OK, but if a developer bumps into German comments while investigating
> code, it doesn't harm to check in a translation to English. Most of our
> more experienced developers know German and English, so it won't be
> problematic to find someone who can ensure that the translation is correct.
>
> On the other hand, I'm not sure that a systematic translation of German
> comments makes sense, since there are modules that are or will soon be
> deprecated; it probably makes more sense to translate when needed.
>
you got it: This way ("translate when needed") is preferable for all
code that is not deprecated. Fortunately there are a lot of developers
here who can understand those comments and who could help to translate
them into English but translating shouldn't be the main focus eg. just
for counting code changes like within our main fork (hint hint...).
Kind regards, Joost
Re: [DISCUSS] IDE, comment translation, debugging, documentation
and other development issues
Posted by Andrea Pescetti <pe...@apache.org>.
On 30/10/2012 Joost Andrae wrote:
>> [Damjan]
>> Many comments are in German. Are translations to English welcome or
>> should we leave them as is?
> German comments are present within code that hasn't been touched for a
> long time.
OK, but if a developer bumps into German comments while investigating
code, it doesn't harm to check in a translation to English. Most of our
more experienced developers know German and English, so it won't be
problematic to find someone who can ensure that the translation is correct.
On the other hand, I'm not sure that a systematic translation of German
comments makes sense, since there are modules that are or will soon be
deprecated; it probably makes more sense to translate when needed.
Regards,
Andrea.
Re: [DISCUSS] IDE, comment translation, debugging, documentation
and other development issues
Posted by Joost Andrae <Jo...@gmx.de>.
Hi Damjan,
>
> AOO is by far the biggest and most complex code I have ever hacked on,
> and I have many questions...
yes it is... :)
>
> What IDE do you guys use to develop AOO? Eclipse CDT runs out of
> memory indexing the code :-(.
I wouldn't try it this way...
Use dmake or maybe make (depends on the status of readiness regarding
using make) to build it. On Windows you could use VisualStudio to debug
it comfortly. On Linux you can use gdb and on Solaris you could use dbx
to start a debugging session. Don't try to leave the console...it's not
worth it...
Some building instructions including a document describing building
requirements can be found here:
http://wiki.openoffice.org/wiki/Documentation/Building_Guide
>
> Many comments are in German. Are translations to English welcome or
> should we leave them as is?
German comments are present within code that hasn't been touched for a
long time. Remember: OOo/StarOffice has been originally developed in
Hamburg at StarDivision and most of the developers were German. But it's
better to have German comments within the source code than having no
comments...
>
> Debugging is such a pain. Why do binaries get stripped when the tar.gz
> is built even though debugging has been enabled (build debug=true
> dbglevel=2 --all)?
Hint: If you want to run dbx or gdb then start to include gdb within the
command line of the soffice shell script to get the runtime environment
of the soffice binary.
>
> The layout of the source code tree is incredibly complex, with eg.
> confusing duplication of CSV parsing between binfilter/ and sc/. Is
> there somewhere I should document the structure of various modules?
> http://wiki.openoffice.org/wiki/Source_code_directories seems like a
> good place to start but I would add a lot more detail.
Don't touch binfilter. It's somehow static and nowadays completely
deprecated.
Do you know http://wiki.openoffice.org/wiki/Architecture ?
Or this http://wiki.openoffice.org/wiki/Documentation/DevGuide ?
>
> Searching with grep takes forever. I've tried indexing the source tree
> with Lucene, but it doesn't find everything. Is there a better tool?
eg. OpenGrok at http://svn.services.openoffice.org/opengrok/ but be
aware that this instance is really old and I don't know a version that
has been updated recently and if someone at Apache Infra started to
build-up an equal environment so far...
Nice to read is also http://wiki.openoffice.org/wiki/Development
Kind regards, Joost