2019-04-06 15:08:09 +02:00
|
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
|
2018-04-05 19:11:15 +02:00
|
|
|
|
2019-05-06 15:50:24 +02:00
|
|
|
zephyr_interface_library_named(posix_subsys)
|
2018-04-05 19:11:15 +02:00
|
|
|
|
2019-08-29 20:57:19 +02:00
|
|
|
if(CONFIG_POSIX_API)
|
2022-03-29 21:52:59 +02:00
|
|
|
target_include_directories(posix_subsys INTERFACE ${ZEPHYR_BASE}/include/zephyr/posix)
|
2019-08-29 20:57:19 +02:00
|
|
|
endif()
|
2018-04-05 19:11:15 +02:00
|
|
|
|
|
|
|
zephyr_library()
|
2022-06-25 18:55:46 +02:00
|
|
|
zephyr_library_sources(perror.c)
|
2018-04-05 19:11:15 +02:00
|
|
|
zephyr_library_sources(pthread_common.c)
|
2018-09-28 08:15:47 +02:00
|
|
|
zephyr_library_sources_ifdef(CONFIG_PTHREAD_IPC pthread_cond.c)
|
|
|
|
zephyr_library_sources_ifdef(CONFIG_PTHREAD_IPC pthread_mutex.c)
|
|
|
|
zephyr_library_sources_ifdef(CONFIG_PTHREAD_IPC pthread_barrier.c)
|
|
|
|
zephyr_library_sources_ifdef(CONFIG_PTHREAD_IPC pthread.c)
|
2019-08-29 20:57:19 +02:00
|
|
|
zephyr_library_sources_ifdef(CONFIG_PTHREAD_IPC pthread_sched.c)
|
|
|
|
zephyr_library_sources_ifdef(CONFIG_POSIX_CLOCK clock.c)
|
|
|
|
zephyr_library_sources_ifdef(CONFIG_POSIX_CLOCK sleep.c)
|
|
|
|
zephyr_library_sources_ifdef(CONFIG_POSIX_CLOCK timer.c)
|
2018-09-28 08:15:47 +02:00
|
|
|
zephyr_library_sources_ifdef(CONFIG_PTHREAD_IPC pthread_rwlock.c)
|
|
|
|
zephyr_library_sources_ifdef(CONFIG_PTHREAD_IPC semaphore.c)
|
|
|
|
zephyr_library_sources_ifdef(CONFIG_PTHREAD_IPC pthread_key.c)
|
2018-04-05 19:11:15 +02:00
|
|
|
zephyr_library_sources_ifdef(CONFIG_POSIX_MQUEUE mqueue.c)
|
2018-05-03 13:47:22 +02:00
|
|
|
zephyr_library_sources_ifdef(CONFIG_POSIX_FS fs.c)
|
2019-11-05 16:09:42 +01:00
|
|
|
zephyr_library_sources_ifdef(CONFIG_EVENTFD eventfd.c)
|
2021-07-01 11:00:15 +02:00
|
|
|
add_subdirectory_ifdef(CONFIG_GETOPT getopt)
|
2018-04-05 19:11:15 +02:00
|
|
|
|
2020-05-23 12:09:28 +02:00
|
|
|
if(NOT (CONFIG_BOARD_NATIVE_POSIX OR CONFIG_BOARD_NATIVE_POSIX_64BIT))
|
|
|
|
zephyr_library_sources(nanosleep.c)
|
|
|
|
endif()
|
|
|
|
|
2019-10-24 17:08:21 +02:00
|
|
|
zephyr_library_include_directories(
|
|
|
|
${ZEPHYR_BASE}/kernel/include
|
2020-07-07 08:06:27 +02:00
|
|
|
${ARCH_DIR}/${ARCH}/include
|
2019-10-24 17:08:21 +02:00
|
|
|
)
|
|
|
|
|
2019-08-07 15:42:25 +02:00
|
|
|
zephyr_library_link_libraries(posix_subsys)
|