summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad Bishop <bradleyb@fuzziesquirrel.com>2018-12-11 16:36:02 -0500
committerBrad Bishop <bradleyb@fuzziesquirrel.com>2018-12-17 13:10:10 +0000
commitb666e539af3e70bf73f3aa459e54190c71c878f0 (patch)
tree6ae1f9b54776b85da656c5e03e11174efec4fbbc
parent783d1f98e32a7ee77db645196ba6843c0b0d9419 (diff)
downloadphosphor-inventory-manager-b666e539af3e70bf73f3aa459e54190c71c878f0.tar.gz
phosphor-inventory-manager-b666e539af3e70bf73f3aa459e54190c71c878f0.zip
types: minor build improvements
We don't need all of message.hpp to be included from types.hpp since all we need is the variant definition. Instead, just get sdbusplus/message/types.hpp, which has the variant definition. message.hpp picks up <memory> so add that where it is now missing (events.hpp). Add a missing cstdint include. Change-Id: Ic033ceafcd982dba3e39592a4d8f64e5b4e65f2e Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
-rw-r--r--events.hpp3
-rw-r--r--types.hpp17
2 files changed, 18 insertions, 2 deletions
diff --git a/events.hpp b/events.hpp
index 0cdcfbc..735834a 100644
--- a/events.hpp
+++ b/events.hpp
@@ -2,6 +2,9 @@
#include "types.hpp"
+#include <memory>
+#include <vector>
+
namespace phosphor
{
namespace inventory
diff --git a/types.hpp b/types.hpp
index 4160dc9..1526ce9 100644
--- a/types.hpp
+++ b/types.hpp
@@ -1,10 +1,23 @@
#pragma once
+#include <cstdint>
#include <functional>
#include <map>
-#include <sdbusplus/message.hpp>
+#include <sdbusplus/message/types.hpp>
#include <string>
+namespace sdbusplus
+{
+namespace message
+{
+class message;
+}
+namespace bus
+{
+class bus;
+}
+} // namespace sdbusplus
+
namespace phosphor
{
namespace inventory
@@ -16,7 +29,7 @@ class Manager;
/** @brief Inventory manager supported property types. */
using InterfaceVariantType =
- sdbusplus::message::variant<bool, int64_t, std::string>;
+ sdbusplus::message::variant_ns::variant<bool, int64_t, std::string>;
template <typename T>
using InterfaceType = std::map<std::string, T>;
OpenPOWER on IntegriCloud