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

there isn't the file falconSetPoint.h #6

Closed
jcorredorc opened this issue Jul 20, 2018 · 22 comments
Closed

there isn't the file falconSetPoint.h #6

jcorredorc opened this issue Jul 20, 2018 · 22 comments

Comments

@jcorredorc
Copy link

Hi,
I was wondering if this package works in kinetic (as is seen in package.xml).

Besides, I have an issue when try to build the package. I get this error,

catkin_ws/src/ROS-Falcon/src/falcon_js_pid.cpp:7:38: fatal error: rosfalcon/falconSetPoint.h: There is no file or directory #include "rosfalcon/falconSetPoint.h"

I'm building with catkin build ros_falcon, I'll appreciate any advice to solve this,

Best,

@jcorredorc jcorredorc changed the title there isn't the file falconSerPoint.h there isn't the file falconSetPoint.h Jul 20, 2018
@adnanmunawar
Copy link
Member

This seems to be an issue with the latest ROS releases where the msg packages (deps) aren't built before the target for ros_falcon is being compiled. As per your question, the falconSetPoint does exist in the msg folder so that isn't the issue I think. There are two solutions.

  1. Explicitly build the message before using the command catkin_make. I don't have linux on hand so can't verify but it should be "catkin_make --pkg ros_falcon_msgs". Just double check the "ros_falcon_msgs" name using "rosmsg show <msg_package_name>" to verify that the message files are there now.

  2. I have found that using catkin_make multiple times also solves the problem. "catkin_make" would fail a few times but does end up succeeding eventually.

Lastly, it should work using the catkin build after the first step but I don't have linux to test that for a few days.

@jcorredorc
Copy link
Author

Thanks for your reply. I try build it several times and it works.

@OEspitia77
Copy link

OEspitia77 commented Feb 24, 2020

I have the same problem, but the previous solution did not work for me. @adnanmunawar

@adnanmunawar
Copy link
Member

Can you please specify your OS and preferably your ROS version

@adnanmunawar adnanmunawar reopened this Feb 24, 2020
@OEspitia77
Copy link

@adnanmunawar is Ubuntu and ROS kinetic

@adnanmunawar
Copy link
Member

adnanmunawar commented Feb 25, 2020

Are you sure you have installed libnifalcon as mentioned in the README?

@OEspitia77
Copy link

@adnanmunawar , yes, I did it

@adnanmunawar
Copy link
Member

Please paste the output of your build commands cmake and make

@OEspitia77
Copy link

@adnanmunawar This is the message when using catkin_make:

/home/omar/catkin_ws/src/falcon/src/main.cpp:11:33: fatal error: rosfalcon/falconPos.h: No existe el archivo o el directorio
/home/omar/catkin_ws/src/falcon/src/falcon_cs_pid.cpp:7:38: fatal error: rosfalcon/falconSetPoint.h: No existe el archivo o el directorio
#include "rosfalcon/falconSetPoint.h"
^
/home/omar/catkin_ws/src/falcon/src/falcon_js_pid.cpp:7:38: fatal error: rosfalcon/falconSetPoint.h: No existe el archivo o el directorio
#include "rosfalcon/falconSetPoint.h"
^
compilation terminated.

@OEspitia77
Copy link

then continue this message:
compilation terminated.
compilation terminated.
[ 3%] Built target tf2_msgs_generate_messages_eus
[ 3%] Built target nav_msgs_generate_messages_lisp
falcon/CMakeFiles/falcon_js_pid.dir/build.make:79: fallo en las instrucciones para el objetivo 'falcon/CMakeFiles/falcon_js_pid.dir/src/falcon_js_pid.cpp.o'
falcon/CMakeFiles/falcon_cs_pid.dir/build.make:79: fallo en las instrucciones para el objetivo 'falcon/CMakeFiles/falcon_cs_pid.dir/src/falcon_cs_pid.cpp.o'
falcon/CMakeFiles/falcon_node.dir/build.make:79: fallo en las instrucciones para el objetivo 'falcon/CMakeFiles/falcon_node.dir/src/main.cpp.o'
make[2]: *** [falcon/CMakeFiles/falcon_js_pid.dir/src/falcon_js_pid.cpp.o] Error 1
make[2]: *** [falcon/CMakeFiles/falcon_cs_pid.dir/src/falcon_cs_pid.cpp.o] Error 1
make[2]: *** [falcon/CMakeFiles/falcon_node.dir/src/main.cpp.o] Error 1
CMakeFiles/Makefile2:3932: fallo en las instrucciones para el objetivo 'falcon/CMakeFiles/falcon_cs_pid.dir/all'
make[1]: *** [falcon/CMakeFiles/falcon_cs_pid.dir/all] Error 2
make[1]: *** Se espera a que terminen otras tareas....
CMakeFiles/Makefile2:3710: fallo en las instrucciones para el objetivo 'falcon/CMakeFiles/falcon_js_pid.dir/all'
make[1]: *** [falcon/CMakeFiles/falcon_js_pid.dir/all] Error 2
CMakeFiles/Makefile2:4317: fallo en las instrucciones para el objetivo 'falcon/CMakeFiles/falcon_node.dir/all'
make[1]: *** [falcon/CMakeFiles/falcon_node.dir/all] Error 2
[ 3%] Built target tf2_msgs_generate_messages_nodejs
Makefile:157: fallo en las instrucciones para el objetivo 'all'
make: *** [all] Error 2
Invoking "make -j4 -l4" failed

@OEspitia77
Copy link

When I use cmake : $ cmake -G "Unix Makefiles" ..

-- Installation Prefix: /usr/local
-- Building Static Libraries for LIBNIFALCON
-- Building Shared Libraries for LIBNIFALCON
-- NOT using gprof output for LIBNIFALCON
-- Found libusb-1.0:
-- - Includes: /usr/include
-- - Libraries: /usr/lib/x86_64-linux-gnu/libusb-1.0.so
-- Not compiling falcon_mouse example - X11 compiling requires the XTest library
-- Generating /home/omar/Descargas/libnifalcon-master/build/libnifalcon.pc
-- Configuring done
-- Generating done
-- Build files have been written to: /home/omar/Descargas/libnifalcon-master/build

@OEspitia77
Copy link

OEspitia77 commented Feb 25, 2020

when I use make after, in libnifalcon:

cmake -G "Unix Makefiles" ..
-- Installation Prefix: /usr/local
-- Building Static Libraries for LIBNIFALCON
-- Building Shared Libraries for LIBNIFALCON
-- NOT using gprof output for LIBNIFALCON
-- Found libusb-1.0:
-- - Includes: /usr/include
-- - Libraries: /usr/lib/x86_64-linux-gnu/libusb-1.0.so
-- Not compiling falcon_mouse example - X11 compiling requires the XTest library
-- Generating /home/omar/Descargas/libnifalcon-master/build/libnifalcon.pc
-- Configuring done
-- Generating done
-- Build files have been written to: /home/omar/Descargas/libnifalcon-master/build

@adnanmunawar
Copy link
Member

adnanmunawar commented Feb 25, 2020

I briefly glanced the output, it seems you changed the name of your package from ros_falcon to falcon. Then you also seemed to have modified your src files includes from ros_falcon to rosfalcon. You need to be consistent with your naming.

@OEspitia77
Copy link

I renamed the package and get this:

CMake Warning (dev) in CMakeLists.txt:
No project() command is present. The top-level CMakeLists.txt file must
contain a literal, direct call to the project() command. Add a line of
code such as

project(ProjectName)

near the top of the file, but after cmake_minimum_required().

CMake is pretending there is a "project(Project)" command on the first
line.
This warning is for project developers. Use -Wno-dev to suppress it.

@adnanmunawar
Copy link
Member

You need to clear your build and devel folder, remove the package from your src tree and then clone a fresh copy without any of your edits and then try to compile

@OEspitia77
Copy link

@adnanmunawar thanks a lot. It works, but I realized that I did not install libnifalcon correctly. I got this message:

omar@omar-All-Series:~/catkin_ws$ rosrun rosfalcon falcon_node
/home/omar/catkin_ws/devel/lib/rosfalcon/falcon_node: error while loading shared libraries: libnifalcon.so.1.0.2: cannot open shared object file: No such file or directory

@OEspitia77
Copy link

I do not how to install it, I got confuse cause I just cloned the libnifalcon package in my workspace src folder

@adnanmunawar
Copy link
Member

So I would suggest to NOT clone the libnifalcon to catkin workspace (ROS src folder). But instead just clone it in your home directory. Then, after the cmake and make command in the build folder, make sure to run the make install command. You might need sudo for the make install command.

@OEspitia77
Copy link

I did all that you told me but I got this message:

rosrun rosfalcon falcon_node
/home/omar/catkin_ws/devel/lib/rosfalcon/falcon_node: error while loading shared libraries: libnifalcon.so.1.0.2: cannot open shared object file: No such file or directory

@adnanmunawar
Copy link
Member

Why are you renaming the files and executables? If you create/comment on an existing issue, make sure to state what you have modified. There isn't any executable named falcon_node in the package. Nor is the name of the package rosfalcon.

@OEspitia77
Copy link

I do not renamed them, and falcon_node exists, I saw it in the path that the shell indicates

@adnanmunawar
Copy link
Member

Closing this issue as the solution specified in #2 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants