File tree Expand file tree Collapse file tree 4 files changed +17
-7
lines changed
Expand file tree Collapse file tree 4 files changed +17
-7
lines changed Original file line number Diff line number Diff line change @@ -205,7 +205,8 @@ webc_runner_rt_dproxy = [
205205 " tower-http" ,
206206 " journal" ,
207207]
208-
208+ # the minimal sys implementation
209+ sys-minimal = [" wasmer/sys" , " sys-thread" , " tokio/fs" ]
209210sys = [
210211 " webc/mmap" ,
211212 " time" ,
Original file line number Diff line number Diff line change 1414//! [WASI plugin example](https://github.com/wasmerio/wasmer/blob/main/examples/plugin.rs)
1515//! for an example of how to extend WASI using the WASI FS API.
1616
17- #[ cfg( all( not( feature = "sys" ) , not( feature = "js" ) ) ) ]
18- compile_error ! ( "At least the `sys` or the `js` feature must be enabled. Please, pick one." ) ;
17+ #[ cfg( all(
18+ not( feature = "sys" ) ,
19+ not( feature = "js" ) ,
20+ not( feature = "sys-minimal" )
21+ ) ) ]
22+ compile_error ! (
23+ "At least the `sys` or the `js` or `sys-minimal` feature must be enabled. Please, pick one."
24+ ) ;
1925
20- #[ cfg( all( feature = "sys" , feature = "js" ) ) ]
26+ #[ cfg( any(
27+ all( feature = "js" , feature = "sys" ) ,
28+ all( feature = "js" , feature = "sys-minimal" )
29+ ) ) ]
2130compile_error ! (
22- "Cannot have both `sys` and `js` features enabled at the same time. Please, pick one."
31+ "Cannot have both `sys` and `js` or `sys-minimal` and `sys` features enabled at the same time. Please, pick one."
2332) ;
2433
2534#[ cfg( all( feature = "sys" , target_arch = "wasm32" ) ) ]
Original file line number Diff line number Diff line change 11mod global;
22mod thread_local;
33
4- #[ cfg( feature = "sys" ) ]
4+ #[ cfg( any ( feature = "sys" , feature = "sys-minimal" ) ) ]
55pub ( crate ) use global:: * ;
66#[ cfg( feature = "js" ) ]
77pub ( crate ) use thread_local:: * ;
Original file line number Diff line number Diff line change 1- #![ cfg_attr( feature = "sys" , allow( unused) ) ]
1+ #![ cfg_attr( any ( feature = "sys" , feature = "sys-minimal" ) , allow( unused) ) ]
22use std:: cell:: { Ref , RefCell , RefMut } ;
33use std:: ops:: { Deref , DerefMut } ;
44use std:: {
You can’t perform that action at this time.
0 commit comments