mirror of
https://github.com/fluencelabs/wasmer
synced 2024-12-04 18:10:18 +00:00
Add skeleton of exported api
This commit is contained in:
parent
9829d97d7d
commit
d8bd258ef2
8
Cargo.lock
generated
8
Cargo.lock
generated
@ -1842,6 +1842,13 @@ dependencies = [
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "wasmer"
|
name = "wasmer"
|
||||||
version = "0.16.2"
|
version = "0.16.2"
|
||||||
|
dependencies = [
|
||||||
|
"wasmer-runtime-core",
|
||||||
|
]
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "wasmer-bin"
|
||||||
|
version = "0.16.2"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"atty",
|
"atty",
|
||||||
"byteorder",
|
"byteorder",
|
||||||
@ -1854,6 +1861,7 @@ dependencies = [
|
|||||||
"structopt",
|
"structopt",
|
||||||
"typetag",
|
"typetag",
|
||||||
"wabt",
|
"wabt",
|
||||||
|
"wasmer",
|
||||||
"wasmer-clif-backend",
|
"wasmer-clif-backend",
|
||||||
"wasmer-dev-utils",
|
"wasmer-dev-utils",
|
||||||
"wasmer-emscripten",
|
"wasmer-emscripten",
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "wasmer"
|
name = "wasmer-bin"
|
||||||
version = "0.16.2"
|
version = "0.16.2"
|
||||||
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
|
authors = ["The Wasmer Engineering Team <engineering@wasmer.io>"]
|
||||||
edition = "2018"
|
edition = "2018"
|
||||||
@ -27,6 +27,7 @@ fern = { version = "0.5", features = ["colored"], optional = true }
|
|||||||
log = "0.4"
|
log = "0.4"
|
||||||
structopt = "0.3"
|
structopt = "0.3"
|
||||||
wabt = { version = "0.9.1", optional = true }
|
wabt = { version = "0.9.1", optional = true }
|
||||||
|
wasmer = { path = "lib/api" }
|
||||||
wasmer-clif-backend = { path = "lib/clif-backend", optional = true }
|
wasmer-clif-backend = { path = "lib/clif-backend", optional = true }
|
||||||
wasmer-singlepass-backend = { path = "lib/singlepass-backend", optional = true }
|
wasmer-singlepass-backend = { path = "lib/singlepass-backend", optional = true }
|
||||||
wasmer-middleware-common = { path = "lib/middleware-common" }
|
wasmer-middleware-common = { path = "lib/middleware-common" }
|
||||||
@ -44,6 +45,7 @@ wasmer-wasi-experimental-io-devices = { path = "lib/wasi-experimental-io-devices
|
|||||||
|
|
||||||
[workspace]
|
[workspace]
|
||||||
members = [
|
members = [
|
||||||
|
"lib/api",
|
||||||
"lib/clif-backend",
|
"lib/clif-backend",
|
||||||
"lib/singlepass-backend",
|
"lib/singlepass-backend",
|
||||||
"lib/runtime",
|
"lib/runtime",
|
||||||
|
@ -2,13 +2,13 @@
|
|||||||
#[macro_use]
|
#[macro_use]
|
||||||
extern crate libfuzzer_sys;
|
extern crate libfuzzer_sys;
|
||||||
|
|
||||||
extern crate wasmer;
|
extern crate wasmer_bin;
|
||||||
extern crate wasmer_runtime_core;
|
extern crate wasmer_runtime_core;
|
||||||
|
|
||||||
use wasmer_runtime_core::backend::Features;
|
use wasmer_runtime_core::backend::Features;
|
||||||
|
|
||||||
fuzz_target!(|data: &[u8]| {
|
fuzz_target!(|data: &[u8]| {
|
||||||
let _ = wasmer::utils::is_wasm_binary(data);
|
let _ = wasmer_bin::utils::is_wasm_binary(data);
|
||||||
let _ = wasmer_runtime_core::validate_and_report_errors_with_features(
|
let _ = wasmer_runtime_core::validate_and_report_errors_with_features(
|
||||||
&data,
|
&data,
|
||||||
Features {
|
Features {
|
||||||
|
@ -50,7 +50,7 @@ fn handle_client(mut stream: UnixStream) {
|
|||||||
let mut wasm_binary: Vec<u8> = Vec::with_capacity(binary_size as usize);
|
let mut wasm_binary: Vec<u8> = Vec::with_capacity(binary_size as usize);
|
||||||
unsafe { wasm_binary.set_len(binary_size as usize) };
|
unsafe { wasm_binary.set_len(binary_size as usize) };
|
||||||
stream.read_exact(&mut wasm_binary).unwrap();
|
stream.read_exact(&mut wasm_binary).unwrap();
|
||||||
use wasmer::webassembly;
|
use wasmer_bin::webassembly;
|
||||||
use wasmer_runtime_core::{
|
use wasmer_runtime_core::{
|
||||||
backend::{CompilerConfig, MemoryBoundCheckMode},
|
backend::{CompilerConfig, MemoryBoundCheckMode},
|
||||||
loader::Instance,
|
loader::Instance,
|
||||||
|
@ -22,7 +22,7 @@ use std::str::FromStr;
|
|||||||
|
|
||||||
use structopt::{clap, StructOpt};
|
use structopt::{clap, StructOpt};
|
||||||
|
|
||||||
use wasmer::*;
|
use wasmer_bin::*;
|
||||||
#[cfg(feature = "backend-cranelift")]
|
#[cfg(feature = "backend-cranelift")]
|
||||||
use wasmer_clif_backend::CraneliftCompiler;
|
use wasmer_clif_backend::CraneliftCompiler;
|
||||||
#[cfg(feature = "backend-llvm")]
|
#[cfg(feature = "backend-llvm")]
|
||||||
|
Loading…
Reference in New Issue
Block a user