mirror of
https://github.com/pezkuwichain/wasm-instrument.git
synced 2026-10-30 23:49:56 +00:00
update layout for the rest
This commit is contained in:
1 parent
f326e46f5c
commit
fc5f5adf2a
13 files changed
+4
-45
No files matched your search
@@ -1,22 +0,0 @@
|
||||
extern crate parity_wasm;
|
||||
extern crate wasm_utils;
|
||||
|
||||
use std::env;
|
||||
|
||||
fn main() {
|
||||
|
||||
wasm_utils::init_log();
|
||||
|
||||
let args = env::args().collect::<Vec<_>>();
|
||||
if args.len() != 3 {
|
||||
println!("Usage: {} input_file.wasm output_file.wasm", args[0]);
|
||||
return;
|
||||
}
|
||||
|
||||
let module = wasm_utils::externalize(
|
||||
parity_wasm::deserialize_file(&args[1]).expect("Module to deserialize ok"),
|
||||
vec!["_free", "_malloc", "_memcpy", "_memset", "_memmove"],
|
||||
);
|
||||
|
||||
parity_wasm::serialize_to_file(&args[2], module).expect("Module to serialize ok");
|
||||
}
|
||||
Reference in new issue
Block a user