File tree 4 files changed +12
-9
lines changed 4 files changed +12
-9
lines changed Original file line number Diff line number Diff line change 6
6
7
7
;; Global Variables
8
8
(global (export #__stack_pointer) (id 0) (type i32) (const 0))
9
- (global (export #gv1) (id 1) (type i32) (const 0))
10
- (global (export #gv2) (id 2) (type i32) (const 0))
11
9
12
10
;; Functions
13
11
(func (export #fib) (param i32) (result i32)
Original file line number Diff line number Diff line change 30
30
)
31
31
(memory (;0;) 16 )
32
32
(global $__stack_pointer (;0;) (mut i32 ) i32.const 1048576 )
33
- (global (;1;) i32 i32.const 1048576 )
34
- (global (;2;) i32 i32.const 1048576 )
35
33
(export " memory" (memory 0 ))
36
34
(export " fib" (func $fib ))
37
- (export " __data_end" (global 1 ))
38
- (export " __heap_base" (global 2 ))
39
35
)
Original file line number Diff line number Diff line change @@ -251,14 +251,23 @@ impl ProjectBuilder {
251
251
}
252
252
253
253
fn skip_rust_compilation ( & self , artifact_name : & str ) -> bool {
254
- let computed_artifact_path = self
254
+ let artifact_path_wasm32_wasi = self
255
+ . root ( )
256
+ . join ( "target" )
257
+ . join ( "wasm32-wasip1" )
258
+ . join ( "release" )
259
+ . join ( artifact_name)
260
+ . with_extension ( "wasm" ) ;
261
+ let artifact_path_wasm32_unknown = self
255
262
. root ( )
256
263
. join ( "target" )
257
264
. join ( "wasm32-unknown-unknown" )
258
265
. join ( "release" )
259
266
. join ( artifact_name)
260
267
. with_extension ( "wasm" ) ;
261
- if std:: env:: var ( "SKIP_RUST" ) . is_ok ( ) && computed_artifact_path. exists ( ) {
268
+ let artifact_exists =
269
+ artifact_path_wasm32_unknown. exists ( ) || artifact_path_wasm32_wasi. exists ( ) ;
270
+ if std:: env:: var ( "SKIP_RUST" ) . is_ok ( ) && ( artifact_exists) {
262
271
eprintln ! ( "Skipping Rust compilation" ) ;
263
272
true
264
273
} else {
Original file line number Diff line number Diff line change @@ -629,7 +629,7 @@ impl CompilerTestBuilder {
629
629
let config = CargoTest :: new ( artifact_name, project_dir)
630
630
. with_build_alloc ( true )
631
631
. with_target_dir ( target_dir)
632
- . with_target ( "wasm32-unknown-unknown " )
632
+ . with_target ( "wasm32-wasip1 " )
633
633
. with_entrypoint ( entrypoint) ;
634
634
CompilerTestBuilder :: new ( config)
635
635
}
You can’t perform that action at this time.
0 commit comments