[Lazarus] Indy compilation problem revisited.

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

[Lazarus] Indy compilation problem revisited.

vfclists .


There is a persistent problem in installing Indy which always returns to bite me and I have to get the bottom of it.

Whenever Indy is being compiled it compiles okay.

When I want to reinstall the package this error comes up.

Recompiling IdStreamVCL, checksum changed for IdGlobal
IdStreamVCL.pas(13,20) Fatal: Can't find unit IdStreamVCL used by IdStream

What do they actually mean, in particular which process is emitting the message Fatal: Can't find unit IdStreamVCL used by IdStream?

--
Frank Church

=======================
http://devblog.brahmancreations.com

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Indy compilation problem revisited.

Peter Williams
Hi Frank,


Date: Tue, 22 Mar 2011 10:21:04 +0000
From: [hidden email]
To: [hidden email]
Subject: [Lazarus] Indy compilation problem revisited.



>There is a persistent problem in installing Indy which always returns to bite me and I have to get the bottom of it.

>Whenever Indy is being compiled it compiles okay.

>When I want to reinstall the package this error comes up.

>Recompiling IdStreamVCL, checksum changed for IdGlobal
>IdStreamVCL.pas(13,20) Fatal: Can't find unit IdStreamVCL used by IdStream

>What do they actually mean, in particular which process is emitting the message Fatal: Can't find unit IdStreamVCL used by IdStream?


