Home > Net >  CMake Error at /snap/flutter/126/usr/share/cmake-3.10/Modules/FindPkgConfig.cmake:419 Flutter Linux
CMake Error at /snap/flutter/126/usr/share/cmake-3.10/Modules/FindPkgConfig.cmake:419 Flutter Linux

Time:10-01

I am trying to use the FirebaseCoreDesktop and FirebaseAuthDesktop packages in my Flutter Project for linux (ubuntu). Unfortunatly when trying to run the App, I am getting the following Error.

CMake Error at /snap/flutter/126/usr/share/cmake-3.10/Modules/FindPkgConfig.cmake:419 (message):
  A required package was not found
Call Stack (most recent call first):
  /snap/flutter/126/usr/share/cmake-3.10/Modules/FindPkgConfig.cmake:597 (_pkg_check_modules_internal)
  flutter/ephemeral/.plugin_symlinks/desktop_webview_auth/linux/CMakeLists.txt:21 (pkg_check_modules)

Thanks for your help in advance.

CodePudding user response:

Found the solution.

Run

sudo apt install libwebkit2gtk-4.0-dev -y

and I had to uninstall flutter(snap) and install the Flutter git version in directory of your choice.

git clone https://github.com/flutter/flutter.git

As said in DesktopWebviewAuth. And then change flutter SDK path to the one you cloned and remove the build folder from my project.

CodePudding user response:

For me, I had to install webkit2gtk package.

For example on Arch linux: yay -S webkit2gtk

  • Related