1
$\begingroup$

I've recently been encountering an issue when trying to create a working catkin workspace for ROS through RoboStack.

Robostack is utilized to create a working ROS environment installed in Conda.

When activating the environment in Conda, I have been able to successfully very that ROS is working when I run the set ros command through the miniconda command prompt:

(robostackenv) C:\.....>set ros

ROS_DISTRO=noetic
ROS_ETC_DIR=C:\Users\user\miniconda3\envs\robostackenv\Library\etc\ros
ROS_IP=127.0.0.1
ROS_MASTER_URI=http://127.0.0.1:11311
ROS_OS_OVERRIDE=conda:win64
ROS_PACKAGE_PATH=C:\Users\user\miniconda3\envs\robostackenv\Library\share
ROS_PYTHON_VERSION=3
ROS_ROOT=C:/Users/user/miniconda3/envs/robostackenv/Library/share/ros
ROS_VERSION=1

I've also installed various extensions to succesfully utilize ROS within VSCode (NOT the full IDE Visual Studio one). These extensions include:

  • ROS
  • C/C++ (VsCode is configured with a GCC compiler, which allows it to run C//C++ files already
  • CMake

However, for some reason I can't create a workspace for ROS. I've already created a catkin_workspace and src folder by:

(robostackenv) C:\.....>robostackenv\mkdir catkin_workspace
(robostackenv) C:\.....>robostackenv\catkin_workspace\mkdir src

But every time I try to utilize catkin_make within the main workspace directory, it ends up failing:

(robostackenv) C:\Users\user\ProgrammingProjects\robostackenv\catkin_workspace>catkin_make
Base path: C:\Users\user\ProgrammingProjects\robostackenv\catkin_workspace
Source space: C:\Users\user\ProgrammingProjects\robostackenv\catkin_workspace\src
Build space: C:\Users\user\ProgrammingProjects\robostackenv\catkin_workspace\build
Devel space: C:\Users\user\ProgrammingProjects\robostackenv\catkin_workspace\devel
Install space: C:\Users\user\ProgrammingProjects\robostackenv\catkin_workspace\install
Copying file from "C:\Users\user\miniconda3\envs\robostackenv\Library\share\catkin\cmake\toplevel.cmake" to "C:\Users\user\ProgrammingProjects\robostackenv\catkin_workspace\src\CMakeLists.txt"
####
#### Running command: "cmake C:\Users\user\ProgrammingProjects\robostackenv\catkin_workspace\src -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCATKIN_DEVEL_PREFIX=C:\Users\user\ProgrammingProjects\robostackenv\catkin_workspace\devel -DCMAKE_INSTALL_PREFIX=C:\Users\user\ProgrammingProjects\robostackenv\catkin_workspace\install -G NMake Makefiles" in "C:\Users\user\ProgrammingProjects\robostackenv\catkin_workspace\build"
####
CMake Error at CMakeLists.txt:6 (project):
  Running

   'nmake' '-?'

  failed with:

   The system cannot find the file specified


CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!
See also "C:/Users/user/ProgrammingProjects/robostackenv/catkin_workspace/build/CMakeFiles/CMakeOutput.log".
Invoking "cmake" failed

What am I doing that's wrong? ROS is installed properly with RoboStack, set ros shows that it works, my files are named corrently, what gives?

If I run, catkin_init_workspace, it'll generate a CMakeLists.txt file, but that is it.

New contributor
omar7439 is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.
$\endgroup$

1 Answer 1

0
$\begingroup$

Did you install a C/C++ compiler, make and CMake? Not the VS Code extensions, the programs themselves.

Be sure also to add them into the Windows path environment variable.

$\endgroup$

Your Answer

omar7439 is a new contributor. Be nice, and check out our Code of Conduct.

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.