mirror of
https://github.com/json-c/json-c.git
synced 2026-03-23 23:19:06 +08:00
Merge pull request #904 from Lakshmi-Surekha/aix-getopt-dont-include
Include getopt.h header file if the platform is not AIX.
This commit is contained in:
@@ -94,6 +94,9 @@ endif() # end "standalone mode" block
|
||||
|
||||
# ---------------------------------
|
||||
|
||||
# Check whether getopt.h exists
|
||||
check_include_file(getopt.h HAVE_GETOPT_H)
|
||||
|
||||
check_include_file(sys/resource.h HAVE_SYS_RESOURCE_H) # for getrusage
|
||||
if (HAVE_SYS_RESOURCE_H)
|
||||
check_symbol_exists(getrusage "sys/resource.h" HAVE_GETRUSAGE)
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
#include <assert.h>
|
||||
#include <errno.h>
|
||||
#include <fcntl.h>
|
||||
#ifdef HAVE_GETOPT_H
|
||||
#include <getopt.h>
|
||||
#endif
|
||||
#include <stddef.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
Reference in New Issue
Block a user