On Sat, 6 Feb 2021 01:15:46 +0000, Graeme Geldenhuys via fpc-pascal <fpc-pascal@lists.freepascal.org> wrote:
>On 05/02/2021 11:18 pm, Bo Berglund via fpc-pascal wrote: >> Can they share the same fpc.cfg file (or rather .fpc.cfg)? > >Yes, I've been doing so for probably the last 10 years. I have >7 different FPC versions installed on my system - all working together. > >The trick is to have paths as follows in you ~/.fpc.cfg file: > .... >I'm happy to send you a full copy of my ~/.fpc.cfg file if that will help. > >And as you can see from my paths above, all my FPC version are all installed >under the /data/devel/* path and looks like this: > >===================== >/data/devel/fpc-2.6.4 > ??? src/ > ??? x86_64-freebsd/ > ??? x86_64-linux/ >/data/devel/fpc-3.0.0 > ??? go.sh* > ??? src/ > ??? x86_64-freebsd/ > ??? x86_64-linux/ >/data/devel/fpc-3.0.2 > ??? go.sh* > ??? src/ > ??? x86_64-freebsd/ > ??? x86_64-linux/ >/data/devel/fpc-3.0.4 > ??? go.sh* > ??? src/ > ??? x86_64-freebsd/ > ??? x86_64-linux/ >/data/devel/fpc-3.2.0 > ??? go.sh* > ??? src/ > ??? x86_64-freebsd/ > ??? x86_64-linux/ >/data/devel/fpc-3.2.1 > ??? go.sh* > ??? src/ > ??? x86_64-linux/ >/data/devel/fpc-3.3.1 > ??? go-arduino.sh* > ??? go-freebsd.sh* > ??? go.sh* > ??? src/ > ??? x86_64-linux/ > >===================== > > >The "go.sh" files you see are to compile the desired FPC version with the >previous stable FPC version, and install it into the correct location. > >=============[ example go.sh ]=============== >#!/bin/sh > >TARGET_VER=3.2.0 >TARGET=x86_64-linux >COMPILER=/data/devel/fpc-3.0.4/$TARGET/bin/ppcx64 > >cd src > >make clean >make all FPC=$COMPILER OPT="-Fl/usr/local/lib" >make install INSTALL_PREFIX=/data/devel/fpc-$TARGET_VER/$TARGET >FPC=/data/devel/fpc-$TARGET_VER/src/compiler/ppcx64 >============================================= > >I use this same setup in my Windows VMs too, when I need to support multiple >FPC versions. Graeme thanks for the info! Since I am not doing any fpc or lazarus development I guess I don't really need all of that.. My .fpc.cfg file also has the $fpcversion everywhere in the paths so I guess that unless a new version of fpc adds extra stuff into the file I don't really need to modify the .fpc.cfg file when installing a new fpc release? In that case I will add a note in my script file (I use it on Linux platforms to install from sources) to the effect that this is only needed for a first install on any given device. BTW, my installs sit in: fpc: $HOME/dev/fpc/$fpcversion lazarus: $HOME/dev/lazarus/$lazversion And the support files go into $HOME/lib/fpc/ and $HOME/share -- Bo Berglund Developer in Sweden _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal