[Lazarus] Runtime package (manual compilation only) forced to re-compile by a design time dependant package?

Mattias Gaertner nc-gaertnma at netcologne.de
Wed Apr 17 17:32:56 CEST 2013


On Wed, 17 Apr 2013 17:18:05 +0300
patspiper <patspiper at gmail.com> wrote:

> On 17/04/13 15:19, Mattias Gaertner wrote:
> > On Wed, 17 Apr 2013 14:09:28 +0300
> > patspiper <patspiper at gmail.com> wrote:
> >
> >> It is always good to know the exact reason why a package (or a 
> >> unit/units belonging to a package) was or was not compiled. 
> > The dialog only shows what *will* be compiled, not why it *was*
> > compiled.
> First, just to be clear, I am not pushing for the feature by replying.

Well, actually you are. And that's ok.

 
> A few days ago, I was experimenting with 'Manual compile only' packages 
> and was puzzled why units pertaining to such a package were being 
> recompiled when the IDE was rebuilt. You advised me to check IDE 
> internals.

Yes, it was more a reflex than a well thought answer.
Manually compiled packages do not follow the recommendations. So I
guess it will be hard to write an analyzer that gives the right
advice.
For packages that share source directories the advice is easy, but
maybe not pleasant.


> Hence, the cycle was to inspect IDE internals, rebuild the 
> IDE, and check the messages window. So I had an insight on what was 
> supposed to be recompiled and most importantly why, and compared that 
> with the actual compilation.
> > You can see in the stdout log, why something was compiled.
> I believe the terminal (from which I launch startlazarus) is incapable 
> of buffering so many lines. Are you referring to that terminal log, or 
> to piping the output to a log file?

You can pass --debug-log=log.txt as parameter.
Or use a better terminal. ;)


> >> This relates
> >> mostly to user packages sharing the same folder thus forcing unnecessary
> >> units recompilation, include files not listed explicitly in packages and
> >> thus not causing automatic recompilation, etc...
> > What has this to do with inherited compilation needs?
> > Maybe you want a best practices analyzer for projects/packages?
> Not to that extent, but I find the IDE internals to be a good learning 
> aid, and gives a good insight on the internals under the hood. It helps 
> as well in debugging issues which might stem from bad practices, 
> misunderstanding of the package mechanism, or plain bugs.

Yes, and when such dialog matures enough it becomes a normal dialog.
Like the "Package links".

Mattias




More information about the Lazarus mailing list