ament / uncrustify_vendor

CMake shim over the uncrustify library: https://github.com/uncrustify/uncrustify
Apache License 2.0
0 stars 9 forks source link

Use custom command. #19

Closed clalancette closed 3 years ago

clalancette commented 3 years ago

This should work around an issue when trying to build the package multiple times in some circumstances.

Signed-off-by: Chris Lalancette clalancette@openrobotics.org

@cottsay I still can't reproduce the problem on Linux. I was able to reproduce it on macOS, and tested that this fixes it there. Can you give it a try?

This should fix #17

clalancette commented 3 years ago

CI:

cottsay commented 3 years ago

This did resolve the issue for me on Linux, but it looks like it didn't work on Windows.

clalancette commented 3 years ago

Of course Windows is difficult.

crystaldust commented 3 years ago

Thanks @clalancette! I encounter the same issue and the PR really saved my life.

Would like to suggest to put a git checkout ./ before applying the patch. I actually broke the build after the git patch, and build the whole ros2 project again, then colcon always complains that the patch won't apply(since it's already patched), even though it's my own stupidity, it's always good to check things first and don't let the developer feel it :)

clalancette commented 3 years ago

Well, it turns out that I could in no way get this to work with Windows. But thanks to @crystaldust 's suggestion, I have a much simpler solution using git checkout . that seems to work on all platforms in local testing. I'm going to close this one out and open a new PR that has that fix.