首页
下载
文档
问答社区
视频
捐赠
源代码
AI 助理
赞助商
CRMEB
Apipost
腾讯云
微擎
禅道
51Talk
商业产品
Swoole AI 智能文档翻译器
Swoole-Compiler PHP 代码加密器
CRMEB 新零售社交电商系统
登录
注册
全部
提问
分享
讨论
建议
公告
开发框架
CodeGalaxy
发表新帖
编译报错反馈
### 问题描述 按照官方编译步骤make出现代码展示的报错 ### Swoole版本,PHP版本,以及操作系统版本信息 centos7 php7.2 win7-64位 ### 相关代码 ```php [root@localhost swoole]# make /bin/sh /root/swoole/libtool --mode=compile g++ -I. -I/root/swoole -DPHP_ATOM_INC -I/root/swoole/include -I/root/swoole/main -I/root/swoole -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/usr/lib/openssl/include -I/root/swoole -I/root/swoole/include -I/root/swoole/thirdparty/hiredis -DHAVE_CONFIG_H -g -O2 -Wall -Wno-unused-function -Wno-deprecated -Wno-deprecated-declarations -std=c++11 -c /root/swoole/swoole_table.cc -o swoole_table.lo g++ -I. -I/root/swoole -DPHP_ATOM_INC -I/root/swoole/include -I/root/swoole/main -I/root/swoole -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/usr/lib/openssl/include -I/root/swoole -I/root/swoole/include -I/root/swoole/thirdparty/hiredis -DHAVE_CONFIG_H -g -O2 -Wall -Wno-unused-function -Wno-deprecated -Wno-deprecated-declarations -std=c++11 -c /root/swoole/swoole_table.cc -fPIC -DPIC -o .libs/swoole_table.o /root/swoole/swoole_table.cc: 在函数‘void zim_swoole_table___construct(zend_execute_data*, zval*)’中: /root/swoole/swoole_table.cc:396:22: 错误:invalid user-defined conversion from ‘zim_swoole_table___construct(zend_execute_data*, zval*)::__lambda0’ to ‘uint64_t (*)(const char*, size_t) {aka long long unsigned int (*)(const char*, unsigned int)}’ [-fpermissive] table->hash_func = [](const char *key, size_t len) { ^ /root/swoole/swoole_table.cc:396:54: 附注:candidate is: zim_swoole_table___construct(zend_execute_data*, zval*)::__lambda0::operator unsigned int (*)(const char*, size_t)() const <就近匹配> table->hash_func = [](const char *key, size_t len) { ^ /root/swoole/swoole_table.cc:396:54: 附注: no known conversion for implicit ‘this’ parameter from ‘unsigned int (*)(const char*, size_t) {aka unsigned int (*)(const char*, unsigned int)}’ to ‘uint64_t (*)(const char*, size_t) {aka long long unsigned int (*)(const char*, unsigned int)}’ make: *** [swoole_table.lo] 错误 1 ``` ### 你期待的结果是什么?实际看到的错误信息又是什么? 告知原因和解决方案
发布于4年前 · 0 次浏览 · 来自
提问
yonomo
### 问题描述 按照官方编译步骤make出现代码展示的报错 ### Swoole版本,PHP版本,以及操作系统版本信息 centos7 php7.2 win7-64位 ### 相关代码 ```php [root@localhost swoole]# make /bin/sh /root/swoole/libtool --mode=compile g++ -I. -I/root/swoole -DPHP_ATOM_INC -I/root/swoole/include -I/root/swoole/main -I/root/swoole -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/usr/lib/openssl/include -I/root/swoole -I/root/swoole/include -I/root/swoole/thirdparty/hiredis -DHAVE_CONFIG_H -g -O2 -Wall -Wno-unused-function -Wno-deprecated -Wno-deprecated-declarations -std=c++11 -c /root/swoole/swoole_table.cc -o swoole_table.lo g++ -I. -I/root/swoole -DPHP_ATOM_INC -I/root/swoole/include -I/root/swoole/main -I/root/swoole -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/usr/lib/openssl/include -I/root/swoole -I/root/swoole/include -I/root/swoole/thirdparty/hiredis -DHAVE_CONFIG_H -g -O2 -Wall -Wno-unused-function -Wno-deprecated -Wno-deprecated-declarations -std=c++11 -c /root/swoole/swoole_table.cc -fPIC -DPIC -o .libs/swoole_table.o /root/swoole/swoole_table.cc: 在函数‘void zim_swoole_table___construct(zend_execute_data*, zval*)’中: /root/swoole/swoole_table.cc:396:22: 错误:invalid user-defined conversion from ‘zim_swoole_table___construct(zend_execute_data*, zval*)::__lambda0’ to ‘uint64_t (*)(const char*, size_t) {aka long long unsigned int (*)(const char*, unsigned int)}’ [-fpermissive] table->hash_func = [](const char *key, size_t len) { ^ /root/swoole/swoole_table.cc:396:54: 附注:candidate is: zim_swoole_table___construct(zend_execute_data*, zval*)::__lambda0::operator unsigned int (*)(const char*, size_t)() const <就近匹配> table->hash_func = [](const char *key, size_t len) { ^ /root/swoole/swoole_table.cc:396:54: 附注: no known conversion for implicit ‘this’ parameter from ‘unsigned int (*)(const char*, size_t) {aka unsigned int (*)(const char*, unsigned int)}’ to ‘uint64_t (*)(const char*, size_t) {aka long long unsigned int (*)(const char*, unsigned int)}’ make: *** [swoole_table.lo] 错误 1 ``` ### 你期待的结果是什么?实际看到的错误信息又是什么? 告知原因和解决方案
赞
0
分享
收藏
提问
分享
讨论
建议
公告
开发框架
CodeGalaxy
评论
2020-05-02
yonomo
``` /local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/root/swoole-src-4.5.0 -I/root/swoole-src-4.5.0/include -I/root/swoole-src-4.5.0/thirdparty/hiredis -DHAVE_CONFIG_H -g -O2 -Wall -Wno-unused-function -Wno-deprecated -Wno-deprecated-declarations -std=c++11 -c /root/swoole-src-4.5.0/src/coroutine/socket.cc -fPIC -DPIC -o src/coroutine/.libs/socket.o /root/swoole-src-4.5.0/src/coroutine/socket.cc: 在成员函数‘ssize_t swoole::coroutine::Socket::recv_packet(double)’中: /root/swoole-src-4.5.0/src/coroutine/socket.cc:1730:37: 警告:在有符号和无符号整数表达式间比较 [-Wsign-compare] else if (buf_len > protocol.package_max_length) ```
赞
0
回复
微信公众号
热门内容
暂无回复的问答
- CodeGalaxy K3s 轻量集群节点之间如何实现负载均衡
- 关于openssl CURL WARNING swSSL_connect: SSL_connect(fd=69) failed. Error: error:141A318A:SSL routines:tls_process_ske_dhe:dh key too small[1|394]
- 多个模型如何进行事务异常回退?
- websocket开启wss报错
- 协程tcp服务器如何使用多进程?recv()方法接收信息,打印出来的pid一直是同一个。没用使用到多进程啊。