mirror of https://github.com/ndarilek/tts-rs.git
temporary fix to a build issue with the crate speech-dispatcher
This commit is contained in:
parent
8c8dc0ae9f
commit
008662c940
|
@ -8,6 +8,15 @@ license = "MIT"
|
||||||
exclude = ["*.cfg", "*.yml"]
|
exclude = ["*.cfg", "*.yml"]
|
||||||
edition = "2018"
|
edition = "2018"
|
||||||
|
|
||||||
|
[package.metadata.patch.speech-dispatcher]
|
||||||
|
version = "0.7.0"
|
||||||
|
patches = [
|
||||||
|
"speech-dispatcher.patch"
|
||||||
|
]
|
||||||
|
|
||||||
|
[patch.crates-io]
|
||||||
|
speech-dispatcher = { path = './target/patch/speech-dispatcher-0.7.0'}
|
||||||
|
|
||||||
[lib]
|
[lib]
|
||||||
crate-type = ["lib", "cdylib", "staticlib"]
|
crate-type = ["lib", "cdylib", "staticlib"]
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,22 @@
|
||||||
|
diff --git src/lib.rs src/lib.rs
|
||||||
|
index 26ba271..180513e 100644
|
||||||
|
--- src/lib.rs
|
||||||
|
+++ src/lib.rs
|
||||||
|
@@ -127,7 +127,7 @@ unsafe extern "C" fn cb(msg_id: u64, client_id: u64, state: u32) {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
-unsafe extern "C" fn cb_im(msg_id: u64, client_id: u64, state: u32, index_mark: *mut i8) {
|
||||||
|
+unsafe extern "C" fn cb_im(msg_id: u64, client_id: u64, state: u32, index_mark: *mut u8) {
|
||||||
|
let index_mark = CStr::from_ptr(index_mark);
|
||||||
|
let index_mark = index_mark.to_string_lossy().to_string();
|
||||||
|
let state = match state {
|
||||||
|
@@ -325,7 +325,7 @@ impl Connection {
|
||||||
|
i32_to_bool(v)
|
||||||
|
}
|
||||||
|
|
||||||
|
- pub fn wchar(&self, priority: Priority, wchar: i32) -> bool {
|
||||||
|
+ pub fn wchar(&self, priority: Priority, wchar: u32) -> bool {
|
||||||
|
let v = unsafe { spd_wchar(self.0, priority as u32, wchar) };
|
||||||
|
i32_to_bool(v)
|
||||||
|
}
|
Loading…
Reference in New Issue