How to build the LittlevGL into .so file in the Linux?

I want to build the LittlevGL into .so file format in the Linux , but I don’t known how to start this work, anyone can give me some advise?
Thank your

First of all, if you don’t know how to build a .so file, you can check this link out:

Then you should compile all of the LittlevGL source files in the same manner (Step 1). Obviously, you’ll want to compile all the object files and then put them all into a single library (Step 2), not multiple.

Keep in mind that header files are not included in shared libraries so you’ll need a copy of those available as well to actually build an application.

Out of curiosity, what use case are you planning where building LittlevGL as a shared library is necessary?

Thank you for your great help, I accomplish this work with your help.
In our team,There are two developer who dream for .so very mush, so I need to build the .so for them.

Would you be so kind in explaining me how to compile and build for Ubuntu ?

I managed to compile both lvgl and lv_drivers:

    /home/raphy/LVGL/lvgl/demos/widgets/../../src/misc/../lv_conf_internal.h:46:17: note: ‘#pragma message: Possible failure to include lv_conf.h, please read the comment in this file if you get errors’
       46 |         #pragma message("Possible failure to include lv_conf.h, please read the comment in this file if you get errors")
          |                 ^~~~~~~
    [100%] Linking C static library liblvgl_demos.a
    [100%] Built target lvgl_demos

    raphy@raohy:~/LVGL/lv_drivers$ cmake --build build
    [ 95%] Building C object CMakeFiles/lv_drivers.dir/win_drv.c.o
    [100%] Linking C static library lib/liblv_drivers.a
    [100%] Built target lv_drivers

I tried to compile and build an example but got 'undefined reference to main` :

raphy@raohy:~/LVGL/lvgl/examples/widgets/menu$ g++ lv_example_menu_1.c -std=c++17 -I ../../../src/ -I ../../../../lv_drivers/src -L ../../../build/lib -L ../../../../lv_drivers/build/lib/ -llvgl -o example_menu_1
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/12/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x1b): undefined reference to `main'
collect2: error: ld returned 1 exit status

What do I have to do next?