meson: Only allow CONFIG_USER_ONLY from certain source sets

Poison CONFIG_USER_ONLY and CONFIG_SOFTMMU unless
the compilation unit is in specific_ss, libuser_ss,
or libsystem_ss.  This is intended to prevent files
being incorrectly added to common_ss.

Remove #ifndef CONFIG_USER_ONLY / #error / #endif blocks.
All they do is trigger the poison error.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
This commit is contained in:
Richard Henderson 2025-03-12 20:24:44 -07:00
parent e4610f3809
commit 8916c373a3
6 changed files with 9 additions and 18 deletions

View file

@ -66,4 +66,9 @@
#pragma GCC poison CONFIG_WHPX
#pragma GCC poison CONFIG_XEN
#ifndef COMPILING_SYSTEM_VS_USER
#pragma GCC poison CONFIG_USER_ONLY
#pragma GCC poison CONFIG_SOFTMMU
#endif
#endif