This blog for my kinect-v2 ros configure.


  • Thinkpad P70
  • Ubuntu 14.04
  • indigo

Reference to


Before start, make sure the cuda, cudnn has been configured correctly.

First, you need to install libfreenect2.

I recommend to use export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda/lib64 in your .zshrc or .bashrc (more professional, in bash_profile or .zshenv). You will avoid some problems about library error.

When installing libfreenect2, Use cmake .. -DCMAKE_INSTALL_PREFIX=$HOME/freenect2 -DENABLE_CXX11=ON to generate Makeifle at build/

Then Install iai-Kinect

I use catkin_make -DCMAKE_BUILD_TYPE="Release" -Dfreenect2_DIR=$HOME/freenect2/lib/cmake/freenect2 to Compile iai-Kinect because installing to $HOME/freenect2 before.


  1. enable C++11 by using cmake .. -DENABLE_CXX11=ON instead of cmake ..
  2. If something is not working, check out the latest stable release, for example git checkout v0.2.0.
  3. check your opencv version: pkg-config --modversion opencv.
  4. NEVER EVER use sudo prime-select intel.


I missed sudo apt-get install beignet-dev; so I got this error: