[Lazarus] How to use two different versions of FPC
Joost van der Sluis
joost at cnoc.nl
Wed May 9 12:34:31 CEST 2018
Op 08-05-18 om 13:46 schreef Giuliano Colla via Lazarus:
> E.G. you may have a full tree (fpc+Lazarus) in ~/development/ another
> one in ~/production and a third one in ~/experiments. The main trick, as
> far as fpc is concerned, is to have as fpc executable an fpc.sh (a name
> which is accepted by Lazarus) which sets up whatever is needed. This is
> a sample of fpc.sh:
>
>> #!/bin/sh # This script starts the fpc compiler installed by fpcup #
>> and ignores any system-wide fpc.cfg files # Note: maintained by fpcup;
>> do not edit directly, your edits will be lost.
>> /home/colla/development/fpc/bin/x86_64-linux/fpc -n
>> @/home/colla/development/fpc/bin/x86_64-linux/fpc.cfg "$@"
That's more a hack then a solution, and the real solution is simple and
also works outside Lazarus: place the fpc.cfg in ~/experiments/etc,
~/development/etc etc, as already suggested by Ingo. Or, even better,
just alongside the compiler-executable. You can call 'fpc -va' to check
which configuration file is used.
See the documentation for more info:
https://www.freepascal.org/docs-html/user/usersu10.html
Regards,
Joost.
More information about the Lazarus
mailing list