Fix ARM compilation: vendor libhackrf with c_char portability fix
The upstream libhackrf v0.1.1 crate fails to compile on ARM because c_char is u8 on ARM (not i8 like on x86). The transmute at lib.rs:102 explicitly casts &[i8] -> &[u8], but on ARM the source is already &[u8], causing a type mismatch. Vendored the crate at vendor/libhackrf/ with the transmute replaced by slice::from_raw_parts with a pointer cast, which works on both architectures. Also cleaned up transmute calls in transfer.rs. Fixes #1
This commit is contained in:
Generated
-2
@@ -482,8 +482,6 @@ checksum = "bcc35a38544a891a5f7c865aca548a982ccb3b8650a5b06d0fd33a10283c56fc"
|
||||
[[package]]
|
||||
name = "libhackrf"
|
||||
version = "0.1.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "e640122f67f490129cd3ab1517149b4091eeca0a14de3df7510626df258196b9"
|
||||
dependencies = [
|
||||
"num-complex",
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user