diff --git a/CMakeLists.txt b/CMakeLists.txt index 589df88..eae055f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -102,13 +102,28 @@ set_target_properties(${MODULE_NAME} PROPERTIES if(ENABLE_GNOME_NETWORKMANAGER) - target_sources(${MODULE_NAME} PRIVATE NetworkManagerGnomeProxy.cpp - NetworkManagerGnomeWIFI.cpp - NetworkManagerGnomeEvents.cpp - NetworkManagerGnomeUtils.cpp ) - target_include_directories(${MODULE_NAME} PRIVATE ${GLIB_INCLUDE_DIRS} ${LIBNM_INCLUDE_DIRS}) - target_link_libraries(${MODULE_NAME} PRIVATE ${LIBNM_LIBRARIES}) + if(ENABLE_GNOME_GDBUS) + message("networkmanager building with gdbus") + target_sources(${MODULE_NAME} PRIVATE + gdbus/NetworkManagerGdbusProxy.cpp + gdbus/NetworkManagerGdbusClient.cpp + gdbus/NetworkManagerGdbusEvent.cpp + gdbus/NetworkManagerGdbusMgr.cpp + gdbus/NetworkManagerGdbusUtils.cpp ) + target_include_directories(${MODULE_NAME} PRIVATE ${GLIB_INCLUDE_DIRS} ${GIO_INCLUDE_DIRS} ${LIBNM_INCLUDE_DIRS}) + target_link_libraries(${MODULE_NAME} PRIVATE ${GLIB_LIBRARIES} ${GIO_LIBRARIES}) + else() + message("networkmanager building with libnm") + target_sources(${MODULE_NAME} PRIVATE + NetworkManagerGnomeProxy.cpp + NetworkManagerGnomeWIFI.cpp + NetworkManagerGnomeEvents.cpp + NetworkManagerGnomeUtils.cpp ) + target_include_directories(${MODULE_NAME} PRIVATE ${GLIB_INCLUDE_DIRS} ${LIBNM_INCLUDE_DIRS}) + target_link_libraries(${MODULE_NAME} PRIVATE ${LIBNM_LIBRARIES}) + endif() else() + message("networkmanager building with netsrvmgr") target_sources(${MODULE_NAME} PRIVATE NetworkManagerRDKProxy.cpp) target_include_directories(${MODULE_NAME} PRIVATE ${IARMBUS_INCLUDE_DIRS}) target_link_libraries(${MODULE_NAME} PRIVATE ${IARMBUS_LIBRARIES})