Skip to content
This repository has been archived by the owner on Feb 4, 2021. It is now read-only.

Cmake warning about unused variable SECURITY #79

Closed
sloretz opened this issue Jan 4, 2018 · 4 comments
Closed

Cmake warning about unused variable SECURITY #79

sloretz opened this issue Jan 4, 2018 · 4 comments
Labels
wontfix This will not be worked on

Comments

@sloretz
Copy link

sloretz commented Jan 4, 2018

This ci job has a CMake warning about the variable SECURITY being unused.

CMake Warning:
  Manually-specified variables were not used by the project:

    SECURITY

I think a workaround is to add a cmake arg --no-warn-unused-cli by default to CI_AMENT_BUILD_ARGS here, but I'm not sure what the process is. Do I need to re-run create_jenkins_job.py manually? Or is it automatically run when a pull request is merged?

@sloretz sloretz assigned sloretz and unassigned sloretz Jan 4, 2018
@dirk-thomas
Copy link
Member

dirk-thomas commented Jan 4, 2018

After closing #73 yesterday the test builds (e.g. http://ci.ros2.org/job/ci_windows/3911/) didn't show this warning - also neither of the nightly builds has them. I am not sure what is different in this case.

I think a workaround is to add a cmake arg --no-warn-unused-cli by default to CI_AMENT_BUILD_ARGS here

These warnings are supposed to be filtered out explicitly since SECURITY is just one example (see https://github.com/ros-infrastructure/buildfarm_deployment/pull/169/files#diff-4994eebff7eed3fdad0878c909c1e8a6R6). E.g. some packages don't use BUILD_TESTING. In the future we should pass arguments only to specific packages which need that and not have any warning anymore. Therefore I don't think passing --no-warn-unused-cli is a good idea.

but I'm not sure what the process is. Do I need to re-run create_jenkins_job.py manually? Or is it automatically run when a pull request is merged?

Yes, the reconfiguration needs to be run manually - nothing automatic here.

@sloretz
Copy link
Author

sloretz commented Jan 4, 2018

Strange, 3194 has the warning while 3195 does not.

Looking closer at the console text I wonder if the regular expression isn't matching due to the output being interleaved in a --parallel build. This is the console output referenced in the jenkins GUI.

CMake Warning:
     2>Done Building Project "C:\J\workspace\ci_windows\ws\build\ament_cmake_export_definitions\ALL_BUILD.vcxproj.metaproj" (default targets).
     1>Done Building Project "C:\J\workspace\ci_windows\ws\build\ament_cmake_export_definitions\ament_cmake_export_definitions.sln" (default targets).
  Manually-specified variables were not used by the project:

    SECURITY

@dirk-thomas
Copy link
Member

That is indeed the problem. I only looked at some of them and didn't see the few which are interleaved.

I don't think the warnings plugin in Jenkins can deal with this since all warning extraction is based on non-interleaved output. Therefore I am inclined to close this with "wontfix". What do you think?

Hopefully we can switch to a tool in the near future which will ensure to print the messages from each package non-interleaving even when run in parallel.

@sloretz sloretz added the wontfix This will not be worked on label Jan 4, 2018
@sloretz
Copy link
Author

sloretz commented Jan 4, 2018

+1 to closing as wontfix. A false positive cmake warning in the jenkins GUI doesn't seem worth spending too much time on.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

2 participants