Ask Your Question
0

ROS qt plugin

asked 2018-01-23 10:19:32 -0600

RogerPi gravatar image

updated 2018-01-23 10:47:01 -0600

Hello. I'm having trouble trying to use Qt for my ROS projects.

First I tried with standard Qt from official webpage, running it from terminal and with some path configurations I managed to make autocomplete work (only in c++ files) but not in include files and also no building was possible because I got some errors as "undefined reference to std::__cxx" from g++ compiler.

Then, I removed Qt and installed ros qt pluguin following this tutorial: link

Now I have qtcreator-ros but I can only launch it from desktop app. When I try to run it from terminal, I get a core dump:

image description

edit: I realized that using sudo solves the issue.

Anyway, I run it from applications, I can create a workspace where I select my catkin_ws.

I try to build I get this catkin_make error:

16:37:49: Running steps for project catkin_ws... 16:37:49: Could not start process "catkin_make" --cmake-args -G 'CodeBlocks - Unix Makefiles' Error while building/deploying project catkin_ws (kit: Imported Kit) When executing step "CatkinMake Step" 16:37:50: Elapsed time: 00:01.

So I check my kits and there is something weird...

image description image description

My kits are not well configured, and I don't know what should I do. It's supposed to be configured automatically, and I don't know where the error is.

Any idea?

Thank you

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2018-01-23 11:14:45 -0600

RogerPi gravatar image

Finally I managed to solve it!!

The first problem is solved running it using sudo, I suppose is because the program is in opt and some permissions might be unset.

To solve Kits problems I reinstalled qt several times, until I realized that the configuration was always the same, so I deleted ~/.config/QtProject folder. I assume that having different Qt, installing, un-installing, maybe I touched something I shouldn't.

When I deleted configuration and run it again, there was only 1 kit and everything is set up properly. But building made the same error:

16:37:49: Running steps for project catkin_ws... 16:37:49: Could not start process "catkin_make" --cmake-args -G 'CodeBlocks - Unix Makefiles' Error while building/deploying project catkin_ws (kit: Imported Kit) When executing step "CatkinMake Step" 16:37:50: Elapsed time: 00:01.

To solve this, just go to your workspace and run manually "catkin_make --cmake-args -G 'CodeBlocks - Unix Makefiles' "

After doing it for first time, you will be able to do it using Qt.

I just figured out these things trying and trying, but I don't have a clear idea of what's going on. So if anybody has any comment on this, it will be welcome!

edit flag offensive delete link more

Comments

The first problem is solved running it using sudo, [..]

I'm happy for you that you got things to work, but never run programs as root (which is what sudo sort of does) unless it's absolutely, really, necessary. It'll just complicate things later on, and should not be necessary at all ..

gvdhoorn gravatar imagegvdhoorn ( 2018-01-23 11:18:57 -0600 )edit

No, I'm not running it as root, it was just for testing, but I know I can screw something in my computer easily. But I still don't understand why I can't run it from terminal, but I can by desktop application...

RogerPi gravatar imageRogerPi ( 2018-01-23 11:21:22 -0600 )edit
1

.. to run something as simple as Qt Creator.

The fact that it doesn't work without sudo points to issues with how your OS is setup, which would be something to check.

Google-searching for "qt platform plugin xcb" returns a host of results.

gvdhoorn gravatar imagegvdhoorn ( 2018-01-23 11:21:52 -0600 )edit

After you ran "catkin_make --cmake-args -G 'CodeBlocks - Unix Makefiles' " were you able to build from within Qt Creator?

Levi-Armstrong gravatar imageLevi-Armstrong ( 2018-01-24 07:38:29 -0600 )edit

Yes, after doing it for first time in terminal I can build from terminal or Qt with no problem.

RogerPi gravatar imageRogerPi ( 2018-01-25 10:27:59 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2018-01-23 10:19:32 -0600

Seen: 870 times

Last updated: Jan 23 '18