Recent

Author Topic: Using old LCL  (Read 7309 times)

dodi

  • New Member
  • *
  • Posts: 25
Using old LCL
« on: February 06, 2023, 05:04:13 pm »
I've just found a very old LCL (0.8.5.2) that I would like to use with a current Lazarus IDE. Last installed is IDE 2.0.12.

How can I swap the old LCL for the new one in the IDE?

For the curious: I'm searching for a component base without AnchorDocking.

Thaddy

  • Hero Member
  • *****
  • Posts: 16187
  • Censorship about opinions does not belong here.
Re: Using old LCL
« Reply #1 on: February 06, 2023, 07:00:03 pm »
Old versions of any software is not maintained. Use the old software.
If I smell bad code it usually is bad code and that includes my own code.

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 10553
  • Debugger - SynEdit - and more
    • wiki
Re: Using old LCL
« Reply #2 on: February 06, 2023, 08:37:23 pm »
For the curious: I'm searching for a component base without AnchorDocking.

Just don't use it?
Don't install it. Don't add it to any project.

If needs must, delete the folder...



Any (such) old LCL will not be able to read forms (lfm files) by any newer IDE.
Also, it will not compile with current FPC. So you would need an ages old fpc.

And likely tons of other issues. Probably not working with current versions of Windows or Linux.




Thaddy

  • Hero Member
  • *****
  • Posts: 16187
  • Censorship about opinions does not belong here.
Re: Using old LCL
« Reply #3 on: February 06, 2023, 08:40:44 pm »
Indeed.
If I smell bad code it usually is bad code and that includes my own code.

KodeZwerg

  • Hero Member
  • *****
  • Posts: 2269
  • Fifty shades of code.
    • Delphi & FreePascal
Re: Using old LCL
« Reply #4 on: February 06, 2023, 08:48:44 pm »
« Last Edit: Tomorrow at 31:76:97 xm by KodeZwerg »

dodi

  • New Member
  • *
  • Posts: 25
Re: Using old LCL
« Reply #5 on: February 06, 2023, 11:56:56 pm »
Any (such) old LCL will not be able to read forms (lfm files) by any newer IDE.
Also, it will not compile with current FPC.

We'll see.

Unfortunately I don't remember and cannot find how to install the entire Lazarus/fpc version. Can somebody help with *.rpm files based distribution?

Otherwise for a first attack can I simply replace the newer LCL source folder by the old one? Or where can I change the Lazarus source folder?

dbannon

  • Hero Member
  • *****
  • Posts: 3156
    • tomboy-ng, a rewrite of the classic Tomboy
Re: Using old LCL
« Reply #6 on: February 07, 2023, 12:11:12 am »
Hi Dodi, did you read the comments above ?  Mixing old with new will lead certainly fail !  Using just the old ones, that is at least the old FPC, the old Lazarus and possibly the old Linux might get you going but why on earth would you want to ?

https://wiki.freepascal.org/Installing_Lazarus_on_Linux  shows you how to install properly in several different ways.  Your distro provided one is probably easiest but will get you a slightly older version probably.

My (always) recommended model is to check you distro's package manager and if it provides FPC 3.2.2 (and its likely) then install that and the lazarus dependencies and then build Lazarus from source.

Its all documented in the above wiki page, if you run into problems after reading that wiki page, come back.

Davo
Lazarus 3, Linux (and reluctantly Win10/11, OSX Monterey)
My Project - https://github.com/tomboy-notes/tomboy-ng and my github - https://github.com/davidbannon

TRon

  • Hero Member
  • *****
  • Posts: 3641
Re: Using old LCL
« Reply #7 on: February 07, 2023, 06:17:23 am »
Any (such) old LCL will not be able to read forms (lfm files) by any newer IDE.
Also, it will not compile with current FPC.

We'll see.
Just a heads up: You'll fail  :)

Quote
Unfortunately I don't remember and cannot find how to install the entire Lazarus/fpc version. Can somebody help with *.rpm files based distribution?
Use the source Luke !

Quote
Otherwise for a first attack can I simply replace the newer LCL source folder by the old one? Or where can I change the Lazarus source folder?
Oh boy. Don't take my word for it and for sure do not take it personally but if you ask such type of questions then you are in over your head and have no idea about what others just tried to tell you and the implications that your idea has/will have.

Just use the old source-code for compiler and Lazarus and build your own (custom) setup. Mixing the new with old /will/ fail.
This tagline is powered by AI (AI advertisement: Free Pascal the only programming language that matters)

dodi

  • New Member
  • *
  • Posts: 25
Re: Using old LCL
« Reply #8 on: February 09, 2023, 06:18:53 am »
if you run into problems after reading that wiki page, come back.
Now I tried to install Lazarus on MintFX from gitlab repository. Make fails with

<pre>Free Pascal Compiler version 3.0.4+dfsg-18ubuntu2 [2018/08/29] for x86_64
Copyright (c) 1993-2017 by Florian Klaempfl and others
(1002) Target OS: Linux for x86-64
(3104) Compiling fcllaz.pas
/home/dodi/lazarus/packager/registration/fcllaz.pas(11,3) Fatal: (10022) Can&apos;t find unit db used by fcllaz
</pre>

What's wrong?

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 11944
  • FPC developer.
