question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Building catkin Workspace fails - install-layout not recognized

See original GitHub issue

Hello, as I tried building ROS in catkin workspace today I got following error after invoking catkin_make_isolated --install -DCMAKE_BUILD_TYPE=Release

/usr/bin/env PYTHONPATH=/home/ecke/catkin_ws/install_isolated/lib/python3/dist-packages:/home/ecke/catkin_ws/build_isolated/catkin/lib/python3/dist-packages::/usr/local/lib/paraview-4.3/site-packages/:/usr/local/lib/veloview-3.1/site-packages/:/usr/local/lib/paraview-4.3/:/usr/local/lib/paraview-4.3/site-packages/vtk/ CATKIN_BINARY_DIR=/home/ecke/catkin_ws/build_isolated/catkin /home/ecke/miniconda3/bin/python /home/ecke/catkin_ws/src/catkin/setup.py build --build-base /home/ecke/catkin_ws/build_isolated/catkin install –install-layout=deb --prefix=/home/ecke/catkin_ws/install_isolated --install-scripts=/home/ecke/catkin_ws/install_isolated/bin usage: setup.py [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] …] or: setup.py --help [cmd1 cmd2 …] or: setup.py --help-commands or: setup.py cmd --help

error: option --install-layout not recognized CMake Error at catkin_generated/safe_execute_install.cmake:4 (message):

execute_process(/home/ecke/catkin_ws/build_isolated/catkin/catkin_generated/python_distutils_install.sh) returned error code Call Stack (most recent call first): cmake_install.cmake:149 (include)

Makefile:61: die Regel für Ziel „install“ scheiterteros make: *** [install] Fehler 1 <== Failed to process package ‘catkin’: Command ‘[‘make’, ‘install’]’ returned non-zero exit status 2

Upto this point I followed the ROS-setup-tutorial to make sure I’m not missing out on any step.

Checking dependencies rosdep update && rosdep install --from-paths /home/ecke/catkin_ws/src --ignore-src --os=ubuntu:xenial resolved in #All required rosdeps installed successfully

system-info: uname -a Linux mechlab-GL552JX 4.4.0-53-generic #74-Ubuntu SMP Fri Dec 2 15:59:10 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

python --version Python 3.6.0 :: Continuum Analytics, Inc.

which python /home/ecke/miniconda3/bin/python

Might there be an issue with python 3.6 through miniconda being the system default?

Thanks in advance for your help.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:17 (4 by maintainers)

github_iconTop GitHub Comments

47reactions
Grillen80commented, Mar 30, 2017

Keeping on searching I finally found a work around the --install-layout issue here. Invoking ./src/catkin/bin/catkin_make_isolated --install -DCMAKE_BUILD_TYPE=Release -DSETUPTOOLS_DEB_LAYOUT=OFF did it.

5reactions
icolwell-ascommented, Jan 21, 2022

I just ran into this problem on Ubuntu 20.04 using ROS Noetic trying to build Autoware.ai. To summarize on what some others in this thread have suggested, there are 3 options to fix this:

  1. Downgrade your locally-installed setuptools to match the same version of released as part of ubuntu focal:
pip3 install setuptools==45.2.0

Credit for this solution goes to this PR: https://github.com/usdot-fhwa-stol/carma-base/pull/111

  1. Use the -DSETUPTOOLS_DEB_LAYOUT=OFF option and forget about it. If you are using colcon, you can add this to your default file located at ~/.colcon/defaults.yaml. Here’s an example:
{
    "build": {
        "cmake-args": ["-DSETUPTOOLS_DEB_LAYOUT=OFF"]
    }
}

This way you don’t have to specify it on the command line every time.

  1. I also tried the nuclear option and deleted ~/.local/lib/python3.8 which reverted to using the system-install python and resolved the issue. If you are nervous about deleting your local python install, the PYTHONUSERBASE env variable might work for you to switch to the system-installed python.

I tested all 3 of these options and they all seem to resolve the issue. Option 1 seems like the cleanest solution.

EDIT: Added another option to resolve the issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

catkin config – Configure a Workspace
Doing so will not modify your workspace. The catkin command is context-sensitive, so it will determine which workspace contains the current working directory....
Read more >
Failing to create catkin workspace - ROS Answers
Im using ROS-indigo and Gazebo 2.2 Edit#1: Workspace structure my workspace looks something like this: catkin_ws build devel install src ...
Read more >
Getting a CMake Error trying to create a catkin workspace in ...
delete folder devel and build again; Open another terminal, in the workspace and try again. Share.
Read more >
catkin_tools command man page - ManKier
Initialize a workspace with a default layout (src/build/devel) in the current directory: catkin init; catkin init --workspace . catkin config --init; mkdir src ......
Read more >
Create a catkin workspace and a ROS package
ROS is installed on the computer you are working on (be that working “directly” ... Ignore the "build" and "devel" folder of the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found