diff options
| -rw-r--r-- | polyp/cpulimit.c | 5 | ||||
| -rw-r--r-- | polyp/util.c | 5 | 
2 files changed, 8 insertions, 2 deletions
| diff --git a/polyp/cpulimit.c b/polyp/cpulimit.c index f121123f..53920f50 100644 --- a/polyp/cpulimit.c +++ b/polyp/cpulimit.c @@ -30,10 +30,13 @@  #include <string.h>  #include <assert.h>  #include <sys/time.h> -#include <sys/resource.h>  #include <unistd.h>  #include <signal.h> +#ifdef HAVE_SYS_RESOURCE_H +#include <sys/resource.h> +#endif +  #include "cpulimit.h"  #include "util.h"  #include "log.h" diff --git a/polyp/util.c b/polyp/util.c index a05e601d..cccb6651 100644 --- a/polyp/util.c +++ b/polyp/util.c @@ -37,7 +37,6 @@  #include <signal.h>  #include <pthread.h>  #include <sys/time.h> -#include <sys/resource.h>  #include <limits.h>  #include <unistd.h> @@ -45,6 +44,10 @@  #include <sched.h>  #endif +#ifdef HAVE_SYS_RESOURCE_H +#include <sys/resource.h> +#endif +  #ifdef HAVE_NETDB_H  #include <netdb.h>  #endif | 
