You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-- make as a static library
set_kind("binary")
set_warnings("all", "error")
set_languages("c99", "c++11")
set_optimize("fastest")
-- add the common source files
add_files("*.c")
-- add depends packages
add_packages("tbox", "openssl")
The text was updated successfully, but these errors were encountered:
以下是测试代码,跟踪到 tb_co_schedular_switch->tb_context_jump 进程就退出了。
// test_main.cpp
#include <tbox/tbox.h>
static tb_void_t test_run(tb_cpointer_t priv)
{
tb_socket_ref_t sock_fd;
tb_ipaddr_t addr, peer_addr;
tb_size_t ret;
}
int main(int ac, char *av[])
{
tb_co_scheduler_ref_t scheduler;
}
//xmake.lua
add_requires("tbox", {configs = {debug = false, coroutine=true}})
add_requires("openssl")
-- project
set_project("testudp")
-- set project version
set_version("1.0.0", {build = "%Y%m%d%H%M"})
-- set warning all as error
set_warnings("all", "error")
set_languages("c99")
set_optimize("fastest")
-- disable some compiler errors
add_cxflags("-Wno-error=deprecated-declarations", "-fno-strict-aliasing", "-Wno-error=expansion-to-defined", "-Wall", "-Wextra", "-Werror", "-g")
add_mxflags("-Wno-error=deprecated-declarations", "-fno-strict-aliasing", "-Wno-error=expansion-to-defined")
-- add build modes
add_rules("mode.debug", "mode.release")
-- add target
target("test_udp")
-- deps project
The text was updated successfully, but these errors were encountered: