mirror of https://github.com/F-Stack/f-stack.git
Fix compiling errors of tools.
This commit is contained in:
parent
7787718ee8
commit
1f5381c9ea
|
@ -37,10 +37,6 @@
|
|||
#define __dead __dead2
|
||||
#endif
|
||||
|
||||
#ifndef __unused
|
||||
#define __unused __attribute__((__unused__))
|
||||
#endif
|
||||
|
||||
#ifndef nitems
|
||||
#define nitems(x) (sizeof((x)) / sizeof((x)[0]))
|
||||
#endif
|
||||
|
|
|
@ -31,6 +31,12 @@ __FBSDID("$FreeBSD$");
|
|||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#ifdef FSTACK
|
||||
#ifndef __unused
|
||||
#define __unused __attribute__((__unused__))
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Stub out what's in -lcrypt.
|
||||
*/
|
||||
|
|
|
@ -13,7 +13,7 @@ CLEANFILES+= nl_symbols.c nl_defs.h
|
|||
|
||||
CFLAGS+= -I${TOPDIR}/tools/libutil
|
||||
CFLAGS+= -I${TOPDIR}/tools/libmemstat
|
||||
CFLAGS+= -I${TOPDIR}/tools/libxo/libxo
|
||||
CFLAGS+= -I${TOPDIR}/tools/libxo
|
||||
|
||||
LIBS+= -L${TOPDIR}/tools/libutil -lutil
|
||||
LIBS+= -L${TOPDIR}/tools/libmemstat -lmemstat
|
||||
|
|
|
@ -32,6 +32,12 @@
|
|||
|
||||
#include <sys/cdefs.h>
|
||||
|
||||
#ifdef FSTACK
|
||||
#ifndef __unused
|
||||
#define __unused __attribute__((__unused__))
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#define satosin(sa) ((struct sockaddr_in *)(sa))
|
||||
#define satosin6(sa) ((struct sockaddr_in6 *)(sa))
|
||||
#define sin6tosa(sin6) ((struct sockaddr *)(sin6))
|
||||
|
|
Loading…
Reference in New Issue