diff options
| author | Quentin Schulz <quentin.schulz@cherry.de> | 2025-06-12 14:14:32 +0200 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2025-06-16 17:57:29 +0100 |
| commit | 795702eb0e5509212089c2ce50596553fc16f296 (patch) | |
| tree | 4189c3946f7e16670493c0599fbd3eff38277728 | |
| parent | 1393f68da716dac6a0391695e9b3f85ade0c7aec (diff) | |
| download | poky-795702eb0e5509212089c2ce50596553fc16f296.tar.gz | |
mesa: do not build nouveau NVIDIA gallium-llvm driver if not requested
The Nouveau driver is used for NVIDIA GPUs and thus doesn't really need
to be always enabled when building gallium-llvm drivers.
So let's guard it with a nouveau PACKAGECONFIG.
The only intended change is nouveau not being build on target mesa on
non-x86/i686 machines when building gallium-llvm drivers as I assume
NVIDIA GPUs aren't that common on other CPU architectures (tegra already
bringing in the nouveau driver should handle the NVIDIA SoCs that would
benefit from nouveau driver and thus are not impacted by this change).
(From OE-Core rev: 22e7f562fb4b5becc342fe7d60c37c70e42ccf6b)
Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rw-r--r-- | meta/recipes-graphics/mesa/mesa.inc | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/meta/recipes-graphics/mesa/mesa.inc b/meta/recipes-graphics/mesa/mesa.inc index 291124f29f..56ac18ea53 100644 --- a/meta/recipes-graphics/mesa/mesa.inc +++ b/meta/recipes-graphics/mesa/mesa.inc | |||
| @@ -93,10 +93,10 @@ PACKAGECONFIG = " \ | |||
| 93 | # skip all Rust dependencies if we are not building OpenCL" | 93 | # skip all Rust dependencies if we are not building OpenCL" |
| 94 | INHIBIT_DEFAULT_RUST_DEPS = "${@bb.utils.contains('PACKAGECONFIG', 'opencl', '', '1', d)}" | 94 | INHIBIT_DEFAULT_RUST_DEPS = "${@bb.utils.contains('PACKAGECONFIG', 'opencl', '', '1', d)}" |
| 95 | 95 | ||
| 96 | PACKAGECONFIG:append:x86 = " libclc gallium-llvm intel amd svga" | 96 | PACKAGECONFIG:append:x86 = " libclc gallium-llvm intel amd nouveau svga" |
| 97 | PACKAGECONFIG:append:x86-64 = " libclc gallium-llvm intel amd svga" | 97 | PACKAGECONFIG:append:x86-64 = " libclc gallium-llvm intel amd nouveau svga" |
| 98 | PACKAGECONFIG:append:i686 = " libclc gallium-llvm intel amd svga" | 98 | PACKAGECONFIG:append:i686 = " libclc gallium-llvm intel amd nouveau svga" |
| 99 | PACKAGECONFIG:append:class-native = " libclc gallium-llvm amd svga" | 99 | PACKAGECONFIG:append:class-native = " libclc gallium-llvm amd nouveau svga" |
| 100 | 100 | ||
| 101 | # "gbm" requires "opengl" | 101 | # "gbm" requires "opengl" |
| 102 | PACKAGECONFIG[gbm] = "-Dgbm=enabled,-Dgbm=disabled" | 102 | PACKAGECONFIG[gbm] = "-Dgbm=enabled,-Dgbm=disabled" |
| @@ -173,14 +173,16 @@ GALLIUMDRIVERS:append = "${@bb.utils.contains('PACKAGECONFIG', 'zink', ',zink', | |||
| 173 | GALLIUMDRIVERS_ASAHI = "${@bb.utils.contains('PACKAGECONFIG', 'asahi libclc opencl', ',asahi', '', d)}" | 173 | GALLIUMDRIVERS_ASAHI = "${@bb.utils.contains('PACKAGECONFIG', 'asahi libclc opencl', ',asahi', '', d)}" |
| 174 | GALLIUMDRIVERS_AMD = "${@bb.utils.contains('PACKAGECONFIG', 'amd', ',r300', '', d)}" | 174 | GALLIUMDRIVERS_AMD = "${@bb.utils.contains('PACKAGECONFIG', 'amd', ',r300', '', d)}" |
| 175 | GALLIUMDRIVERS_IRIS = "${@bb.utils.contains('PACKAGECONFIG', 'intel libclc', ',iris', '', d)}" | 175 | GALLIUMDRIVERS_IRIS = "${@bb.utils.contains('PACKAGECONFIG', 'intel libclc', ',iris', '', d)}" |
| 176 | GALLIUMDRIVERS_NOUVEAU = "${@bb.utils.contains('PACKAGECONFIG', 'nouveau', ',nouveau', '', d)}" | ||
| 176 | GALLIUMDRIVERS_RADEONSI = "${@bb.utils.contains('PACKAGECONFIG', 'amd', ',radeonsi', '', d)}" | 177 | GALLIUMDRIVERS_RADEONSI = "${@bb.utils.contains('PACKAGECONFIG', 'amd', ',radeonsi', '', d)}" |
| 177 | GALLIUMDRIVERS_LLVMPIPE = ",llvmpipe" | 178 | GALLIUMDRIVERS_LLVMPIPE = ",llvmpipe" |
| 178 | # llvmpipe crashes on x32 | 179 | # llvmpipe crashes on x32 |
| 179 | GALLIUMDRIVERS_LLVMPIPE:x86-x32 = "" | 180 | GALLIUMDRIVERS_LLVMPIPE:x86-x32 = "" |
| 180 | GALLIUMDRIVERS_SVGA = "${@bb.utils.contains('PACKAGECONFIG', 'svga', ',svga', '', d)}" | 181 | GALLIUMDRIVERS_SVGA = "${@bb.utils.contains('PACKAGECONFIG', 'svga', ',svga', '', d)}" |
| 181 | GALLIUMDRIVERS_LLVM = ",nouveau${GALLIUMDRIVERS_LLVMPIPE}${GALLIUMDRIVERS_AMD}${GALLIUMDRIVERS_ASAHI}${GALLIUMDRIVERS_IRIS}${GALLIUMDRIVERS_RADEONSI}${GALLIUMDRIVERS_SVGA}" | 182 | GALLIUMDRIVERS_LLVM = "${GALLIUMDRIVERS_LLVMPIPE}${GALLIUMDRIVERS_AMD}${GALLIUMDRIVERS_ASAHI}${GALLIUMDRIVERS_IRIS}${GALLIUMDRIVERS_NOUVEAU}${GALLIUMDRIVERS_RADEONSI}${GALLIUMDRIVERS_SVGA}" |
| 182 | 183 | ||
| 183 | PACKAGECONFIG[amd] = "" | 184 | PACKAGECONFIG[amd] = "" |
| 185 | PACKAGECONFIG[nouveau] = "" | ||
| 184 | PACKAGECONFIG[svga] = "" | 186 | PACKAGECONFIG[svga] = "" |
| 185 | PACKAGECONFIG[virgl] = "" | 187 | PACKAGECONFIG[virgl] = "" |
| 186 | 188 | ||
