Add service file
Add the service file to run the buttons application and
install it from the CMakeLists.txt file.
It is not a templated service because the code is hardcoded
to use the instance 0 D-Bus object paths.
Change-Id: I4c57d9f47000bca4a5b1cd445f5bd4a7dfeb8b74
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
diff --git a/CMakeLists.txt b/CMakeLists.txt
index ce31c2c..790a95b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -55,4 +55,10 @@
add_executable(${PROJECT_NAME} ${SRC_FILES} )
target_link_libraries(${PROJECT_NAME} "${SDBUSPLUSPLUS_LIBRARIES} -lphosphor_dbus -lstdc++fs")
+set (
+ SERVICE_FILES
+ ${PROJECT_SOURCE_DIR}/service_files/xyz.openbmc_project.Chassis.Buttons.service
+)
+
+install (FILES ${SERVICE_FILES} DESTINATION /lib/systemd/system/)
install (TARGETS ${PROJECT_NAME} DESTINATION ${CMAKE_INSTALL_SBINDIR})