文章目录

今天安装libmemcached安装时出错。


CC clients/ms_stats.o

CC clients/ms_task.o

CC clients/ms_thread.o

CCLD clients/memslap

clients/msconn.o: In function `ms_get

udp_request_id’:

/var/go2packages/libmemcached-0.37/clients/ms_conn.c:184: undefined reference to `__sync_fetch_and_add_4’

clients/ms_conn.o: In function `ms_reconn_socks’:

/var/go2packages/libmemcached-0.37/clients/ms_conn.c:1055: undefined reference to `__sync_fetch_and_add_4’

clients/ms_conn.o: In function `ms_reconn’:

/var/go2packages/libmemcached-0.37/clients/ms_conn.c:924: undefined reference to `__sync_fetch_and_add_4’

/var/go2packages/libmemcached-0.37/clients/ms_conn.c:960: undefined reference to `__sync_fetch_and_add_4’

clients/ms_thread.o: In function `ms_setup_thread’:

/var/go2packages/libmemcached-0.37/clients/ms_thread.c:215: undefined reference to `__sync_fetch_and_add_4’

clients/ms_thread.o:/var/go2packages/libmemcached-0.37/clients/ms_thread.c:198: more undefined references to `__sync_fetch_and_add_4’ follow

collect2: ld returned 1 exit status

make[2]: * [clients/memslap] Error 1

make[2]: Leaving directory `/var/go2packages/libmemcached-0.37’

make[1]: * [all-recursive] Error 1

make[1]: Leaving directory `/var/go2packages/libmemcached-0.37’

make: * [all] Error 2


解决方法:

./configure —disable-64bit CFLAGS=”-O3 -march=i686”

文章目录