@validators-dao/solana-entry-decoder 2.0.1 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +10 -0
- package/dist/index.darwin-arm64.node +0 -0
- package/dist/index.darwin-x64.node +0 -0
- package/dist/index.linux-arm64-gnu.node +0 -0
- package/dist/index.linux-x64-gnu.node +0 -0
- package/package.json +10 -7
- package/.cargo/config.toml +0 -18
- package/Cargo.toml +0 -18
- package/index.darwin-arm64.node +0 -0
- package/index.linux-arm64-gnu.node +0 -0
- package/index.linux-x64-gnu.node +0 -0
- package/index.node +0 -0
- package/src/lib.rs +0 -14
- /package/{index.d.ts → dist/index.d.ts} +0 -0
- /package/{index.js → dist/index.js} +0 -0
package/README.md
CHANGED
|
@@ -115,6 +115,16 @@ brew install x86_64-unknown-linux-gnu aarch64-unknown-linux-gnu zig
|
|
|
115
115
|
|
|
116
116
|
For now please use WSL2 and follow the Linux instructions.
|
|
117
117
|
|
|
118
|
+
## Build packages
|
|
119
|
+
|
|
120
|
+
```bash
|
|
121
|
+
pnpm i
|
|
122
|
+
pnpm build
|
|
123
|
+
|
|
124
|
+
// or from the root of the monorepo
|
|
125
|
+
pnpm -F @validators-dao/solana-entry-decoder build
|
|
126
|
+
```
|
|
127
|
+
|
|
118
128
|
## Repository
|
|
119
129
|
|
|
120
130
|
This utility is part of the [Solana Stream Monorepo](https://github.com/ValidatorsDAO/solana-stream).
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@validators-dao/solana-entry-decoder",
|
|
3
3
|
"description": "Decoding Solana Shreds Entry Data",
|
|
4
|
-
"version": "2.0
|
|
4
|
+
"version": "2.1.0",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
|
-
"main": "index.js",
|
|
7
|
-
"types": "index.d.ts",
|
|
6
|
+
"main": "dist/index.js",
|
|
7
|
+
"types": "dist/index.d.ts",
|
|
8
8
|
"repository": {
|
|
9
9
|
"type": "git",
|
|
10
10
|
"url": "https://github.com/ValidatorsDAO/solana-stream.git"
|
|
@@ -14,6 +14,9 @@
|
|
|
14
14
|
"npm": "please_use_pnpm_instead",
|
|
15
15
|
"node": "22"
|
|
16
16
|
},
|
|
17
|
+
"files": [
|
|
18
|
+
"dist"
|
|
19
|
+
],
|
|
17
20
|
"bugs": {
|
|
18
21
|
"url": "https://discord.gg/C7ZQSrCkYR"
|
|
19
22
|
},
|
|
@@ -22,10 +25,10 @@
|
|
|
22
25
|
"npm-run-all": "4.1.5"
|
|
23
26
|
},
|
|
24
27
|
"scripts": {
|
|
25
|
-
"build:linux:x64": "OPENSSL_STATIC=1 PKG_CONFIG_ALLOW_CROSS=1 napi build --platform --release --target x86_64-unknown-linux-gnu --zig",
|
|
26
|
-
"build:linux:arm64": "OPENSSL_STATIC=1 PKG_CONFIG_ALLOW_CROSS=1 napi build --platform --release --target aarch64-unknown-linux-gnu --zig",
|
|
27
|
-
"build:mac:x64": "OPENSSL_DIR=$(brew --prefix openssl@3) OPENSSL_LIB_DIR=$(brew --prefix openssl@3)/lib OPENSSL_INCLUDE_DIR=$(brew --prefix openssl@3)/include arch -x86_64 napi build --release --target x86_64-apple-darwin",
|
|
28
|
-
"build:mac:arm64": "napi build --release --target aarch64-apple-darwin",
|
|
28
|
+
"build:linux:x64": "OPENSSL_STATIC=1 PKG_CONFIG_ALLOW_CROSS=1 napi build --platform --release --target x86_64-unknown-linux-gnu --zig dist",
|
|
29
|
+
"build:linux:arm64": "OPENSSL_STATIC=1 PKG_CONFIG_ALLOW_CROSS=1 napi build --platform --release --target aarch64-unknown-linux-gnu --zig dist",
|
|
30
|
+
"build:mac:x64": "OPENSSL_DIR=$(brew --prefix openssl@3) OPENSSL_LIB_DIR=$(brew --prefix openssl@3)/lib OPENSSL_INCLUDE_DIR=$(brew --prefix openssl@3)/include arch -x86_64 napi build --release --platform --target x86_64-apple-darwin dist",
|
|
31
|
+
"build:mac:arm64": "napi build --release --platform --target aarch64-apple-darwin dist",
|
|
29
32
|
"build:all": "npm-run-all --parallel build:linux:x64 build:linux:arm64 build:mac:arm64 build:mac:x64",
|
|
30
33
|
"build": "pnpm run build:all",
|
|
31
34
|
"build:debug": "napi build"
|
package/.cargo/config.toml
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
[target.aarch64-apple-darwin]
|
|
2
|
-
rustflags = [
|
|
3
|
-
"-C", "link-arg=-undefined",
|
|
4
|
-
"-C", "link-arg=dynamic_lookup"
|
|
5
|
-
]
|
|
6
|
-
|
|
7
|
-
[target.x86_64-apple-darwin]
|
|
8
|
-
rustflags = [
|
|
9
|
-
"-C", "link-arg=-undefined",
|
|
10
|
-
"-C", "link-arg=dynamic_lookup"
|
|
11
|
-
]
|
|
12
|
-
|
|
13
|
-
[target.x86_64-unknown-linux-gnu]
|
|
14
|
-
linker = "x86_64-linux-gnu-gcc"
|
|
15
|
-
|
|
16
|
-
[target.aarch64-unknown-linux-gnu]
|
|
17
|
-
linker = "aarch64-linux-gnu-gcc"
|
|
18
|
-
|
package/Cargo.toml
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
[package]
|
|
2
|
-
name = "solana-entry-decoder"
|
|
3
|
-
version.workspace = true
|
|
4
|
-
description.workspace = true
|
|
5
|
-
authors.workspace = true
|
|
6
|
-
homepage.workspace = true
|
|
7
|
-
edition.workspace = true
|
|
8
|
-
|
|
9
|
-
[lib]
|
|
10
|
-
crate-type = ["cdylib"]
|
|
11
|
-
|
|
12
|
-
[dependencies]
|
|
13
|
-
solana-entry = {version = "=2.2.1"}
|
|
14
|
-
bincode = "1.3"
|
|
15
|
-
napi = { version = "2.15.0", default-features = false, features = ["napi4", "serde-json"] }
|
|
16
|
-
napi-derive = "2.15.0"
|
|
17
|
-
serde = { version = "1", features = ["derive"] }
|
|
18
|
-
serde_json = "1.0"
|
package/index.darwin-arm64.node
DELETED
|
Binary file
|
|
Binary file
|
package/index.linux-x64-gnu.node
DELETED
|
Binary file
|
package/index.node
DELETED
|
Binary file
|
package/src/lib.rs
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
use napi::bindgen_prelude::*;
|
|
2
|
-
use napi_derive::napi;
|
|
3
|
-
use solana_entry::entry::Entry;
|
|
4
|
-
|
|
5
|
-
#[napi]
|
|
6
|
-
#[allow(dead_code)]
|
|
7
|
-
fn decode_solana_entries(data: Buffer) -> napi::Result<serde_json::Value> {
|
|
8
|
-
let entries: Vec<Entry> = bincode::deserialize(data.as_ref())
|
|
9
|
-
.map_err(|e| Error::from_reason(format!("Deserialize failed: {}", e)))?;
|
|
10
|
-
|
|
11
|
-
let json = serde_json::to_value(&entries)
|
|
12
|
-
.map_err(|e| Error::from_reason(format!("JSON conversion failed: {}", e)))?;
|
|
13
|
-
Ok(json)
|
|
14
|
-
}
|
|
File without changes
|
|
File without changes
|