Make netfilter constants available for musl Linux targets #2152
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The netfilter constants added in #911 and #926 are currently only available for Linux targets using glibc because they weren't available in the musl-sanitized kernel headers at the time these PRs were made.
With current versions of the sanitized headers, these constants are available, and this PR moves them to
unix/linux_like/linux/mod.rs
so that they can be used on targets using musl libc.The kernel header version currently set in
ci/install_musl.sh
already supports these constants, but has different values for e.g.NFT_TABLE_MAXNAMELEN
than the ones that were already defined for glibc. It seems like the maximum name length for various netfilter objects has been changed in the kernel (the respective commits are 1 2 3 and 4). To match these values with the ones that were already defined, this PR also updates the used kernel header version inci/install_musl.sh
.