alexmercerind / dart_vlc

Flutter bindings to libVLC.
GNU Lesser General Public License v2.1
513 stars 137 forks source link

Cannot run example on Ubuntu 22.04.1, seems Glibc version related #343

Closed xukangmin closed 1 year ago

xukangmin commented 2 years ago

Describe the bug Cannot run Example code on Ubuntu 22.04.1 LTS

It seems ubuntu is using Glibc 2.35 but VLC needs 2.34 / 2.33 for compiling, any solutions?

libvlc-dev and vlc installed.

ldd --version ldd (Ubuntu GLIBC 2.35-0ubuntu3.1) 2.35 Copyright (C) 2022 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Written by Roland McGrath and Ulrich Drepper.

Minimal reproducible code example code

Flutter logs

[  +73 ms] executing: uname -m
[  +31 ms] Exit code 0 from: uname -m
[        ] x86_64
[   +8 ms] executing: [/home/kangmin/snap/flutter/common/flutter/] git -c
log.showSignature=false log -n 1 --pretty=format:%H
[   +9 ms] Exit code 0 from: git -c log.showSignature=false log -n 1
--pretty=format:%H
[        ] b8f7f1f9869bb2d116aa6a70dbeac61000b52849
[        ] executing: [/home/kangmin/snap/flutter/common/flutter/] git tag
--points-at b8f7f1f9869bb2d116aa6a70dbeac61000b52849
[  +15 ms] Exit code 0 from: git tag --points-at
b8f7f1f9869bb2d116aa6a70dbeac61000b52849
[        ] 3.3.9
[  +48 ms] executing: [/home/kangmin/snap/flutter/common/flutter/] git rev-parse
--abbrev-ref --symbolic @{upstream}
[   +5 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic @{upstream}
[        ] origin/stable
[        ] executing: [/home/kangmin/snap/flutter/common/flutter/] git ls-remote
--get-url origin
[   +5 ms] Exit code 0 from: git ls-remote --get-url origin
[        ] https://github.com/flutter/flutter.git
[  +40 ms] executing: [/home/kangmin/snap/flutter/common/flutter/] git rev-parse
--abbrev-ref HEAD
[   +5 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[        ] stable
[  +79 ms] Artifact Instance of 'AndroidGenSnapshotArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping
update.
[        ] Artifact Instance of 'FlutterWebSdk' is not required, skipping
update.
[   +4 ms] Artifact Instance of 'WindowsEngineArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping
update.
[        ] Artifact Instance of 'LinuxEngineArtifacts' is not required, skipping
update.
[        ] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required,
skipping update.
[  +89 ms] executing: /home/kangmin/Android/Sdk/platform-tools/adb devices -l
[  +55 ms] List of devices attached
[   +5 ms] Artifact Instance of 'AndroidGenSnapshotArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping
update.
[   +1 ms] Artifact Instance of 'WindowsEngineArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping
update.
[   +1 ms] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required,
skipping update.
[  +87 ms] Skipping pub get: version match.
[  +21 ms] Found plugin dart_vlc at /home/kangmin/Downloads/dart_vlc-master/
[  +16 ms] Found plugin flutter_native_view at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/flu
tter_native_view-0.0.2/
[   +7 ms] Found plugin path_provider at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider-2.0.11/
[   +3 ms] Found plugin path_provider_android at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_android-2.0.22/
[   +8 ms] Found plugin path_provider_ios at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_ios-2.0.11/
[   +3 ms] Found plugin path_provider_linux at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_linux-2.1.7/
[   +1 ms] Found plugin path_provider_macos at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_macos-2.0.6/
[   +3 ms] Found plugin path_provider_windows at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_windows-2.0.7/
[   +7 ms] Found plugin screen_retriever at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/scr
een_retriever-0.1.4/
[   +6 ms] Found plugin window_manager at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/win
dow_manager-0.2.7/
[  +40 ms] Found plugin dart_vlc at /home/kangmin/Downloads/dart_vlc-master/
[   +7 ms] Found plugin flutter_native_view at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/flu
tter_native_view-0.0.2/
[   +4 ms] Found plugin path_provider at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider-2.0.11/
[   +2 ms] Found plugin path_provider_android at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_android-2.0.22/
[   +2 ms] Found plugin path_provider_ios at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_ios-2.0.11/
[   +4 ms] Found plugin path_provider_linux at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_linux-2.1.7/
[   +2 ms] Found plugin path_provider_macos at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_macos-2.0.6/
[   +3 ms] Found plugin path_provider_windows at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_windows-2.0.7/
[   +4 ms] Found plugin screen_retriever at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/scr
een_retriever-0.1.4/
[   +3 ms] Found plugin window_manager at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/win
dow_manager-0.2.7/
[ +130 ms] Initializing file store
[  +12 ms] Skipping target: gen_localizations
[   +3 ms] gen_dart_plugin_registrant: Starting due to
{InvalidatedReasonKind.inputChanged: The following inputs have updated contents:
/home/kangmin/Downloads/dart_vlc-master/example/.dart_tool/package_config_subset
,/home/kangmin/Downloads/dart_vlc-master/example/.dart_tool/flutter_build/dart_p
lugin_registrant.dart}
[   +9 ms] Found plugin dart_vlc at /home/kangmin/Downloads/dart_vlc-master/
[   +6 ms] Found plugin flutter_native_view at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/flu
tter_native_view-0.0.2/
[   +6 ms] Found plugin path_provider at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider-2.0.11/
[   +1 ms] Found plugin path_provider_android at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_android-2.0.22/
[   +1 ms] Found plugin path_provider_ios at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_ios-2.0.11/
[   +2 ms] Found plugin path_provider_linux at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_linux-2.1.7/
[   +1 ms] Found plugin path_provider_macos at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_macos-2.0.6/
[   +1 ms] Found plugin path_provider_windows at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/pat
h_provider_windows-2.0.7/
[   +4 ms] Found plugin screen_retriever at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/scr
een_retriever-0.1.4/
[   +2 ms] Found plugin window_manager at
/home/kangmin/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/win
dow_manager-0.2.7/
[   +6 ms] gen_dart_plugin_registrant: Complete
[   +1 ms] Skipping target: _composite
[   +1 ms] complete
[   +5 ms] Launching lib/main.dart on Linux in debug mode...
[   +4 ms] /home/kangmin/snap/flutter/common/flutter/bin/cache/dart-sdk/bin/dart
--disable-dart-dev
/home/kangmin/snap/flutter/common/flutter/bin/cache/dart-sdk/bin/snapshots/front
end_server.dart.snapshot --sdk-root
/home/kangmin/snap/flutter/common/flutter/bin/cache/artifacts/engine/common/flut
ter_patched_sdk/ --incremental --target=flutter --debugger-module-names
--experimental-emit-debug-metadata -DFLUTTER_WEB_AUTO_DETECT=true --output-dill
/tmp/flutter_tools.PARVVQ/flutter_tool.VZRENU/app.dill --packages
/home/kangmin/Downloads/dart_vlc-master/example/.dart_tool/package_config.json
-Ddart.vm.profile=false -Ddart.vm.product=false --enable-asserts
--track-widget-creation --filesystem-scheme org-dartlang-root
--initialize-from-dill
build/c075001b96339384a97db4862b8ab8db.cache.dill.track.dill --source
/home/kangmin/Downloads/dart_vlc-master/example/.dart_tool/flutter_build/dart_pl
ugin_registrant.dart --source package:flutter/src/dart_plugin_registrant.dart
-Dflutter.dart_plugin_registrant=file:///home/kangmin/Downloads/dart_vlc-master/
example/.dart_tool/flutter_build/dart_plugin_registrant.dart --verbosity=error
--enable-experiment=alternative-invalidation-strategy
[  +21 ms] Building Linux application...
[  +15 ms] <- compile package:dart_vlc_example/main.dart
[   +2 ms] executing: [build/linux/x64/debug/] cmake -G Ninja
-DCMAKE_BUILD_TYPE=Debug -DFLUTTER_TARGET_PLATFORM=linux-x64
/home/kangmin/Downloads/dart_vlc-master/example/linux
[  +60 ms] -- Configuring done
[  +76 ms] -- Generating done
[        ] -- Build files have been written to:
/home/kangmin/Downloads/dart_vlc-master/example/build/linux/x64/debug
[   +3 ms] executing: ninja -C build/linux/x64/debug install
[  +14 ms] ninja: Entering directory `build/linux/x64/debug'
[+3686 ms] [1/11] Generating
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/libflutt
er_linux_gtk.so,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_basic_message_channel.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_binary_codec.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_binary_messenger.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_dart_project.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_engine.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_json_message_codec.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_json_method_codec.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_message_codec.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_method_call.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_method_channel.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_method_codec.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_method_response.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_plugin_registrar.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_plugin_registry.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_standard_message_codec.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_standard_method_codec.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_string_codec.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_value.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/fl_view.h,
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/flutter_
linux/flutter_linux.h, _phony_
[  +18 ms] [  +82 ms] executing: uname -m
[        ] [  +45 ms] Exit code 0 from: uname -m
[        ] [        ] x86_64
[        ] [   +8 ms] executing: [/home/kangmin/snap/flutter/common/flutter/]
git -c log.showSignature=false log -n 1 --pretty=format:%H
[        ] [   +6 ms] Exit code 0 from: git -c log.showSignature=false log -n 1
--pretty=format:%H
[        ] [        ] b8f7f1f9869bb2d116aa6a70dbeac61000b52849
[        ] [        ] executing: [/home/kangmin/snap/flutter/common/flutter/]
git tag --points-at b8f7f1f9869bb2d116aa6a70dbeac61000b52849
[        ] [  +16 ms] Exit code 0 from: git tag --points-at
b8f7f1f9869bb2d116aa6a70dbeac61000b52849
[   +1 ms] [        ] 3.3.9
[        ] [  +69 ms] executing: [/home/kangmin/snap/flutter/common/flutter/]
git rev-parse --abbrev-ref HEAD
[   +4 ms] [   +5 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[        ] [        ] stable
[        ] [  +62 ms] Artifact Instance of 'AndroidGenSnapshotArtifacts' is not
required, skipping update.
[        ] [        ] Artifact Instance of 'AndroidInternalBuildArtifacts' is
not required, skipping update.
[   +6 ms] [        ] Artifact Instance of 'IOSEngineArtifacts' is not required,
skipping update.
[        ] [        ] Artifact Instance of 'FlutterWebSdk' is not required,
skipping update.
[        ] [   +5 ms] Artifact Instance of 'WindowsEngineArtifacts' is not
required, skipping update.
[        ] [        ] Artifact Instance of 'MacOSEngineArtifacts' is not
required, skipping update.
[        ] [        ] Artifact Instance of 'LinuxEngineArtifacts' is not
required, skipping update.
[        ] [        ] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not
required, skipping update.
[        ] [        ] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not
required, skipping update.
[        ] [        ] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not
required, skipping update.
[        ] [        ] Artifact Instance of 'FlutterRunnerDebugSymbols' is not
required, skipping update.
[        ] [ +105 ms] executing: [/home/kangmin/snap/flutter/common/flutter/]
git rev-parse --abbrev-ref --symbolic @{upstream}
[        ] [   +6 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic
@{upstream}
[   +4 ms] [        ] origin/stable
[        ] [        ] executing: [/home/kangmin/snap/flutter/common/flutter/]
git ls-remote --get-url origin
[        ] [   +6 ms] Exit code 0 from: git ls-remote --get-url origin
[        ] [        ] https://github.com/flutter/flutter.git
[        ] [   +1 ms] Artifact Instance of 'MaterialFonts' is not required,
skipping update.
[        ] [        ] Artifact Instance of 'GradleWrapper' is not required,
skipping update.
[        ] [        ] Artifact Instance of 'AndroidGenSnapshotArtifacts' is not
required, skipping update.
[        ] [        ] Artifact Instance of 'AndroidInternalBuildArtifacts' is
not required, skipping update.
[        ] [        ] Artifact Instance of 'IOSEngineArtifacts' is not required,
skipping update.
[        ] [        ] Artifact Instance of 'FlutterWebSdk' is not required,
skipping update.
[        ] [        ] Artifact Instance of 'FlutterSdk' is not required,
skipping update.
[        ] [        ] Artifact Instance of 'WindowsEngineArtifacts' is not
required, skipping update.
[  +18 ms] [        ] Artifact Instance of 'MacOSEngineArtifacts' is not
required, skipping update.
[  +10 ms] [   +2 ms] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not
required, skipping update.
[   +2 ms] [        ] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not
required, skipping update.
[        ] [        ] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not
required, skipping update.
[        ] [        ] Artifact Instance of 'FlutterRunnerDebugSymbols' is not
required, skipping update.
[        ] [        ] Artifact Instance of 'IosUsbArtifacts' is not required,
skipping update.
[   +3 ms] [        ] Artifact Instance of 'IosUsbArtifacts' is not required,
skipping update.
[        ] [        ] Artifact Instance of 'IosUsbArtifacts' is not required,
skipping update.
[        ] [        ] Artifact Instance of 'IosUsbArtifacts' is not required,
skipping update.
[        ] [        ] Artifact Instance of 'IosUsbArtifacts' is not required,
skipping update.
[        ] [        ] Artifact Instance of 'FontSubsetArtifacts' is not
required, skipping update.
[        ] [        ] Artifact Instance of 'PubDependencies' is not required,
skipping update.
[        ] [  +63 ms] Initializing file store
[        ] [  +22 ms] Done initializing file store
[        ] [  +71 ms] Skipping target: gen_localizations
[        ] [  +28 ms] Skipping target: gen_dart_plugin_registrant
[        ] [ +756 ms] Skipping target: unpack_linux
[        ] [ +739 ms] Skipping target: kernel_snapshot
[   +2 ms] [ +548 ms] Skipping target: debug_bundle_linux-x64_assets
[        ] [   +1 ms] Persisting file store
[        ] [  +14 ms] Done persisting file store
[        ] [  +12 ms] build succeeded.
[   +2 ms] [  +14 ms] "flutter assemble" took 2,416ms.
[        ] [ +221 ms] ensureAnalyticsSent: 214ms
[        ] [   +1 ms] Running shutdown hooks
[        ] [        ] Shutdown hooks complete
[        ] [   +1 ms] exiting with code 0
[ +766 ms] [2/5] Building CXX object
CMakeFiles/dart_vlc_example.dir/flutter/generated_plugin_registrant.cc.o
[ +107 ms] [3/5] Building CXX object
CMakeFiles/dart_vlc_example.dir/my_application.cc.o
[ +377 ms] [4/5] Linking CXX executable intermediates_do_not_run/dart_vlc_example
[        ] FAILED: intermediates_do_not_run/dart_vlc_example 
[  +22 ms] : && /snap/flutter/current/usr/bin/clang++  -g
-B/snap/flutter/current/usr/lib/gcc/x86_64-linux-gnu/9
-B/snap/flutter/current/usr/lib/x86_64-linux-gnu
-B/snap/flutter/current/lib/x86_64-linux-gnu -B/snap/flutter/current/usr/lib/
-L/snap/flutter/current/usr/lib/gcc/x86_64-linux-gnu/9
-L/snap/flutter/current/usr/lib/x86_64-linux-gnu
-L/snap/flutter/current/lib/x86_64-linux-gnu -L/snap/flutter/current/usr/lib/ -lblkid
-lgcrypt -llzma -llz4 -lgpg-error -luuid -lpthread -ldl -lepoxy
-B/snap/flutter/current/usr/lib/gcc/x86_64-linux-gnu/9
-B/snap/flutter/current/usr/lib/x86_64-linux-gnu
-B/snap/flutter/current/lib/x86_64-linux-gnu -B/snap/flutter/current/usr/lib/
-L/snap/flutter/current/usr/lib/gcc/x86_64-linux-gnu/9
-L/snap/flutter/current/usr/lib/x86_64-linux-gnu
-L/snap/flutter/current/lib/x86_64-linux-gnu -L/snap/flutter/current/usr/lib/ -lblkid
-lgcrypt -llzma -llz4 -lgpg-error -luuid -lpthread -ldl -lepoxy
CMakeFiles/dart_vlc_example.dir/main.cc.o
CMakeFiles/dart_vlc_example.dir/my_application.cc.o
CMakeFiles/dart_vlc_example.dir/flutter/generated_plugin_registrant.cc.o  -o
intermediates_do_not_run/dart_vlc_example
-Wl,-rpath,/home/kangmin/Downloads/dart_vlc-master/example/build/linux/x64/debug/plugins/da
rt_vlc:/home/kangmin/Downloads/dart_vlc-master/example/build/linux/x64/debug/plugins/screen
_retriever:/home/kangmin/Downloads/dart_vlc-master/example/build/linux/x64/debug/plugins/wi
ndow_manager:/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral:
plugins/dart_vlc/libdart_vlc_plugin.so
plugins/screen_retriever/libscreen_retriever_plugin.so
plugins/window_manager/libwindow_manager_plugin.so
/home/kangmin/Downloads/dart_vlc-master/example/linux/flutter/ephemeral/libflutter_linux_gt
k.so  /snap/flutter/current/usr/lib/x86_64-linux-gnu/libblkid.so
/snap/flutter/current/usr/lib/x86_64-linux-gnu/liblzma.so
/snap/flutter/current/usr/lib/x86_64-linux-gnu/libgtk-3.so
/snap/flutter/current/usr/lib/x86_64-linux-gnu/libgdk-3.so
/snap/flutter/current/usr/lib/x86_64-linux-gnu/libpangocairo-1.0.so
/snap/flutter/current/usr/lib/x86_64-linux-gnu/libpango-1.0.so
/snap/flutter/current/usr/lib/x86_64-linux-gnu/libharfbuzz.so
/snap/flutter/current/usr/lib/x86_64-linux-gnu/libatk-1.0.so
/snap/flutter/current/usr/lib/x86_64-linux-gnu/libcairo-gobject.so
/snap/flutter/current/usr/lib/x86_64-linux-gnu/libcairo.so
/snap/flutter/current/usr/lib/x86_64-linux-gnu/libgdk_pixbuf-2.0.so
/snap/flutter/current/usr/lib/x86_64-linux-gnu/libgio-2.0.so
/snap/flutter/current/usr/lib/x86_64-linux-gnu/libgobject-2.0.so
/snap/flutter/current/usr/lib/x86_64-linux-gnu/libglib-2.0.so && :
[   +9 ms] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlc.so.5: undefined
reference to `__pthread_register_cancel@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_setspecific@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `dlopen@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_rwlock_init@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `fstat64@GLIBC_2.33'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_rwlock_wrlock@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_sigmask@GLIBC_2.32'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_mutexattr_init@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_testcancel@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_condattr_setclock@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `dlerror@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `stat64@GLIBC_2.33'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_getspecific@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_create@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_mutex_trylock@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `sem_init@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_mutexattr_destroy@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `sem_destroy@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_attr_setstacksize@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_cancel@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_mutexattr_settype@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_join@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `dlclose@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `__pthread_unregister_cancel@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_rwlock_rdlock@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_key_delete@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `sem_post@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_once@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `sem_wait@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_rwlock_destroy@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_key_create@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `pthread_rwlock_unlock@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `dlsym@GLIBC_2.34'
[        ] /snap/flutter/current/usr/bin/ld: /lib/x86_64-linux-gnu/libvlccore.so.9:
undefined reference to `lstat64@GLIBC_2.33'
[        ] clang: error: linker command failed with exit code 1 (use -v to see invocation)
[   +3 ms] ninja: build stopped: subcommand failed.
[  +21 ms] Building Linux application... (completed in 5.3s)
[+9046 ms] Exception: Build process failed
[   +5 ms] "flutter run" took 15,001ms.
[   +7 ms] 
           #0      throwToolExit (package:flutter_tools/src/base/common.dart:10:3)
           #1      RunCommand.runCommand (package:flutter_tools/src/commands/run.dart:713:9)
           <asynchronous suspension>
           #2      FlutterCommand.run.<anonymous closure>
           (package:flutter_tools/src/runner/flutter_command.dart:1209:27)
           <asynchronous suspension>
           #3      AppContext.run.<anonymous closure>
(package:flutter_tools/src/base/context.dart:150:19)
           <asynchronous suspension>
           #4      CommandRunner.runCommand (package:args/command_runner.dart:209:13)
           <asynchronous suspension>
           #5      FlutterCommandRunner.runCommand.<anonymous closure>
           (package:flutter_tools/src/runner/flutter_command_runner.dart:281:9)
           <asynchronous suspension>
           #6      AppContext.run.<anonymous closure>
(package:flutter_tools/src/base/context.dart:150:19)
           <asynchronous suspension>
           #7      FlutterCommandRunner.runCommand
           (package:flutter_tools/src/runner/flutter_command_runner.dart:229:5)
           <asynchronous suspension>
           #8      run.<anonymous closure>.<anonymous closure>
(package:flutter_tools/runner.dart:62:9)
           <asynchronous suspension>
           #9      AppContext.run.<anonymous closure>
(package:flutter_tools/src/base/context.dart:150:19)
           <asynchronous suspension>
           #10     main (package:flutter_tools/executable.dart:91:3)
           <asynchronous suspension>

[  +46 ms] ensureAnalyticsSent: 43ms
[   +1 ms] Running shutdown hooks
[        ] Shutdown hooks complete
[        ] exiting with code 1
[✓] Flutter (Channel stable, 3.3.9, on Ubuntu 22.04.1 LTS 5.15.0-53-generic,
    locale en_US.UTF-8)
    • Flutter version 3.3.9 on channel stable at
      /home/kangmin/snap/flutter/common/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision b8f7f1f986 (2 days ago), 2022-11-23 06:43:51 +0900
    • Engine revision 8f2221fbef
    • Dart version 2.18.5
    • DevTools version 2.15.0

[!] Android toolchain - develop for Android devices (Android SDK version 33.0.0)
    • Android SDK at /home/kangmin/Android/Sdk
    ✗ cmdline-tools component is missing
      Run `path/to/sdkmanager --install "cmdline-tools;latest"`
      See https://developer.android.com/studio/command-line for more details.
    ✗ Android license status unknown.
      Run `flutter doctor --android-licenses` to accept the SDK licenses.
      See https://flutter.dev/docs/get-started/install/linux#android-setup for
      more details.

[✓] Chrome - develop for the web
    • Chrome at google-chrome

[✓] Linux toolchain - develop for Linux desktop
    • clang version 10.0.0-4ubuntu1
    • cmake version 3.16.3
    • ninja version 1.10.0
    • pkg-config version 0.29.1

[✓] Android Studio (version 2021.3)
    • Android Studio at /snap/android-studio/124/android-studio
    • Flutter plugin version 71.0.3
    • Dart plugin version 213.7433
    • Java version OpenJDK Runtime Environment (build
      11.0.13+0-b1751.21-8125866)

[✓] VS Code
    • VS Code at /snap/code/current
    • Flutter extension version 3.52.0

[✓] Connected device (2 available)
    • Linux (desktop) • linux  • linux-x64      • Ubuntu 22.04.1 LTS
      5.15.0-53-generic
    • Chrome (web)    • chrome • web-javascript • Google Chrome 107.0.5304.87

[✓] HTTP Host Availability
    • All required HTTP hosts are available

! Doctor found issues in 1 category.

Operating system: Ubuntu 22.04.1 LTS

Other details:

xukangmin commented 2 years ago

I verified that everything works fine on Ubuntu 20.04.5 LTS (Focal Fossa), but not on Ubuntu 22.04.1 LTS due to GLIBC version mismatch.

alexmercerind commented 2 years ago

I can't say anything in regard to this one unfortunately. Could it be an issue within that specific Ubuntu's version?

Does VLC launch & play media perfectly?

xukangmin commented 1 year ago

I can't say anything in regard to this one unfortunately. Could it be an issue within that specific Ubuntu's version?

Does VLC launch & play media perfectly?

VLC plays perfectly, I even compile a demo c code playing video using libvlc, it works fine on Ubuntu 22.04.

alexmercerind commented 1 year ago

As far as I can tell, the issue is likely due to snap. You are using the snap install of Flutter, which I have highly discouraged in the past (on several other issues). It seems to cause the miss-match. The linking errors seem to be present because of that.

Installing the Flutter manually is the best option.

Flutter snap seems to have it's own ld (internally, see your logs above). Where Flutter Snap uses it's own toolchain, the VLC is installed globally on the other hand through distribution's package manager. In development, this should not be done. When deploying / shipping your software, you have to take handle bundling of dependencies yourself (e.g. FlatHub, Snap or AppImage) or ask your customers to install the required package themselves to run the app.

xukangmin commented 1 year ago

Thanks so much, it worked.

Solution is to use Flutter manually not using snap version.

It builds everything from scratch, while snap version used some of pre-built so files which may cause mismatch.