How to compile LVGL for simple linux framebuffer without wayland support

Hi everyone,

I am trying to cross compile lvgl from Linux x86_64 to arm64 for simple operation on /dev/fb0

I cloned the git repository from here:, along with the recursive lv_drivers and lvgl submodules. I used the following cmake cross toolchain file:

type or pas# the name of the target operating system

# which compilers to use for C and C++
set(CMAKE_C_COMPILER  aarch64-linux-gnu-gcc)
set(CMAKE_CXX_COMPILER aarch64-linux-gnu-g++)

# where is the target environment located
set(CMAKE_FIND_ROOT_PATH  /usr/aarch64-linux-gnu

# adjust the default behavior of the FIND_XXX() commands:
# search programs in the host environment

# search headers and libraries in the target environment

This cam very close to working. It compiles fine and gets all the way to the final link of lvgl_fb and then fails with the following error:

/usr/lib/gcc-cross/aarch64-linux-gnu/7/../../../../aarch64-linux-gnu/bin/ld: cannot find -lwayland-client
/usr/lib/gcc-cross/aarch64-linux-gnu/7/../../../../aarch64-linux-gnu/bin/ld: cannot find -lwayland-cursor
/usr/lib/gcc-cross/aarch64-linux-gnu/7/../../../../aarch64-linux-gnu/bin/ld: cannot find -lxkbcommon
collect2: error: ld returned 1 exit status
CMakeFiles/lvgl_fb.dir/build.make:117: recipe for target 'lvgl_fb' failed
make[2]: *** [lvgl_fb] Error 1
CMakeFiles/Makefile2:124: recipe for target 'CMakeFiles/lvgl_fb.dir/all' failed
make[1]: *** [CMakeFiles/lvgl_fb.dir/all] Error 2
Makefile:135: recipe for target 'all' failed
make: *** [all] Error 2

This is not surprising, as I do not have wayland on the target system, nor do I want wayland on the target system. I would like lvlg to access /dev/fb0 directly without wayland.

Is this possible? If so, what do I need to do?

(As an aside, I did try and cross compile wayland for my arm64 linux system, but it uses the meson build system which doesn’t even get past the first command on an arm64 cross compile. Wayland has no support forum.)

Any assistance is appreciated.