remove dependency on sdeventplus
This repository doesn't really use sdeventplus, other than for
running the dbus-loop, but there is already trivial code in
sdbusplus for that. Simplify and remove the dependency.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I8af7ad87a4fd87df400e810941fe58e412aedb24
diff --git a/meson.build b/meson.build
index 49ce8cb..05fbfc3 100644
--- a/meson.build
+++ b/meson.build
@@ -42,7 +42,6 @@
dependency('phosphor-dbus-interfaces'),
dependency('phosphor-logging'),
dependency('sdbusplus'),
- dependency('sdeventplus'),
exprtk,
nlohmann_json,
],
diff --git a/subprojects/sdeventplus.wrap b/subprojects/sdeventplus.wrap
deleted file mode 100644
index f871ac0..0000000
--- a/subprojects/sdeventplus.wrap
+++ /dev/null
@@ -1,6 +0,0 @@
-[wrap-git]
-url = https://github.com/openbmc/sdeventplus.git
-revision = HEAD
-
-[provide]
-sdeventplus = sdeventplus_dep
diff --git a/virtualSensor.cpp b/virtualSensor.cpp
index bf95bc4..cbf3891 100644
--- a/virtualSensor.cpp
+++ b/virtualSensor.cpp
@@ -3,7 +3,6 @@
#include "config.hpp"
#include <phosphor-logging/lg2.hpp>
-#include <sdeventplus/event.hpp>
#include <fstream>
@@ -941,9 +940,6 @@
*/
int main()
{
- // Get a default event loop
- auto event = sdeventplus::Event::get_default();
-
// Get a handle to system dbus
auto bus = sdbusplus::bus::new_default();
@@ -956,9 +952,8 @@
// Request service bus name
bus.request_name(busName);
- // Attach the bus to sd_event to service user requests
- bus.attach_event(event.get(), SD_EVENT_PRIORITY_NORMAL);
- event.loop();
+ // Run the dbus loop.
+ bus.process_loop();
return 0;
}