Lazarus

Programming => Operating Systems => macOS / Mac OS X => Topic started by: teriyaki on January 16, 2022, 04:31:08 pm

Title: [SOLVED] run Lazarus with error on macOS
Post by: teriyaki on January 16, 2022, 04:31:08 pm
I am developing an app using Lazarus.
It works well on Windows 10.
When I try to migrate the source code to macOS,
it reported error:

1. even a simple empty app can not compile and run on macOS

2. my app needs Zeos DB, Indy LCL to install, when I install the two LCL, it reports error

Your comment welcome
Title: Re: run Lazarus with error on macOS
Post by: trev on January 17, 2022, 12:43:42 am
I am developing an app using Lazarus.
It works well on Windows 10.
When I try to migrate the source code to macOS,
it reported error:

1. even a simple empty app can not compile and run on macOS

It's easier to get 1 fixed because it doesn't involve extra third-party packages.

So:

1) Does Menu > Run > Cleanup and Build fix the problem?
2) If not, what is the actual error when trying to compile the empty application?

[While I don't compile in Windows, I have no problem compiling the same cross-platform application in macOS and running it in Windows. That is, I can compile the same source code for both macOS and Windows in the same project.]
Title: Re: run Lazarus with error on macOS
Post by: teriyaki on January 17, 2022, 12:41:39 pm
I tried

Run
Clean up and Build

still got error as below
Title: Re: run Lazarus with error on macOS
Post by: trev on January 17, 2022, 11:37:57 pm
To fix the permission errors open an Applications > Utilities > Terminal and:

Quote
cd /Applications
sudo chown -R your_username Lazarus

Then try Cleanup and Build again.
Title: Re: run Lazarus with error on macOS
Post by: teriyaki on January 18, 2022, 07:20:05 am
thanks a lot

I have installed Zeos&Indy and compiled successfully.

But there is still a problem when run the empty app
Title: Re: run Lazarus with error on macOS
Post by: trev on January 18, 2022, 12:29:35 pm
You are trying to run the empty application under a debugger without first setting up the debugger.

Please see Step 5 in my Wiki article Installing Lazarus on macOS (https://wiki.freepascal.org/Installing_Lazarus_on_macOS).

If you do not want to run the empty application under the debugger, then choose IDE > Run > Run without debugging.
Title: Re: run Lazarus with error on macOS
Post by: teriyaki on January 18, 2022, 04:10:28 pm
the GUI of the new version of Lazarus changed a lot.

I can not find out where the debugger Tools > Options > Debugger is

https://wiki.freepascal.org/Installing_Lazarus_on_macOS#Step_5:_Configure_the_Debugger
Title: Re: run Lazarus with error on macOS
Post by: trev on January 19, 2022, 02:44:54 am
the GUI of the new version of Lazarus changed a lot.

I can not find out where the debugger Tools > Options > Debugger is

Lazarus > Preferences > Debugger... as per the section in Step 5:

Quote
In the latest versions of Lazarus (tested on 2.1.0 compiled from source) click Lazarus > Preferences... > Debugger > Debugger backend.  In the Debugger type and path box select "LLDB debugger (with fpdebug)(Beta) and /usr/bin/lldb.

I'll make it clear sooner (that quotation is currently at the end of the section).
Title: Re: run Lazarus with error on macOS
Post by: teriyaki on January 21, 2022, 05:02:44 pm
it works !

thanks
Title: Re: run Lazarus with error on macOS
Post by: trev on January 21, 2022, 11:16:38 pm
Great! Thanks for confirming the issue is solved.
Title: Re: run Lazarus with error on macOS
Post by: teriyaki on January 22, 2022, 02:33:02 am
if there is a function/button can mark the answer as the accepted answer will be better.

I can not find it  :(

Title: Re: run Lazarus with error on macOS
Post by: trev on January 22, 2022, 04:03:21 am
The usual practice is to add "[SOLVED]" to the start of the subject line in the first post.
TinyPortal © 2005-2018