This is my best guess. Look for file IdStreamVCL.pas. You will probably find that this has the statement "unit IdStream" at line 1. Then look at line 13, column 20 and you will find IdStreamVCL (in it's uses section).

-- 
>Frank Church

>=======================
>http://devblog.brahmancreations.com

Best Regards,
PEW

-- _______________________________________________ Lazarus mailing list [hidden email] http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Indy compilation problem revisited.

Mattias Gaertner
On Wed, 23 Mar 2011 00:44:43 +1100
Peter Williams <[hidden email]> wrote:

>[...]
> >Recompiling IdStreamVCL, checksum changed for IdGlobal
> >IdStreamVCL.pas(13,20) Fatal: Can't find unit IdStreamVCL used by IdStream

You can try compiling the Indy package with -Ur. Add this to the
compiler options of the Indy package.


> >What do they actually mean, in particular which process is emitting the message Fatal: Can't find unit IdStreamVCL used by IdStream?

Process: fpc
Meaning: a ppu file is outdated. There is a bug in fpc that can trigger
this. There are several ways to work around the bug. One is to use -Ur.


Mattias

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Indy compilation problem revisited.

vfclists .


On 22 March 2011 18:15, Mattias Gaertner <[hidden email]> wrote:
On Wed, 23 Mar 2011 00:44:43 +1100
Peter Williams <[hidden email]> wrote:

>[...]
> >Recompiling IdStreamVCL, checksum changed for IdGlobal
> >IdStreamVCL.pas(13,20) Fatal: Can't find unit IdStreamVCL used by IdStream

You can try compiling the Indy package with -Ur. Add this to the
compiler options of the Indy package.


> >What do they actually mean, in particular which process is emitting the message Fatal: Can't find unit IdStreamVCL used by IdStream?

Process: fpc
Meaning: a ppu file is outdated. There is a bug in fpc that can trigger
this. There are several ways to work around the bug. One is to use -Ur.



I will test your suggestion. I have always suspected that there some bugs in FPC that Indy triggers.
 
Mattias

--
_______________________________________________



--
Frank Church

=======================
http://devblog.brahmancreations.com

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Indy compilation problem revisited.

vfclists .


On 23 March 2011 16:20, Frank Church <[hidden email]> wrote:


On 22 March 2011 18:15, Mattias Gaertner <[hidden email]> wrote:
On Wed, 23 Mar 2011 00:44:43 +1100
Peter Williams <[hidden email]> wrote:

>[...]
> >Recompiling IdStreamVCL, checksum changed for IdGlobal
> >IdStreamVCL.pas(13,20) Fatal: Can't find unit IdStreamVCL used by IdStream

You can try compiling the Indy package with -Ur. Add this to the
compiler options of the Indy package.


> >What do they actually mean, in particular which process is emitting the message Fatal: Can't find unit IdStreamVCL used by IdStream?

Process: fpc
Meaning: a ppu file is outdated. There is a bug in fpc that can trigger
this. There are several ways to work around the bug. One is to use -Ur.



I will test your suggestion. I have always suspected that there some bugs in FPC that Indy triggers.
 


After trying it out it now compiling is okay, but when it comes to registration it stops on the file indylaz.pas, which is the file that registers the components.

It is sensible or the norm for the unit that does the registration to have the same base name of the project file?

ie indylaz.pas and indylaz.lpk

The file also appears to be created at compile time


{ This file was automatically created by Lazarus. do not edit!
  This source is only used to compile and install the package.
 }

unit indylaz;

interface

uses
    IdAbout, IdAboutVCL, IdAntiFreeze, IdCoreDsnRegister, IdDsnBaseCmpEdt,
  IdDsnCoreResourceStrings, IdDsnPropEdBinding, IdDsnPropEdBindingVCL,
  IdDsnRegister, IdDsnResourceStrings, IdDsnSASLListEditor,
  IdDsnSASLListEditorForm, IdDsnSASLListEditorFormVCL, IdRegister,
  IdRegisterCore, LazarusPackageIntf;

implementation

procedure Register;
begin
  RegisterUnit('IdCoreDsnRegister', @IdCoreDsnRegister.Register);
  RegisterUnit('IdDsnRegister', @IdDsnRegister.Register);
  RegisterUnit('IdRegister', @IdRegister.Register);
  RegisterUnit('IdRegisterCore', @IdRegisterCore.Register);
end;

initialization
  RegisterPackage('indylaz', @Register);
end.   




 
Mattias

--
_______________________________________________



--
Frank Church

=======================
http://devblog.brahmancreations.com



--
Frank Church

=======================
http://devblog.brahmancreations.com

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Indy compilation problem revisited.

vfclists .


On 23 March 2011 20:43, Frank Church <[hidden email]> wrote:


On 23 March 2011 16:20, Frank Church <[hidden email]> wrote:


On 22 March 2011 18:15, Mattias Gaertner <[hidden email]> wrote:
On Wed, 23 Mar 2011 00:44:43 +1100
Peter Williams <[hidden email]> wrote:

>[...]
> >Recompiling IdStreamVCL, checksum changed for IdGlobal
> >IdStreamVCL.pas(13,20) Fatal: Can't find unit IdStreamVCL used by IdStream

You can try compiling the Indy package with -Ur. Add this to the
compiler options of the Indy package.


> >What do they actually mean, in particular which process is emitting the message Fatal: Can't find unit IdStreamVCL used by IdStream?

Process: fpc
Meaning: a ppu file is outdated. There is a bug in fpc that can trigger
this. There are several ways to work around the bug. One is to use -Ur.



I will test your suggestion. I have always suspected that there some bugs in FPC that Indy triggers.
 



PS. I missed out the relevant error message:
Recompiling indylaz, checksum changed for IdAbout
indylaz.pas(79,12) Fatal: Can't find unit indylaz used by Lazarus

 

After trying it out it now compiling is okay, but when it comes to registration it stops on the file indylaz.pas, which is the file that registers the components.

It is sensible or the norm for the unit that does the registration to have the same base name of the project file?

ie indylaz.pas and indylaz.lpk

The file also appears to be created at compile time


{ This file was automatically created by Lazarus. do not edit!
  This source is only used to compile and install the package.
 }

unit indylaz;

interface

uses
    IdAbout, IdAboutVCL, IdAntiFreeze, IdCoreDsnRegister, IdDsnBaseCmpEdt,
  IdDsnCoreResourceStrings, IdDsnPropEdBinding, IdDsnPropEdBindingVCL,
  IdDsnRegister, IdDsnResourceStrings, IdDsnSASLListEditor,
  IdDsnSASLListEditorForm, IdDsnSASLListEditorFormVCL, IdRegister,
  IdRegisterCore, LazarusPackageIntf;

implementation

procedure Register;
begin
  RegisterUnit('IdCoreDsnRegister', @IdCoreDsnRegister.Register);
  RegisterUnit('IdDsnRegister', @IdDsnRegister.Register);
  RegisterUnit('IdRegister', @IdRegister.Register);
  RegisterUnit('IdRegisterCore', @IdRegisterCore.Register);
end;

initialization
  RegisterPackage('indylaz', @Register);
end.   




 
Mattias

--
_______________________________________________



--
Frank Church

=======================
http://devblog.brahmancreations.com



--
Frank Church

=======================
http://devblog.brahmancreations.com



--
Frank Church

=======================
http://devblog.brahmancreations.com

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Indy compilation problem revisited.

Mattias Gaertner
On Wed, 23 Mar 2011 20:47:36 +0000
Frank Church <[hidden email]> wrote:

> On 23 March 2011 20:43, Frank Church <[hidden email]> wrote:
>
> >
> >
> > On 23 March 2011 16:20, Frank Church <[hidden email]> wrote:
> >
> >>
> >>
> >> On 22 March 2011 18:15, Mattias Gaertner <[hidden email]>wrote:
> >>
> >>> On Wed, 23 Mar 2011 00:44:43 +1100
> >>> Peter Williams <[hidden email]> wrote:
> >>>
> >>> >[...]
> >>> > >Recompiling IdStreamVCL, checksum changed for IdGlobal
> >>> > >IdStreamVCL.pas(13,20) Fatal: Can't find unit IdStreamVCL used by
> >>> IdStream
> >>>
> >>> You can try compiling the Indy package with -Ur. Add this to the
> >>> compiler options of the Indy package.
> >>>
> >>>
> >>> > >What do they actually mean, in particular which process is emitting
> >>> the message Fatal: Can't find unit IdStreamVCL used by IdStream?
> >>>
> >>> Process: fpc
> >>> Meaning: a ppu file is outdated. There is a bug in fpc that can trigger
> >>> this. There are several ways to work around the bug. One is to use -Ur.
> >>>
> >>>
> >>>
> >> I will test your suggestion. I have always suspected that there some bugs
> >> in FPC that Indy triggers.
> >
>
> PS. I missed out the relevant error message:
> Recompiling indylaz, checksum changed for IdAbout
> indylaz.pas(79,12) Fatal: Can't find unit indylaz used by Lazarus

Well, if -Ur does not work, you have to bite the bullet and change the
uses sections. Remove "inline" modifiers from functions and try to move
units from the implementation to the interface section.


> > After trying it out it now compiling is okay, but when it comes to
> > registration it stops on the file indylaz.pas, which is the file that
> > registers the components.
> >
> > It is sensible or the norm for the unit that does the registration to have
> > the same base name of the project file?

Yes.

Note: Since 0.9.29 you can select another name.


>[...]


Mattias

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Indy compilation problem revisited.

Marco van de Voort
In reply to this post by Mattias Gaertner
On Tue, Mar 22, 2011 at 07:15:57PM +0100, Mattias Gaertner wrote:
>
> > >What do they actually mean, in particular which process is emitting the message Fatal: Can't find unit IdStreamVCL used by IdStream?
>
> Process: fpc
> Meaning: a ppu file is outdated. There is a bug in fpc that can trigger
> this. There are several ways to work around the bug. One is to use -Ur.

Afaik this bug is not caused by that, but due to includefiles with the same
name.

Indy copies their .inc file with $defines and compiler detection in every
dir, and FPC recompiles on (some?) .inc changes, while Delphi does not.

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Indy compilation problem revisited.

Mattias Gaertner
On Thu, 24 Mar 2011 09:20:49 +0100
Marco van de Voort <[hidden email]> wrote:

> On Tue, Mar 22, 2011 at 07:15:57PM +0100, Mattias Gaertner wrote:
> >
> > > >What do they actually mean, in particular which process is emitting the message Fatal: Can't find unit IdStreamVCL used by IdStream?
> >
> > Process: fpc
> > Meaning: a ppu file is outdated. There is a bug in fpc that can trigger
> > this. There are several ways to work around the bug. One is to use -Ur.
>
> Afaik this bug is not caused by that, but due to includefiles with the same
> name.
>
> Indy copies their .inc file with $defines and compiler detection in every
> dir, and FPC recompiles on (some?) .inc changes, while Delphi does not.

Yes, that is not a bug in fpc.
But duplicated include file is fixed by -Ur, isn't it?
So, the remaining is something different.

Mattias

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Indy compilation problem revisited.

Marco van de Voort
On Thu, Mar 24, 2011 at 09:28:54AM +0100, Mattias Gaertner wrote:
> > > Meaning: a ppu file is outdated. There is a bug in fpc that can trigger
> > > this. There are several ways to work around the bug. One is to use -Ur.
> >
> > Afaik this bug is not caused by that, but due to includefiles with the same
> > name.
> >
> > Indy copies their .inc file with $defines and compiler detection in every
> > dir, and FPC recompiles on (some?) .inc changes, while Delphi does not.


> Yes, that is not a bug in fpc.
> But duplicated include file is fixed by -Ur, isn't it?
> So, the remaining is something different.

I haven't tried with -Ur, but I could compile Indy easily by fixing this.

I've pointed this out to Indycore many, many times, but they keep mumbling
"difficult, should be exact copies", and nothing happens.

But while in theory exact copy with the same datetime should work (since
their path is the only differentiator and afaik not checked), extracting it
from an archive might already cause problems with the timestamps

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus