-
-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
Suppress cmake warnings for pcl modules #4431
Conversation
I would rather search for a way to avoid the warnings all together - is it the use of components, that aren't implemented correctly. Ie. VTK and Qt has components as well. |
If I see it correctly, the warnings are not avoidable and it is ok to just suppress them: In this line (or three lines further down if module is header-only), the function |
Just chiming in with low CMake knowledge: Is there a reason we can't correct the name instead (for libusb)? |
As far as I understand it, no: e.g. in the first CMake Warning above, the problem is that |
Thanks mvieth. I now understand what's happening here. Based on the explanation, the changes LGTM 😄 |
Couldn't the messages in FindOpenNI(2) suppressed by moving the |
Hm, sounds doable, but I am not really a cmake expert, and I don't know if there would be any side effects? |
Indeed. I currently taking a look into this and I have fun 😆 Both OpenNI find scripts are looking for libusb-1.0 and define pcl/cmake/Modules/FindOpenNI.cmake Lines 22 to 25 in 79da811
pcl/cmake/Modules/FindOpenNI.cmake Line 79 in 79da811
|
Since LibUSB is found in the general CMakeLists here: Lines 307 to 314 in 79da811
It shouldn't be necessary to search for them again in submodules (ie. All grabbers which are searched for afterwards) |
I refactored the libusb CMake code locally already. Currently just looking why some apps are not build. |
@SunBlack I reverted all changes related to libusb, now only the warnings regarding the individual pcl modules are suppressed. I haven't tested your PR yet, but I think it should successfully remove the libusb warnings. |
Can confirm with CMake 3.19.1 that this PR fixes the issue. |
* Suppress cmake warnings for mismatched names
* Suppress cmake warnings for mismatched names
See issue #3680
Example of suppressed warnings: