Recent

Author Topic: [SOLVED] Multiple Installments of FPC  (Read 5406 times)

lazarusbw

  • Newbie
  • Posts: 3
[SOLVED] Multiple Installments of FPC
« on: July 23, 2021, 10:56:05 pm »
Is it possible, hopefully even easy, to install the 3.2.2 FPC on the same Windows 7 system that now is home to 3.0.4 and Lazarus 2.0.6? The answer to "why do that?" would be time consuming beyond most people's patience. If there is a "yes" out there anywhere, wouldn't you know, there is going to be the eventual how from me. Thanks for listening.
« Last Edit: August 17, 2021, 01:01:36 am by lazarusbw »

wp

  • Hero Member
  • *****
  • Posts: 8787
Re: Multiple Installments of FPC
« Reply #1 on: July 23, 2021, 11:03:30 pm »
On the second page (I think) of the installer there is a checkbox "Secondary installation". When you check it this installation will be independent of the previously installed Lazarus. Of course you must choose a different installation directory, and you should also select a different directory for the user settings, and do not register any file types. Of course you can repeat the same with other installations.
Mainly Lazarus trunk / fpc 3.2.0 / all 32-bit on Win-10, but many more...

lucamar

  • Hero Member
  • *****
  • Posts: 4219
Re: Multiple Installments of FPC
« Reply #2 on: July 23, 2021, 11:08:53 pm »
If all you want is FPC 3.2.0 alongside a Laz/FPC 2.0.6/3.0.4 then it's it's even simpler: just download and run the FPC 3.2.0 installer and it'll install 3.2.0 in his own (top level) directory c:\fpc\

Only problem you might find is with the search order in the PATH but that is easily solvable with a simple batch file to change the path to find first whichever FPC you want and back.
Turbo Pascal 3 CP/M - Amstrad PCW 8256 (512 KB !!!) :P
Lazarus/FPC 2.0.8/3.0.4 & 2.0.12/3.2.0 - 32/64 bits on:
(K|L|X)Ubuntu 12..18, Windows XP, 7, 10 and various DOSes.

lazarusbw

  • Newbie
  • Posts: 3
Re: Multiple Installments of FPC
« Reply #3 on: July 23, 2021, 11:12:43 pm »
Amazingly rapid responses. That alone means off to sip some coffee just to calm down. Thank you for the advice. Now, off to coffee and installation explorations.

Bart

  • Hero Member
  • *****
  • Posts: 4433
    • Bart en Mariska's Webstek
Re: Multiple Installments of FPC
« Reply #4 on: July 23, 2021, 11:21:11 pm »
Is it possible, hopefully even easy, to install the 3.2.2 FPC on the same Windows 7 system that now is home to 3.0.4 and Lazarus 2.0.6?

Yes, I have fpc 3.0.4, 3.2.0, 3.2.2 and fpc trunk installed on my Windows (and Lazarus fixes branch and Lazarus trunk: both built from sources with fpc 3.2.2., and a Lazarus trunk compiled with fpc trunk).

Just run the official fpc installer.
You may need to adjust the systems path, so that by default your favorite fpc comes first in the path (or as the only one: if you have the win32->win64 crosscompiler installed for 3.0.4 and not for 3.2.2, then fpc -Px86_64 will in fact start the 3.0.4 crosscompiler, if 3.0.4 is in the systems path).

Bart

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 9541
  • FPC developer.
Re: Multiple Installments of FPC
« Reply #5 on: July 24, 2021, 11:24:20 am »
I have a bunch of installed, but none in the PATH.

I use a set of batchfiles to quickly switch, e.g.
Code: [Select]
@echo off

Rem we save oldpath only once, so we can always revert to it.

if "%OLDPATH%" neq "" goto :nosave
set OLDPATH=%PATH%
:nosave
SET PATH=%OLDPATH%
PATH d:\fpc\3.2.2\bin\i386-win32;%PATH%

Basically it adds 3.2.2 to the path, but saves the original path. This means I can call several in sequence without ending up with a gigantic set of FPC paths in the %PATH%  :)

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 7414
  • Debugger - SynEdit - and more
    • wiki
Re: Multiple Installments of FPC
« Reply #6 on: July 24, 2021, 11:36:10 am »
I don't have any of my many fpc installs in PATH.

At least, if running them from Lazarus, that does not seem to be needed. (Afaik, the IDE sets the current directory). It's all found in either "current dir" or "the folder from which fpc was started". Not sure which.

However, if you are using "make", you need to have at least make, possible also fpc in path. Not sure.

Gustavo 'Gus' Carreno

  • Hero Member
  • *****
  • Posts: 739
  • Professional amateur ;-P
Re: Multiple Installments of FPC
« Reply #7 on: July 24, 2021, 06:16:13 pm »
Hey lazarusbw,

There's also the amazing fpcupdeluxe. I'm amazed that I'm always the one to mention this, LOL!!!

With fpcupdeluxe I've installed 5, side by side, Lazarus and FPC combinations with various levels of cross-compilation:
  • Lazarus and FPC, both on trunk, with cross-compile for Lin32, Win64, Win32, Raspberry Pie, Arduino
  • Lazarus and FPC, both stable, with cross-compile  for Lin32, Win64, Win32, Raspberry Pie, Arduino
  • Lazarus and FPC, 2.0.12 and 3.2.0
  • Lazarus and FPC, 2.0.10 and 3.2.0
  • Lazarus and FPC, 2.0.6 and 3.0.4

You can also have that type of variety in your machine.

