@@ -98,6 +98,8 @@ const EXTRA_CHECK_CFGS: &[(Option<Mode>, &str, Option<&[&'static str]>)] = &[
9898 /* Extra values not defined in the built-in targets yet, but used in std */
9999 ( Some ( Mode :: Std ) , "target_env" , Some ( & [ "libnx" ] ) ) ,
100100 // (Some(Mode::Std), "target_os", Some(&[])),
101+ ( Some ( Mode :: Std ) , "target_os" , Some ( & [ "zkvm" ] ) ) ,
102+ ( Some ( Mode :: Std ) , "target_vendor" , Some ( & [ "risc0" ] ) ) ,
101103 ( Some ( Mode :: Std ) , "target_arch" , Some ( & [ "asmjs" , "spirv" , "nvptx" , "xtensa" ] ) ) ,
102104 /* Extra names used by dependencies */
103105 // FIXME: Used by serde_json, but we should not be triggering on external dependencies.
@@ -729,6 +731,11 @@ impl Build {
729731 if self . config . profiler_enabled ( target) {
730732 features. push_str ( " profiler" ) ;
731733 }
734+ // Generate memcpy, etc. FIXME: Remove this once compiler-builtins
735+ // automatically detects this target.
736+ if target. contains ( "zkvm" ) {
737+ features. push_str ( " compiler-builtins-mem" ) ;
738+ }
732739 features
733740 }
734741
0 commit comments