-
Notifications
You must be signed in to change notification settings - Fork 6
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
Add a vendored
feature that uses a vendored copy
#4
Conversation
The `probe` function was introduced to replace `find` in version 0.3.7.
Make the pregenerated and compile-time cases more alike.
This avoids problems with linker that keeping C code and Rust bindings to it causes.
This makes it possible to drop the pkg-config hack as it turns out to be needed only for unit tests.
Not fully tested, but at least the build script seems to compile.
The libftdi1 API is defined in a cross-platform way and should just work on new platforms. This feature may still be desired for cases like building against a newer libftdi version.
@cr1901 / @roqvist, would be cool if one of you could test whether everything still works on Windows as I don't have the corresponding development environment at hand. By "everything" here I mean all the supported feature configurations: none, vendored, bindgen. The combination of bindgen and vendored does not work (as in "bindgen is compiled, but not used"). Ideally one should test both that examples do compile and that tests do pass. |
Alternatively I'm going to make a few more textual cleanups and merge this anyway with the intention of adding CI later. |
@tanriol I'll test this within the next few hours. Yesterday, I was trying to create a draft for unifying |
@tanriol My guess is that with the
Additionally, if you're choosing not to publish the |
This is just a temporary setting - I don't have much experience with
That's one of the problems I was afraid of. Any other ideas how to avoid duplication? Sure, we can just copy files, but that feels a bit wrong... |
I don't see how we get around copying files. However, to still get the benefits of code reuse, we could use
I haven't fully thought out this idea yet, but it could be completely feasible to make Rust think the |
Ok, so I've thought about this and I don't see a good way to do this. The options I see are:
Your opinions? P.S. Would be nice if you could check the suggested clone command - for me just |
Seems up in the air how well |
P.P.S. Also looks like the |
That is beyond the scope of what a With that said, if a user is going to build using a local copy of libftdi, they should have prerequisite packages ahead of time. I would have to see the exact error you're getting to diagnose further; I don't see any indication as to whether vcpkg |
Vcpkg |
Anyway, I'm getting tired of this problem, so, unless we can make good progress in the next day or two, I'll just release 1.0.0 without the |
I seem to vaguely recall this is a long-standing bug with
That is fine with me, tbh. I'm happy to revisit later if it comes up and do a release tonight. Please make sure to merge #3 before releasing |
Closed in favor of #5. |
Note that this feature requires splitting the crate in two to separate permissively licensed bindings and LGPL sources so that the crate licenses correctly match the content.