00979b2a89ba9292bf12c5cb58fd6cf833b2e121
[oota-llvm.git] / include / llvm / Config / sys / resource.h
1 /*
2  * Header file: resource.h
3  *
4  * Description:
5  *      This header file is the autoconf replacement for sys/resource.h (if it
6  *      lives on the system).
7  */
8
9 #ifndef _CONFIG_SYS_RESOURCE_H
10 #define _CONFIG_SYS_RESOURCE_H
11
12 #include "Config/config.h"
13
14 #ifdef HAVE_SYS_RESOURCE_H
15
16 /*
17  * In LLVM, we use sys/resource.h to use getrusage() and maybe some other
18  * stuff.  Some man pages say that you also need sys/time.h and unistd.h.
19  * So, to be paranoid, we will try to include all three if possible.
20  */
21 #ifdef HAVE_SYS_TIME_H
22 #include <sys/time.h>
23 #endif
24
25 #include <sys/resource.h>
26
27 #ifdef HAVE_UNISTD_H
28 #include <unistd.h>
29 #endif
30
31 #endif
32
33 #endif