include(CheckIncludeFiles) include(CheckStructHasMember) check_include_files(GeoIPCity.h HAVE_GEOIPCITY_H) check_include_files(getopt.h HAVE_GETOPT_H) check_include_files(inttypes.h HAVE_INTTYPES_H) check_include_files(magic.h HAVE_MAGIC_H) check_include_files(memory.h HAVE_MEMORY_H) check_include_files(netinet/ether.h HAVE_NETINET_ETHER_H) check_include_files(netinet/if_ether.h HAVE_NETINET_IF_ETHER_H) check_include_files(netinet/in.h HAVE_NETINET_IN_H) check_include_files(netinet/ip6.h HAVE_NETINET_IP6_H) check_include_files(net/ethernet.h HAVE_NET_ETHERNET_H) check_include_files(socket.h HAVE_SOCKET_H) check_include_files(stdint.h HAVE_STDINT_H) check_include_files(stdlib.h HAVE_STDLIB_H) check_include_files(strings.h HAVE_STRINGS_H) check_include_files(string.h HAVE_STRING_H) check_include_files(sys/ethernet.h HAVE_SYS_ETHERNET_H) check_include_files(sys/stat.h HAVE_SYS_STAT_H) check_include_files(sys/types.h HAVE_SYS_TYPES_H) check_include_files(termcap.h HAVE_TERMCAP_H) check_include_files(term.h HAVE_TERM_H) check_include_files(unistd.h HAVE_UNISTD_H) check_include_files(time.h HAVE_TIME_H) check_include_files(sys/time.h HAVE_SYS_TIME_H) check_include_files("time.h;sys/time.h" TIME_WITH_SYS_TIME) check_include_files(os-proto.h HAVE_OS_PROTO_H) check_struct_has_member(HISTORY_STATE entries "stdio.h;readline/readline.h" HAVE_READLINE_HISTORY_ENTRIES) check_include_files("stdio.h;readline/readline.h" HAVE_READLINE_READLINE_H) check_include_files("stdio.h;readline/history.h" HAVE_READLINE_HISTORY_H) if (HAVE_READLINE_READLINE_H AND HAVE_READLINE_HISTORY_H AND HAVE_READLINE_HISTORY_ENTRIES) set(HAVE_READLINE true) endif () check_struct_has_member("struct sockaddr_in" sin_len "netinet/in.h" SIN_LEN)