user:~/catkin_ws$ cd ~/catkin_ws/src/cpp_course_repo/utilities/
user:~/catkin_ws/src/cpp_course_repo/utilities$ g++ -std=c++11 file.cpp -o name_compiled
/usr/lib/gcc/x86_64-linux-gnu/5/…/…/…/x86_64-linux-gnu/crt1.o: In function _start': (.text+0x20): undefined reference to main’
collect2: error: ld returned 1 exit status
Did you define another main() function in your code, other than int main() in the beginning?
If you are calling main() function from inside your, int main(), this might cause compilation errors. Please carefully read the documentation, everything is well tested, should have no issues upon careful implementation.