File tree Expand file tree Collapse file tree 2 files changed +9
-4
lines changed Expand file tree Collapse file tree 2 files changed +9
-4
lines changed Original file line number Diff line number Diff line change 28
28
cargo_quiet =--verbose
29
29
endif
30
30
31
+ alloc-cfgs = \
32
+ --cfg no_global_oom_handling \
33
+ --cfg no_rc \
34
+ --cfg no_sync
35
+
31
36
quiet_cmd_rustdoc = RUSTDOC $(if $(rustdoc_host ) ,H, ) $<
32
37
cmd_rustdoc = \
33
38
OBJTREE=$(abspath $(objtree ) ) \
@@ -62,7 +67,7 @@ rustdoc-compiler_builtins: $(srctree)/rust/compiler_builtins.rs rustdoc-core FOR
62
67
# `no_global_oom_handling` functions refer to non-`no_global_oom_handling`
63
68
# functions. Ideally `rustdoc` would have a way to distinguish broken links
64
69
# due to things that are "configured out" vs. entirely non-existing ones.
65
- rustdoc-alloc : private rustc_target_flags = --cfg no_global_oom_handling \
70
+ rustdoc-alloc : private rustc_target_flags = $( alloc-cfgs ) \
66
71
-Abroken_intra_doc_links
67
72
rustdoc-alloc : $(srctree ) /rust/alloc/lib.rs rustdoc-core \
68
73
rustdoc-compiler_builtins FORCE
@@ -304,7 +309,7 @@ $(objtree)/rust/compiler_builtins.o: $(srctree)/rust/compiler_builtins.rs \
304
309
$(call if_changed_dep,rustc_library)
305
310
306
311
$(objtree ) /rust/alloc.o : private skip_clippy = 1
307
- $(objtree ) /rust/alloc.o : private rustc_target_flags = --cfg no_global_oom_handling
312
+ $(objtree ) /rust/alloc.o : private rustc_target_flags = $( alloc-cfgs )
308
313
$(objtree ) /rust/alloc.o : $(srctree ) /rust/alloc/lib.rs \
309
314
$(objtree)/rust/compiler_builtins.o FORCE
310
315
$(call if_changed_dep,rustc_library)
Original file line number Diff line number Diff line change @@ -180,12 +180,12 @@ pub mod collections;
180
180
pub mod fmt;
181
181
pub mod prelude;
182
182
pub mod raw_vec;
183
- #[ cfg( not( CONFIG_RUST ) ) ]
183
+ #[ cfg( not( no_rc ) ) ]
184
184
pub mod rc;
185
185
pub mod slice;
186
186
pub mod str;
187
187
pub mod string;
188
- #[ cfg( all( target_has_atomic = "ptr" , not ( CONFIG_RUST ) ) ) ]
188
+ #[ cfg( all( not ( no_sync ) , target_has_atomic = "ptr" ) ) ]
189
189
pub mod sync;
190
190
#[ cfg( all( not( no_global_oom_handling) , target_has_atomic = "ptr" ) ) ]
191
191
pub mod task;
You can’t perform that action at this time.
0 commit comments