zephyr/lib/libc/minimal/include
Stephanos Ioannidis e918783af1 lib: libc: minimal: Define off_t as intptr_t
The `off_t` type, which is specified by the POSIX standard as a signed
integer type representing file sizes, was defined as `long` or `int`
depending on the target architecture without a clear explanation on why
it was defined as such.

While the POSIX standard does not specify the size requirement of the
`off_t` type, it generally corresponds to the size of a pointer in
practice, mainly because the optimal file handling size is closely tied
to the native pointer size.

For this reason, this commit removes the per-architecture `off_t`
definition and defines it as `intptr_t` such that its size always
matches the native pointer size.

Note that the toolchain-defined `__INTPTR_TYPE__` macro is used instead
of the `intptr_t` typedef as per the common convention used in the C
standard library headers.

Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
2022-08-19 02:47:50 +09:00
..
sys lib: libc: minimal: Define off_t as intptr_t 2022-08-19 02:47:50 +09:00
assert.h lib: migrate includes to <zephyr/...> 2022-05-06 19:58:09 +02:00
ctype.h
errno.h lib: migrate includes to <zephyr/...> 2022-05-06 19:58:09 +02:00
fcntl.h
inttypes.h libc: minimal: Add PRIxMAX macros for [u]intmax_t 2022-05-26 17:38:50 +02:00
limits.h
math.h lib/libc/minimal: Move sqrt/sqrtf from samples 2022-05-14 08:49:36 +09:00
stdbool.h
stdint.h
stdio.h lib: posix: add perror() implementation 2022-07-04 22:53:36 +02:00
stdlib.h libc: minimal: Add reentrant rand_r function 2022-06-01 11:03:38 +02:00
string.h libc: minimal: add strerror and strerror_r function 2022-07-04 22:53:36 +02:00
strings.h
time.h lib: migrate includes to <zephyr/...> 2022-05-06 19:58:09 +02:00