-
Notifications
You must be signed in to change notification settings - Fork 113
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
Bug: error: linking with cc
failed: exit status: 1 in rust crate
#378
Comments
Interesting, which compiler are you using, @ShelbyJenkins? If there is a minimal test case you can submit as a PR, that would really help prioritize this patch 🤗 |
from /workspaces/test/target/debug/build/usearch-d165d1039b6b3263/output Details
cargo:CXXBRIDGE_PREFIX=usearch exit status: 1 exit status: 1 exit status: 1 exit status: 1 exit status: 1 I also tried to clone the repo and compile it and that gave a ton of errors, but I didn't thinnk to save them. Usearch previously worked for me, so IDK what's going on. |
If you are trying to compile locally - you should pull dependencies:
See I'll look deeper into your logs and will try to reproduce. |
There seem to be two problems here:
|
That's actually why I was trying to compile locally - I noticed the sub module was not in the crate. So if you pull the submodules and try to build it resolves that issue of simsimd not being found, but it still doesn't build correctly. Sorry I forgot to mention that last night. |
Gotcha! @ShelbyJenkins and @embe-pw if you have a PR to add files to the crate - I am ready to merge 🤗 Can you please share the build errors as well? I suspect you are using an older compiler. Thanks! |
@ashvardanian sorry, I don't have the build logs from trying to build with the repos cloned. No PR from me. This is WAY above my pay grade :) FWIW, I tried with both the latest clang and g++ libs. |
# [2.11.0](v2.10.5...v2.11.0) (2024-04-08) ### Add * `b1x8` for Rust ([540fc75](540fc75)) * `filtered_search` API in C & C++ ([5bb38aa](5bb38aa)) * `filtered_search` in Rust ([e1b24e1](e1b24e1)) * Hyper-param configs in C ([c7ed1d4](c7ed1d4)) * Metadata extraction in C ([2c698cd](2c698cd)) ### Docs * Guides for Rust and C ([fe05ad8](fe05ad8)) ### Fix * `-Wdeprecated-this-capture` (#387) ([a233e20](a233e20)), closes [#387](#387) * Explicit capture ([208e383](208e383)) * Filter the entry point in the 0 layer ([4ff568b](4ff568b)) * JS imports & Doxygen (#384) ([7356158](7356158)), closes [#384](#384) * More adequate default Rust params ([c4f9e65](c4f9e65)) ### Improve * `metric_punned_t` static methods ([220ef57](220ef57)) ### Make * Configure Rust compilation options ([32c9f3b](32c9f3b)), closes [#378](#378) * Include sources in Crates ([0d414e4](0d414e4))
🎉 This issue has been resolved in version 2.11.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
@ashvardanian happy to see this! Sadly, with i'm still unable to build with or without SIMD. Build error for included below. Let me know if there are any other tests or logs I can get that would be helpful for you. Build logerror: linking with = note: some error: could not compile |
One new problem is that $ tar xvf ~/.cargo/registry/cache/index.crates.io-6f17d22bba15001f/usearch-2.11.0.crate
usearch-2.11.0/.cargo_vcs_info.json
usearch-2.11.0/Cargo.toml
usearch-2.11.0/Cargo.toml.orig
usearch-2.11.0/README.md
usearch-2.11.0/fp16/include/fp16/__init__.py
usearch-2.11.0/fp16/include/fp16/avx.py
usearch-2.11.0/fp16/include/fp16/avx2.py
usearch-2.11.0/fp16/include/fp16/bitcasts.h
usearch-2.11.0/fp16/include/fp16/fp16.h
usearch-2.11.0/fp16/include/fp16/psimd.h
usearch-2.11.0/fp16/include/fp16.h
usearch-2.11.0/include/usearch/index.hpp
usearch-2.11.0/include/usearch/index_dense.hpp
usearch-2.11.0/include/usearch/index_plugins.hpp
usearch-2.11.0/rust/README.md
usearch-2.11.0/rust/lib.cpp
usearch-2.11.0/rust/lib.hpp
usearch-2.11.0/rust/lib.rs (it probably needs to be added to Also, note that |
@embe-pw that’s quite weird. Yes, I didn’t specify build.rs in Cargo.toml, but simsimd/* should be there 🤷♂️ |
Indeed, @embe-pw and @ShelbyJenkins, even with the most recent build the issue persists, but you don't have to download the crate to check that: $ cargo package --list --allow-dirty
Cargo.toml
Cargo.toml.orig
README.md
build.rs
fp16/include/fp16/__init__.py
fp16/include/fp16/avx.py
fp16/include/fp16/avx2.py
fp16/include/fp16/bitcasts.h
fp16/include/fp16/fp16.h
fp16/include/fp16/psimd.h
fp16/include/fp16.h
include/usearch/index.hpp
include/usearch/index_dense.hpp
include/usearch/index_plugins.hpp
rust/README.md
rust/lib.cpp
rust/lib.hpp
rust/lib.rs I have tried changing a few things listed in the docs, but no result as of now. Here is what my "includes" look like now: include = [
"/rust/**",
"/include/**",
"/fp16/include/**",
"/simsimd/include/**",
"/stringzilla/include/**",
"/build.rs",
] Will keep poking! |
Another hour wasted. Help needed ✋ |
Relates to #378. but doesn't fix it
To quote the docs:
You should depend on those other crates instead of inlining them in this one. That will also help prevent weird symbol mismatches. |
🎉 This issue has been resolved in version 2.11.2 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
I'll try it in the morning if it's pushed to crates registry! |
Hi @ShelbyJenkins! Is it working fine for you now? |
It is! Thank you. The only blocker for using in my project is lack of filtering, but that's a me problem and not a usearch problem :D |
@ShelbyJenkins filtering is supported, or do you mean something different from existing functionality? |
Yes, sorry. Metadata filtering - specifically date filtering. I know I could implement it myself, but I couldn't think of an efficient way to do so! No problem though, Usearch works great for some tasks. |
Describe the bug
It builds, but upon running it errors.
Steps to reproduce
Running in a container.
Expected behavior
To run.
USearch version
2.10.3
Operating System
Ubuntu 22.04
Hardware architecture
x86
Which interface are you using?
Other bindings
Contact Details
No response
Is there an existing issue for this?
Code of Conduct
The text was updated successfully, but these errors were encountered: