How to use Unreal Engine as a library in an Xcode project on macOS

Hi.
I have a macOS application built with Objective-C.
The application had developed about 10 years ago and it also continue being updated until now.
A few days ago, we have made new milestone and we are going to integrate 3D view to our application to view some products and buildings with some animations of cars and peope.
And the 3D view might have settings for day and night, wheather including sunny, cloudy, rainy, snow, foggy.
After researching about various 3d rendering engines, We decided to use Unreal Engine to make the 3d view immersive and realistic.

So my question is:
How can we use Unreal Engine as a library in an Xcode project on macOS?

We have seen this blog already and noticed that is only for windows applications.

Android platform is the same unreal is built as a library