如何在构建节俭 0.9.2 时启用 Tonblocking服务器

How to enable TNonblockingServer while I'm building Thrift 0.9.2

本文关键字:启用 Tonblocking 服务器 构建      更新时间:2023-10-16

我试图用0.9.2版本建立一个节俭,这是我执行的命令:

sudo ./configure --with-boost=/usr/local/boost_1.58.0

它将成功,但我得到这样的返回消息:

thrift 0.9.2
Building C++ Library ......... : yes
Building C (GLib) Library .... : yes
Building Java Library ........ : yes
Building C# Library .......... : no
Building Python Library ...... : yes
Building Ruby Library ........ : no
Building Haskell Library ..... : no
Building Perl Library ........ : no
Building PHP Library ......... : yes
Building Erlang Library ...... : no
Building Go Library .......... : no
Building D Library ........... : no
Building NodeJS Library ...... : no
Building Lua Library ......... : yes
C++ Library:
   Build TZlibTransport ...... : yes
   Build TNonblockingServer .. : no
   Build TQTcpServer (Qt) .... : yes
Java Library:
   Using javac ............... : javac
   Using java ................ : java
   Using ant ................. : /usr/bin/ant
Python Library:
   Using Python .............. : /usr/bin/python
PHP Library:
   Using php-config .......... : 
Lua Library:
   Using Lua .............. : /usr/bin/lua
If something is missing that you think should be present,
please skim the output of configure to find the missing
component.  Details are present in config.log.

我已经尝试了很多方法让构建TNonblockingServer选项是YES,但我失败了。

需要安装libevent。以下是configure.ac的相关部分:

AX_LIB_EVENT([1.0])
have_libevent=$success

echo "   Build TNonblockingServer .. : $have_libevent"

它也列在这里的"语言要求"部分:

语言要求

c++

  • 提高1.53.0

  • libevent(可选,构建非阻塞服务器)

  • zlib(可选)

最小的boost版本实际上是1.54,网站在这一点上有点过时。