From 08f6b21ce7cc4aa4069b4461785fc7173bed2998 Mon Sep 17 00:00:00 2001 From: Josh Blum Date: Fri, 26 Mar 2010 11:45:56 -0700 Subject: added interface address discovery --- host/lib/CMakeLists.txt | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'host/lib/CMakeLists.txt') diff --git a/host/lib/CMakeLists.txt b/host/lib/CMakeLists.txt index 22fbde265..4dd638336 100644 --- a/host/lib/CMakeLists.txt +++ b/host/lib/CMakeLists.txt @@ -28,6 +28,7 @@ SET(libuhd_sources time_spec.cpp types.cpp wax.cpp + transport/if_addrs.cpp transport/udp_simple.cpp transport/vrt.cpp usrp/dboard/basic.cpp @@ -60,7 +61,6 @@ LIST(APPEND libuhd_sources # Setup defines for module loading ######################################################################## INCLUDE(CheckIncludeFileCXX) - CHECK_INCLUDE_FILE_CXX(dlfcn.h HAVE_DLFCN_H) CHECK_INCLUDE_FILE_CXX(Winbase.h HAVE_WINBASE_H) @@ -74,6 +74,19 @@ ELSE(HAVE_DLFCN_H) MESSAGE(STATUS "Module loading not supported...") ENDIF(HAVE_DLFCN_H) +######################################################################## +# Setup defines for interface address discovery +######################################################################## +INCLUDE(CheckIncludeFileCXX) +CHECK_INCLUDE_FILE_CXX(ifaddrs.h HAVE_IFADDRS_H) + +IF(HAVE_IFADDRS_H) + MESSAGE(STATUS "Interface address discovery supported through getifaddrs...") + ADD_DEFINITIONS(-DHAVE_IFADDRS_H) +ELSE(HAVE_IFADDRS_H) + MESSAGE(STATUS "Interface address discovery not supported...") +ENDIF(HAVE_IFADDRS_H) + ######################################################################## # Setup libuhd library ######################################################################## -- cgit v1.2.3