I am currently using ros kinetic
↧
I have a trouble using catkin build when I enter thar command it says command not found, however catkin_make does work.
↧
Importing python module from another ROS package setup.py
Hi
I am trying to import a python module from another ROS package.
My package is utils
utils
-----/src
------------file_io.py (python module)
------------__init__.py
I have a node in Package A that wants to import a function in file_io.py
So far I have created a setup.py file for the package utils
## ! DO NOT MANUALLY INVOKE THIS setup.py, USE CATKIN INSTEAD
from distutils.core import setup
from catkin_pkg.python_setup import generate_distutils_setup
# fetch values from package.xml
setup_args = generate_distutils_setup(
packages=['utils'],
package_dir={'': 'src'},
requires=['roscpp', 'rospy', 'tf']
)
setup(**setup_args)
In my cmakeList file I made the following changes
install(PROGRAMS src/file_io.py
DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION})
and uncommented #catkin_python_setup()
In the package.xml of package A, I made the utils package a build and run dependency, modified the cmakList of package A and added the package utils to the find_package(catkin required COMPONENTS).
from utils.file_io import extractor
results in the import error: No module name file_io.
Am I missing something? To be honest I did not really understand the tutorial, I am kind of new to python.
As I understand in order to import a python module it has to be in your python path, I thought this setup thing was meant to make ROS automatically add the files to the python path of any package that depends on utils...
↧
↧
ROS using C++ 11 & How to Use With Catkin?
Is ROS compiled using c++ 11 with catkin? I suspect not since I am getting an error trying to use {} initializer for a vector, i.e. c++98...must be initialized...
For at least my builds where in the catkin files would I add the '-std=c++11' option?
I am using Eclipse but I think this is controlled via the cmake files, not a project property.
↧
Using Eigen libraries in ROS
Hi, I am fairly new to ROS and was wanting to do some matrix multiplication in a node. I found that Eigen has a good range of different matrices and vectors to use but was not quite sure what modifications I would have to make to allow it to be used in ROS.
First of all when I download the libraries, where do I put them? Is it inside the workspace folder, the src folder inside the workspace folder or is it inside the package inside the src folder? So one of these:
/workspace
/workspace/src
/workspace/src/package
In addition what changes do I have to make to the `CMakeLists.txt` file inside the package to include these new libraries?
Is there anything else I have to do in order to get these libraries working? I take it I need to include the header files in the node files I’m using (i.e. `#include ` `#include `)
Any help would be greatly appreciated. I am using catkin and the OS is Ubuntu Kinetic 16.04. If any more information is required please don't hesitate to ask.
↧
Problems linking wiringPi in catkin
I've been trying to write a node that reads encoder ticks through the GPIO pins on a RPi3 but I can't figure out what's wrong with my environment and/or this library. I'm still very new to catkin and compiling with cmake. I've searched pretty thoroughly and the threads I've found have been informative, but not helpful.
When compiling in my workspace, I get the following errors:
Errors << encoder_node:make /home/robot/ROS/encoder_test/logs/encoder_node/build.make.006.log
/usr/local/lib/libwiringPi.so: undefined reference to `crypt'
/usr/local/lib/libwiringPi.so: undefined reference to `shm_open'
collect2: error: ld returned 1 exit status
make[2]: *** [/home/robot/ROS/encoder_test/devel/.private/encoder_node/lib/encoder_node/readEncoder] Error 1
make[1]: *** [CMakeFiles/readEncoder.dir/all] Error 2
make: *** [all] Error 2
After seeing this the first time, I pulled WiringPi from the source and built it according to the instructions on Gordon's site. Following the build, I tried to compile the examples with gcc, and got the following errors:
/usr/lib/gcc/arm-linux-gnueabihf/5/../../../../lib/libwiringPi.so: undefined reference to `crypt'
/usr/lib/gcc/arm-linux-gnueabihf/5/../../../../lib/libwiringPi.so: undefined reference to `rint'
/usr/lib/gcc/arm-linux-gnueabihf/5/../../../../lib/libwiringPi.so: undefined reference to `pthread_join'
/usr/lib/gcc/arm-linux-gnueabihf/5/../../../../lib/libwiringPi.so: undefined reference to `pthread_create'
/usr/lib/gcc/arm-linux-gnueabihf/5/../../../../lib/libwiringPi.so: undefined reference to `pow'
/usr/lib/gcc/arm-linux-gnueabihf/5/../../../../lib/libwiringPi.so: undefined reference to `shm_open'
/usr/lib/gcc/arm-linux-gnueabihf/5/../../../../lib/libwiringPi.so: undefined reference to `pthread_cancel'cd
I'm lost at this point. In another workspace, I'm still able to compile with wiringPi using . Prior to purging wiringPi from apt, I was able to use wiringPi to run some sample code.
So my question is: What misunderstanding do I have about linking libraries that's caused this? And how do I fix it?
Here's my CMakeLists.txt. I kind of understand what I'm doing, but can't identify my problem:
cmake_minimum_required(VERSION 2.8.3)
project(encoder_node)
## Compile as C++11, supported in ROS Kinetic and newer
# add_compile_options(-std=c++11)
## Find catkin macros and libraries
## if COMPONENTS list like find_package(catkin REQUIRED COMPONENTS xyz)
## is used, also find other catkin packages
#find_library(WIRINGPI_LIBRARY wiringPi /usr/include)
find_library(WIRINGPI_LIBRARY wiringPi /home/git/wiringPi)
#FIND_LIBRARY(WIRINGPI_LIBRARY wiringPi /usr/local/lib)
find_package(catkin REQUIRED COMPONENTS
roscpp
std_msgs
)
## System dependencies are found with CMake's conventions
#find_package(WIRINGPI_LIBRARY REQUIRED)
catkin_package(
#INCLUDE_DIRS include
)
include_directories(
# include
${catkin_INCLUDE_DIRS}
# TODO: Check names of system library include directories (wiringPi)
#${wiringPi_INCLUDE_DIRS}
# /usr/local/include
)
add_executable(readEncoder src/rotaryEncoder.cpp)
target_link_libraries(readEncoder
${catkin_LIBRARIES}
#wiringPi
${WIRINGPI_LIBRARY})
add_dependencies(readEncoder wiringPi)
↧
↧
catkin build question
If I have two catkin work directories and one is dependent on the other for a package. How do I tell the build to look there. Does it use ROS environment variable for a list of source directories? I did put source setup for both in my bashrc file. But the referring directory still does not find the package in the other ws.
↧
How compile a ROS package if previously I compiled ROS Cartographer
I am testing Cartographer in a ROS Kinect installation.
In my catkin_ws I have installed ROS Cartographer following the notes from the documentation:
https://google-cartographer-ros.readthedocs.io/en/latest/
and I tested some demos so the installation run nice.
Later, I have created a new package but when I try to compile:
-- ~~ traversing 6 packages in topological order:
-- ~~ - ceres-solver (plain cmake)
-- ~~ - cartographer (plain cmake)
-- ~~ - cartographer_ros_msgs
-- ~~ - cartographer_ros
-- ~~ - cartographer_new <- NEW ROS PACKAGE
-- ~~ - cartographer_rviz
I receive the following error:
CMake Error at /opt/ros/kinetic/share/catkin/cmake/catkin_workspace.cmake:95 (message):
This workspace contains non-catkin packages in it, and catkin cannot build
a non-homogeneous workspace without isolation. Try the
'catkin_make_isolated' command instead.
Call Stack (most recent call first):
CMakeLists.txt:63 (catkin_workspace)
I tried with catkin_make and catkin_make_isolated but I can´t solve the problem.
I think that it is a error from a beginner.
Many thanks in advance.
Juan Antonio
↧
catkin_make fails with Invalid email and Invalid package
When I try to catkin_make my workspace the following is output:
Base path: /home/user/catkin_ws
Source space: /home/user/catkin_ws/src
Build space: /home/user/catkin_ws/build
Devel space: /home/user/catkin_ws/devel
Install space: /home/user/catkin_ws/install
Package name "${pkg_name}" does not follow naming conventions
Invalid email "${email}" for person "${author}"
Invalid email "${email}" for person "${author}"
When I try to launch a launchfile which had been working fine before (and nothing changed on the file or the related files):
Traceback (most recent call last):
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/__init__.py", line 225, in main
args = rlutil.resolve_launch_arguments(args)
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslaunch/rlutil.py", line 92, in resolve_launch_arguments
resolved = roslib.packages.find_resource(args[0], args[1])
File "/opt/ros/kinetic/lib/python2.7/dist-packages/roslib/packages.py", line 504, in find_resource
source_path_to_packages=source_path_to_packages)
File "/opt/ros/kinetic/lib/python2.7/dist-packages/catkin/find_in_workspaces.py", line 143, in find_in_workspaces
source_path_to_packages[source_path] = find_packages(source_path)
File "/usr/lib/python2.7/dist-packages/catkin_pkg/packages.py", line 87, in find_packages
packages = find_packages_allowing_duplicates(basepath, exclude_paths=exclude_paths,
exclude_subspaces=exclude_subspaces, warnings=warnings)
File "/usr/lib/python2.7/dist-packages/catkin_pkg/packages.py", line 137, in find_packages_allowing_duplicates
xml, filename=filename, warnings=warnings)
File "/usr/lib/python2.7/dist-packages/catkin_pkg/package.py", line 589, in parse_package_string
pkg.validate(warnings=warnings)
File "/usr/lib/python2.7/dist-packages/catkin_pkg/package.py", line 268, in validate
raise InvalidPackage('\n'.join(errors))
InvalidPackage: Package name "${pkg_name}" does not follow naming conventions
Invalid email "${email}" for person "${author}"
Invalid email "${email}" for person "${author}"
What I *did* do before this occurred was following the "Create your rqt plugin package" tutorial and at some point ran cmake on the package which added a bunch of folders and files to my catkin workspace (in retrospect, I think I misunderstood the wording on the tutorial...) I tried deleting the new stuff but that just caused more errors.
I'm not sure what exactly happened and how to fix it. Any help is appreciated.
↧
Nesting of workspaces
I am following an example in the book "Programming Robots with ROS" from OReilly. Here's a snippet:
mkdir -p ~/wanderbot_ws/src
cd ~wanderbot_ws
catkin_init_workspace
Ok, so I understand that wanderbot_ws is now a valid catkin workspace. Next I did:
catkin create_pkg
At which point I have a directory structure that looks like this:
wanderbot_ws/
├── CMakeLists.txt -> /opt/ros/kinetic/share/catkin/cmake/toplevel.cmake└── src
└── wanderbot
├── CMakeLists.txt
├── package.xml
└── src
└── bluegreen.py
Which looks so repetitive. Can someone kind of explain the intended semantics here?
p.s. what is the mythology behind the name `catkin`?
↧
↧
How to avoid installing files like setup.bash more than once?
I use "catkin build" and "catkin config --install". Then each package will install for example setup.bash. How can I avoid that. I would like to only install these files in one package.
The reason I would like to do that is that I use CPACK to build a debian package for each ros package. And I get duplicate files in the debian packages.
↧
Missing compile step?
I'm learning ROS for Turtlebot3, and am getting an error message that appears to tell me that I missed a compilation or build step. Perhaps I am missing an environment variable. Here are the key steps:
$ catkin_create_pkg wanderbot rospy geometry_msgs sensor_msgs
$ source ~/catkin_ws/devel/setup.bash
pitosalas@ubuntu:~/catkin_ws/wanderbot/src$ ./redgreen.py
from: can't read /var/mail/geometry_msgs.msg
./redgreen.py: line 6: syntax error near unexpected token `('
./redgreen.py: line 6: `cmd_vel_pub = rospy.Publisher('cmd_vel', Twist, queue_size=1) #<1>'
And here's the environment:
$ tree .
.
├── build
│ ├── beginner_tutorials
│ │ ├── catkin_generated
│ │ │ ├── installspace
│ │ │ │ ├── beginner_tutorialsConfig.cmake
│ │ │ │ ├── beginner_tutorialsConfig-version.cmake
│ │ │ │ └── beginner_tutorials.pc
│ │ │ ├── ordered_paths.cmake
│ │ │ ├── package.cmake
│ │ │ ├── pkg.develspace.context.pc.py
│ │ │ ├── pkg.installspace.context.pc.py
│ │ │ └── stamps
│ │ │ └── beginner_tutorials
│ │ │ ├── package.xml.stamp
│ │ │ └── pkg.pc.em.stamp
│ │ ├── CMakeFiles
│ │ │ ├── CMakeDirectoryInformation.cmake
│ │ │ ├── progress.marks
│ │ │ ├── roscpp_generate_messages_cpp.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ ├── roscpp_generate_messages_eus.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ ├── roscpp_generate_messages_lisp.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ ├── roscpp_generate_messages_nodejs.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ ├── roscpp_generate_messages_py.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ ├── rosgraph_msgs_generate_messages_cpp.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ ├── rosgraph_msgs_generate_messages_eus.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ ├── rosgraph_msgs_generate_messages_lisp.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ ├── rosgraph_msgs_generate_messages_nodejs.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ ├── rosgraph_msgs_generate_messages_py.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ ├── std_msgs_generate_messages_cpp.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ ├── std_msgs_generate_messages_eus.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ ├── std_msgs_generate_messages_lisp.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ ├── std_msgs_generate_messages_nodejs.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ └── progress.make
│ │ │ └── std_msgs_generate_messages_py.dir
│ │ │ ├── build.make
│ │ │ ├── cmake_clean.cmake
│ │ │ ├── DependInfo.cmake
│ │ │ └── progress.make
│ │ ├── cmake_install.cmake
│ │ ├── CTestTestfile.cmake
│ │ └── Makefile
│ ├── catkin
│ │ └── catkin_generated
│ │ └── version
│ │ └── package.cmake
│ ├── catkin_generated
│ │ ├── env_cached.sh
│ │ ├── generate_cached_setup.py
│ │ ├── installspace
│ │ │ ├── env.sh
│ │ │ ├── setup.bash
│ │ │ ├── setup.sh
│ │ │ ├── _setup_util.py
│ │ │ └── setup.zsh
│ │ ├── order_packages.cmake
│ │ ├── order_packages.py
│ │ ├── setup_cached.sh
│ │ └── stamps
│ │ └── Project
│ │ ├── interrogate_setup_dot_py.py.stamp
│ │ ├── order_packages.cmake.em.stamp
│ │ ├── package.xml.stamp
│ │ └── _setup_util.py.stamp
│ ├── CATKIN_IGNORE
│ ├── catkin_make.cache
│ ├── CMakeCache.txt
│ ├── CMakeFiles
│ │ ├── 3.5.1
│ │ │ ├── CMakeCCompiler.cmake
│ │ │ ├── CMakeCXXCompiler.cmake
│ │ │ ├── CMakeDetermineCompilerABI_C.bin
│ │ │ ├── CMakeDetermineCompilerABI_CXX.bin
│ │ │ ├── CMakeSystem.cmake
│ │ │ ├── CompilerIdC
│ │ │ │ ├── a.out
│ │ │ │ └── CMakeCCompilerId.c
│ │ │ └── CompilerIdCXX
│ │ │ ├── a.out
│ │ │ └── CMakeCXXCompilerId.cpp
│ │ ├── clean_test_results.dir
│ │ │ ├── build.make
│ │ │ ├── cmake_clean.cmake
│ │ │ ├── DependInfo.cmake
│ │ │ └── progress.make
│ │ ├── cmake.check_cache
│ │ ├── CMakeDirectoryInformation.cmake
│ │ ├── CMakeError.log
│ │ ├── CMakeOutput.log
│ │ ├── CMakeRuleHashes.txt
│ │ ├── CMakeTmp
│ │ ├── download_extra_data.dir
│ │ │ ├── build.make
│ │ │ ├── cmake_clean.cmake
│ │ │ ├── DependInfo.cmake
│ │ │ └── progress.make
│ │ ├── doxygen.dir
│ │ │ ├── build.make
│ │ │ ├── cmake_clean.cmake
│ │ │ ├── DependInfo.cmake
│ │ │ └── progress.make
│ │ ├── feature_tests.bin
│ │ ├── feature_tests.c
│ │ ├── feature_tests.cxx
│ │ ├── Makefile2
│ │ ├── Makefile.cmake
│ │ ├── progress.marks
│ │ ├── run_tests.dir
│ │ │ ├── build.make
│ │ │ ├── cmake_clean.cmake
│ │ │ ├── DependInfo.cmake
│ │ │ └── progress.make
│ │ ├── TargetDirectories.txt
│ │ └── tests.dir
│ │ ├── build.make
│ │ ├── cmake_clean.cmake
│ │ ├── DependInfo.cmake
│ │ └── progress.make
│ ├── cmake_install.cmake
│ ├── CTestTestfile.cmake
│ ├── gtest
│ │ ├── CMakeFiles
│ │ │ ├── CMakeDirectoryInformation.cmake
│ │ │ ├── gtest.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ ├── depend.make
│ │ │ │ ├── flags.make
│ │ │ │ ├── link.txt
│ │ │ │ ├── progress.make
│ │ │ │ └── src
│ │ │ ├── gtest_main.dir
│ │ │ │ ├── build.make
│ │ │ │ ├── cmake_clean.cmake
│ │ │ │ ├── DependInfo.cmake
│ │ │ │ ├── depend.make
│ │ │ │ ├── flags.make
│ │ │ │ ├── link.txt
│ │ │ │ ├── progress.make
│ │ │ │ └── src
│ │ │ └── progress.marks
│ │ ├── cmake_install.cmake
│ │ ├── CTestTestfile.cmake
│ │ └── Makefile
│ ├── Makefile
│ └── test_results
├── devel
│ ├── env.sh
│ ├── lib
│ │ └── pkgconfig
│ │ └── beginner_tutorials.pc
│ ├── setup.bash
│ ├── setup.sh
│ ├── _setup_util.py
│ ├── setup.zsh
│ └── share
│ └── beginner_tutorials
│ └── cmake
│ ├── beginner_tutorialsConfig.cmake
│ └── beginner_tutorialsConfig-version.cmake
├── src
│ ├── beginner_tutorials
│ │ ├── CMakeLists.txt
│ │ ├── include
│ │ │ └── beginner_tutorials
│ │ ├── package.xml
│ │ └── src
│ └── CMakeLists.txt -> /opt/ros/kinetic/share/catkin/cmake/toplevel.cmake└── wanderbot
├── CMakeLists.txt
├── package.xml
└── src
├── redgreen.py
└── rospy
59 directories, 170 files
I won't give all the steps to get there to save space, unless I need to to further clarify.
↧
How could I detect that ROS is installed in CMakeLists
Hi!
I need to make universal CMakeLists.txt, able to build package with ROS or not.
So I need some conditional variable to detect, that package could be build with ROS:
if(SOMEVAR)
set(USE_ROS true)
endif()
if(USE_ROS)
find_package ...
catkin_package ...
endif()
Thanks!
↧
Using C++ class in Python 2.7 and 3.x
Hey, I was trying to write a Python C++ wrapper as described in the Tutorial: "Using a C++ class in Python".
Now to my question, is there a way to compile the Module for Python 2.7 and 3 simultaneously using catkin?
So i can import the wrapper Class in both versions?
Because currently when Importing the wrapper to python 3 this error is thrown:
ImportError: dynamic module does not define module export function (PyInit__wrapper_cpp)
Since i can only link it against the python 2 libs.
Under Python 2 it is currently working without any errors.
Thanks for your help,
Thomas
↧
↧
Using catkin without ROS
So I like the catkin build system and am interesting in using it outside ROS, and working with people that don't want to install ROS. Is this possible?
I've tried installing catkin with pip but am getting errors like unable to find catkinConfig.cmake. Before I start going down this rabbit hole and try copying just that file, has anyone tried this?
edit: I built from source and when I run `catkin_make` after sourcing `/usr/local/setup.sh`, I get this:
Base path: workspace
Source space: workspace/src
Build space: workspace/build
Devel space: workspace/devel
Install space: workspace/install
####
#### Running command: "cmake workspace/src -DCATKIN_DEVEL_PREFIX=workspace/devel -DCMAKE_INSTALL_PREFIX=workspace/ins\
tall" in "workspace/build"
####
CMake Error at CMakeLists.txt:59 (message):
find_package(catkin) failed. catkin was neither found in the workspace nor
in the CMAKE_PREFIX_PATH. One reason may be that no ROS setup.sh was
sourced before.
I've tried setting `/usr/local/share/catkin/cmake/` as `CMAKE_PREFIX_PATH`.
edit: ok, appears to have been a permissions issue and now `catkin_make` is working, but the directories created appear to be incompatible with catkin build now, which fails on its own. Is that command deprecated? It is how I create eclipse projects.
↧
Installing catkin on Ubuntu 16.04.3
Building dependency tree
I can't seem to be able to install the 'catkin' package (I want catkin_make) on a recent Ubuntu Xenial installation:
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
catkin : Depends: python-catkin-pkg but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
This seems to be caused by the presence of a more recent python-catkin-pkg in the packages.ros.org packages repositroy, that conflicts with the default package from Ubuntu:
$ apt-cache policy python-catkin-pkg
python-catkin-pkg:
Installed: 0.3.5-1
Candidate: 0.3.5-1
Version table:
*** 0.3.5-1 500
500 http://ros.informatik.uni-freiburg.de/packages/ros/ubuntu xenial/main amd64 Packages
500 http://ros.informatik.uni-freiburg.de/packages/ros/ubuntu xenial/main i386 Packages
500 http://repo.ros2.org/ubuntu/main xenial/main amd64 Packages
100 /var/lib/dpkg/status
0.2.10-2 500
500 http://fr.archive.ubuntu.com/ubuntu xenial/universe amd64 Packages
500 http://fr.archive.ubuntu.com/ubuntu xenial/universe i386 Packages
↧
Has anyone actually got ROS working on Mac OS X Sierra?
I understand that ROS Kinetic or Lunar are "experimental" on OS X (Homebrew), but what does that mean? Does it mean that someone has actually been able to get it installed and simulate a simple robot on Mac? I have been following the steps at https://gist.github.com/jmtatsch/44e7c1a55fc29432254bdc61559d91c7 "ROS Kinetic on Sierra Work in Progress" on a FRESH install (system completely wiped and reinstalled) Mac OS X Sierra, but I am running into some difficulties:
When I perform the step "rosdep install --from-paths src --ignore-src --rosdistro kinetic -y", I get an error message "robot: Missing resource robot", which I find interesting because presumably it should find the robot metapackage easily within the src/metapackages folder. Under the assumption that "maybe this isn't that big of a deal", I continued with the installation steps outlined in the Github, but I am having issues with the step:
"catkin build \
-DCMAKE_BUILD_TYPE=Release \
-DPYTHON_LIBRARY=/usr/local/Cellar/python/2.7.11/Frameworks/Python.framework/Versions/2.7/lib/libpython2.7.dylib \
-DPYTHON_INCLUDE_DIR=/usr/local/Cellar/python/2.7.11/Frameworks/Python.framework/Versions/2.7/include/python2.7"
It fails almost immediately on:
"Failed << cpp_common:cmake [ Exited with code 1 ]
Failed <<< cpp_common [ 0.2 seconds ] "
"Errors << cpp_common:cmake /Users/karl/ros_catkin_ws/logs/cpp_common/build.cmake.000.log
CMake Error at /Users/karl/ros_catkin_ws/src/roscpp_core/cpp_common/CMakeLists.txt:5 (find_package):
By not providing "Findconsole_bridge.cmake" in CMAKE_MODULE_PATH this
project has asked CMake to find a package configuration file provided by
"console_bridge", but CMake did not find one.
Could not find a package configuration file provided by "console_bridge"
with any of the following names:
console_bridgeConfig.cmake
console_bridge-config.cmake
Add the installation prefix of "console_bridge" to CMAKE_PREFIX_PATH or set
"console_bridge_DIR" to a directory containing one of the above files. If
"console_bridge" provides a separate development package or SDK, be sure it
has been installed.
"
Why is it even looking for console_bridge in Kinetic? I thought console_bridge was replaced with rosconsole_bridge? Why would there still be a dependency?
The reasons I can't just install ROS on a Linux box natively are (1) all I have are Mac systems, (2) I can't afford a Linux workstation with suitable performance right now, and (3) I can use a Linux VPS remotely, but applications like Gazebo do not seem to graphically perform well remotely through VNC (I tried this before). What would you recommend?
↧
Error while creating a catkin workspace
I am using Ubuntu 14.04, ROS Indigo. I am getting the following catkin_make error, and I am not sure how to fix that -
-- The C compiler identification is GNU 4.8.5
-- The CXX compiler identification is GNU 4.8.5
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Using CATKIN_DEVEL_PREFIX: /home/ubuntu/dl_workspace/devel
-- Using CMAKE_PREFIX_PATH: /opt/ros/indigo
-- This workspace overlays: /opt/ros/indigo
-- Found PythonInterp: /home/ubuntu/anaconda2/bin/python (found version "2.7.13")
-- Using PYTHON_EXECUTABLE: /home/ubuntu/anaconda2/bin/python
-- Using Debian Python package layout
-- Using empy: /usr/bin/empy
-- Using CATKIN_ENABLE_TESTING: ON
-- Call enable_testing()
-- Using CATKIN_TEST_RESULTS_DIR: /home/ubuntu/dl_workspace/build/test_results
-- Looking for include file pthread.h
-- Looking for include file pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Found gtest sources under '/usr/src/gtest': gtests will be built
-- Using Python nosetests: /usr/bin/nosetests-2.7
Traceback (most recent call last):
File "/opt/ros/indigo/share/catkin/cmake/parse_package_xml.py", line 107, in
main()
File "/opt/ros/indigo/share/catkin/cmake/parse_package_xml.py", line 99, in main
package = parse_package(args.package_xml)
File "/home/ubuntu/anaconda2/lib/python2.7/site-packages/catkin_pkg/package.py", line 317, in parse_package
return parse_package_string(f.read(), filename)
File "/home/ubuntu/anaconda2/lib/python2.7/site-packages/catkin_pkg/package.py", line 450, in parse_package_string
raise InvalidPackage('Error(s) in %s:%s' % (filename, ''.join(['\n- %s' % e for e in errors])))
catkin_pkg.package.InvalidPackage: Invalid package manifest "/opt/ros/indigo/share/catkin/cmake/../package.xml": Error(s) in /opt/ros/indigo/share/catkin/cmake/../package.xml:
- The manifest must not contain the following tags: depend, build_export_depend, buildtool_export_depend
CMake Error at /opt/ros/indigo/share/catkin/cmake/safe_execute_process.cmake:11 (message):
execute_process(/home/ubuntu/anaconda2/bin/python
"/opt/ros/indigo/share/catkin/cmake/parse_package_xml.py"
"/opt/ros/indigo/share/catkin/cmake/../package.xml"
"/home/ubuntu/dl_workspace/build/catkin/catkin_generated/version/package.cmake")
returned error code 1
Call Stack (most recent call first):
/opt/ros/indigo/share/catkin/cmake/catkin_package_xml.cmake:63 (safe_execute_process)
/opt/ros/indigo/share/catkin/cmake/all.cmake:151 (_catkin_package_xml)
/opt/ros/indigo/share/catkin/cmake/catkinConfig.cmake:20 (include)
CMakeLists.txt:52 (find_package)
-- Configuring incomplete, errors occurred!
See also "/home/ubuntu/dl_workspace/build/CMakeFiles/CMakeOutput.log".
See also "/home/ubuntu/dl_workspace/build/CMakeFiles/CMakeError.log".
Invoking "cmake" failed
Kindly help!
↧
↧
catkin cmake error with ros (error code 1)
Hello everyone, I am following the tutorial here to create a workspace with catkin: http://wiki.ros.org/catkin/Tutorials/create_a_workspace
When I invoke catkin_make, I get this output:
ertugrul@Ertugrul-Laptop:~/ros/workspace/tutorial$ catkin_make
Base path: /home/ertugrul/ros/workspace/tutorial
Source space: /home/ertugrul/ros/workspace/tutorial/src
Build space: /home/ertugrul/ros/workspace/tutorial/build
Devel space: /home/ertugrul/ros/workspace/tutorial/devel
Install space: /home/ertugrul/ros/workspace/tutorial/install
####
#### Running command: "cmake /home/ertugrul/ros/workspace/tutorial/src -DCATKIN_DEVEL_PREFIX=/home/ertugrul/ros/workspace/tutorial/devel -DCMAKE_INSTALL_PREFIX=/home/ertugrul/ros/workspace/tutorial/install -G Unix Makefiles" in "/home/ertugrul/ros/workspace/tutorial/build"
####
-- Using CATKIN_DEVEL_PREFIX: /home/ertugrul/ros/workspace/tutorial/devel
-- Using CMAKE_PREFIX_PATH: /opt/ros/kinetic
-- This workspace overlays: /opt/ros/kinetic
-- Using PYTHON_EXECUTABLE: /home/ertugrul/anaconda2/bin/python
-- Using Debian Python package layout
-- Using empy: /usr/bin/empy
-- Using CATKIN_ENABLE_TESTING: ON
-- Call enable_testing()
-- Using CATKIN_TEST_RESULTS_DIR: /home/ertugrul/ros/workspace/tutorial/build/test_results
-- Found gtest sources under '/usr/src/gtest': gtests will be built
-- Using Python nosetests: /usr/bin/nosetests-2.7
Traceback (most recent call last):
File "/opt/ros/kinetic/share/catkin/cmake/parse_package_xml.py", line 107, in
main()
File "/opt/ros/kinetic/share/catkin/cmake/parse_package_xml.py", line 99, in main
package = parse_package(args.package_xml)
File "/home/ertugrul/anaconda2/lib/python2.7/site-packages/catkin_pkg/package.py", line 317, in parse_package
return parse_package_string(f.read(), filename)
File "/home/ertugrul/anaconda2/lib/python2.7/site-packages/catkin_pkg/package.py", line 450, in parse_package_string
raise InvalidPackage('Error(s) in %s:%s' % (filename, ''.join(['\n- %s' % e for e in errors])))
catkin_pkg.package.InvalidPackage: Invalid package manifest "/opt/ros/kinetic/share/catkin/cmake/../package.xml": Error(s) in /opt/ros/kinetic/share/catkin/cmake/../package.xml:
- The manifest must not contain the following tags: depend, build_export_depend, buildtool_export_depend
CMake Error at /opt/ros/kinetic/share/catkin/cmake/safe_execute_process.cmake:11 (message):
execute_process(/home/ertugrul/anaconda2/bin/python
"/opt/ros/kinetic/share/catkin/cmake/parse_package_xml.py"
"/opt/ros/kinetic/share/catkin/cmake/../package.xml"
"/home/ertugrul/ros/workspace/tutorial/build/catkin/catkin_generated/version/package.cmake")
returned error code 1
Call Stack (most recent call first):
/opt/ros/kinetic/share/catkin/cmake/catkin_package_xml.cmake:63 (safe_execute_process)
/opt/ros/kinetic/share/catkin/cmake/all.cmake:151 (_catkin_package_xml)
/opt/ros/kinetic/share/catkin/cmake/catkinConfig.cmake:20 (include)
CMakeLists.txt:52 (find_package)
-- Configuring incomplete, errors occurred!
See also "/home/ertugrul/ros/workspace/tutorial/build/CMakeFiles/CMakeOutput.log".
See also "/home/ertugrul/ros/workspace/tutorial/build/CMakeFiles/CMakeError.log".
Invoking "cmake" failed
I have tried anything I could find online, but I'm now clueless. Thank you for any help!
↧
Create ROS workspace - check if properly overlayed
I have ROS kinetic and i am following the tutorial: [http://wiki.ros.org/ROS/Tutorials/InstallingandConfiguringROSEnvironment]
After I enter:
echo $ROS_PACKAGE_PATH
I expect this:
/home/youruser/catkin_ws/src:/opt/ros/kinetic/share
But instead, I'm getting a blank line, as a return.
I've already checked if the file setup.bash is included in `/opt/ros/kinetic/` as well as in `/catkin_ws/devel/`.
Also, i've sourced it: `$ source devel/setup.bash`, but still no output after echo.
Any idea?
thanks a lot
↧
Cannot execute catkin_make in githook
I have a pre-push [githook](https://git-scm.com/docs/githooks) that tries to execute catkin_make before pushing, to only allow pushes that (at least) can compile. It works by git invoking invoking a bash script and depending on the return code allowing or denying the push "request". The script looks like this (only the important parts):
#!/bin/bash
# "This hook is called by git push and can be used to prevent a push from taking place.
# If this hook exits with a non-zero status, git push will abort without pushing anything.
# Information about why the push is rejected may be sent to the user by writing to standard error."
# see: https://git-scm.com/docs/githooks
# make the script fail if any line fails, see: http://redsymbol.net/articles/unofficial-bash-strict-mode/
set -euo pipefail # does not work with nvm
# go to the project root
# taken from here: https://stackoverflow.com/a/1571525/3753684
repo_root=$( git rev-parse --show-toplevel )
cd $repo_root
# build the project once
# this still prints output *on error*, which is what we want
build_output=$( catkin_make )
build_exit_status=$?
if [ $build_exit_status -eq 0 ];
then # it worked, let git push it
# log success message
echo "build succeeded, pushing is allowed"
# exit successfully
exit 0
else # it failed, prevent git from pushing
# log fail message
echo -e "--------------------\n\n"
echo "Failed to build the project. Not pushing."
# exit non-successfully
exit $build_exit_status
fi
↧