Skip to content

Commit a5915a5

Browse files
committed
add fix for full tools and sanitizer
1 parent 34d898a commit a5915a5

File tree

3 files changed

+21
-19
lines changed

3 files changed

+21
-19
lines changed

Cargo.lock

Lines changed: 5 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -2178,20 +2178,6 @@ dependencies = [
21782178
"smallvec",
21792179
]
21802180

2181-
[[package]]
2182-
name = "measureme"
2183-
version = "12.0.1"
2184-
source = "registry+https://github.com/rust-lang/crates.io-index"
2185-
checksum = "570a507d8948a66a97f42cbbaf8a6bb9516a51017d4ee949502ad7a10a864395"
2186-
dependencies = [
2187-
"log",
2188-
"memmap2",
2189-
"parking_lot",
2190-
"perf-event-open-sys",
2191-
"rustc-hash 1.1.0",
2192-
"smallvec",
2193-
]
2194-
21952181
[[package]]
21962182
name = "memchr"
21972183
version = "2.7.4"
@@ -2275,7 +2261,7 @@ dependencies = [
22752261
"libc",
22762262
"libffi",
22772263
"libloading",
2278-
"measureme 11.0.1",
2264+
"measureme",
22792265
"rand 0.9.0",
22802266
"regex",
22812267
"rustc_version",
@@ -3379,7 +3365,7 @@ dependencies = [
33793365
"gimli 0.30.0",
33803366
"itertools",
33813367
"libc",
3382-
"measureme 12.0.1",
3368+
"measureme",
33833369
"object 0.36.7",
33843370
"rustc-demangle",
33853371
"rustc_abi",
@@ -3497,7 +3483,7 @@ dependencies = [
34973483
"indexmap",
34983484
"jobserver",
34993485
"libc",
3500-
"measureme 12.0.1",
3486+
"measureme",
35013487
"memmap2",
35023488
"parking_lot",
35033489
"portable-atomic",
@@ -4262,7 +4248,8 @@ dependencies = [
42624248
name = "rustc_query_impl"
42634249
version = "0.0.0"
42644250
dependencies = [
4265-
"measureme 12.0.1",
4251+
"measureme",
4252+
"rustc_attr_data_structures",
42664253
"rustc_data_structures",
42674254
"rustc_errors",
42684255
"rustc_hashes",

src/bootstrap/src/core/build_steps/llvm.rs

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -814,6 +814,10 @@ fn configure_cmake(
814814
cflags.push(s);
815815
}
816816

817+
if target.contains("ohos") {
818+
cflags.push(" -D_LINUX_SYSINFO_H");
819+
}
820+
817821
if builder.config.llvm_clang_cl.is_some() {
818822
cflags.push(format!(" --target={target}"));
819823
}
@@ -834,6 +838,11 @@ fn configure_cmake(
834838
cxxflags.push(" ");
835839
cxxflags.push(s);
836840
}
841+
842+
if target.contains("ohos") {
843+
cxxflags.push(" -D_LINUX_SYSINFO_H");
844+
}
845+
837846
if builder.config.llvm_clang_cl.is_some() {
838847
cxxflags.push(format!(" --target={target}"));
839848
}
@@ -1220,6 +1229,10 @@ impl Step for Sanitizers {
12201229
cfg.define("COMPILER_RT_USE_LIBCXX", "OFF");
12211230
cfg.define("LLVM_CONFIG_PATH", &llvm_config);
12221231

1232+
if self.target.contains("ohos") {
1233+
cfg.define("COMPILER_RT_USE_BUILTINS_LIBRARY", "ON");
1234+
}
1235+
12231236
// On Darwin targets the sanitizer runtimes are build as universal binaries.
12241237
// Unfortunately sccache currently lacks support to build them successfully.
12251238
// Disable compiler launcher on Darwin targets to avoid potential issues.

src/ci/docker/host-x86_64/dist-ohos/Dockerfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,9 @@ ENV \
6060

6161
ENV RUST_CONFIGURE_ARGS \
6262
--enable-profiler \
63-
--disable-docs
63+
--disable-docs \
64+
--tools=cargo,clippy,rustdocs,rustfmt,analysis,src,wasm-component-ld \
65+
--enable-extended
6466

6567
ENV SCRIPT python3 ../x.py dist --host=$TARGETS --target $TARGETS
6668

0 commit comments

Comments
 (0)