From: Ramakrishnan Muthukrishnan <ram@rkrishnan.org>
Date: Wed, 8 Mar 2023 13:40:41 +0000 (+0530)
Subject: rust: misc
X-Git-Url: https://git.rkrishnan.org/listings/COPYING.TGPPL.html?a=commitdiff_plain;h=refs%2Fheads%2Frustification;p=pihpsdr.git

rust: misc
---

diff --git a/hpsdrsim.c b/hpsdrsim.c
index cbcc943..5ff85bb 100644
--- a/hpsdrsim.c
+++ b/hpsdrsim.c
@@ -518,7 +518,7 @@ int main(int argc, char *argv[])
 			udp_retries=0;
 		}
 		if (bytes_read <= 0) continue;
-			memcpy(&code, buffer, 4);
+                memcpy(&code, buffer, 4);
 
 			switch (code)
 			{
diff --git a/rust/Cargo.toml b/rust/Cargo.toml
index 0060b33..453e46a 100644
--- a/rust/Cargo.toml
+++ b/rust/Cargo.toml
@@ -7,10 +7,14 @@ authors = ["Ramakrishnan Muthukrishnan <ram@rkrishnan.org>"]
 [dependencies]
 libc = "0.2"
 cbindgen = "0.24.3"
+binary-layout = "3.1.3"
 
 [lib]
 name = "hpsdr"
 crate-type = ["staticlib"]
 
+[[bin]]
+name = "hpsdrsim-rs"
+path = "cmd/hpsdrsim.rs"
 [build-dependencies]
 cbindgen = "0.20.0"