Skip to content

Commit bbac3a6

Browse files
committed
Land #1190 - fix resolv.h and arpa/nameser.h detection
Change-Id: I6a6a6964e97961b85bb743940f38aa31c19004bd
2 parents 887c1d0 + d580acb commit bbac3a6

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

CMakeLists.txt

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -378,6 +378,16 @@ if(HAVE_NETINET_IP_H)
378378
add_definitions(-DHAVE_NETINET_IP_H)
379379
endif()
380380

381+
check_include_files(resolv.h HAVE_RESOLV_H)
382+
if(HAVE_RESOLV_H)
383+
add_definitions(-DHAVE_RESOLV_H)
384+
endif()
385+
386+
check_include_files(arpa/nameser.h HAVE_ARPA_NAMESER_H)
387+
if(HAVE_ARPA_NAMESER_H)
388+
add_definitions(-DHAVE_ARPA_NAMESER_H)
389+
endif()
390+
381391
# This isn't ready for universal binaries yet, since we do conditional
382392
# compilation based on the architecture, but this makes cross compiling for a
383393
# single architecture work on macOS at least.

0 commit comments

Comments
 (0)