bmybbs / PrototypeDevManagement

1 stars 1 forks source link

onion helloworld 编译(单线程、多线程) #2

Closed IronBlood closed 10 years ago

IronBlood commented 10 years ago

貌似只是在 onion_new() 的时候指定运行模式, 例如 O_POOL O_ONE_LOOP,不受编译参数 -DHAVE_PTHREADS 的影响。

但是在 Ubuntu 10.04 中运行出错,详见 onion #31。 @Liu-Ameng 你找个环境跑一下他们的 example 试试?

Liu-Ameng commented 10 years ago

Re

在 2013年10月15日星期二,Yang Shen 写道:

貌似只是在 onion_new() 的时候指定运行模式, 例如 O_POOL O_ONE_LOOP,不受编译参数 -DHAVE_PTHREADS的影响。

但是在 Ubuntu 10.04 中运行出错,详见 onion #31https://github.com/davidmoreno/onion/issues/31。 @Liu-Ameng https://github.com/Liu-Ameng 你找个环境跑一下他们的 example 试试?

— Reply to this email directly or view it on GitHubhttps://github.com/bmybbs/ExtDevMng/issues/2#issuecomment-26309561 .

IronBlood commented 10 years ago

Ubuntu 10.04 x64 运行 example 失败,Ubuntu 12.04 x86 貌似可行。

IronBlood commented 10 years ago

刚在一个 ubuntu 10.04 x64 的环境上编译,记录一下依赖的库

onion-0.5 编译警告被当成错误,中断了,暂无精力去检查 cmake。git 中的编译、运行 hello 也ok

cc1: warnings being treated as errors
/home/ironblood/onion-0.5/src/onion/poller.c: In function ‘onion_poller_stop’:
/home/ironblood/onion-0.5/src/onion/poller.c:453: error: ignoring return value of ‘write’, declared with attribute warn_unused_result
make[2]: *** [src/onion/CMakeFiles/onion.dir/poller.c.o] Error 1
make[1]: *** [src/onion/CMakeFiles/onion.dir/all] Error 2
IronBlood commented 10 years ago

10.04 x64 运行成功。测试站原因不详。 @Liu-Ameng 你那边也开始看看他的hello吧,挺easy的,我把部分代码这两天迁移过来,然后周末前把后端登录的功能搞定,部署到测试站上去。