In some cases, you might want to enable some of the memcached features that have to be baked-in during the compile time of the program. In this recipe, we will learn how to compile memcached from a source on Ubuntu
We will install the requirements of the package by using apt-get
:
sudo apt-get install g++ make libevent-dev
This installed the C++ compiler , make, and the libevent library headers needed to compile memcached.
Let's download the latest version of memcached in your home directory
curl -O --location http://memcached.org/latest mv latest memcached-latest.tar.gz tar vxzf memcached-latest.tar.gz
Next, let's configure and compile
cd memcached-* ./configure && make
If the compilation process went well, we install the binaries:
sudo make install