feat(echo): add echo client and server with CLI support

This commit is contained in:
Ваше Имя
2025-10-04 20:28:19 +04:00
parent a4c84379ff
commit 75563091c1
13 changed files with 314 additions and 9 deletions
+21 -9
View File
@@ -2,16 +2,28 @@ set_languages "c++23"
add_rules("plugin.compile_commands.autoupdate", { outputdir = "." })
add_requires("boost", {
system = true, -- sudo pacman -S boost
add_requires("cmake::Boost", {
alias = "boost",
system = true,
configs = {
all = false,
system = true, -- asio
components = { "program_options", "log" },
},
})
target "app"
set_kind "binary"
add_files "src/*.cpp"
add_links "boost_system"
-- Echo server target
target "echo_server"
do
set_kind "binary"
add_files("src/main/echo_server_main.cpp", "src/server/*.cpp", "src/session/*.cpp", "src/common/*.cpp")
add_includedirs("src", "src/server", "src/session", "src/common", { public = true })
add_packages "boost"
end
-- Echo client target
target "echo_client"
do
set_kind "binary"
add_files("src/main/echo_client_main.cpp", "src/client/*.cpp", "src/session/*.cpp", "src/common/*.cpp")
add_includedirs("src", "src/client", "src/session", "src/common", { public = true })
add_packages "boost"
end