On 10 Dec 2024, at 00:51, Joel Winarske via lists.yoctoproject.org 
<joel.winarske=gmail....@lists.yoctoproject.org> wrote:
> 
> Building on scarthgap I'm seeing a problem using meson.
> 
> meson snippet:
> ```
> lvgl_opt_var = cmake.subproject_options()
> lvgl_c_flags = '-DEGL_NO_X11 -DLV_CONF_PATH=' + meson.current_source_dir() + 
> '/lv_conf.h'
> lvgl_cxx_flags = '-DEGL_NO_X11 -DLV_CONF_PATH=' + meson.current_source_dir() 
> + '/lv_conf.h'
> lvgl_opt_var.add_cmake_defines(
>     {
>         'CMAKE_VERBOSE_MAKEFILE' : true,
>         'CMAKE_C_FLAGS' : lvgl_c_flags,
>         'CMAKE_CXX_FLAGS' : lvgl_cxx_flags })
> ```
> 
> Build Error:
> ```
> | In file included from ../git/subprojects/lvgl/src/core/lv_group.h:16,
> |                  from 
> ../git/subprojects/lvgl/src/core/lv_group_private.h:17,
> |                  from ../git/subprojects/lvgl/src/core/lv_group.c:9:
> | ../git/subprojects/lvgl/src/core/../lv_conf_internal.h:54:42: fatal error: 
> /mnt/raid10/yocto/scarthgap/up2u/tmp/work/corei7-64-poky-1/libdrmpp/git/git/examples/lvgl/lv_conf.h:
>  No such file or directory
> |    54 |         #include __LV_TO_STR(LV_CONF_PATH)
> |       |                                          ^
> | compilation terminated.
> ```
> 
> Observations:
> ```
> $ ls -la 
> /mnt/raid10/yocto/scarthgap/up2u/tmp/work/corei7-64-poky-1/libdrmpp/git/git/examples/lvgl/lv_conf.h
> ls: cannot access 
> '/mnt/raid10/yocto/scarthgap/up2u/tmp/work/corei7-64-poky-1/libdrmpp/git/git/examples/lvgl/lv_conf.h':
>  No such file or directory
> ```
> 
> ```
> $ ls -la 
> /mnt/raid10/yocto/scarthgap/up2u/tmp/work/corei7-64-poky-linux/libdrmpp/git/git/examples/lvgl/lv_conf.h
>  
> -rw-r--r--. 1 joel joel 36431 Dec  9 16:39 
> /mnt/raid10/yocto/scarthgap/up2u/tmp/work/corei7-64-poky-linux/libdrmpp/git/git/examples/lvgl/lv_conf.h
> ```
> 
> The same meson snippet works correctly on desktop
> 
> Why does `meson.current_source_dir()` in Yocto build return an incorrect path?

Can you replicate this with a minimal (like, just 
message(meson.current_source_dir())) meson file?

Ross
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#64423): https://lists.yoctoproject.org/g/yocto/message/64423
Mute This Topic: https://lists.yoctoproject.org/mt/110017878/21656
Group Owner: yocto+ow...@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to