Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing Waypoint.h file #11

Open
surendhar091992 opened this issue Jun 24, 2022 · 13 comments
Open

Missing Waypoint.h file #11

surendhar091992 opened this issue Jun 24, 2022 · 13 comments
Labels
bug Something isn't working

Comments

@surendhar091992
Copy link

While attempting the catkin_make as instructed by the document, it gives the fatal error of not having simulator_utils\Waypoint.h

@malintha
Copy link
Owner

Thanks for opening the issue. Did you managed to get it fixed?

@surendhar091992
Copy link
Author

surendhar091992 commented Jul 5, 2022

No, i couldnt resolve it

@malintha
Copy link
Owner

malintha commented Jul 5, 2022

Can you share the complete console output? :)

@Qishunpeng
Copy link

Can you share the complete console output? :)

origin_img_v2_4d296520-7894-490a-99d1-da938d086bfg
origin_img_v2_780a3db0-17af-41ed-91fc-1477d9b3b53g

While attempting the catkin_make as instructed by the document, it gives the fatal error of not having simulator_utils\Waypoint.h

@malintha
Copy link
Owner

malintha commented Jul 9, 2022

@Qishunpeng @surendhar091992
Could you try building the simulator_utils package separately and then the whole repo?

First,
catkin build simulator_utils
Then,
catkin build

@malintha
Copy link
Owner

While attempting the catkin_make as instructed by the document, it gives the fatal error of not having simulator_utils\Waypoint.h

Try using catkin build instead of catkin_make

@malintha
Copy link
Owner

malintha commented Oct 17, 2022

@Qishunpeng hope this has solved your issue.

@wpower12
Copy link

In an attempt to get things working (i have an issue/question for installing this on Ubuntu 20,04 open), I switched to trying on a ubuntu-16.04/ros-kinetic installation. This got me further, but then I this exact issue; missing Waypoint.h file. When I run the suggested step of building the simulator_utils first, I get the following error;

Errors     << simulator_utils:make /home/vboxuser/Documents/catkin_ws/logs/simulator_utils/build.make.002.log                  
/home/vboxuser/Documents/catkin_ws/src/multi_uav_simulator/simulator_utils/src/Drone.cpp: In constructor ‘Drone::Drone(int, const ros::NodeHandle&)’:
/home/vboxuser/Documents/catkin_ws/src/multi_uav_simulator/simulator_utils/src/Drone.cpp:24:34: error: ‘to_string’ was not declared in this scope
     ss << "/robot_"<<to_string(id)<<"/current_state";
                                  ^
make[2]: *** [CMakeFiles/simulator_utils.dir/src/Drone.cpp.o] Error 1
make[1]: *** [CMakeFiles/simulator_utils.dir/all] Error 2
make: *** [all] Error 2
cd /home/vboxuser/Documents/catkin_ws/build/simulator_utils; catkin build --get-env simulator_utils | catkin env -si  /usr/bin/make --jobserver-fds=3,4 -j; cd -

@malintha
Copy link
Owner

malintha commented Nov 21, 2022

I guess the problem is that it's trying to look for the message header whilst it is being built which is inside the same package. Typically, this goes away when you execute catkin build for the entire workspace for a second time. That is why it worked for you the next time. If you check within the devel/ and build/ spaces you should find Waypoint.h inside the simulator utils. But an ideal solution would be to separate the message source to a different package that would be built prior to the simulation_utils.

But the to_string() issue is new. This should work with c++ 11, may be Ubuntu 16.04 doesn't have it enabled by default? Can you check what your c++ version is and switch the compiler?

@malintha malintha reopened this Nov 21, 2022
@malintha malintha added the bug Something isn't working label Nov 21, 2022
@wpower12
Copy link

Currently on c++ --version 5.4.0
I ran some apt updates and a dist-upgrade and reinstalled build-essentials to be sure, and its def the most 'up to date' i can get through those sources.

Sorry for not having more to give you, and that I'm clogging up your issues. Just been chasing my tail on getting this, or any UAV sims up and running.

@malintha
Copy link
Owner

malintha commented Nov 23, 2022

I just do not have a machine with kinetic with me; so this would be a good build test for Ubuntu 16.04/Kinetic. Are you still getting the to_string error?
Can you try forcing it to use c++ 11 by uncommenting this line? https://github.com/malintha/multi_uav_simulator/blob/master/simulator_utils/CMakeLists.txt#L5
Use catkin build simulator_utils to build only the utils package.

However, I'd recommend using Ubuntu 20.04 + Noetic, that's the one I have tested this on. Referring to your previous bug (#14) on Noetic, did you get that one on a clean catkin_ws?

@malintha
Copy link
Owner

malintha commented Nov 23, 2022

@wpower12 Alright. I did a bit of searching and apparently to_string issue is a known bug in GCC 5.4 on Ubuntu. So it won't compile without a workaround to the code (adding D_GLIBCXX_USE_C99 to the CMakeLists.txt).
https://bugs.launchpad.net/ubuntu/+source/gcc-5/+bug/1739778

If it is the "newest" you get on Ubuntu 16.04, I would recommend you to switch to Ubuntu 20.04. So we can focus on solving #14.

@matteovidali
Copy link
Contributor

I experienced this issue as well, and the solution of first running catkin build simulation_utils, and then catkin build seemed to solve this build issue for me (Ubuntu 20.04.5 with kernel 5.15.0-67-generic)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants