Skip to content

Comments

Add native arm64-simulator support to FFmpeg Kit frameworks#142

Open
chownation wants to merge 1 commit intosk3llo:masterfrom
dart-technologies:arm64-simulator-support
Open

Add native arm64-simulator support to FFmpeg Kit frameworks#142
chownation wants to merge 1 commit intosk3llo:masterfrom
dart-technologies:arm64-simulator-support

Conversation

@chownation
Copy link

Adds native arm64 simulator support to the FFmpeg Kit frameworks, enabling native performance on Apple Silicon Macs without requiring Rosetta 2 or EXCLUDED_ARCHS workarounds.

Changes

  • Binary Patching: Utilized vtool to patch the Mach-O headers of existing arm64 device binaries, re-tagging them for the IOSSIMULATOR platform.
  • Dependency Integration: Bundled the patched frameworks (binaries + headers) directly into the repository to support seamless integration via Git dependency.
  • Architecture Validation: Verified architectures using lipo and vtool to ensure universal support (x86_64 + arm64-sim).

Verification

  • Verified that all 8 core frameworks (libavcodec, libavformat, libavutil, etc.) pass the architecture check.
  • Successfully built and ran on an iPhone 17 Pro simulator (ARM64) with functional video encoding.

@ahmetveysels
Copy link

its not working to me. 17 Pro

`
Launching lib/main.dart on iPhone 17 Pro in debug mode...
The following plugin(s) are excluding the arm64 architecture, which is a requirement for Xcode 26+:

  • ffmpeg_kit_flutter_new
    Consider installing the "Universal" Xcode or file an issue with the plugin(s) to support arm64.
    Xcode build done. 69,5s
    Failed to build iOS app
    Error (Xcode): Building for 'iOS-simulator', but linking in dylib (/Users/avs/.pub-cache/git/ffmpeg_kit_flutter-f8ae8cc3da04a82f502f39a32d4671b546acaeaf/ios/Frameworks/ffmpegkit.framework/ffmpegkit) built for 'iOS'

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 17 Pro.

Exited (1).

`

@martin-headspace
Copy link

@chownation I was running into a similar issue, but I made sure to:

  • remove config.build_settings['EXCLUDED_ARCHS[sdk=iphonesimulator*]'] = 'arm64' from my Podfile
  • Check in my Xcode project that "EXCLUDED_ARCHS" was set to "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = i386;

That did the trick. Can confirm this worked on my simulator.

@martin-headspace
Copy link

@symful @sk3llo thank you so much for your continued support on this library! Would you mind helping us review this PR?

It is proving to be very helpful!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants