libc: minimal: include: move fcntl.h to posix

The `fcntl.h` header has never been a part of ISO C so move it to
`include/zephyr/posix`.

To ensure a smooth migration, a header was left in
`lib/libc/minimal/include` that prints a deprecation warning.

Users should either include `<zephyr/posix/fcntl.h>` or switch to
`CONFIG_POSIX_API=y`.

Signed-off-by: Chris Friedt <cfriedt@meta.com>
This commit is contained in:
Chris Friedt 2022-11-16 17:04:17 -05:00 committed by Stephanos Ioannidis
commit 8659e2f69e
13 changed files with 64 additions and 14 deletions

View file

@ -12,7 +12,7 @@
#include <string.h>
#include <zephyr/sys/fdtable.h>
#include <zephyr/posix/sys/stat.h>
#include <fcntl.h>
#include <zephyr/posix/fcntl.h>
#include <zephyr/fs/fs.h>
BUILD_ASSERT(PATH_MAX >= MAX_FILE_NAME, "PATH_MAX is less than MAX_FILE_NAME");