sbooth / SFBAudioEngine

A powerhouse of audio functionality for macOS and iOS
https://sbooth.github.io/SFBAudioEngine/
MIT License
552 stars 87 forks source link

Can't run in physical device #209

Closed lijuncode closed 2 years ago

lijuncode commented 2 years ago

This is the error:

dyld: Library not loaded: @rpath/dumb.framework/dumb Referenced from: /private/var/containers/Bundle/Application/A0F8ED47-B1D7-446D-B894-4AE245E8ED0F/SimplePlayer-iOS.app/Frameworks/SFBAudioEngine.framework/SFBAudioEngine Reason: no suitable image found. Did find: /private/var/containers/Bundle/Application/A0F8ED47-B1D7-446D-B894-4AE245E8ED0F/SimplePlayer-iOS.app/Frameworks/SFBAudioEngine.framework/Frameworks/dumb.framework/dumb: code signature in (/private/var/containers/Bundle/Application/A0F8ED47-B1D7-446D-B894-4AE245E8ED0F/SimplePlayer-iOS.app/Frameworks/SFBAudioEngine.framework/Frameworks/dumb.framework/dumb) not valid for use in process using Library Validation: mapped file has no cdhash, completely unsigned? Code has to be at least ad-hoc signed. dyld: launch, loading dependent libraries DYLD_LIBRARY_PATH=/usr/lib/system/introspection DYLD_INSERT_LIBRARIES=/Developer/usr/lib/libBacktraceRecording.dylib:/Developer/usr/lib/libMainThreadChecker.dylib:/Developer/Library/PrivateFrameworks/DTDDISupport.framework/libViewDebuggerSupport.dylib

sbooth commented 2 years ago

Duplicate of #196

tryWabbit commented 11 months ago

Hey @sbooth Can you help me provide clear instructions on library installation?

I followed these steps

git clone https://github.com/sbooth/SFBAudioEngine.git --recurse-submodules
cd SFBAudioEngine
make -C XCFrameworks

Then I created a framework by make and also tried make build/iOS.xcarchive

I was able to run it on simulator but on device it is crashing.

I added all the xcframeworks too (dumb, flac etc) but it is still crashing on physical device.

Library not loaded: @rpath/ogg.framework/ogg
  Referenced from: <D1B7643F-7425-358F-9895-BD74227E9D3E> /private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/SFBAudioEngine.framework/SFBAudioEngine
  Reason: tried: '/usr/lib/swift/ogg.framework/ogg' (no such file, not in dyld cache), '/private/preboot/Cryptexes/OS/usr/lib/swift/ogg.framework/ogg' (no such file), '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/Frameworks/ogg.framework/ogg' (no such file), '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/SFBAudioEngine.framework/Frameworks/ogg.framework/ogg' (no such file), '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/ogg.framework/ogg' (no such file), '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/ogg.framework/ogg' (no such file), '/System/Library/Frameworks/ogg.framework/ogg' (no such file, not in dyld cache)Library not loaded: @rpath/ogg.framework/ogg
  Referenced from: <2FE6CD0D-F82C-3DEF-955C-3FA3751CAE94> /private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/FLAC.framework/FLAC
  Reason: tried: '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/Frameworks/ogg.framework/ogg' (no such file), '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/FLAC.framework/Frameworks/ogg.framework/ogg' (no such file), '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/ogg.framework/ogg' (no such file), '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/ogg.framework/ogg' (no such file)Library not loaded: @rpath/ogg.framework/ogg
  Referenced from: <277D368F-B6FD-372C-9DFC-694029CB8B74> /private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/sndfile.framework/sndfile
  Reason: tried: '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/Frameworks/ogg.framework/ogg' (no such file), '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/sndfile.framework/Frameworks/ogg.framework/ogg' (no such file), '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/ogg.framework/ogg' (no such file), '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/ogg.framework/ogg' (no such file)Library not loaded: @rpath/ogg.framework/ogg
  Referenced from: <60684A8F-78BB-3476-A3C0-056912A1C5EF> /private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/vorbis.framework/vorbis
  Reason: tried: '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/Frameworks/ogg.framework/ogg' (no such file), '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/vorbis.framework/Frameworks/ogg.framework/ogg' (no such file), '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/ogg.framework/ogg' (no such file), '/private/var/containers/Bundle/Application/4AFE4E5D-A1A6-4A42-81E8-451BE9A03557/RPTools.app/Frameworks/ogg.framework/ogg' (no such file)
Screenshot 2023-10-16 at 11 53 40 PM

I also have a question in discussion if you can help me with that it would be great.

Thanks

sbooth commented 11 months ago

Do you have a build phase to copy the embedded frameworks? SimplePlayer-iOS has an example.