Check for sys/resource.h and include it conditionally.