blog » PHP » bind_textdomain_codeset undefined
bind_textdomain_codeset undefined
雪豹上,对php动态编译gettext成功后,发现这个函数还是不能用。
编译的一般过程是:
1。 编译gettext
2。 到php的扩展目录gettext下 phpize然后编译
编译安装后,发现部分函数可用,部分不可用。
排查了很久,通过在ext/gettext/ 目录下 configure编译时,输出
checking for GNU gettext support… yes, shared
checking for bindtextdomain in -lintl… yes
checking for ngettext in -lintl… no
checking for dngettext in -lintl… no
checking for dcngettext in -lintl… no
checking for bind_textdomain_codeset in -lintl… no
很明显,我要的函数,没给编进去
进行跟踪,发现是这几句的测试代码,都没加-L库,很奇怪。因为我的路径比较特殊,指定在了/src/gettext下。继续跟踪,在configure脚本中发现一句 (4200)
LDFLAGS=$O_LDFLAGS
好像是把LDFLAGS还原回去,不知道configure脚本为啥这么做。直接给注释了,再重新编,就都是yes了。
另,php版本是5.3.4
相关文章:
- php多进程时,遇到mysql has gone away的解决
- PHP中控制proc_open的执行时间
- 使用apache 的PHP cgi时遇到的Internal Server Error可能原因
- PHP json解析的注意事项
- 使用cgi作为php运行的命令需要注意的
RSS 2.0 | leave a response | trackback
发表评论