mirror of
https://git.rtems.org/rtems-libbsd/
synced 2025-05-19 08:28:03 +08:00

Add compatibility with Newlib header files. Some FreeBSD header files are mapped by the translation script: o rtems/bsd/sys/_types.h o rtems/bsd/sys/errno.h o rtems/bsd/sys/lock.h o rtems/bsd/sys/param.h o rtems/bsd/sys/resource.h o rtems/bsd/sys/time.h o rtems/bsd/sys/timespec.h o rtems/bsd/sys/types.h o rtems/bsd/sys/unistd.h It is now possible to include <sys/socket.h> directly for example. Generate one Makefile which builds everything including tests.
23 lines
493 B
C
23 lines
493 B
C
/* $FreeBSD$ */
|
|
|
|
#ifndef _PORT_BEFORE_H_
|
|
#define _PORT_BEFORE_H_
|
|
|
|
#define _LIBC 1
|
|
#define DO_PTHREADS 1
|
|
#define USE_KQUEUE 1
|
|
|
|
#define ISC_SOCKLEN_T socklen_t
|
|
#define ISC_FORMAT_PRINTF(fmt, args) \
|
|
__attribute__((__format__(__printf__, fmt, args)))
|
|
#define DE_CONST(konst, var) \
|
|
do { \
|
|
union { const void *k; void *v; } _u; \
|
|
_u.k = konst; \
|
|
var = _u.v; \
|
|
} while (0)
|
|
|
|
#define UNUSED(x) (void)(x)
|
|
|
|
#endif /* _PORT_BEFORE_H_ */
|