From 7acc4141cebb57cc8d78b5cc8f6d53154ae0d636 Mon Sep 17 00:00:00 2001 From: Kaspar Schleiser Date: Tue, 7 Jul 2015 10:31:17 +0200 Subject: [PATCH] sys: add libc includes directory and sys/uio.h header --- sys/Makefile.include | 4 +++- sys/libc/include/sys/uio.h | 41 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 44 insertions(+), 1 deletion(-) create mode 100644 sys/libc/include/sys/uio.h diff --git a/sys/Makefile.include b/sys/Makefile.include index b18355d6942b..e6e289abcff5 100644 --- a/sys/Makefile.include +++ b/sys/Makefile.include @@ -102,4 +102,6 @@ endif ifneq (,$(filter newlib,$(USEMODULE))) include $(RIOTBASE)/sys/newlib/Makefile.include -endif \ No newline at end of file +endif + +INCLUDES += -I$(RIOTBASE)/sys/libc/include diff --git a/sys/libc/include/sys/uio.h b/sys/libc/include/sys/uio.h new file mode 100644 index 000000000000..8ee74b0f4299 --- /dev/null +++ b/sys/libc/include/sys/uio.h @@ -0,0 +1,41 @@ +/* + * Copyright (C) 2015 Kaspar Schleiser + * + * This file is subject to the terms and conditions of the GNU Lesser + * General Public License v2.1. See the file LICENSE in the top level + * directory for more details. + */ + +/** + * @addtogroup posix + * @{ + */ + +/** + * @file + * @brief libc header for scatter/gather I/O + * + * @author Kaspar Schleiser + */ +#ifndef UIO_H +#define UIO_H + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * @brief Structure for scatter/gather I/O. + */ +struct iovec { + void *iov_base; /**< Pointer to data. */ + size_t iov_len; /**< Length of data. */ +}; + +#ifdef __cplusplus +} +#endif +/** @} */ +#endif /* UIO_H */