Mercurial > irccd
changeset 658:e0714513ed1d
CMake: move contrib to systemd, closes #786 @5m
author | David Demelier <markand@malikania.fr> |
---|---|
date | Tue, 27 Mar 2018 13:35:53 +0200 |
parents | c09aee75fde4 |
children | e9adad05580f |
files | CMakeLists.txt contrib/CMakeLists.txt contrib/irccd.service systemd/CMakeLists.txt systemd/irccd.service |
diffstat | 5 files changed, 45 insertions(+), 45 deletions(-) [+] |
line wrap: on
line diff
--- a/CMakeLists.txt Tue Mar 27 21:10:00 2018 +0200 +++ b/CMakeLists.txt Tue Mar 27 13:35:53 2018 +0200 @@ -35,13 +35,13 @@ # # Build system is then processed in different directories: # -# contrib - User contributions. # doc - The documentation process. # extern - External libraries. # lib - The irccd library # irccd - The irccd executable. # irccdctl - The irccdctl utility. # plugins - Official irccd plugins. +# systemd - Unit file for systemd. # tests - The unit tests. # win32 - Additional files for Windows platform. # @@ -91,7 +91,7 @@ add_subdirectory(irccd) add_subdirectory(irccdctl) add_subdirectory(irccd-test) -add_subdirectory(contrib) +add_subdirectory(systemd) if (HAVE_JS) add_subdirectory(plugins)
--- a/contrib/CMakeLists.txt Tue Mar 27 21:10:00 2018 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,33 +0,0 @@ -# -# CMakeLists.txt -- CMake build system for irccd -# -# Copyright (c) 2013-2018 David Demelier <markand@malikania.fr> -# -# Permission to use, copy, modify, and/or distribute this software for any -# purpose with or without fee is hereby granted, provided that the above -# copyright notice and this permission notice appear in all copies. -# -# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF -# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -# - -project(contrib) - -if (WITH_SYSTEMD) - set(PATH "${CMAKE_INSTALL_PREFIX}/${WITH_BINDIR}/irccd") - - configure_file( - ${CMAKE_CURRENT_SOURCE_DIR}/irccd.service - ${CMAKE_CURRENT_BINARY_DIR}/irccd.service - ) - - install( - FILES ${CMAKE_CURRENT_BINARY_DIR}/irccd.service - DESTINATION ${WITH_SYSTEMDDIR} - ) -endif()
--- a/contrib/irccd.service Tue Mar 27 21:10:00 2018 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,10 +0,0 @@ -[Unit] -Description=IRC Client Daemon -After=network.target - -[Service] -Type=forking -ExecStart=@PATH@ - -[Install] -WantedBy=multi-user.target
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/systemd/CMakeLists.txt Tue Mar 27 13:35:53 2018 +0200 @@ -0,0 +1,33 @@ +# +# CMakeLists.txt -- CMake build system for irccd +# +# Copyright (c) 2013-2018 David Demelier <markand@malikania.fr> +# +# Permission to use, copy, modify, and/or distribute this software for any +# purpose with or without fee is hereby granted, provided that the above +# copyright notice and this permission notice appear in all copies. +# +# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +# + +project(contrib) + +if (WITH_SYSTEMD) + set(PATH "${CMAKE_INSTALL_PREFIX}/${WITH_BINDIR}/irccd") + + configure_file( + ${CMAKE_CURRENT_SOURCE_DIR}/irccd.service + ${CMAKE_CURRENT_BINARY_DIR}/irccd.service + ) + + install( + FILES ${CMAKE_CURRENT_BINARY_DIR}/irccd.service + DESTINATION ${WITH_SYSTEMDDIR} + ) +endif()