include(MacroEnsureVersion)
macro_optional_find_package(NetworkManager)

set(HAVE_NETWORKMANAGER FALSE)
if(NETWORKMANAGER_FOUND)
  macro_ensure_version("0.9.0" ${NETWORKMANAGER_VERSION} NM_0_9)
  if (NM_0_9)
    message(STATUS "Will build networkmanager-0.9")
    set(HAVE_NETWORKMANAGER TRUE)
    add_subdirectory(networkmanager-0.9)
  endif (NM_0_9)
endif (NETWORKMANAGER_FOUND)
macro_log_feature(HAVE_NETWORKMANAGER "NetworkManager" "A daemon for user controlled networking" "http://www.gnome.org/projects/NetworkManager" FALSE "0.9.0" "Needed for building Network Management support in Solid.")
