Select to view content in your preferred language

dyld[2691]: Library not loaded:

1049
9
Jump to solution
09-26-2024 04:15 PM
RTC
by
Emerging Contributor

I have a Framework (call it myFramework) that uses the ArcGIS.Framework. MyFramework is then embedded into the main project. I have add the package dependency as per the Esri instructions and the app will compile and run in the simulator but when I try to compile to a device I get the below error.  

dyld[2691]: Library not loaded: @rpath/ArcGIS.framework/ArcGIS

  Referenced from: <B7F213FC-91BD-3F78-A27E-9AE222D5A028> /private/var/containers/Bundle/Application/4906320B-CF1B-4002-BEE1-69384617317E/MyApp.app/Tablet CMD.debug.dylib

  Reason: tried: '/Users/Me/Library/Developer/Xcode/DerivedData/MyApp-bkoteomqilntvhdaldwszajpidbn/Build/Products/Debug-iphoneos/PackageFrameworks/ArcGIS.framework/ArcGIS' (no such file)

 

I have tried to delete the package, delete derived data, re-apply the package, check the Search Path but noting seems to fix the issue.

0 Kudos
1 Solution

Accepted Solutions
ZacharyKline
Esri Contributor

I was able to reproduce this and thank you for providing those steps. Unfortunately, it seems the problem you are running into is that nested frameworks are not supported on iOS. See the screenshot below of an Apple employee pointing this out.

But as a potential workaround depending on what you are trying to achieve, you could add the Swift SDK as a dependency to your app project and you will see both ArcGIS and your custom framework are embedded into the app and the app runs fine.

View solution in original post

0 Kudos
9 Replies
NimeshJarecha
Esri Regular Contributor

Hi @RTC,

Do you see your framework or ArcGIS framework listed under `Frameworks, Libraries, and Embedded Content` in Xcode project? If not, try adding it.

Screenshot 2024-09-27 at 8.28.49 AM.png

Regards,

Nimesh

 

0 Kudos
RTC
by
Emerging Contributor

Yes, it is under the Frameworks and Libraries for the target of my framework

0 Kudos
ZacharyKline
Esri Contributor

Screenshot 2024-09-27 at 8.33.22 AM.png

Hello,

 

Can you try making sure the framework is embed and sign and see if that fixes the problem?

0 Kudos
RTC
by
Emerging Contributor

RTC_0-1727458368514.png

There is no option to select.

The ArcGIS framework is being embedded in a custom framework that is then embedded in the app project, there the custom framework is set to embed & signed.

0 Kudos
ZacharyKline
Esri Contributor

I see. I tried reproducing this with no luck. Can you provide a reproducer?

Thanks,

Zach

0 Kudos
ZacharyKline
Esri Contributor

Can you also let me know what version of Xcode and ArcGIS Maps SDK version you are using?

0 Kudos
RTC
by
Emerging Contributor

I have tried Xcode 16 with SDK 200.5.1 and Xcode 15.3 with SDK 200.5.1, in both cases, I get the same error.

To recreate the issue:

  1. Create a new Project App
  2. Create a new Project Framework
  3. Create a new Workspace
  4. Drag the Project and Framework into the Workspace
  5. Add the Esri SDK dependency to the Framework
  6. Add the Framework to the "Frameworks, Libraries, and Embedded Content" of the Project
0 Kudos
ZacharyKline
Esri Contributor

I was able to reproduce this and thank you for providing those steps. Unfortunately, it seems the problem you are running into is that nested frameworks are not supported on iOS. See the screenshot below of an Apple employee pointing this out.

But as a potential workaround depending on what you are trying to achieve, you could add the Swift SDK as a dependency to your app project and you will see both ArcGIS and your custom framework are embedded into the app and the app runs fine.

0 Kudos
RTC
by
Emerging Contributor

I did see that post but wonder if is is referring to something different. We are able to accomplish this with Esri 100 SDK, it is only an issue with 200. It does work if embedded in the app project so we will just go with that. Thanks for your help!

0 Kudos