Configuring MPD with NCMPCPP under RHEL/CentOS 6

So yesterday while I was sitting in front of my computer, getting bored, had nothing to do. I decided to tweak my RHEL desktop to make it little more cool to work on. Since I only use it for serious work there were not much applications installed. So I tried to install my favorite music player MPD with NCMPCPP but that was not so easy ( at least for me). It took me so much time (almost whole day) just to figure out how to install NCMPCPP. So I am posting this how-to for anyone else who might be looking for the same.

Installing MPD and MPC

First install the RPMforge repository :-

http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el6.rf.x86_64.rpm
Tip: use “uname -i” to get your architecture info and replace x86_64 according to that.

Install DAG’s gpg key :-

# rpm --import http://apt.sw.be/RPM-GPG-KEY.dag.txt

Verify the package :-

# rpm -K rpmforge-release-0.5.2-2.el6.rf.x86_64.rpm

Install the package :-

# rpm -i rpmforge-release-0.5.2-2.el6.rf.x86_64.rpm

Install MPC and MPD :-

# yum --enablerepo=rpmforge install mpd mpc

Installing NCMPCPP :-

$ cd $HOME

$ git clone git://repo.or.cz/ncmpcpp.git

Install some prerequisites before compiling :-


# yum install ncurses-devel taglib-devel libmpdclient2-devel

* this “libmpdclient2-devel” was not available on my system that is why i was getting the compiling errors. Took me whole day just to figure out the package is libmpdclient2-devel . Always remember if you get any compilation errors on RHEL always make sure the related “-devel” package is present.

Compile NCMPCPP :-

$ cd ncmpcpp

$ ./autogen.sh --prefix=/usr --enable-clock --with-taglib
* See ./autogen.sh –help for more options that you can enable/disable.
$ make

$ sudo make install

See this Archlinux wiki for MPD configuration, although it is Archlinux but the MPD configuration is applicable on RHEL. (See this link Archlinux:MPD)

And here is a sample NCMPCPP config file. Save this file as  ~/.ncmpcpp/config (Here is the file)

About Gaurav Trivedi

Gaurav Trivedi is a Gnu/Linux user, geek and technology enthusiast. He loves to play FPS games and travelling.
This entry was posted in CentOS and tagged , , , , , , . Bookmark the permalink.

3 Responses to Configuring MPD with NCMPCPP under RHEL/CentOS 6

  1. valent says:

    Ok, I found solution to previous issue, it needed to have full devtools packages installed:
    yum install devtoolset-1.0

    and exported new path:
    export PATH=/opt/centos/devtoolset-1.0/root/usr/bin/:$PATH

    and installed missing package:
    yum install boost-devel

    and linked missing file:
    ln -s /usr/include/boost/typeof/std/locale.hpp /usr/include/boost/locale.hpp

    and still hit new wall that is explained in this arch post:
    https://aur.archlinux.org/packages/ncmpcpp-git/?setlang=hr&comments=all

    “configure: error: no boost.locale library found”

    Looks it just won’t compile on Centos 6.3…

  2. valent says:

    Hmm, actually this guide unfortunatelly is not working 😦
    I get an error that too old version of GCC is installed when running autogen command:

    configure: error: Your compiler doesn’t seem to support lambda functions, please upgrade (GCC >= 4.6)

    Then I installed devtools repo and newer gcc:
    wget http://dev.centos.org/~tru/devtools/devtools.repo
    cp devtools.repo /etc/yum.repos.d/
    yum install devtoolset-1.0-gcc

    new gcc is located in:
    /opt/centos/devtoolset-1.0/root/usr/bin/gcc

    any I even renamed gcc:
    mv /usr/bin/gcc /usr/bin/gcc.old

    And linked new version to old:
    ln -s /opt/centos/devtoolset-1.0/root/usr/bin/gcc /usr/bin/gcc

    But I still get same error 😦

    Any ideas?

  3. valent says:

    Awesome guide, you are only missing one dependency – “libtool”

Leave a reply to valent Cancel reply