[fpc-pascal] Re: fpc registry unit

Sven Barth pascaldragon at googlemail.com
Sat Mar 2 12:00:03 CET 2013


On 02.03.2013 01:01, John Lee wrote:
> Registry is not part of rtl because it's not a base unit??? This is my
> point it uses 200 other f*** units that aren't really needed!

Not needed by you perhaps. The Registry unit also provides the 
TRegIniFile out of Delphi compatiblity which is a TIniFile descendant of 
which the name value pairs are stored in the registry.

> So you are saying if one wants a single 50 line unit & does a complex
> procedure eg installi ng 10^10 lines of fpc etc then it is simple?  And
> of course you have to do this for every version of fpc you want to use!

You install the FPC distribution once and then you have access to all 
the units provided with FPC. And in normal cases the compiler will 
recognize if you don't use certain code or certain classes in a unit and 
then it will not link in the corresponding code (e.g. the TRegIniFile 
mentioned above will not be in your final executable if you don't use 
it). The compiler needs all used units however during the parsing phase 
to check whether everything is ok.

> And, of course as I've seen, the size of the .exe from  v2.2.2 cf v2.6.2
> is twice as large because of all the c*** included by the various uses..

You need to give explicit examples and what compiler options you used. 
These can make a big difference.

> This is all simple?  Not in my dictionary's definition! Dooooooh

Yes, it is simple.

Regards,
Sven



More information about the fpc-pascal mailing list