Skip to content

v5.0.x: autogen.pl: fix submodule hash check #10808

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

Merged
merged 2 commits into from
Sep 20, 2022

Conversation

jsquyres
Copy link
Member

Update the git submodule check to just look at the first character in each line of "git submodule status" output:

  • If it's "-", then the submodule is missing (this check was already there)
  • If it's "+", then the locally-checked out hash is different than what is expected by the submodule, so emit a warning (this check was there, but was incorrect)

Signed-off-by: Jeff Squyres [email protected]
(cherry picked from commit f9fc72a)

Update the git submodule check to just look at the first character in
each line of "git submodule status" output:

* If it's "-", then the submodule is missing (this check was already
  there)
* If it's "+", then the locally-checked out hash is different than
  what is expected by the submodule, so emit a warning (this check was
  there, but was incorrect)

Signed-off-by: Jeff Squyres <[email protected]>
(cherry picked from commit f9fc72a)
@jsquyres jsquyres added this to the v5.0.0 milestone Sep 15, 2022
@jsquyres jsquyres requested a review from bwbarrett September 15, 2022 22:45
@jsquyres jsquyres marked this pull request as draft September 16, 2022 00:15
@jsquyres
Copy link
Member Author

Moving to draft, per #10807 (comment)

The output of `git submodule status` will be of the following form:

```
Xgit_hash submodule_path [(git_ref)]
```

* `X` is either a space, `+`, or `-`
* `git_hash` is 40 hex digits
* `submodule_path` is the path in the repo where the submodule is
  located
* `(git_ref)` is optional, and will not be there if the submodule is
  missing (which the previous regexp did not handle).

This commit tightens up the regexp to be a bit more robust and handle
the case where the git_ref token is not present.

Signed-off-by: Jeff Squyres <[email protected]>
(cherry picked from commit 5c66993)
@jsquyres jsquyres marked this pull request as ready for review September 16, 2022 15:43
@jsquyres
Copy link
Member Author

jsquyres commented Sep 16, 2022

Added commit from #10810 to make the autogen test more robust. This PR is now ready.

@awlauria awlauria merged commit 3d69b9d into open-mpi:v5.0.x Sep 20, 2022
@jsquyres jsquyres deleted the pr/v5.0.x/autogen-fixup-for-oac branch October 12, 2022 13:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants