FreeBSD compat for makedev

Signed-off-by: Chris Rees <utisoft@gmail.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Chris Rees 2011-01-24 17:07:40 +01:00 committed by Denys Vlasenko
parent 330718ef55
commit e22af94afb

View File

@ -8,8 +8,14 @@
/* We do not include libbb.h - #define makedev() is there! */ /* We do not include libbb.h - #define makedev() is there! */
#include "platform.h" #include "platform.h"
#include <features.h> #if !(defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) \
#include <sys/sysmacros.h> || defined(__APPLE__) \
)
# include <features.h>
# include <sys/sysmacros.h>
#else
# include <sys/types.h>
#endif
#ifdef __GLIBC__ #ifdef __GLIBC__
/* At least glibc has horrendously large inline for this, so wrap it */ /* At least glibc has horrendously large inline for this, so wrap it */