Re: Using old LCL
« Reply #9 on: February 09, 2023, 09:26:36 am »

(3104) Compiling fcllaz.pas
/home/dodi/lazarus/packager/registration/fcllaz.pas(11,3) Fatal: (10022) Can&apos;t find unit db used by fcllaz
</pre>

What's wrong?

Db is a standard FPC unit. Wrong or partial install of FPC. Make sure you install all the fpc-* packages.

MarkMLl

  • Hero Member
  • *****
  • Posts: 8035
Re: Using old LCL
« Reply #10 on: February 09, 2023, 09:58:15 am »
You're going to have problems, both technical and- as you're seeing- otherwise.

I don't think you'll manage to use a very old LCL with an IDE which is grossly newer. There have been a couple of inflection points: a relatively recent change in the IDE's .lfm format (with an option to use the older format added after enough users had squealed) plus one somewhere around Lazarus v1 where it started embedding version numbers. There was also a major reorganisation of the various tabbed controls, and of Synedit.

If my memory is correct, there's been at least one IDE change which had to be paralleled by a compiler change (not necessarily on all platforms): TFrame support somewhere around FPC 2.6.4.

There's the perennial problem of the widget set supported by the IDE being obsoleted or having an underlying library change, e.g. GTK1 being obsoleted plus occasional problems with Qt.

There were changes around FPC 3 related to the linker's -T warning. And there's probably still a current linker foulup affecting Debian testing/sid/Bookworm, and it was the hostile way that was handled that resulted in my spending far less time on the forum than I used to.

The oldest Lazarus+FPC that I'm currently running is 0.9.24 2.2.4 on Debian "Lenny" i386. I might have had slightly older versions running in the past, but if one tries to work back much further one has problems with the FPC release which Does Not Exist.

I believe that I have in the past managed to run Debian "Lenny" i386 is a Docker container on a much newer x86_64 system: with a bit of setup one can ssh into it hence run a version of the IDE which requires older underlying libraries etc. Failing that Qemu etc. will obviously work.

MarkMLl
MT+86 & Turbo Pascal v1 on CCP/M-86, multitasking with LAN & graphics in 128Kb.
Logitech, TopSpeed & FTL Modula-2 on bare metal (Z80, '286 protected mode).
Pet hate: people who boast about the size and sophistication of their computer.
GitHub repositories: https://github.com/MarkMLl?tab=repositories

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 11944
  • FPC developer.
Re: Using old LCL
« Reply #11 on: February 09, 2023, 10:04:43 am »
There are so many things, just from the top of my head: $Mode objfpc requiring properties to be sorted, taking the address of properties that refer to a field is no longer allowed.


MarkMLl

  • Hero Member
  • *****
  • Posts: 8035
Re: Using old LCL
« Reply #12 on: February 09, 2023, 10:30:51 am »
There are so many things, just from the top of my head: $Mode objfpc requiring properties to be sorted, taking the address of properties that refer to a field is no longer allowed.

True. And of course the point that I omitted was that a specific Lazarus version typically had a very small number of FPC versions that it could be built with (and with which it would work happily), and that the FPC sources typically requires the previous stable FPC to build. The result of that is that working backwards towards an older version that one want to use is tricky: one really has to start off with a very old FPC binary from FTP etc. and then work forwards.

I used to keep the full range on i386 and test various things regularly, but the move to x86_64 has introduced another inflection. Hats off to Linux+Docker here for generally being pretty good about old distreaux on a modern kernel.

MarkMLl
MT+86 & Turbo Pascal v1 on CCP/M-86, multitasking with LAN & graphics in 128Kb.
Logitech, TopSpeed & FTL Modula-2 on bare metal (Z80, '286 protected mode).
Pet hate: people who boast about the size and sophistication of their computer.
GitHub repositories: https://github.com/MarkMLl?tab=repositories

dodi

  • New Member
  • *
  • Posts: 25
Re: Using old LCL
« Reply #13 on: February 09, 2023, 11:37:47 am »
Db is a standard FPC unit. Wrong or partial install of FPC. Make sure you install all the fpc-* packages.
I installed (again) both the fpc and fpc-source packages of fpc 3.0.4 and run into

Code: Pascal  [Select][+][-]
  1. Fatal: (10026) There were 50 errors compiling module, stopping
  2. Fatal: (1018) Compilation aborted
  3. Makefile:3354: recipe for target 'lazutils.ppu' failed
  4. make[1]: *** [lazutils.ppu] Error 1
  5. make[1]: Leaving directory '/home/dodi/lazarus/components/lazutils'
  6. Makefile:1964: recipe for target 'lazutils' failed
  7. make: *** [lazutils] Error 2

From which source can I obtain a current and working fpc/Lazarus system?

KodeZwerg

  • Hero Member
  • *****
  • Posts: 2269
  • Fifty shades of code.
    • Delphi & FreePascal
Re: Using old LCL
« Reply #14 on: February 09, 2023, 11:43:16 am »
From which source can I obtain a current and working fpc/Lazarus system?
You can experiment with Fcpupdeluxe which is a GUI installer for FPC and Lazarus in one easy to use app.
Good luck!
« Last Edit: Tomorrow at 31:76:97 xm by KodeZwerg »

 

TinyPortal © 2005-2018