fix: declare missing RPC build dependencies - #90
Conversation
| Priority: optional | ||
| Maintainer: Mingze Li <limingze.jiayou@bytedance.com>; Guangbo Shu <shuguangbo@bytedance.com>; Nan Qi <qinan.cn@bytedance.com> | ||
| Build-Depends: autoconf, automake, tcl-dev, libncurses-dev | ||
| Build-Depends: autoconf, automake, tcl-dev, libncurses-dev, libtirpc-dev |
There was a problem hiding this comment.
Starting from version 2.32, glibc removed the built-in Sun RPC, which is now provided by the standalone libtirpc library. For Ubuntu:
Ubuntu | Version | glibc Version | xdr.h SourcePath
———————————————————————————————————————
20.04 and earlier |≤ 2.31 |libc6-dev |/usr/include/rpc/xdr.h
———————————————————————————————————————
21.10 / 22.04 / 24.04|≥ 2.34 |libtirpc-dev |/usr/include/tirpc/rpc/xdr.h
I think we need to consider compatibility both in low version and high Ubuntu version for libtirpc-dev. e.g. adding dependency checking in volcinstall.sh instead of here. Please let Mingze give more reviewing.
There was a problem hiding this comment.
Thanks, this is a good catch. I ran a clean Ubuntu 20.04/22.04/24.04 matrix to verify the boundary rather than assuming one dependency set works everywhere: https://github.com/ZedingZhang/volclava/actions/runs/33379130227
- 20.04 / glibc 2.31:
libc6-devowns/usr/include/rpc/xdr.h; configure, build, and tests pass withoutlibtirpc-dev. - 22.04 / glibc 2.35: the base toolchain currently pulls
libnsl-devandlibtirpc-devthroughlibc6-dev, so the build also passes without a direct addition here. - 24.04 / glibc 2.39: the base toolchain no longer provides either RPC header. Configure first fails on
rpc/xdr.h; adding onlylibtirpc-devthen fails on the requiredlibnslcheck; addinglibnsl-devas well completes configure,make, andmake check.
So I agree that an unconditional libtirpc-dev in debian/control is redundant for the supported 20.04 environment and incomplete for 24.04.
If DEB package builds remain 20.04-only, my proposed revision is to remove this Debian metadata change and update volcinstall.sh after installing the base Ubuntu development packages: when /usr/include/rpc/xdr.h is absent, install both libtirpc-dev and libnsl-dev. I would also limit both standalone RPM development packages to RHEL-family 8+ so CentOS 6/7 keep using their built-in interfaces.
If newer Ubuntu DEB build roots are intended to be supported too, the package recipe instead needs version-aware alternatives for both libtirpc and libnsl. I will wait for @limingze-ste's preference before changing the PR direction.
There was a problem hiding this comment.
I also prepared the installer-based revision on a separate validation branch and tested it before touching this PR: https://github.com/ZedingZhang/volclava/actions/runs/33379779430
All four jobs pass: Ubuntu 20.04 keeps the built-in RPC path without installing the standalone packages; 22.04 and 24.04 install/retain both required development packages and complete the build/tests; the RPM job verifies the dependencies are absent when the spec is evaluated as EL7, present on EL8, and completes the Rocky 8 build. The revision is ready to apply once the intended DEB support scope is confirmed.
Fixes #89.
Why
configure.acunconditionally requires the libtirpc headers and library, but neither package recipe declared the corresponding development package. A clean build root created from those recipes therefore cannot satisfy the configure checks.While validating the RPM change in a clean Rocky 8 container, configure advanced past libtirpc and exposed the same metadata drift for the required libnsl check.
volcinstall.shalready installslibnsl2-develon Rocky, but the RPM spec did not declare it.What changed
libtirpc-devto DebianBuild-Depends.libtirpc-develto RPMBuildRequires.libnsl2-develfor RHEL-family version 8 and newer, while keeping the existing CentOS 6/7 dependency set intact.Validation
Clean-container validation passed in both jobs:
debian/controlbuild dependencies, randpkg-checkbuilddeps,./bootstrap.sh,make -j2, andmake check.BuildRequires, then ran./bootstrap.sh,make -j2, andmake check.The validation commit used the exact final contents of
debian/controlandspec/volclava.spec; its temporary workflow is intentionally excluded from this PR.