Closed nlfiedler closed 6 years ago
Uh, bindgen 0.42 hasn't been released yet, right? I'm not going mad, am I?
It has, I did that after #1410. The only difference between bindgen 0.41 and 0.42 in that test is the clang-sys version.
The new clang-sys version includes https://github.com/KyleMayes/clang-sys/commit/cc11523200e7372bebbf2ac9552ddb78afc3f853, which is likely to be the culprit, cc @KyleMayes.
Closing as "not a bindgen bug", filed https://github.com/KyleMayes/clang-sys/issues/83 for this. If this is very severe we could consider revert the clang-sys upgrade for now, just let me know.
Uh, bindgen 0.42 hasn't been released yet, right? I'm not going mad, am I?
I just checked and I forgot to tag it, should be fixed now, sorry :)
This one is on me...
I removed searching for versioned libraries matching the pattern libclang.so.*
(e.g., libclang.so.1
) in v0.24.0
because I thought that adding it originally must have been a mistake because ld
can't link to libraries with filenames like libclang.so.1
.
However:
a) On BSD distributions, dynamic libraries are versioned like this: libclang.so.7.0
(fixed in v0.25.0
)
b) On Linux distributions, while ld
can't link to libclang.so.1
, libloading
can (fixed in v0.26.0
)
I have published v0.26.0
which enables linking to versioned libraries matching the pattern libclang.so.*
on Linux only when the runtime
feature is enabled.
I have tested this version with the magick-rust
Docker container and it works (though there is an error in the generated Rust code, but that shouldn't have anything to do with clang-sys
).
Thanks for the quick turnaround! I updated it in #1415.
Gentlemen,
in my test, I still get this same error.
Using docker as build environment I cannot get bindgen to work.
The project I am trying to build is: github.com/redbeardlab/redisql While the image I am using is: siscia/x86_64-unknown-linux-gnu2.14:1-error-bindgen
I am trying to build the image using cross
Cheers, Simone
Update, the problem seems to be cross
and not bindgen.
Using this repo (https://github.com/nlfiedler/magick-rust/) to compile bindings for ImageMagick has been working pretty well for a while. Was using bindgen 0.29, then tried to update to 0.42 today. That was relatively painless and builds fine on macOS, but the build fails using the latest official Docker image for rust (https://hub.docker.com/_/rust/). Versions of bindgen between 0.32 and 0.41 result in voluminous (different) compiler errors, while only 0.42 errors out as seen here:
For now, sticking with bindgen 0.31 as that is working without any issue.
Just to be absolutely clear, the only thing changing is the version of bindgen in the project's
Cargo.toml
; the docker image is the same. Also note that versions 0.29, 0.31, and 0.42 all build fine on macOS. This appears to be specific to 0.42 and the Linux-based docker image.