Skip to content

packaging: Introduce Packit CI to track RPM building - #7910

Merged
hzhou merged 7 commits into
pmodels:mainfrom
Growl1234:rpm
Aug 3, 2026
Merged

packaging: Introduce Packit CI to track RPM building#7910
hzhou merged 7 commits into
pmodels:mainfrom
Growl1234:rpm

Conversation

@Growl1234

Copy link
Copy Markdown
Collaborator

Pull Request Description

This PR brings the maintenance of the Fedora RPM build into the upstream repository, with the aim of strengthening the connection and collaboration between upstream development and downstream packaging. It also makes it possible to track the potential impact of upstream changes on the Fedora RPM during development. The goal is to minimize the maintenance burden associated with the RPM build and keep the upstream project more closely synchronized with the version available in the Fedora repositories.

The relevant CI tests are handled by Packit. Every commit pushed to the main branch triggers Packit CI, and users with triage permissions can also trigger a build from a pull request by commenting /packit build. This requires maintainers to install Packit-as-a-Service app for this repository and obtain access to Packit (see https://packit.dev/docs/guide).

The RPM spec with corresponding patches is copied from downstream repo; patches are adjust to meet the current upstream condition. Since MPICH uses release artifact, the maint/release.pl is reused in Packit to provide the proper tarball that allows the Packit workflow to pass.

Author Checklist

  • Provide Description
    Particularly focus on why, not what. Reference background, issues, test failures, xfail entries, etc.
  • Commits Follow Good Practice
    Commits are self-contained and do not do two things at once.
    Commit message is of the form: module: short description
    Commit message explains what's in the commit.
  • Passes All Tests
    Whitespace checker. Warnings test. Additional tests via comments.
  • Contribution Agreement
    For non-Argonne authors, check contribution agreement.
    If necessary, request an explicit comment from your companies PR approval manager.

@Growl1234
Growl1234 requested review from LecrisUT and hzhou July 31, 2026 03:58

@LecrisUT LecrisUT left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you split the first commit in 2, one copying the downstream content as-is and another adding the changes to make it buildable for upstream? I will keep the review minimal here for just getting things to build, and minimizing the difference with downstream, and then we can work on improving the process in subsequent PRs/reviews

Comment thread .packit.yaml Outdated
Comment thread packaging/rpm/mpich.spec Outdated
%dir %{_libdir}/%{name}/lib/cmake
%dir %{_libdir}/%{name}/include
%dir %{_fmoddir}/mpich
%{_libdir}/%{name}/lib/*.so.*

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to handle soversion here somehow.

Also best not to glob the library names. If a library is removed downstream needs to rebuild the dependencies (same with soversion changes)

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The development branch treats soversion as 0, while release tarball is 12. Therefore, RPM-build tests failed. Is there way to better handle this?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Autotools and perl, my archenemies. I think

system(qq(perl -p -i -e 's/\\[libmpi_so_version_m4\\],\\[0:0:0\\]/[libmpi_so_version_m4],[$so_version]/g' ./maint/version.m4));

should handle the versioning if my blind guess is correct. Maybe check the order of the actions and if it does indeed replace that snippet after archiving.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IIUC the soversion flag should be passed as 18:1:6 for now, thus libmpi.so.12. What I'm concerning is whether we have to add --so-version 18:1:6 to .packit.yaml, which means for maintainers one more place will need to care, as I guess there's only one way to pull in soversion for MPICH: to run release.pl with manually adding --so-version.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually downstream did no soversion locked it so we can postpone this for a bit later.

For the PR and such here it would be fine to use some dummy values, unless you want to use a copr for more production stuff. We can just replace with actual good soversions in the propose_to_downstream when the specific value is given in the archive

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've temporarily set soversion to 0 in RPM spec. Hope we can find a solution in the future.

@Growl1234
Growl1234 force-pushed the rpm branch 4 times, most recently from 8ec52d4 to 2fc8b75 Compare August 1, 2026 03:25
@hzhou

hzhou commented Aug 1, 2026

Copy link
Copy Markdown
Collaborator

@Growl1234 What is the impact if we merge this? I am tempted to merge this first to get the CI working. Then we can use additional PR to clean it up.

Please prefix each commit subject with packaging: prefix. Please add commit message stating the purpose of each commit.

@Growl1234
Growl1234 force-pushed the rpm branch 2 times, most recently from e18aa0a to 283b27f Compare August 2, 2026 06:08
@Growl1234

Copy link
Copy Markdown
Collaborator Author

What is the impact if we merge this? I am tempted to merge this first to get the CI working. Then we can use additional PR to clean it up.

Sorry, I don't understand what did you mean by "impact"🤔 As I understand it, this doesn't touch the other part of the repository, except the need to adjust release.pl which is done via #7909. What we need in the next step is:

This requires maintainers to install Packit-as-a-Service app for this repository and obtain access to Packit (see https://packit.dev/docs/guide).

@LecrisUT

LecrisUT commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator

Preferably the github app installation is done before the merge. If the app is not installed and this is merged, then it is just a no-op, but when it is installed you might get a flood of notifications if there are slight misconfigurations or you will get a bunch of red checks in the PR. If you install the app before though, all the notifications and statuses are still confined to this PR. Also from my experience, people forget to enable the app, and eventually lead to some nasty bit-rots.

For how ready this one is, from reading the commits, it should be all good, but seeing a green check here is always the best confirmation for it.

- Adjust patches: delete patches that are no longer needed, and sync
  some of them with upstream
- Minor adjustments to spec itself, e.g. upstream no longer use README;
  they use README.md instead
Test RPM-build workflow upstream so that potentianal problems can be
easier to track.
If library soversion is changed downstream needs to rebuild the dependencies, so we have to track it
If a library is removed downstream needs to rebuild the dependencies, so
we have to track them.
This is a workaround to simply get rid of RPM-build failure. It should be revised somehow.
@hzhou

hzhou commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator
image

@LecrisUT What permission should I grant?

--
Never mind. I see issue packit/notifications#746. On it.

@Growl1234

Growl1234 commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator Author

/packit build

@Growl1234 Growl1234 changed the title Introduce Packit CI to track RPM building packaging: Introduce Packit CI to track RPM building Aug 3, 2026
@hzhou

hzhou commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator

Is there a way to use version defined in

m4_define([MPICH_VERSION_m4],[5.1.0a1])dnl
?

Is there a way to run a basic test after the rpm install to verify working status? The following would be a good test:

mpicc -o cpi examples/cpi.c
mpiexec -n 2 ./cpi

@Growl1234

Copy link
Copy Markdown
Collaborator Author

Is there a way to run a basic test after the rpm install to verify working status?

IIRC we can leverage Test Farm; unfortunately I'm not very familiar with it, but @LecrisUT can provide more information.

@LecrisUT

LecrisUT commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator

Is there a way to use version defined in

m4_define([MPICH_VERSION_m4],[5.1.0a1])dnl

?

Definitely, but it depends on what you have in mind by "using it". How about making an issue to clarify that and address it in a follow up PR?

Is there a way to run a basic test after the rpm install to verify working status? The following would be a good test:

mpicc -o cpi examples/cpi.c
mpiexec -n 2 ./cpi

Do I have a fancy vacuum cleaner to sell you 😅. I'll make a PR to show the testing-farm onboarding for defining these kind of tests 😉.

@hzhou

hzhou commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator

Okay. Sounds good.

One last question: can we disable the default pull requests build but retain a way to manually invoke it? I would like to keep the amount of noise low during a pull request iteration.

@Growl1234

Growl1234 commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator Author

can we disable the default pull requests build but retain a way to manually invoke it?

Done. It can be easily triggered via a simple /packit build.

(Btw, it not only processes new comments but also listens to edits. So, you can just re-use an existing comment. Inserting even a single space character will trigger a re-eval.)

@hzhou hzhou left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Thanks @Growl1234 @LecrisUT for the work!

@hzhou

hzhou commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator

test:mpich/ch3/tcp
test:mpich/ch4/ofi

There are a few unrelated test failures: ch4-ofi-vci: pt2pt/pingping and comm/comm_idup_comm2, both timeouts. Will investigate separately.

@LecrisUT

LecrisUT commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator

Okay. Sounds good.

One last question: can we disable the default pull requests build but retain a way to manually invoke it? I would like to keep the amount of noise low during a pull request iteration.

Definitely. You can either run it based on a PR label (recommended workflow) or based on manual trigger. I do however recommend to still have at least either the rawhide-x86_64 or aarch64 running as regularly as possible because it also tracks changes outside of the project that you should be aware of. Can always ping us when something like that happens or we can add it so that we are pinged on each builf failure (prefer to avoid atm because we also get pinged when it fails while working on PRs 1)

Footnotes

  1. https://github.com/packit/packit-service/issues/2231

@hzhou
hzhou merged commit 3385527 into pmodels:main Aug 3, 2026
15 of 16 checks passed
@hzhou

hzhou commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator

@LecrisUT It still runs on every merge, right? Do I get notifications when the merge tests fail?

@hzhou hzhou mentioned this pull request Aug 3, 2026
@Growl1234

Copy link
Copy Markdown
Collaborator Author

Uh it turns out I forgot to add it to my copr project, which is why the CI didn't work on the merge. Sorry. Now it should be OK.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants