This is a temporary trick I use to kind-a get Lazarus Pascal to run under macOS Mojave.
Minor refresh issues remain though and compiling your final product under macOS 10.13.x is recommended (I use Parallels Desktop Lite for that, it's free in the Apple App Store and you can install 10.13.x on it without a problem).
Steps to get Lazarus running;
1) Remove the directory "/Library/Developer/CommandLineTools":
sudo rm -rf /Library/Developer/CommandLineTools
2) Download and Install XCode command line tools for XCode 10 for macOS 10.13 (login to https://developer.app.com before clicking the link).
3) Rename "/Library/Developer/CommandLineTools" to "/Library/Developer/CommandLineTools-10.13":
sudo mv /Library/Developer/CommandLineTools /Library/Developer/CommandLineTools-10.13
4) Download and Install XCode command line tools for XCode 10 for macOS 10.14 (login to https://developer.app.com before clicking the link).
5) Edit /etc/fpc.cfg and add these lines at the bottom, you'll need to use something like this to edit:
sudo nano /etc/fpc.cfg
Add these lines at the end of fpc.cfg:
#ifdef cpui386
-XR/Library/Developer/CommandLineTools-10.13/SDKs/MacOSX.sdk/
-Fl/Library/Developer/CommandLineTools-10.13/usr/lib/clang/9.1.0/
#endif
#ifdef cpux86_64
-XR/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/
-Fl/Library/Developer/CommandLineTools/usr/lib/clang/10.0.0/
#endif
Now you can compile the Lazarus IDE, I do this from SVN as such:
cd ~
mkdir freepascal
cd freepascal
mkdir lazarus
svn co http://svn.freepascal.org/svn/lazarus/trunk lazarus
make LCL_PLATFORM=cocoa CPU_TARGET=x86_64
cd lazarus
./startlazarus
This should get you started.
The refresh issues are visible when scrolling through properties in the object inspector, and occasionally in the source-code window. There are a few other places where this occurs, even in your compiled application - hence the advise to compile your final product under macOS 10.13).