Arm compatibility#23
Conversation
- Fix compilation error - Handle arm triplets package config checks
| } | ||
| } | ||
|
|
||
| impl<'a> TryFrom<Slice<'a, c_char>> for &'a str { |
There was a problem hiding this comment.
Here is the error I was facing
error[E0119]: conflicting implementations of trait std::convert::TryFrom<Slice<'_, u8>> for type &str:
--> ddprof-ffi/src/lib.rs:198:1
|
189 | impl<'a> TryFrom<Slice<'a, u8>> for &'a str {
| ------------------------------------------- first implementation here
...
198 | impl<'a> TryFrom<Slice<'a, c_char>> for &'a str {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation for &str
There was a problem hiding this comment.
You read my mind. I think these two tactical change are sufficient since ARM uses unsigned char.
| # images, so -static-libgcc is recommended there. | ||
| case "$target" in | ||
| "x86_64-alpine-linux-musl") | ||
| "x86_64-alpine-linux-musl"|"aarch64-alpine-linux-musl") |
There was a problem hiding this comment.
I agree that Linux is sufficiently general in terms of the x86 and ARM builds that handling both in the same section is appropriate.
What does this PR do?
Fix compilation error
c_char can be several types depending on platform.
Handle arm64 triplets package config checks
co-authored with @sanchda
Motivation
Delivering on ARM platforms
Additional Notes
None
How to test the change?
The downstream PR is available to test these changes