Jagpal Singh Gill | 6d131aa | 2024-04-07 23:56:48 -0700 | [diff] [blame] | 1 | #include "item_updater.hpp" |
Jagpal Singh Gill | 2311b64 | 2024-06-23 15:20:35 -0700 | [diff] [blame] | 2 | |
Jagpal Singh Gill | cc49878 | 2024-02-29 15:16:36 -0800 | [diff] [blame] | 3 | #include <phosphor-logging/lg2.hpp> |
Jagpal Singh Gill | 2311b64 | 2024-06-23 15:20:35 -0700 | [diff] [blame] | 4 | #include <sdbusplus/async.hpp> |
Jagpal Singh Gill | 6d131aa | 2024-04-07 23:56:48 -0700 | [diff] [blame] | 5 | |
| 6 | using ItemUpdaterIntf = phosphor::software::updater::ItemUpdater; |
Jagpal Singh Gill | cc49878 | 2024-02-29 15:16:36 -0800 | [diff] [blame] | 7 | |
| 8 | PHOSPHOR_LOG2_USING; |
| 9 | |
| 10 | int main() |
| 11 | { |
| 12 | info("Creating Software Manager"); |
Jagpal Singh Gill | 2311b64 | 2024-06-23 15:20:35 -0700 | [diff] [blame] | 13 | auto path = std::string(SOFTWARE_OBJPATH) + "/bmc"; |
| 14 | sdbusplus::async::context ctx; |
Jagpal Singh Gill | 6d131aa | 2024-04-07 23:56:48 -0700 | [diff] [blame] | 15 | sdbusplus::server::manager_t manager{ctx, SOFTWARE_OBJPATH}; |
Jagpal Singh Gill | 2311b64 | 2024-06-23 15:20:35 -0700 | [diff] [blame] | 16 | |
Jagpal Singh Gill | 6d131aa | 2024-04-07 23:56:48 -0700 | [diff] [blame] | 17 | constexpr auto serviceName = "xyz.openbmc_project.Software.Manager"; |
| 18 | |
| 19 | ItemUpdaterIntf itemUpdater{ctx, path}; |
| 20 | ctx.request_name(serviceName); |
Jagpal Singh Gill | 2311b64 | 2024-06-23 15:20:35 -0700 | [diff] [blame] | 21 | |
| 22 | ctx.run(); |
Jagpal Singh Gill | cc49878 | 2024-02-29 15:16:36 -0800 | [diff] [blame] | 23 | return 0; |
| 24 | } |