[Lazarus] Environment variables in IDE's search path
Mattias Gaertner
nc-gaertnma at netcologne.de
Sat May 16 08:04:53 CEST 2009
On Sat, 16 May 2009 09:46:17 +0400
dmitry boyarintsev <skalogryz.lists at gmail.com> wrote:
> 2009/5/16 Mattias Gaertner <nc-gaertnma at netcologne.de>:
> >
> > Why? What is not compatible?
> >
> > 1. The lpi file stores the used path delimiter and converts the
> > paths automatically.
> > 2. The file names are stored as UTF-8.
> > 3. The IDE always tries to store relative file names.
> > 4. The IDE tries to find out the real file upper/lower under
> > windows.
>
> Let's assume, there's a team of developers working on the same
> project. The project uses some 3d party lib. It can be located
> anywhere on developer's machine. So relative paths for one developer,
> are not suitable for other developer's configuration.
That's why there are packages.
Put the 3rd party lib in a package.
Packages can be anywhere on your disk.
Each developer need to open once the .lpk file. Then the IDE knows
where to find the package on the machine. The next time a project needs
the package with this name the IDE will find it. This information is
stored in the lazarus config directory.
You can store a default path to the lpk in the lpi too. So when you
distribute a package together with a project the package is found
automatically.
> Yes, it can be fixed, by forcing all developers to have the same
> directory structure, or by using lazarus packages . But is there any
> other way?
Of course.
And they don't even need to use the same package version.
> on Delphi it's resolved by declaring system environment variable, i.e:
> SOMELIB=c:\work\somelib
> and the delphi's search path is declared as this
> ${SOMELIB}\
>
> AFAIK, Lazarus uses internal codetool defines, like ${LazarusDir}
> $(TargetCPU) $(LCLWidgetType) and so on.
> IDE does not support environment variables in search paths. Am i wrong
> here? if i'm right, how hard would it be to implement?
A search path is seldom enough.
Mattias
More information about the Lazarus
mailing list