Skip to content

[CICD] Add openEuler 24.03 RPM build support#29

Open
shiptux wants to merge 2 commits into
flagos-ai:mainfrom
shiptux:pr/openeuler-rpm
Open

[CICD] Add openEuler 24.03 RPM build support#29
shiptux wants to merge 2 commits into
flagos-ai:mainfrom
shiptux:pr/openeuler-rpm

Conversation

@shiptux

@shiptux shiptux commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Summary

Extends the RPM packaging so the same spec builds on openEuler
24.03 LTS
in addition to Fedora 43. openEuler ships Python 3.11
and does not ship pyproject-rpm-macros, so the Fedora-built
.fc43 noarch RPM (python(abi) = 3.14) cannot install there —
each RPM distro family needs a native rebuild.

What changed (packaging + CI only, no source changes)

  • packaging/rpm/specs/flagsparse.spec — parse-time capability
    check: when %pyproject_wheel is defined (Fedora/EL9+) the
    existing macro path is used unchanged; otherwise a pip-based
    wheel/install fallback with an explicit %files list.
  • packaging/rpm/dockerfiles/Dockerfile.rpm — installs
    pyproject-rpm-macros opportunistically; reconstructs the empty
    %dist tag on openEuler images (.oe2403) so Release fields
    match official openEuler packages.
  • packaging/rpm/build-flagsparse-rpm.shBASE_IMAGE /
    BASE_IMAGE_VERSION / OUTPUT_DIR env overrides. The original
    single-arg Fedora flow (./build-flagsparse-rpm.sh 43) is
    preserved.
  • .github/workflows/build-rpm.yml — build matrix
    fedora43 + openeuler2403 (fail-fast: false). The Fedora
    artifact keeps its exact name (flagsparse-amd64-rpm-packages);
    openEuler uploads as flagsparse-amd64-oe2403-rpm-packages.

Tested

Both targets built locally via the modified script:

Target Artifact python(abi) Result
fedora43 (regression) python3-flagsparse-1.0.0-1.fc43.noarch.rpm 3.14 build unchanged vs main
openeuler2403 python3-flagsparse-1.0.0-1.oe2403.noarch.rpm 3.11 installs + imports on openeuler/openeuler:24.03-lts (/usr/lib/python3.11/site-packages/flagsparse/)

Limitations

  • openEuler artifact is not yet consumed downstream; the
    flagos-packaging collector/publisher will start routing .oe2403
    RPMs into the rpm/openeuler2403/ repo dir in a follow-up.
  • EL8-family distros would take the same pip fallback path but are
    not added to the matrix yet.

- flagsparse.spec: fall back to a pip-based build on distros without
  pyproject-rpm-macros (openEuler 24.03, EL8-family); the Fedora/EL9
  pyproject-macros path is unchanged.
- Dockerfile.rpm: install pyproject-rpm-macros opportunistically and
  reconstruct the empty %dist tag on openEuler images (.oe2403).
- build-flagsparse-rpm.sh: BASE_IMAGE/BASE_IMAGE_VERSION/OUTPUT_DIR
  env overrides; default single-arg Fedora flow preserved.
- build-rpm.yml: build matrix fedora43 + openeuler2403; the Fedora
  artifact name is unchanged for downstream collectors.

Verified locally: fedora43 build unchanged (python3-flagsparse-1.0.0-1.fc43,
python(abi)=3.14); openeuler2403 build installs and imports on an
openEuler 24.03 container (python3-flagsparse-1.0.0-1.oe2403,
python(abi)=3.11, /usr/lib/python3.11/site-packages).
…dnf layer

A separate RUN re-downloads all repo metadata after dnf clean all;
on slow openEuler mirrors from CI runners this costs tens of minutes
(observed 43 min for a failing install in FlagAttention's CI).
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.

1 participant