Docker images for compiling static Rust binaries using musl-libc and musl-gcc, with static versions of useful C libraries. Supports openssl and diesel crates.
Apache License 2.0
1.54k
stars
193
forks
source link
Unable to use native netlink library from libc crate? #61
Attempting to a compile a crate that has a dependency on the netstat library which uses the native netlink API causes a bunch of errors like:
error[E0412]: cannot find type `nlmsghdr` in this scope
error[E0425]: cannot find value `NETLINK_INET_DIAG` in this scope
error[E0063]: missing fields `__pad1`, `__pad2` in initializer of `libc::msghdr`
Which leads me to believe that parts of the libc crate are not being linked in correctly? Trying to understand this issue.
As it turns out, musl-libc doesn't define the NETLINK_INET_DIAG and other constants used in the netstat-rs library. This isn't an issue with the builder here but with the crate itself. Closing!
Attempting to a compile a crate that has a dependency on the netstat library which uses the native
netlink
API causes a bunch of errors like:Which leads me to believe that parts of the
libc
crate are not being linked in correctly? Trying to understand this issue.