-
Notifications
You must be signed in to change notification settings - Fork 26
allow string.c to be disabled when it conflicts with other libs #15
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
base: main
Are you sure you want to change the base?
allow string.c to be disabled when it conflicts with other libs #15
Conversation
|
Having features that disable code is somewhat counter-intuitive for me. But I’m not sure if a positive feature that enables |
|
I have no preference - as long as there is control as to where these functions come from. |
|
From the Cargo book
Another solution would be to expect the user to always bring their own implementation. This is only matters for embedded so it's not shocking. |
Thats fine too. One can always use to bridge the gap. |
|
I don’t see |
|
Your correct :-( |
|
In that case I would vote for keeping the functions in |
|
That works for me. |
|
I'll open an issue on |
|
|
|
I would still keep a feature flag that brings in |
There are other crates that are based on C libs and define various functions like
strchr. This PR adds a feature that when enabled does not compilestring.cand expects some external source to provide the functions within.I ran into this issue with the current (unreleased)
esp-wifithat when combined with littlefs2 fails to link becausestrchris multiply defined.When combining crates that do this one can disable
string.cand if needed add this to fill in any functions that are still missing: