Open jacobwelchvirtusense opened 2 months ago
For whoever is curious about integrating unity as a library with the MediaPipeUnityPlugin, I have found the solution to the above problem. At least for iOS that is.
You will need to add the MediaPipeUnity.framework to the main xCode project's frameworks folder along with your unity project as you would normally. A window will pop-up and check "Copy items if needed". You will also need to add the MediaPipeUnity framework to the main xCode project's Frameworks, Libraries, and Embedded Content and set it to Embed & Sign.
What specific actions would you like this project to take?
If you could make a note somewhere that the MediaPipeUnityPlugin for iOS needs to be in the root xCode project that would be helpful.
Could you attach an XCode screenshot that shows the settings? I don't plan to support UaaL, but I can leave a link to this issue in the documentation.
I'll also note here for other Unity people who want to use Unity as a library that this often a problem with other plugins too. Basically if you see that framework files are missing just add them to your base xCode project framework folder just like this.
Plugin Version or Commit ID
v0.15.0
Unity Version
2021.3.16f1
Your Host OS
Windows
Target Platform
iOS
Target Device
iPad
[Windows Only] Visual Studio C++ and Windows SDK Version
No response
[Linux Only] GCC/G++ and GLIBC Version
No response
[Android Only] Android Build Tools and NDK Version
No response
[iOS Only] XCode Version
15.3
Build Command
python build.py build --desktop cpu --opencv cmake -vv
Bug Description
I am getting the same issue as this ticket here: https://github.com/homuler/MediaPipeUnityPlugin/issues/1042
When running from editor and in standalone iOS builds everything works as intended, but when trying to integrate the unity project as a library into an iOS swift app it is unable to fine the necessary MediaPipeUnity files.
Steps to Reproduce the Bug
The resulting error will be that the project has "(no such file)" when referring to MediaPipeUnity.
Log
dyld[8336]: Library not loaded: @rpath/MediaPipeUnity.framework/MediaPipeUnity Referenced from: <798BC7D6-7C50-34E0-A8EC-0C3B80819760> /private/var/containers/Bundle/Application/8692E076-E0A5-4C50-B96E-3D44378A5C9D/ProactiveStrides.app/Frameworks/UnityFramework.framework/UnityFramework Reason: tried: '/private/var/containers/Bundle/Application/8692E076-E0A5-4C50-B96E-3D44378A5C9D/ProactiveStrides.app/Frameworks/MediaPipeUnity.framework/MediaPipeUnity' (no such file), '/usr/lib/swift/MediaPipeUnity.framework/MediaPipeUnity' (no such file, not in dyld cache), '/private/preboot/Cryptexes/OS/usr/lib/swift/MediaPipeUnity.framework/MediaPipeUnity' (no such file), '/Users/hitheshr/Library/Developer/Xcode/DerivedData/ProactiveStrides-emhctmkgrkdgphbfbtywaeuhhhir/Build/Products/Debug-iphoneos/PackageFrameworks/MediaPipeUnity.framework/MediaPipeUnity' (no such file), '/private/preboot/Cryptexes/OS/Users/hitheshr/Library/Developer/Xcode/DerivedData/ProactiveStrides-emhctmkgrkdgphbfbtywaeuhhhir/Build/Products/Debug-iphoneos/PackageFrameworks/MediaPipeUnity.framework/MediaPipeUnity' (no such file), '/private/var/containers/Bundle/Application/8692E076-E0A5-4C50-B96E-3D44378A5C9D/ProactiveStrides.app/Frameworks/MediaPipeUnity.framework/MediaPipeUnity' (no such file), '/usr/lib/swift/MediaPipeUnity.framework/MediaPipeUnity' (no such file, not in dyld cache), '/private/preboot/Cryptexes/OS/usr/lib/swift/MediaPipeUnity.framework/MediaPipeUnity' (no such file), '/Users/hitheshr/Library/Developer/Xcode/DerivedData/ProactiveStrides-emhctmkgrkdgphbfbtywaeuhhhir/Build/Products/Debug-iphoneos/PackageFrameworks/MediaPipeUnity.framework/MediaPipeUnity' (no such file), '/private/preboot/Cryptexes/OS/Users/hitheshr/Library/Developer/Xcode/DerivedData/ProactiveStrides-emhctmkgrkdgphbfbtywaeuhhhir/Build/Products/Debug-iphoneos/PackageFrameworks/MediaPipeUnity.framework/MediaPipeUnity' (no such file), '/private/var/containers/Bundle/Application/8692E076-E0A5-4C50-B96E-3D44378A5C9D/ProactiveStrides.app/Frameworks/MediaPipeUnity.framework/MediaPipeUnity' (no such file)
Screenshot/Video
No response
Additional Context
No response