Page 1 of 1
Forum

Welcome to the Tweaking4All community forums!
When participating, please keep the Forum Rules in mind!

Topics for particular software or systems: Start your topic link with the name of the application or system.
For example “MacOS X – Your question“, or “MS Word – Your Tip or Trick“.

Please note that switching to another language when reading a post will not bring you to the same post, in Dutch, as there is no translation for that post!



Share:
Notifications
Clear all

[Solved] Lazarus Pascal - Possible fix for a corrupted LPI

1 Posts
1 Users
0 Reactions
20 Views
 Hans
(@hans)
Famed Member Admin
Joined: 13 years ago
Posts: 3035
Topic starter  

So I had this the other day: I had a project developed under macOS and opened it under Windows to compile it there.
Oddly enough, opening the project under macOS would crash the IDE, which comes with that nervous feeling you just ruined your entire project.

So the project would still open under Windows correctly.
Opening it under macOS (not simultaneously of course) would give an error and the option to retry which then would crash the IDE.

In an attempt to debug this I used the Lazarus debug option:

./lazarus --debug-log=~/lazaruslog.txt

Note that I'm starting Lazarus from Terminal, and am using the "lazarus" binary - not the lazarus.app, and not startlazarus!

The resulting log file was rather useless, but ... Lazarus did open and fixed the LPI file once I saved and closed Lazarus again.

Now this is obviously not what the debug function is for, but it saved my project.
Just posting it here in case it is of use to anyone.

Note: this does not always work of course!


This topic was modified 13 hours ago by Hans

   
ReplyQuote
Share: