[lazarus] Compiler Options

Michal Bukovjan m_bukovjan at advis.cz
Mon Mar 20 03:06:48 EST 2000


Curtis White wrote:

> I just commited a new version of the Compiler Options dialog to CVS. It
> now saves the options in an XML file. But there are a couple of problems I
> can't seem to be able to figure out. Can someone take a look at this and
> see if you can see something obvious I am doing wrong?
>
> Here are the problems.
>
> In the TCompilerOptions class, in the Create method, it creates a
> TXMLConfig object near the top. When this object is created, you pass in a
> path to the XML file you want it to use. I have currently hardcoded the
> path to /opt/fpc/lazarus/cplopts.xml.  So Windows users will need to
> change this before you compile it, if you are going to go into the
> Compiler Options dialog. The reason for the hardcoded path is that for
> some reason the following method does not seem to be returning the path:
>
> ExtractFilePath(ParamStr(0));

For the storage of Lazarus options, I would recommend using something like
~/lazarus/.compileroptions.xml instead. This is the preferred Unix way. For
the application executable EXEname, Application.EXEName is used in Delphi,
but I think it is not implemented right now. In the above directory, these
would be user-specific options. The global defaults should go to
/etc/lazarus/.compileroptions.xml

I think that these options/directories should be defined in the Makefile, as
it is done this way in any other project I have worked in Unix. This would
allow to define something else for Windows. (But I don't know enough about
Makefiles, any idea?)

Michal Bukovjan






More information about the Lazarus mailing list