Denis Petrov
Denis Petrov

Reputation: 861

Using 3rd party framework for IOS in Delphi Firemonkey

I need to use SendAnywhere SDK (github.com/estmob/SendAnywhere-IOS-SDK) for IOS in Delphi Seattle (www.embarcadero.com/products/delphi). I have to convert obj-c code into delphi, like Embarcadero did that with native frameworks.

I have already read these articles:

They are the most complete guides for using native frameworks. But what about 3rd party?

  1. What folders have I to put downloaded from GitHub files in?
  2. There is an static .a library in SDK. How to include/import/use/open it in a FMX project?
  3. Or I need to create my own static library from this SDK. But How?
  4. Where to start from?

Upvotes: 2

Views: 1670

Answers (1)

Allen Drennan
Allen Drennan

Reputation: 301

If you have a framework file it usually includes a set of header files and a static library. You can extract the static library (the file with the same name as the framework) and rename it by adding an '.a' extension. You can then use that file directly your Delphi project. I have done this with XE8 to X10.

Simply put the static library in your path when you build and you also need to trick the Delphi compiler to link it. Just add a line of code to your implementation section of your unit such as:

procedure LibWhatever2; cdecl; external 'libWhatever.a' name 'OBJC_CLASS_$_SomeClassName'

Upvotes: 1

Related Questions