Skip to content

Commit 7395229

Browse files
committed
docs: update README and build documentation for Windows support limitations
fix: adjust bridge FFI implementation for Windows compatibility fix: modify Cargo.toml to conditionally include bridge dependency fix: enhance error handling in bridge FFI for unsupported Windows operations refactor: update crypto module to use correct Wots imports refactor: improve BridgeClient to handle null checks and hex encoding test: skip integration tests on Windows due to bridge limitations test: enhance unit tests to handle native availability checks
1 parent 0204af4 commit 7395229

16 files changed

Lines changed: 373 additions & 58 deletions

File tree

README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,13 +84,24 @@ PonziTech.BitVM.Bridge - Bridge operations (peg-in/peg-out graphs)
8484

8585
## Supported Platforms
8686

87+
**Core (script execution + crypto):**
8788
| Platform | Architecture | Status |
8889
|----------|--------------|--------|
8990
| Windows | x64 | ✅ Supported |
9091
| Linux | x64 | ✅ Supported |
9192
| macOS | x64 | ✅ Supported |
9293
| macOS | ARM64 | ✅ Supported |
9394

95+
**Bridge (peg-in/peg-out operations):**
96+
| Platform | Architecture | Status |
97+
|----------|--------------|--------|
98+
| Windows | x64 | ❌ Not supported (see note below) |
99+
| Linux | x64 | ✅ Supported |
100+
| macOS | x64 | ✅ Supported |
101+
| macOS | ARM64 | ✅ Supported |
102+
103+
**Note:** The bridge Rust crate depends on unix-only SSH/SFTP components upstream. On Windows, the bridge FFI exports are present but return an error stating that bridge support is unavailable. Use WSL/Linux for bridge workflows.
104+
94105
## Building from Source
95106

96107
### Prerequisites

STATUS.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ The repository now provides working BitVM core bindings (script execution, hashi
3535
- Peg-out graphs and flows are not yet exposed in the C# API.
3636
- Peg-in status calls require Esplora connectivity (provide `BridgeConfiguration.EsploraUrl` or rely on defaults).
3737
- Peg-in graphs are stored as raw JSON for round-tripping; only top-level metadata is parsed into managed fields.
38+
- Bridge functionality is not supported on Windows due to upstream unix-only SSH/SFTP dependencies.
3839

3940
---
4041

docs/WINDOWS_BUILD.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@
22

33
This document details all dependencies required to build PonziTech.BitVM on Windows.
44

5+
## Windows Support Scope
6+
7+
- **Core library** (script execution + cryptographic primitives): ✅ supported on Windows.
8+
- **Bridge library** (peg-in/peg-out operations): ❌ not supported on Windows due to upstream unix-only SSH/SFTP dependencies.
9+
- **Workaround**: Use WSL/Linux to build and run bridge workflows.
10+
511
## Required Dependencies
612

713
### 1. .NET 10.0 SDK

ffi/Cargo.toml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ crate-type = ["cdylib", "staticlib"]
99
[dependencies]
1010
# Core BitVM library (platform-agnostic)
1111
bitvm = { path = "../external/BitVM/bitvm" }
12-
bridge = { path = "../external/BitVM/bridge" }
1312

1413
# Bitcoin primitives
1514
bitcoin = { version = "0.32.5", features = ["std"] }
@@ -20,7 +19,6 @@ hex = "0.4"
2019
rand = "0.8"
2120
serde = { version = "1.0", features = ["derive"] }
2221
serde_json = "1.0"
23-
tokio = { version = "1.37.0", features = ["rt-multi-thread"] }
2422

2523
# FFI bindings generator
2624
safer-ffi = { version = "0.1", features = ["proc_macros"] }
@@ -32,4 +30,7 @@ csbindgen = "1.0"
3230
[target.'cfg(windows)'.dependencies]
3331

3432
# Unix-specific dependencies (not used on Windows)
35-
[target.'cfg(unix)'.dependencies]
33+
[target.'cfg(not(windows))'.dependencies]
34+
bridge = { path = "../external/BitVM/bridge" }
35+
esplora-client = { git = "https://github.com/BitVM/rust-esplora-client" }
36+
tokio = { version = "1.37.0", features = ["rt-multi-thread"] }

0 commit comments

Comments
 (0)