Skip to content

Commit 3c8c07a

Browse files
mbyxtgross35
authored andcommitted
libc: change ctest name to ctest-old
(backport <#4655>) (cherry picked from commit b185a13)
1 parent e3cae50 commit 3c8c07a

File tree

2 files changed

+10
-12
lines changed

2 files changed

+10
-12
lines changed

libc-test/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@ annotate-snippets = { version = "0.11.5", features = ["testing-colors"] }
2121
[build-dependencies]
2222
cc = "1.2.29"
2323
# FIXME: Use fork ctest until the maintainer gets back.
24-
ctest2 = "0.4.3"
24+
ctest-old = { version = "0.4.3", package = "ctest2" }
2525
# Use the in-tree `ctest` from the `main` branch via crates.io
26-
ctest_next = { version = "0.5.0-beta.0", package = "ctest" }
26+
ctest-next = { version = "0.5.0-beta.0", package = "ctest" }
2727
regex = "1.11.1"
2828

2929
[features]

libc-test/build.rs

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
#![deny(warnings)]
22
#![allow(clippy::match_like_matches_macro)]
33

4-
extern crate ctest2 as ctest;
5-
64
use std::fs::File;
75
use std::io::{BufRead, BufReader, BufWriter, Write};
86
use std::path::{Path, PathBuf};
@@ -75,8 +73,8 @@ fn do_ctest() {
7573
}
7674
}
7775

78-
fn ctest_cfg() -> ctest::TestGenerator {
79-
let mut cfg = ctest::TestGenerator::new();
76+
fn ctest_cfg() -> ctest_old::TestGenerator {
77+
let mut cfg = ctest_old::TestGenerator::new();
8078
let libc_cfgs = ["libc_thread_local"];
8179
for f in &libc_cfgs {
8280
cfg.cfg(f, None);
@@ -3479,7 +3477,7 @@ fn test_neutrino(target: &str) {
34793477
});
34803478

34813479
cfg.volatile_item(|i| {
3482-
use ctest::VolatileItemKind::*;
3480+
use ctest_old::VolatileItemKind::*;
34833481
match i {
34843482
// The following fields are volatie but since we cannot express that in
34853483
// Rust types, we have to explicitly tell the checker about it here:
@@ -3602,7 +3600,7 @@ fn test_neutrino(target: &str) {
36023600
fn test_vxworks(target: &str) {
36033601
assert!(target.contains("vxworks"));
36043602

3605-
let mut cfg = ctest::TestGenerator::new();
3603+
let mut cfg = ctest_old::TestGenerator::new();
36063604
headers! { cfg:
36073605
"vxWorks.h",
36083606
"yvals.h",
@@ -3705,7 +3703,7 @@ fn test_vxworks(target: &str) {
37053703
cfg.generate(src_hotfix_dir().join("lib.rs"), "ctest_output.rs");
37063704
}
37073705

3708-
fn config_gnu_bits(target: &str, cfg: &mut ctest::TestGenerator) {
3706+
fn config_gnu_bits(target: &str, cfg: &mut ctest_old::TestGenerator) {
37093707
let pointer_width = env::var("CARGO_CFG_TARGET_POINTER_WIDTH").unwrap_or_default();
37103708
if target.contains("gnu")
37113709
&& target.contains("linux")
@@ -4894,7 +4892,7 @@ fn test_linux(target: &str) {
48944892
});
48954893

48964894
cfg.volatile_item(|i| {
4897-
use ctest::VolatileItemKind::*;
4895+
use ctest_old::VolatileItemKind::*;
48984896
match i {
48994897
// aio_buf is a volatile void** but since we cannot express that in
49004898
// Rust types, we have to explicitly tell the checker about it here:
@@ -5215,7 +5213,7 @@ fn test_haiku(target: &str) {
52155213
cfg.flag("-Wno-deprecated-declarations");
52165214
cfg.define("__USE_GNU", Some("1"));
52175215
cfg.define("_GNU_SOURCE", None);
5218-
cfg.language(ctest::Lang::CXX);
5216+
cfg.language(ctest_old::Lang::CXX);
52195217

52205218
// POSIX API
52215219
headers! { cfg:
@@ -5835,7 +5833,7 @@ fn test_aix(target: &str) {
58355833
});
58365834

58375835
cfg.volatile_item(|i| {
5838-
use ctest::VolatileItemKind::*;
5836+
use ctest_old::VolatileItemKind::*;
58395837
match i {
58405838
// 'aio_buf' is of type 'volatile void**' but since we cannot
58415839
// express that in Rust types, we have to explicitly tell the

0 commit comments

Comments
 (0)