节俭动态库编译

进入lib/cpp执行让编译libthrift

1)。/src/节俭/节俭。h: 48:39:致命错误:增加/工具/enable_if。高压泵:没有这样的文件或目录
# include & lt;提高/工具/enable_if.hpp>

解决yum安装boost-devel


2)/opt/thrift-0.9.0/lib/cpp/lib/libthrift。所以:未定义的参考“SSL_accept”

/opt/thrift-0.9.0/lib/cpp/lib/libthrift。所以:未定义的参考“SSL_shutdown”
/opt/thrift-0.9.0/lib/cpp/lib/libthrift。所以:未定义的参考“SSL_get_shutdown”
/opt/thrift-0.9.0/lib/cpp/lib/libthrift。所以:未定义的参考“SSL_CTX_ctrl”
/opt/thrift-0.9.0/lib/cpp/lib/libthrift。所以:未定义的参考“X509_NAME_ENTRY_get_data”
/opt/thrift-0.9.0/lib/cpp/lib/libthrift。所以:未定义的参考“SSL_get_error”
/opt/thrift-0.9.0/lib/cpp/lib/libthrift。所以:未定义的参考“SSL_CTX_free”
collect2:错误:ld返回1退出状态
[1]: * * *(基准)错误1
[1]:离开目录”/opt/thrift-0.9.0/lib/cpp/测试”

解决修改编辑/Makefile文件,链接库轻轨车-lpthread添加-lssl -lcrtypto


编译错误:语法支持问题

src/生成/t_rb_generator。答:成员函数的虚拟空t_rb_generator: generate_enum (t_enum *):
src/生成/t_rb_generator。答:359:11:错误:操作数?:有不同类型“bool”和“std:: basic_ostream ?第=false: f_types_ & lt; & lt;”、“;
~ ~ ~ ~ ~ ~ ^ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
src/生成/t_rb_generator。答:369:11:错误:操作数?:有不同类型“bool”和“std:: basic_ostream ?第=false: f_types_ & lt; & lt;”、“;
~ ~ ~ ~ ~ ~ ^ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
[3]: * * * (Makefile: 749: thrift-t_rb_generator。o]错误1
[3]:离开目录“/home/东/thrift-0.9.0/编译器/cpp的

解决

将第一?第=false: f_types_ & lt; & lt;”、“;

修改为

如果(第一个)
{
第一=false:
}

其他{
f_types_ & lt; & lt;”、“;
}


节俭动态库编译