-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Prototype gz header migration #51
Conversation
Signed-off-by: Steve Peters <scpeters@openrobotics.org>
* REPLACE_IGNITION_INCLUDE_PATH gz/utils * Include from gz/* in header files * Update header guards to use GZ_* * Add gz subdirectory in CMakeLists.txt Signed-off-by: Steve Peters <scpeters@openrobotics.org>
Signed-off-by: Steve Peters <scpeters@openrobotics.org>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, @scpeters , this approach looks good to me. Some questions / comments:
- How do you think we should do the deprecation warnings? Using a
#pragma message()
in everyignition
header? - Did you use a script or just prototyped it manually?
- It would be good to move the files from
ignition
togz
so we keep their commit history. - When this PR is ready for merging, we should update examples and tests
I'm not sure if
I did this manually, but it shouldn't be too hard to script
I did a It doesn't show up because github is a little confused, but I think our history is preserved with this approach.
we can decide how to split the work up into phases, but I believe this approach can be merged independently without breaking anything. We could optionally update the Some possible steps:
Because GitHub gets confused by the diff in this pull request, I like making a narrow PR like this to add the |
we could arguably backport this to fortress since I think it's backwards compatible, but I'm not sure if it's worth it |
Something to keep in mind for later 👍🏽 |
* | ||
*/ | ||
|
||
#include <gz/utils.hh> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this meant to be gz/utils/utils.hh
?
(I'll write the script assuming that it's utils/utils.hh
, but it'll be a trivial change to change it back.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in general, it should only have one utils
, so gz/utils.hh
is correct (look at the installed paths of any ign-*
package to confirm)
the one exception is libsdformat, which has sdf/sdf.hh
but that one is a bit different anyway
It prints a message for me, not sure what's missing? I think the only downside to it is that it's not an actual warning.
Ah perfect, indeed GitHub gets confused in the PR diff
I'm fine with that 👍🏽 We just have to make sure we don't introduce warnings in the intermediate steps. |
#53 was merged instead |
🎉 New feature
Prototype part of gazebo-tooling/release-tools#698
Summary
The big diff is not so easy to read, so I recommend going commit-by-commit:
ignition
header folder togz
gz
headersignition/*
headers that simply redirect to theirgz/
counterpartThis takes a very minimal approach, just to change the include path without changing any namespaces or even the
IGNITION_*
variables in config.hh. The only macros changed are for header guards of the newgz/*
headers.Test it
Checklist
codecheck
passed (See contributing)Note to maintainers: Remember to use Squash-Merge and edit the commit message to match the pull request summary while retaining
Signed-off-by
messages.