Problem compiling extension for ios

Hi my name is Ricardo, I’m new to haxe and I’m looking for some help compiling my game for ios. I made an extension for my project for rsa encryption that only includes c and cpp code, managed to make it work for mac and android but I’m getting some linker errors on ios, to build the extension i do

lime rebuild RSAExtension ios

which works fine and to build the game

lime test ios

which also compiles but when I open xcode (version 8.3.2) and try to run the app I get

Undefined symbols for architecture arm64:
  "_ltc_mp", referenced from:
      rsaextension::GetPublicKey(_value*) in librsaextension.a(da4c9716_RSAExtension.o)
      rsaextension::ReadServerKey(_value*) in librsaextension.a(da4c9716_RSAExtension.o)

I’m using:

  • flixel-addons: [2.4.1]
  • flixel-demos: [2.4.0]
  • flixel-templates: [2.4.1]
  • flixel-tools: [1.3.0]
  • flixel-ui: [2.2.0]
  • flixel: [4.2.1]
  • hxcpp: [3.4.64]
  • layout: [1.2.1]
  • lime: [2.9.1]
  • openfl: [3.6.1]

And for my extension I’m using the following 2 libraries

My guess is that the extension and the game are using 2 different compilers but i don’t know how to test this. Any help is really appreciated, thanks.

There might be something in here:

Another possibility is you may need the -force_load flag. Do you use <ndll /> or <dependency />? If you use <dependency />, try using <dependency path="to/lib" force-load="true" />

Thanks for the reply, I’m using <ndll />, forgot to mention that I didn’t add the .a files from the libraries, added the entire code base (.c and .h files) and I’m letting lime rebuild RSAExtension target compile everything.

I read the post and ‘ltc_mp’ is declared twice once in .h file as extern ltc_math_descriptor ltc_mp; and once on a .c file as ltc_math_descriptor ltc_mp;, tried using'-y _ltc_mp' as the post suggests but the linker says "_ltc_mp file not found"