tomaszzmuda / Xabe.FFmpeg

.NET Standard wrapper for FFmpeg. It allows to process media without know how FFmpeg works, and can be used to pass customized arguments to FFmpeg from dotnet core application.

Home Page:https://xabe.net/product/xabe_ffmpeg/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Receiving 'Missing system type and architecture.' exception on Android in VS 2022 Emulator

acasciani opened this issue · comments

Hello! In my code I have the following call:
await FFmpegDownloader.GetLatestVersion(FFmpegVersion.Android);

This throws an System.InvalidOperationException: 'Missing system type and architecture.' in the Pixel 5, Android 11.0 API 30 Visual Studio 2022 emulator and using .NET 8. I pulled the Xabe.FFmpeg.Downloader code locally and loaded side by side by code. The exception is happening here: https://github.com/tomaszzmuda/Xabe.FFmpeg/blob/7af0345089bec7a6c5ecdcb339dd6e01e36b96cd/src/Xabe.FFmpeg.Downloader/OperatinSystemProvider/OperatingSystemProvider.cs#L54C15-L54C15

Each of the following will return false within this emulator.

RuntimeInformation.IsOSPlatform(OSPlatform.Windows)
RuntimeInformation.IsOSPlatform(OSPlatform.OSX)
RuntimeInformation.IsOSPlatform(OSPlatform.Linux)

Per this .net core documentation (dotnet/runtime#51052 (comment)) it does not look like this is the preferred way to check for Android.

Is this a bug in the OperatingSystemProvider.cs implementation for Android, or is there a different way we should go about using await FFmpegDownloader.GetLatestVersion(FFmpegVersion.Android); with Android?

Thank you!

i have the same problem