File tree Expand file tree Collapse file tree 2 files changed +1
-4
lines changed Expand file tree Collapse file tree 2 files changed +1
-4
lines changed Original file line number Diff line number Diff line change @@ -322,7 +322,7 @@ impl SDKBuilder<'_> {
322
322
println ! ( "cargo:rustc-env=API_LEVEL={}" , self . api_level) ;
323
323
println ! ( "cargo:warning=API_LEVEL is {}" , self . api_level) ;
324
324
}
325
- None => Err ( SDKBuildError :: InvalidAPILevel ) ,
325
+ None => return Err ( SDKBuildError :: InvalidAPILevel ) ,
326
326
}
327
327
328
328
// Export other SDK infos into env for 'infos.rs'
Original file line number Diff line number Diff line change @@ -17,7 +17,6 @@ macro_rules! const_cstr {
17
17
} ;
18
18
}
19
19
20
- #[ cfg( not( target_os = "nanos" ) ) ]
21
20
const fn const_parse_api_level ( x : & str ) -> u8 {
22
21
let a = x. as_bytes ( ) ;
23
22
let mut res = a[ 0 ] - b'0' ;
@@ -32,11 +31,9 @@ const fn const_parse_api_level(x: &str) -> u8 {
32
31
33
32
/// Expose the API_LEVEL
34
33
#[ used]
35
- #[ cfg( not( target_os = "nanos" ) ) ]
36
34
static API_LEVEL : u8 = const_parse_api_level ( env ! ( "API_LEVEL" ) ) ;
37
35
38
36
// Store metadata in the ELF file
39
- #[ cfg( not( target_os = "nanos" ) ) ]
40
37
const_cstr ! ( ELF_API_LEVEL , "ledger.api_level" , env!( "API_LEVEL" ) ) ;
41
38
42
39
const_cstr ! ( ELF_TARGET , "ledger.target" , env!( "TARGET" ) ) ;
You can’t perform that action at this time.
0 commit comments