Cheers,
Gus
Lazarus 2.3.0(trunk) FPC 3.3.1(trunk) Ubuntu 21.04 64b Dark Theme
Lazarus 2.0.12(stable) FPC 3.2.2(stable) Ubuntu 21.04 64b Dark Theme
http://github.com/gcarreno

trev

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1589
  • Former Delphi 1-7, 10.2 user
Re: Multiple Installments of FPC
« Reply #8 on: July 25, 2021, 03:50:35 am »
There's also the amazing fpcupdeluxe. I'm amazed that I'm always the one to mention this, LOL!!!

Perhaps because it is not the officially sanctioned or supported installation method and has, from time to time, its own bugs, all of which makes determining what is going wrong when a user rocks up saying installation failed more difficult. In the past I have had the issue of making sense of failed MacPorts and FPCUpDeluxe installs which was not fun especially when users attempted multiple installs.
Lazarus 2.3 2021-08-10 FPC 3.3.1 r49223 macOS 10.14.6 Xcode 11.3.1
Lazarus 2.3 r65500 FPC 3.3.1 r49634 macOS 11.6 aarch64 Xcode 13
Lazarus 2.3 2021-08-11 FPC 3.2.2 FreeBSD 13.0 amd64 VMware VM
Lazarus 2.1 r61574 FPC 3.0.4 Ubuntu 20.04 Parallels VM
Lazarus 2.0.10 FPC 3.2.0 Win10 Parallels VM

Gustavo 'Gus' Carreno

  • Hero Member
  • *****
  • Posts: 739
  • Professional amateur ;-P
Re: Multiple Installments of FPC
« Reply #9 on: July 26, 2021, 01:34:31 am »
Hey Trev,

Perhaps because it is not the officially sanctioned or supported installation method ...

Hummm, never thought of it from that angle. Thanks, Trev, for giving me another perspective that I was lacking!!

... and has, from time to time, its own bugs, all of which makes determining what is going wrong when a user rocks up saying installation failed more difficult. In the past I have had the issue of making sense of failed MacPorts and FPCUpDeluxe installs which was not fun especially when users attempted multiple installs.

Yeap, I get it now. Thanks again, Trev, for a third person's view that I wasn't experienced with.
Since I've been using fpcudeluxe I've had a few problems, of course, but they were never something I wasn't able to solve.
Well, if you consider the extreme case of deleting the folder and starting all over again a solution.
So, very wrongly, I've been assuming that my experience with it has been the same across the board, which I should know, by now, is a cognitive bias and I should avoid it. Yeah, thems are the worst to avoid ;)

Nonetheless, fpcupdeluxe is still a very good tool to have on your arsenal, even if it's a pain to help with around here, so I'll continue recommending it and I apologise for any future trouble shooting some of use will have to endure.

What you think Trev, is that okay with you?

Cheers,
Gus
Lazarus 2.3.0(trunk) FPC 3.3.1(trunk) Ubuntu 21.04 64b Dark Theme
Lazarus 2.0.12(stable) FPC 3.2.2(stable) Ubuntu 21.04 64b Dark Theme
http://github.com/gcarreno

trev

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1589
  • Former Delphi 1-7, 10.2 user
Re: Multiple Installments of FPC
« Reply #10 on: July 26, 2021, 02:38:06 am »
I have no particular issue with FPCUpDeluxe which I think is an absolutely amazing work by Fred, but I don't recommend it over the official installations for new users doing their first install.

For myself, I use my own scripts for non-release installations from source of both FPC and Lazarus simply because I like to know what's going on and when it goes south, I can debug it easily and generally fix whatever the issue happens to be. That's the only reason why I don't use FPCUpDeluxe.
Lazarus 2.3 2021-08-10 FPC 3.3.1 r49223 macOS 10.14.6 Xcode 11.3.1
Lazarus 2.3 r65500 FPC 3.3.1 r49634 macOS 11.6 aarch64 Xcode 13
Lazarus 2.3 2021-08-11 FPC 3.2.2 FreeBSD 13.0 amd64 VMware VM
Lazarus 2.1 r61574 FPC 3.0.4 Ubuntu 20.04 Parallels VM
Lazarus 2.0.10 FPC 3.2.0 Win10 Parallels VM

Gustavo 'Gus' Carreno

  • Hero Member
  • *****
  • Posts: 739
  • Professional amateur ;-P
Re: Multiple Installments of FPC
« Reply #11 on: July 26, 2021, 02:47:20 am »
Hey Trev,

I have no particular issue with FPCUpDeluxe which I think is an absolutely amazing work by Fred, but I don't recommend it over the official installations for new users doing their first install.

Noted and I'll begin to add a disclaimer when I mention fpcupdeluxe just in case my cognitive biases run amok.
Your arguments are quite valid and, again, maybe due to some cognitive bias, this has completely never popped up in my brain.
Again, many thanks Trev for giving me a bit more perspective!!

For myself, I use my own scripts for non-release installations from source of both FPC and Lazarus simply because I like to know what's going on and when it goes south, I can debug it easily and generally fix whatever the issue happens to be. That's the only reason why I don't use FPCUpDeluxe.

To each their own and as long as we use it, doesn't really matter how we install it, right?

Cheers,
Gus

PS:
I have no particular issue with FPCUpDeluxe which I think is an absolutely amazing work by Fred[...]
I couldn't agree more !!! :)
Lazarus 2.3.0(trunk) FPC 3.3.1(trunk) Ubuntu 21.04 64b Dark Theme
Lazarus 2.0.12(stable) FPC 3.2.2(stable) Ubuntu 21.04 64b Dark Theme
http://github.com/gcarreno

 

TinyPortal © 2005-2018