Move abi-checker to y.rs test
This commit is contained in:
parent
e5ba71a71b
commit
7610be478f
5
.github/workflows/main.yml
vendored
5
.github/workflows/main.yml
vendored
@ -105,11 +105,6 @@ jobs:
|
||||
|
||||
./y.rs test
|
||||
|
||||
|
||||
- name: Run abi-checker
|
||||
if: matrix.env.TARGET_TRIPLE == ''
|
||||
run: ./y.rs abi-checker
|
||||
|
||||
- name: Package prebuilt cg_clif
|
||||
run: tar cvfJ cg_clif.tar.xz build
|
||||
|
||||
|
@ -1,4 +1,5 @@
|
||||
use super::build_sysroot;
|
||||
use super::config;
|
||||
use super::utils::spawn_and_wait_with_input;
|
||||
use build_system::SysrootKind;
|
||||
use std::env;
|
||||
@ -13,10 +14,15 @@ pub(crate) fn run(
|
||||
host_triple: &str,
|
||||
target_triple: &str,
|
||||
) {
|
||||
assert_eq!(
|
||||
host_triple, target_triple,
|
||||
"abi-checker not supported on cross-compilation scenarios"
|
||||
);
|
||||
if !config::get_bool("testsuite.abi-checker") {
|
||||
eprintln!("[SKIP] abi-checker");
|
||||
return;
|
||||
}
|
||||
|
||||
if host_triple != target_triple {
|
||||
eprintln!("[SKIP] abi-checker (cross-compilation not supported)");
|
||||
return;
|
||||
}
|
||||
|
||||
eprintln!("Building sysroot for abi-checker");
|
||||
build_sysroot::build_sysroot(
|
||||
|
@ -22,9 +22,6 @@ fn usage() {
|
||||
eprintln!(
|
||||
" ./y.rs test [--debug] [--sysroot none|clif|llvm] [--target-dir DIR] [--no-unstable-features]"
|
||||
);
|
||||
eprintln!(
|
||||
" ./y.rs abi-checker [--debug] [--sysroot none|clif|llvm] [--target-dir DIR] [--no-unstable-features]"
|
||||
);
|
||||
}
|
||||
|
||||
macro_rules! arg_error {
|
||||
@ -39,7 +36,6 @@ macro_rules! arg_error {
|
||||
enum Command {
|
||||
Build,
|
||||
Test,
|
||||
AbiChecker,
|
||||
}
|
||||
|
||||
#[derive(Copy, Clone, Debug)]
|
||||
@ -71,7 +67,6 @@ pub fn main() {
|
||||
}
|
||||
Some("build") => Command::Build,
|
||||
Some("test") => Command::Test,
|
||||
Some("abi-checker") => Command::AbiChecker,
|
||||
Some(flag) if flag.starts_with('-') => arg_error!("Expected command found flag {}", flag),
|
||||
Some(command) => arg_error!("Unknown command {}", command),
|
||||
None => {
|
||||
@ -147,6 +142,15 @@ pub fn main() {
|
||||
&host_triple,
|
||||
&target_triple,
|
||||
);
|
||||
|
||||
abi_checker::run(
|
||||
channel,
|
||||
sysroot_kind,
|
||||
&target_dir,
|
||||
&cg_clif_build_dir,
|
||||
&host_triple,
|
||||
&target_triple,
|
||||
);
|
||||
}
|
||||
Command::Build => {
|
||||
build_sysroot::build_sysroot(
|
||||
@ -158,15 +162,5 @@ pub fn main() {
|
||||
&target_triple,
|
||||
);
|
||||
}
|
||||
Command::AbiChecker => {
|
||||
abi_checker::run(
|
||||
channel,
|
||||
sysroot_kind,
|
||||
&target_dir,
|
||||
&cg_clif_build_dir,
|
||||
&host_triple,
|
||||
&target_triple,
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -48,3 +48,5 @@ test.libcore
|
||||
test.regex-shootout-regex-dna
|
||||
test.regex
|
||||
test.portable-simd
|
||||
|
||||
testsuite.abi-checker
|
||||
|
Loading…
x
Reference in New Issue
Block a user