一见

编译 thrift-0.14.2 的 C++ 版本

编译命令:

./configure --prefix=/usr/local/thrift-0.14.2 --with-cpp=yes --with-php=no --with-python=no --with-qt5=no --with-c_glib=no --with-java=no --with-erlang=no --with-nodejs=no --with-nodets=no --with-lua=no --with-py3=no --with-perl=no --with-php_extension=no --with-dart=no --with-ruby=no --with-haskell=no --with-go=no --with-rs=no --with-swift=no --with-cl=no --with-haxe=no --with-netstd=no --with-d=no --enable-tests=no --with-as3=no --with-libevent=/usr/local/libevent --with-openssl=/usr/local/openssl --with-boost=/usr/local/boost

执行 configure 成功:

thrift 0.14.2

Building ActionScript3 Library : no
Building C (GLib) Library .... : no
Building C++ Library ......... : yes
Building Common Lisp Library.. : no
Building D Library ........... : no
Building Dart Library ........ : no
Building .NET Standard Library : no
Building Erlang Library ...... : no
Building Go Library .......... : no
Building Haskell Library ..... : no
Building Haxe Library ........ : no
Building Java Library ........ : no
Building Lua Library ......... : no
Building NodeJS Library ...... : no
Building Perl Library ........ : no
Building PHP Library ......... : no
Building Python Library ...... : no
Building Py3 Library ......... : no
Building Ruby Library ........ : no
Building Rust Library ........ : no
Building Swift Library ....... : no

C++ Library:
   C++ compiler .............. : g++ -std=c++11
   Build TZlibTransport ...... : yes
   Build TNonblockingServer .. : yes
   Build TQTcpServer (Qt5) ... : no
   C++ compiler version ...... : g++ (GCC) 4.8.5 20150623 (Red Hat 4.8.5-39)

注意

执行 configure 时需要指定参数:--with-boost=/usr/local/boost,虽然 0.14.2 版本的运行时库并不依赖 boost,只有测试用例依赖 boost,但如果不指定则不会生成 C++ 版本的库。另外只有指定了 libevent,才会生成库 libthriftnb.a 。

posted on 2021-09-05 09:54  -见  阅读(188)  评论(0编辑  收藏  举报

导航