diff --git a/lib/posix/CMakeLists.txt b/lib/posix/CMakeLists.txt index 19fede849bf..ed9a7c416eb 100644 --- a/lib/posix/CMakeLists.txt +++ b/lib/posix/CMakeLists.txt @@ -1,7 +1,7 @@ # SPDX-License-Identifier: Apache-2.0 -add_library(posix_subsys INTERFACE) +zephyr_interface_library_named(posix_subsys) target_include_directories(posix_subsys INTERFACE ${ZEPHYR_BASE}/include/posix) diff --git a/lib/posix/Kconfig b/lib/posix/Kconfig index ef8e6063876..268a22a26f2 100644 --- a/lib/posix/Kconfig +++ b/lib/posix/Kconfig @@ -96,4 +96,12 @@ config POSIX_MAX_OPEN_FILES endif endif # FILE_SYSTEM +# The name of this option is mandated by zephyr_interface_library_named +# cmake directive. +config APP_LINK_WITH_POSIX_SUBSYS + bool "Make POSIX headers available to application" + default y + help + Add POSIX subsystem header files to the 'app' include path. + endif # POSIX_API