-
Notifications
You must be signed in to change notification settings - Fork 721
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
tracing-journald fix for #1698 fails to build on glibc < 2.27 #1879
Comments
cc @lunaryorn, @Ralith i'm not sure what the best way to handle compatibility with earlier glibc versions is in Rust. possibly a build script to detect the glibc version and set a cfg flag to enable/disable the |
alternatively, i suppose we could just make the system call ourselves rather than depending on it from libc... |
I'm sorry that my changes broke things, but I would not like contribute to fixing this, to be honest. The OP mentions RHEL 7, Ubuntu Xenial, and Debian Stretch. Stretch is end of live, Ubuntu Xenial is in ESM (i.e. you've got to pay for support), and RHEL is flat out enterprise. Whoever uses those distributions works in some kind of commercial enterprise environment, and should definitely have funding and resources to fix things on their own or contract it out for good money, instead of trying to get the community to fix it for free. The OP can just pin to 0.2.0 which is as good as trying to Edit: I'm willing to review any merge requests to tracing-journald of course 🙂 |
I agree that pinning is a reasonable solution to this, though I'd be willing to review a PR to invoke |
I'm from one of those enterprise environments interested in patching this to invoke (Pinning 0.2.0 doesn't work because I need to set the syslog identifier, introduced in 0.2.1.) EDIT: Wait, I think I found the syscall table, nvm. |
Fixes #1879 ## Motivation `journald-tracing>=0.2.1` doesn't build with old glibc. ## Solution Make the `memfd_create` syscall ourselves. cc @lunaryorn @Ralith
Fixes #1879 ## Motivation `journald-tracing>=0.2.1` doesn't build with old glibc. ## Solution Make the `memfd_create` syscall ourselves. cc @lunaryorn @Ralith
Fixes #1879 ## Motivation `journald-tracing>=0.2.1` doesn't build with old glibc. ## Solution Make the `memfd_create` syscall ourselves. cc @lunaryorn @Ralith
Bug Report
Building tracing-journald 0.2.2 on Ubuntu Xenial (supported until 2024), Debian Stretch (supported until June 2022) or RHEL 7 (supported until 2024) fails with
in function `tracing_journald::memfd::create': ... github.com-1ecc6299db9ec823/tracing-journald-0.2.2/src/memfd.rs:11: undefined reference to `memfd_create'
.This syscall was introduced in Linux 3.17 (in 2014, safely out of LTS), but only exposed by glibc in 2.27 (released in Feb 2018). Unfortunately,
libc
(used by #1744) just calls out to glibc for this Linux extension, instead of directly invoking asyscall(2)
stub, which would always link and returnENOSYS
on very old kernels.Version
Platform
Ubuntu Xenial, Debian Stretch, RHEL 7, on x86-64.
Crates
tracing-journald >= 0.2.1
Description
I try to build a crate that depends on
tracing-journald
. Linking fails because no one definesmemfd_create
. Pinning to0.2.0
restores the build.The text was updated successfully, but these errors were encountered: