centos 安装 gearmand-1.1.12

安装 gearmand 前先装一堆依赖,如下:

(boost的版本需要大于 1.39)

yum install boost-devel 

yum install mysql-devel

yum install gperf

yum install libevent

yum install libevent-devel

yum install libuuid-devel


安装好依赖后,执行 ./configure,然后 make 遇到了个困扰我半天的坑,报错

/usr/bin/ld: bin/gearadmin: undefined reference to symbol '__pthread_key_create@@GLIBC_2.2.5'

/usr/bin/ld: note: '__pthread_key_create@@GLIBC_2.2.5' is defined in DSO /lib64/libpthread.so.0 so tr

/lib64/libpthread.so.0: could not read symbols: Invalid operation

collect2: error: ld returned 1 exit status

make[1]: *** [bin/gearadmin] Error 1

make[1]: Leaving directory `/home/web_tar/gearmand-1.1.12'

make: *** [all] Error 2

google看了下,这是个比较通用的解决方法,打开 ./Makefile,

LDFLAGS = -L/usr/lib64/mysql/

改为

LDFLAGS = -L/usr/lib64/mysql/ -lpthread

再 make 就OK了。

你可能感兴趣的:(centos 安装 gearmand-1.1.12)