An error occurred while compiling and installing libmemcached 1.0.14.

Source: Internet
Author: User
Tags php memcached

Recently upgraded php memcached to 2.1.0. because it depends on the libmemcached library, the previously installed version is 1.0.2. An error occurs during compilation and a later version of libmemcached is required. Therefore, download the latest version of libmemcached for compilation and installation. Unfortunately, libmemcached 1.0.14 is saved during compilation. The general error message is:

Libmemcached/auto. cc: In function 'memcached _ return_t text_incr_decr (memcached_server_st *, bool, const char *, size_t, uint64_t, bool) ': libmemcached/auto. cc: 73: error: expected ') 'before' priu64' In file encoded from. /libmemcached/common. h: 72, from. /libmemcached/csl/common. h: 40, from libmemcached/csl/context. cc: 38:

Google queries the problem because the GCC version is low, so we had to upgrade GCC. Fortunately, if there is yum, we can run the following command:

Yum install gcc44 gcc44-c ++ libstdc ++ 44-devel Add the following content to/etc/bashrc export CC =/usr/bin/gcc44export CXX =/usr/bin/g ++ 44

Exit the terminal and log on again. The compilation and installation are successful, and the memcached extension is also successfully upgraded.


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.