Skip to content

HidenoriMatsubayashi/waffle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

waffle

waffle is a lightweight Wayland compositor for embedded devices.

1. Features

  • Optimized for Embedded Systems
    • Lightweight
    • Minimal dependent libraries
    • arm64/x64 devices support
  • Display backends (Still developing!!)
  • Keyboard, mouse and touch inputs support

2. System requirements

Install the following dependent libraries to build this software. Here introduce how to install the libraries on Debian-based systems like Ubuntu.

Operating Systems

Ubuntu 20.04 or above is recommended to develop and build this software.

Dependent libraries

Development environment

  • clang
  • cmake
  • build-essential
  • pkg-config
$ sudo apt install clang cmake build-essential pkg-config

Common system level libraries

  • EGL
  • xkbcommon
  • OpenGL ES (>=3.0)
  • SOIL
  • libwayland
  • wayland-protocols (to generate the source files of Wayland protocols)
$ sudo apt install libegl1-mesa-dev libxkbcommon-dev libgles2-mesa-dev \ 
                   libsoil-dev libwayland-dev wayland-protocols

System level libraries for X11 backends

  • x11
$ sudo apt install libx11-dev

System level libraries for DRM backends

  • libdrm
  • libgbm
  • libinput
  • libudev
  • libsystemd
$ sudo apt install libdrm-dev libgbm-dev libinput-dev libudev-dev \ 
                   libsystemd-dev

3. Building waffle

X11 backend

$ mkdir build && cd build
$ cmake -DBACKEND_TYPE=X11 -DCMAKE_BUILD_TYPE=Release ..
$ cmake --build .

DRM-GBM backend (Still developing)

$ mkdir build && cd build
$ cmake -DBACKEND_TYPE=DRM-GBM -DCMAKE_BUILD_TYPE=Release ..
$ cmake --build .

4. Running waffle

X11 backend

$ ./waffle

DRM-GBM backend (Still developing)

You need to switch from GUI which is running X11 or Wayland to the Character User Interface (CUI). In addition, WAFFLE_DRM_DEVICE must be set properly. The default value is /dev/dri/card0.

$ Ctrl + Alt + F3 # Switching to CUI
$ sudo WAFFLE_DRM_DEVICE=/dev/dri/card1 ./waffle

If you want to switch back from CUI to GUI, run Ctrl + Alt + F2 keys in a terminal.

Note

You need to run this program by a user who has the permission to access the input devices(/dev/input/xxx), if you use the DRM backend. Generally, it is a root user or a user who belongs to an input group.

5. Debugging waffle

Logging levels

You can get more debugging logs using WAFFLE_LOG_LEVELS that is one of environment variables in waffle. If you want to do debugging, set WAFFLE_LOG_LEVELS. The default level is WARNING.

$ WAFFLE_LOG_LEVELS=TRACE ./waffle
$ WAFFLE_LOG_LEVELS=INFO ./waffle
$ WAFFLE_LOG_LEVELS=WARNING ./waffle
$ WAFFLE_LOG_LEVELS=ERROR ./waffle
$ WAFFLE_LOG_LEVELS=FATAL ./waffle

Releases

No releases published

Packages

No packages published