I can't speak to that personally but I found an article^1 that goes over using flutter with C++ and another that goes over debugging C++ with flutter^2. Flutter also has a template project that includes scaffolding for building C/C++ projects that can be asked from the commandline with
> flutter create --template=plugin_ffi demo_library --platforms android,ios,macos,windows,linux
Hope this helps!
1. https://dev.to/andycall/the-comprehensive-guide-to-using-cc-... 2. https://dev.to/andycall/setting-up-a-development-and-debuggi...