Forum > General
Projects written in old Free Pascal
rigczTheSky:
Hello everyone. A few months ago i've got a new job. When i started, i found out that i have to work on Lazarus v 0.9.22. It is like that because my project was primarly written on Turbo Pascal. Next was moved on Lazarus propably someday in 2007. As my collegue said, there was a huge change in Lazarus development propably between version 0.9.22 and 0.9.24 and when new version was released it wasn't possible to compile our code on that. My team tried to rewrite project but the further they goes, the more complicated things became. I heard one of the biggest problem was with wide string. Finally they gave up and until today we work on Lazarus beta version.
I'd like to ask what would you do on my place. Please, don't say "Change your job". I want to keep this project and improve it. Maybe there is a plugin which let me run old Free Pascal code on a newer version or some tool to convert old code. I heard that Delphi could handle old Free Pascal code bether than Lazarus but i'm not sure of that. Anyway, i would like your help.
AlexTP:
Better show us the small test-demo with hard parts (parts taken from your work project). Why this demo is hard to update to Lazarus 2.0?
wp:
--- Quote from: rigczTheSky on November 27, 2023, 01:41:48 pm ---[...] because my project was primarly written on Turbo Pascal.
--- End quote ---
Does your project work in {$mode tp}?
https://www.freepascal.org/docs-html/prog/progse73.html
Handoko:
It is mentioned, the code couldn't compile. So that were compile-time errors. What were the error messages? If it is hard to provide us a small test demo as mentioned, at least you should show us the error messages.
Actually fixing the code isn't too difficult, but it will take plenty of time. All you need to do is step-by-step recompile the code using higher version of Lazarus progressively.
Here is the list of all versions:
https://wiki.freepascal.org/Category:Release_Notes
Until you found the version that won't able to compile the code. For example, if you have no problem compiling until Lazarus version 0.9.30. Follow the link above and click the release note of Lazarus 0.9.30. There you will have information about "Changes affecting compatibility". That probably is the information you need.
But you also need to pay attention about the version of the FPC. You can read them in the link above, which have link started with "User Changes ..."
Alternatively. You can try by skipping some versions but if it fail, then you go down 1 version each time until you find the lowest un-compilable version.
Bart:
--- Quote from: rigczTheSky on November 27, 2023, 01:41:48 pm ---As my collegue said, there was a huge change in Lazarus development propably between version 0.9.22 and 0.9.24
--- End quote ---
Looking at the release notes of 0.9.24, there aren't that many major changes.
Most notably, and indeed breaking, are the changes to TMaskEdit (all of them currently fixed).
B.t.w. what platform are you on (Windows, Linux, macOS)?
Bart
PS. IIRC then 0.9.22 was far from a stable version, it crashes repeatedly on my WinMe machine...
Navigation
[0] Message Index
[#] Next page