As discussed in #16009 .
The meaning of CONFIG_SOCKETS_POSIX_NAMES is "expose Zephyr's namespaced socket API under standard POSIX names".
The meaning of CONFIG_POSIX_API is "expose all POSIX APIs which are available in Zephyr".
From this description, it's clear that these 2 options shouldn't be used together, as CONFIG_POSIX_API has wider scope which subsumes and supersedes meaning of CONFIG_SOCKETS_POSIX_NAMES.
However, implementation-wise, these 2 options are implemented differently, so if someone by mistake enabled them, that can lead to compile-time errors (whose reason may be not immediately clear.
Consequently, we should:
- Either make these 2 options conflict, with explicit error message describing the above, or
- Make CONFIG_POSIX_API silently subsume CONFIG_SOCKETS_POSIX_NAMES.