Hi Markus,

Am 22.06.2022 um 16:18 schrieb Markus Volk via lists.openembedded.org:
Hi,

couldn't we just do it like this?

PACKAGECONFIG ?= ""
PACKAGECONFIG[optviewer] = "-DLLVM_HAVE_OPT_VIEWER_MODULES=ON,-DLLVM_HAVE_OPT_VIEWER_MODULES=OFF,,python3-pygments python3-pyyaml"

Depending on wether the PACKAGECONFIG option is taken it looks like this in CMakeCache.txt:

//No help, variable specified on the command line.
LLVM_HAVE_OPT_VIEWER_MODULES:UNINITIALIZED=OFF

//No help, variable specified on the command line.
LLVM_HAVE_OPT_VIEWER_MODULES:UNINITIALIZED=ON

Have you test it? The config-ix.cmake file sets the LLVM_HAVE_OPT_VIEWER_MODULES variable [1].

Instead of LLVM_HAVE_OPT_VIEWER_MODULES I would set PY_PYGMENTS_FOUND, PY_PYGMENTS_LEXERS_C_CPP_FOUND and PY_YAML_FOUND.

[1] https://github.com/llvm/llvm-project/blob/main/llvm/cmake/config-ix.cmake#L693

Regards
  Stefan

Am 22.06.22 um 15:54 schrieb Stefan Herbrechtsmeier:
Hi Richard,

Am 22.06.2022 um 15:10 schrieb Richard Purdie via lists.openembedded.org:
There is a reproducibility issue which shouldn't be too hard to fix if
someone had a few minutes to help out:

https://bugzilla.yoctoproject.org/show_bug.cgi?id=14845

It is in llvm and is a cmake configuration issue. Rather than setting
that option based on the presence of python modules (with python from
the host), we should add a configuration option to force it to be
disabled in our case. Should be upstreamable with the right patch.

I'm not able to test it at the moment but it should be possible to set the variables (PY_PYGMENTS_FOUND, PY_PYGMENTS_LEXERS_C_CPP_FOUND and PY_YAML_FOUND) to OFF via EXTRA_OECMAKE:

-DPY_PYGMENTS_FOUND=OFF

The find_python_module function in config-ix.cmake returns early if the variable PY_${module_upper}_FOUND is defined.

Regards
  Stefan

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

Reply via email to