ardera / flutter-pi

A light-weight Flutter Engine Embedder for Raspberry Pi that runs without X.
MIT License
1.48k stars 153 forks source link

modesetting.c: Could not set DRM client universal planes capable. drmSetClientCap: Operation not supported #400

Closed juanrubio closed 2 months ago

juanrubio commented 2 months ago

Hi,

I'm trying to get flutter-pi to run some of the Flutter sample apps on my Rpi 4 running bookworm, but I'm getting these errors with all the apps that I've tried (flutter_gallery and material_3_demo)

❯ flutter-pi --release flutter_gallery
modesetting.c: Could not set DRM client universal planes capable. drmSetClientCap: Operation not supported
flutter-pi.c: Could not create drmdev from device at "/dev/dri/card0". Continuing.
flutter-pi.c: Error: Could not load flutter engine from any location. Make sure you have installed the engine binaries.

On the Pi4, I'm using this version of flutter-pi:

commit 783db32ec6441b878783bfa241777d3bfe6b35e2 (HEAD -> master, origin/master, origin/HEAD)
Author: Hannes Winkler <hanneswinkler2000@web.de>
Date:   Mon Mar 11 18:38:56 2024 +0100

    fix offscreen rendering

On the host, I'm using this:

❯ flutter --version
Flutter 3.19.0 • channel stable • https://github.com/flutter/flutter.git
Framework • revision bae5e49bc2 (4 weeks ago) • 2024-02-13 17:46:18 -0800
Engine • revision 04817c99c9
Tools • Dart 3.3.0 • DevTools 2.31.1

I'm attaching the output of drm_info (I'm using the Pi's official 7'' touch display) drm_info.txt

Many thanks in advance

juanrubio commented 2 months ago

Never mind, I found what the problem was.

I was building the 32-bit arm version of the demo app, and the pi4 is 64-bit.

Everything works when you build for the correct arch, in this case: ''' flutterpi_tool build --arch=arm64 --cpu=pi4 --release''' '''