Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

移植到 FreeBSD 的过程中发现的一些问题 #21

Open
GoogleCodeExporter opened this issue Apr 19, 2016 · 0 comments
Open

移植到 FreeBSD 的过程中发现的一些问题 #21

GoogleCodeExporter opened this issue Apr 19, 2016 · 0 comments

Comments

@GoogleCodeExporter
Copy link

提交了一个PR,移植httpsqs到FreeBSD上:
http://www.freebsd.org/cgi/query-pr.cgi?pr=156595

问题:

1. 编译期的一个warning,wait函数被隐式定义。需要加入头文件
#include <sys/wait.h>
根据编译gcc的参数不同,有些gcc会自己include某些头文件,可�
��看不到这个warning。

2. 使用了 procfs,只是为了获取可执行文件的路径。
BSD* 下 procfs 
是不推荐使用的(默认也不挂载),但也没有简单可靠地获��
�进程路径的方法。我在移植过程中把这个路径用编译时port系
统指定的安装路径替换了。

3. 不支持读配置文件。
这个给编写 rc.d 
脚本(或者init.d脚本)带来了困难。因为这些脚本只控制daemo
n的启动,终止等状态,daemon的功能性配置应该与之分离。

4. 以非daemon方式运行时,键盘Ctrl-c不会kill掉子进程。
考虑一下在非daemon模式下响应SIGINT信号(更简单的做法是绑��
�atexit函数)。

Original issue reported on code.google.com by [email protected] on 23 Apr 2011 at 8:57

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant