wang-bin / fvp

Flutter video player plugin for all desktop+mobile platforms. download prebuilt examples from github actions. https://pub.dev/packages/fvp
BSD 3-Clause "New" or "Revised" License
126 stars 20 forks source link

[ios] run failed #19

Closed abdelaziz-mahdy closed 10 months ago

abdelaziz-mahdy commented 10 months ago

trying to run the project on ios

Failed to build iOS app
Error (Xcode): Undefined symbol: _MDK_setLogHandler

Error (Xcode): Undefined symbol: _mdkPlayerAPI_delete

Error (Xcode): Undefined symbol: _mdkPlayerAPI_new

Error (Xcode): Linker command failed with exit code 1 (use -v to see invocation)

Could not build the application for the simulator.
Error launching application on iPhone 14 Pro.

meanwhile the build runs without errors

flutter build ios --no-codesign 
Warning: Building for device with codesigning disabled. You will have to manually codesign before deploying to device.
Building com.zezo357.flutterMeeduVideoplayerExample for device (ios-release)...
Warning: Missing build name (CFBundleShortVersionString).
Warning: Missing build number (CFBundleVersion).
Action Required: You must set a build name and number in the pubspec.yaml file version field before submitting to the App Store.
Running Xcode build...                                                  
 └─Compiling, linking and signing...                      1,659ms
Xcode build done.                                            5.5s
Built /Users/AbdelazizMahdy/flutter_projects/flutter_meedu_videoplayer/package/example/build/ios/iphoneos/Runner.app.

any idea why it may fail?

abdelaziz-mahdy commented 10 months ago

even on fvp example it fails :_(

wang-bin commented 10 months ago

arm64 simulator?

abdelaziz-mahdy commented 10 months ago

The iOS simulator's architecture is x86_64.

That's what I found from Google search

wang-bin commented 10 months ago

i can't reprodyce it. i need build log with --verbose

abdelaziz-mahdy commented 10 months ago

i just searched in the logs its arm64 i think as you mentioned

            {
               "simulator" : true,
               "operatingSystemVersion" : "16.4 (20E247)",
               "available" : true,
               "platform" : "com.apple.platform.iphonesimulator",
               "modelCode" : "iPhone15,2",
               "identifier" : "7E7D7194-D699-40A5-9281-8E5D860CA41F",
               "architecture" : "arm64",
               "modelUTI" : "com.apple.iphone-14-pro-1",
               "modelName" : "iPhone 14 Pro",
               "name" : "iPhone 14 Pro",
               "ignored" : false
             },

also this is the logs file just incase it helps for flutter run --verbose > logs.txt on fvp example logs.txt

wang-bin commented 10 months ago

I've updated mdk in cocoapods. Now you can run pod repo update to update local indices, then run pod cache clean mdk and in example/ios run pod deintegrate

abdelaziz-mahdy commented 10 months ago

thank you very much, now it works <3