Skip to content

getdeps: select EL-specific manifest sections by distro_family - #496

Open
michel-slm wants to merge 1 commit into
facebook:mainfrom
michel-slm:getdeps-el-family-selectors
Open

michel-slm wants to merge 1 commit into
facebook:mainfrom
michel-slm:getdeps-el-family-selectors

Conversation

@michel-slm

Copy link
Copy Markdown
Contributor

The manifests that mean "any Enterprise Linux 9" (or 8) spell it as distro=centos_stream, because CentOS Stream is what CI runs. That never matched AlmaLinux or Rocky, and after the previous change gave RHEL its own distro name it would not match RHEL either. The most consequential case is cachelib's gcc-toolset-14: without it an EL 9 build uses the default GCC 11 and fails to compile C++20 code although the toolset is right there in the repositories.

Rewrite those sections with the distro_family variable introduced in the previous change, preserving each selector's meaning while extending it to the whole family:

- all(distro=centos_stream,distro_vers=9)  -> all(distro_family=rhel,distro_vers=9)
  cachelib, gcc12, gcc14, openr, python, python-setuptools,
  rebalancer, rebalancer-explorer
- all(distro=centos_stream,distro_vers=8)  -> all(distro_family=rhel,distro_vers=8)
  boost, boost-python
- not(all(any(distro=centos_stream,distro=centos),distro_vers=8))
                                            -> not(all(distro_family=rhel,distro_vers=8))
  libmnl
- not(any(all(distro=centos,distro_vers=8),all(distro=centos_stream,distro_vers=9)))
                                            -> not(all(distro_family=rhel,any(distro_vers=8,distro_vers=9)))
  lz4, lz4-python
- rpms.any(distro=centos_stream,...,distro=fedora) -> rpms
  libaio, numa (every rpm distro ships libaio-devel and numactl-devel)
- rpms.distro=centos_stream                -> rpms.distro_family=rhel
  libaio-python

"centos" was the old CentOS Linux 8 name and folds into the family. No manifest still selects on an individual EL distro name.

This must land after the distro_family change: the expression parser rejects unknown selector variables, so on a getdeps without it these manifests fail to load.

Tested with both changes applied: every manifest passes validate-manifest, and install-system-deps --recursive --dry-run --os-type linux --distro rhel --distro-version 9 cachelib now yields the same package set as --distro centos_stream, including gcc-toolset-14, libaio-devel and numactl-devel, where before it lacked all three. The openr, rebalancer and rebalancer-explorer hunks are the same mechanical rewrite but those projects were not built here.

Depends on #495 (distro_family): must land after it, since the expression parser rejects unknown selector variables. Submitted separately so each can be reviewed on its own; the two are otherwise independent of #494.

🤖 Generated with Claude Code

The manifests that mean "any Enterprise Linux 9" (or 8) spell it as
distro=centos_stream, because CentOS Stream is what CI runs. That never
matched AlmaLinux or Rocky, and after the previous change gave RHEL its
own distro name it would not match RHEL either. The most consequential
case is cachelib's gcc-toolset-14: without it an EL 9 build uses the
default GCC 11 and fails to compile C++20 code although the toolset is
right there in the repositories.

Rewrite those sections with the distro_family variable introduced in
the previous change, preserving each selector's meaning while extending
it to the whole family:

- all(distro=centos_stream,distro_vers=9)  -> all(distro_family=rhel,distro_vers=9)
  cachelib, gcc12, gcc14, openr, python, python-setuptools,
  rebalancer, rebalancer-explorer
- all(distro=centos_stream,distro_vers=8)  -> all(distro_family=rhel,distro_vers=8)
  boost, boost-python
- not(all(any(distro=centos_stream,distro=centos),distro_vers=8))
                                            -> not(all(distro_family=rhel,distro_vers=8))
  libmnl
- not(any(all(distro=centos,distro_vers=8),all(distro=centos_stream,distro_vers=9)))
                                            -> not(all(distro_family=rhel,any(distro_vers=8,distro_vers=9)))
  lz4, lz4-python
- rpms.any(distro=centos_stream,...,distro=fedora) -> rpms
  libaio, numa (every rpm distro ships libaio-devel and numactl-devel)
- rpms.distro=centos_stream                -> rpms.distro_family=rhel
  libaio-python

"centos" was the old CentOS Linux 8 name and folds into the family.
No manifest still selects on an individual EL distro name.

This must land after the distro_family change: the expression parser
rejects unknown selector variables, so on a getdeps without it these
manifests fail to load.

Tested with both changes applied: every manifest passes
validate-manifest, and `install-system-deps --recursive --dry-run
--os-type linux --distro rhel --distro-version 9 cachelib` now yields
the same package set as --distro centos_stream, including
gcc-toolset-14, libaio-devel and numactl-devel, where before it lacked
all three. The openr, rebalancer and rebalancer-explorer hunks are
the same mechanical rewrite but those projects were not built here.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Signed-off-by: Michel Lind <salimma@fedoraproject.org>
@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Sep 17, 2026
@meta-codesync

meta-codesync Bot commented Sep 17, 2026

Copy link
Copy Markdown
Contributor

@michel-slm has imported this pull request. If you are a Meta employee, you can view this in D120501944.

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

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant