When attempting to run a flutter app that uses flutter_media_metadata on Linux, the compilation of the application fails.
flutter run -d linux
```
Launching lib/main.dart on Linux in debug mode...
[/home/abitofevrything/Programming/music_player/linux/flutter/ephemeral/.plugin_symlinks/flutter_media_metadata/cxx/utils.hpp:108:12](): warning: variable 'last_index' set but not used [-Wunused-but-set-variable]
[/home/abitofevrything/Programming/music_player/linux/flutter/ephemeral/.plugin_symlinks/flutter_media_metadata/cxx/metadata_retriever.cpp:56:16](): warning: variable 'size' set but not used [-Wunused-but-set-variable]
[/home/abitofevrything/Programming/music_player/linux/flutter/ephemeral/.plugin_symlinks/flutter_media_metadata/cxx/metadata_retriever.cpp:57:16](): warning: variable 'header' set but not used [-Wunused-but-set-variable]
clang-13: error: linker command failed with exit code 1 (use -v to see invocation)
Exception: Build process failed
```
flutter doctor -v
```
[✓] Flutter (Channel stable, 2.10.2, on Artix Linux 5.16.10-artix1-1, locale en_GB.UTF-8)
• Flutter version 2.10.2 at /opt/flutter
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision 097d3313d8 (12 days ago), 2022-02-18 19:33:08 -0600
• Engine revision a83ed0e5e3
• Dart version 2.16.1
• DevTools version 2.9.2
[✗] Android toolchain - develop for Android devices
✗ ANDROID_HOME = /opt/android-sdk
but Android SDK not found at this location.
[✓] Chrome - develop for the web
• CHROME_EXECUTABLE = chromium
[✓] Linux toolchain - develop for Linux desktop
• clang version 13.0.1
• cmake version 3.22.2
• ninja version 1.10.2
• pkg-config version 1.8.0
[!] Android Studio (not installed)
• Android Studio not found; download from https://developer.android.com/studio/index.html
(or visit https://flutter.dev/docs/get-started/install/linux#android-setup for detailed instructions).
[✓] Connected device (2 available)
• Linux (desktop) • linux • linux-x64 • Artix Linux 5.16.10-artix1-1
• Chrome (web) • chrome • web-javascript • Chromium 98.0.4758.102 Arch Linux
[✓] HTTP Host Availability
• All required HTTP hosts are available
! Doctor found issues in 2 categories.
```
After some looking around, this was caused by me not having the mediainfo library installed. It would be nice to mention in the README that that is a prerequisite,
When attempting to run a flutter app that uses
flutter_media_metadata
on Linux, the compilation of the application fails.flutter run -d linux
``` Launching lib/main.dart on Linux in debug mode... [/home/abitofevrything/Programming/music_player/linux/flutter/ephemeral/.plugin_symlinks/flutter_media_metadata/cxx/utils.hpp:108:12](): warning: variable 'last_index' set but not used [-Wunused-but-set-variable] [/home/abitofevrything/Programming/music_player/linux/flutter/ephemeral/.plugin_symlinks/flutter_media_metadata/cxx/metadata_retriever.cpp:56:16](): warning: variable 'size' set but not used [-Wunused-but-set-variable] [/home/abitofevrything/Programming/music_player/linux/flutter/ephemeral/.plugin_symlinks/flutter_media_metadata/cxx/metadata_retriever.cpp:57:16](): warning: variable 'header' set but not used [-Wunused-but-set-variable] clang-13: error: linker command failed with exit code 1 (use -v to see invocation) Exception: Build process failed ```flutter doctor -v
``` [✓] Flutter (Channel stable, 2.10.2, on Artix Linux 5.16.10-artix1-1, locale en_GB.UTF-8) • Flutter version 2.10.2 at /opt/flutter • Upstream repository https://github.com/flutter/flutter.git • Framework revision 097d3313d8 (12 days ago), 2022-02-18 19:33:08 -0600 • Engine revision a83ed0e5e3 • Dart version 2.16.1 • DevTools version 2.9.2 [✗] Android toolchain - develop for Android devices ✗ ANDROID_HOME = /opt/android-sdk but Android SDK not found at this location. [✓] Chrome - develop for the web • CHROME_EXECUTABLE = chromium [✓] Linux toolchain - develop for Linux desktop • clang version 13.0.1 • cmake version 3.22.2 • ninja version 1.10.2 • pkg-config version 1.8.0 [!] Android Studio (not installed) • Android Studio not found; download from https://developer.android.com/studio/index.html (or visit https://flutter.dev/docs/get-started/install/linux#android-setup for detailed instructions). [✓] Connected device (2 available) • Linux (desktop) • linux • linux-x64 • Artix Linux 5.16.10-artix1-1 • Chrome (web) • chrome • web-javascript • Chromium 98.0.4758.102 Arch Linux [✓] HTTP Host Availability • All required HTTP hosts are available ! Doctor found issues in 2 categories. ```