Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to install thrift in centos7

2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

Centos7 how to install thrift, many novices are not very clear about this, in order to help you solve this problem, the following editor will explain for you in detail, people with this need can come to learn, I hope you can gain something.

Installation steps:

1. Install the extensions required by centos

Yum install-y automake libtool flex bison pkgconfig gcc-c++ libevent-devel zlib-devel python-devel ruby-devel openssl-devel

two。 Install boost. Local source code installation is the most secure.

Wget http://sourceforge.net/projects/boost/files/boost/1.53.0/boost_1_53_0.tar.gz

Tar-xvf boost_1_53_0.tar.gz

Cd boost_1_53_0

. / bootstrap.sh

. / b2 install

When installing boost, the yum install boost-devel used will report that the libboost_unit_test_framework.a file cannot be found when the thrift package is finally installed. It is not good to connect / usr/lib64/libboost_unit_test_framework.a softly as expressed in google, but the libboost_unit_test_framework.a file does not exist in the installed boost even in the / usr/lib64/ directory.

3. Source code installation thrift

Wget http://apache.fayea.com/thrift/0.10.0/thrift-0.10.0.tar.gz tar-xvf thrift-0.10.0.tar.gz cd thrift-0.10.0. / configure-- with-lua=no make & & make install

Installation error report and solution:

Error one:

Libtool: link +-std=c++11-Wall-Wextra-pedantic-g-O2-o. Libs / processor_test processor/ProcessorTest.o processor/EventLog.o processor/ServerThread.o-L/usr/lib64. / .libs / libprocessortest.a.. / lib/cpp/.libs/libthrift.so.. / lib/cpp/.libs/libthriftnb.so / usr/lib64/libboost_unit_test_framework.a-levent-lrt-lpthread-Wl,-rpath-Wl,/usr/local/thrift/lib

Gaming: error: / usr/lib64/libboost_unit_test_framework.a: No such file or directory

Make [5]: * * [processor_test] error 1

Make [5]: leave the directory "/ opt/soft/thrift-0.12.0/lib/cpp/test"

Make [4]: * * [all] error 2

Make [4]: leave the directory "/ opt/soft/thrift-0.12.0/lib/cpp/test"

Make [3]: * * [all-recursive] error 1

Make [3]: leave the directory "/ opt/soft/thrift-0.12.0/lib/cpp"

Make [2]: * * [all-recursive] error 1

Make [2]: leave the directory "/ opt/soft/thrift-0.12.0/lib"

Make [1]: * * [all-recursive] error 1

Make [1]: leave the directory "/ opt/soft/thrift-0.12.0"

Make: * * [all] error 2 solution 1:

Modification method: first look for the file find /-name libboost_unit_test_framework.a, such as in / usr/local/lib/libboost_unit_test_framework.a, you can do the following operation, sudo ln-s / usr/local/lib/libboost_unit_test_framework.a / usr/lib64/libboost_unit_test_framework.a, and then re-execute make.

Solution 2:

Source code local compilation boost installation

Wget http://sourceforge.net/projects/boost/files/boost/1.53.0/boost_1_53_0.tar.gz tar-xvf boost_1_53_0.tar.gz cd boost_1_53_0. / bootstrap.sh. / b2 install

Error 2:

GCC macro compilation problem _ _ STDC_FORMAT_MACROS

Do not use git package, because using git package will report when you install it.

Src/thrift/server/TNonblockingServer.cpp:460:16: error: expected') 'before' PRIu32' "(%" >

Is it helpful for you to read the above content? If you want to know more about the relevant knowledge or read more related articles, please follow the industry information channel, thank you for your support.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report