blob: ca71fdba68433ea1a3a3fa6a0020c691c1ecdf31 [file] [log] [blame]
Denis Vlasenko8023d7d2006-11-24 15:06:28 +00001/*
2 * Utility routines.
3 *
Denis Vlasenkod18f52b2008-03-02 12:53:15 +00004 * Copyright (C) 2006 Denys Vlasenko
Denis Vlasenko8023d7d2006-11-24 15:06:28 +00005 *
6 * Licensed under GPL version 2, see file LICENSE in this tarball for details.
7 */
8
9/* We do not include libbb.h - #define makedev() is there! */
Denis Vlasenko9579d872008-06-28 04:58:55 +000010#include "platform.h"
Denis Vlasenko2ea630f2006-12-10 02:52:19 +000011#include <features.h>
Denis Vlasenko8023d7d2006-11-24 15:06:28 +000012#include <sys/sysmacros.h>
13
14#ifdef __GLIBC__
15/* At least glibc has horrendously large inline for this, so wrap it */
16/* uclibc people please check - do we need "&& !__UCLIBC__" above? */
Denis Vlasenko769d1e02007-01-22 23:04:27 +000017
18/* suppress gcc "no previous prototype" warning */
Denis Vlasenko9579d872008-06-28 04:58:55 +000019unsigned long long FAST_FUNC bb_makedev(unsigned int major, unsigned int minor);
20unsigned long long FAST_FUNC bb_makedev(unsigned int major, unsigned int minor)
Denis Vlasenko8023d7d2006-11-24 15:06:28 +000021{
22 return makedev(major, minor);
23}
24#endif