Cargo.toml 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. [package]
  2. name = "srt-win"
  3. version = "0.0.1"
  4. edition = "2024"
  5. publish = false
  6. description = "Windows network sandbox helper for sandbox-runtime"
  7. [lib]
  8. name = "srt_win"
  9. path = "src/lib.rs"
  10. [[bin]]
  11. name = "srt-win"
  12. path = "src/main.rs"
  13. [target.'cfg(windows)'.dependencies]
  14. anyhow = "1"
  15. clap = { version = "4", features = ["derive"] }
  16. serde = { version = "1", features = ["derive"] }
  17. serde_json = "1"
  18. windows = { version = "0.62.2", features = [
  19. "Wdk_Foundation",
  20. "Wdk_Storage_FileSystem",
  21. "Win32_Foundation",
  22. "Win32_System_RemoteDesktop",
  23. "Win32_System_Threading",
  24. "Win32_System_Memory",
  25. "Win32_System_Rpc",
  26. "Win32_System_SystemServices",
  27. "Win32_System_JobObjects",
  28. "Win32_System_StationsAndDesktops",
  29. "Win32_System_Console",
  30. "Win32_System_IO",
  31. "Win32_System_Pipes",
  32. "Win32_Graphics_Gdi",
  33. "Win32_Security",
  34. "Win32_Security_Authorization",
  35. "Win32_Security_Authentication_Identity",
  36. "Win32_Security_Cryptography",
  37. "Win32_Storage_FileSystem",
  38. "Win32_NetworkManagement_WindowsFilteringPlatform",
  39. "Win32_NetworkManagement_NetManagement",
  40. "Win32_UI_Shell",
  41. "Win32_UI_WindowsAndMessaging",
  42. "Win32_System_Registry",
  43. ] }
  44. # `bundled` compiles the sqlite3 amalgamation via `cc` — works on the
  45. # Windows runner (MSVC). NOTE: `cargo check --target …-windows-msvc`
  46. # from a non-Windows host fails at the libsqlite3-sys build script
  47. # (no MSVC toolchain) unless CC/AR are stubbed. The whole library
  48. # (including the clap/serde-derive CLI structs in `cli.rs`) is
  49. # `#![cfg(windows)]`, so a host-target `cargo check` on macOS/Linux
  50. # compiles only the four-line `main.rs` shim — cross-target clippy
  51. # (stubbed CC/AR) is the ONLY local gate that compiles the
  52. # clap-derive structs.
  53. rusqlite = { version = "0.32", features = ["bundled"] }
  54. [profile.release]
  55. opt-level = 2
  56. lto = "thin"
  57. codegen-units = 1
  58. strip = "symbols"