[riot-devel] C headers available in RIOT

Christian Mehlis mehlis at inf.fu-berlin.de
Tue Jun 18 20:57:47 CEST 2013


Am 18.06.2013 17:29, schrieb Martin Lenders:
> Hi Christian,
>
> 2013/6/18 Christian Mehlis <mehlis at inf.fu-berlin.de
> <mailto:mehlis at inf.fu-berlin.de>>
>
>     Hi all,
>
>     I'm currently trying to port CCNx (talk from Van Jakobson:
>     http://www.youtube.com/watch?__v=3zOLrQJ5kbU
>     <http://www.youtube.com/watch?v=3zOLrQJ5kbU>) to RIOT and I need to
>     know which c includes I can rely on in riot?
>
>     I think these are ok:
>
>     #include <stdio.h>
>     #include <stdlib.h>
>     #include <string.h>
>     #include <errno.h>
>     #include <stdint.h>
>
>
> Those should be included by the toolchain, yes.
>
>     but what about (as comment I wrote the names of the used functions):
>
>     #include <arpa/inet.h> // struct sockaddr_storage, socket, connect
>     #include <fcntl.h> // open, fcntl
>     #include <poll.h> // pollfd
>     #include <sys/stat.h> // mkdir
>     #include <sys/time.h> // gettimeofday
>     #include <sys/un.h> // struct sockaddr_un
>     #include <unistd.h> // getpid, close, write, read, sleep, access
>
>
> some of these you can find in
> https://github.com/authmillenon/RIOT/tree/posix_wrapper/sys/posix/include but
> they are absolutely not tested (ETA for tests: July 19, but if you need
> them and would like to test them, I would be more than pleased :D).
> Especially close() propably won't help you since it only closes sockets
> by now. Still missing POSIX-Headers can be found here:
> https://github.com/authmillenon/RIOT/tree/posix_wrapper_todo/sys/posix/include

My question about the includes is more like: which ones are currently 
supported on all board (declared and implemented)? What is the libc on 
these boards? Is this libc feature complete to this list of headers:

http://de.wikipedia.org/wiki/Standard_C_Library

Best
Christian



More information about the devel mailing list