ROS on TK1

I have Jetson TK1 with Ubuntu 16.04 running on it.
I am running ROS Indigo on the same. Rtabmap(a feature of ROS) requires some packages to be installed and compiled on the machine you are using. Some of these codes are in C++. thee compilation of packages is done using catkin_make. this basically invokes the CMAKE command.
after doing this I encounter the following error

Base path: /home/ubuntu/catkin_ws
Source space: /home/ubuntu/catkin_ws/src
Build space: /home/ubuntu/catkin_ws/build
Devel space: /home/ubuntu/catkin_ws/devel
Install space: /home/ubuntu/catkin_ws/install

Running command: “make cmake_check_build_system” in “/home/ubuntu/catkin_ws/build”

– The CXX compiler identification is unknown
CMake Error in CMakeLists.txt:


is not a full path to an existing compiler tool.

Tell CMake where to find the compiler by setting either the environment
variable “CXX” or the CMake cache entry CMAKE_CXX_COMPILER to the full path
to the compiler, or to the compiler name if it is in the PATH.

– Configuring incomplete, errors occurred!
See also “/home/ubuntu/catkin_ws/build/CMakeFiles/CMakeOutput.log”.
See also “/home/ubuntu/catkin_ws/build/CMakeFiles/CMakeError.log”.
Makefile:274: recipe for target ‘cmake_check_build_system’ failed
make: *** [cmake_check_build_system] Error 1
Invoking “make cmake_check_build_system” failed

After changing the environment variables for CXX compiler, the problem persists. Following are the command I followed:

export CXX=/usr/bin/cpp
echo ‘export CXX="/usr/bin/cpp"’ >> ~/.bashrc
source ~/.bashrc

bashrc was updated with CXX filepath after this. Also, note that we had located cpp in /usr/bin/cpp

Post this I tried compiling atleast one simple code in C++
I have written the following simple hello world for c++

using namespace std;
int main()
cout << “Hello World”;
return 0;

when I try to compile this, I encounter the following

The program ‘gpp’ is currently not installed. You can install it by typing:
sudo apt install gpp

Along with the recommended command I also try to reinstall the build essentials but the problm persists.

I believe it to be an issue of not being able to locate the gpp/c++ compiler
I am a novice to this field so if you could explain what exactly has happened, along with the solution, it will be of great help.

Hi bidkar.shubham96, NVIDIA has only officially released Ubuntu 14.04 (armhf) support for TK1, so I’m not entirely sure, however gpp package appears available for both 14.04 and 16.04, do you have Universe repo enabled?