From 7c548dd52a8e46d1605c769c81f0c64439d66e76 Mon Sep 17 00:00:00 2001 From: FondMemoryVVV Date: Tue, 13 Sep 2022 14:54:49 +0800 Subject: [PATCH] Modify the format Signed-off-by: FondMemoryVVV --- commonlibrary/toolchain/BUILD.gn | 61 ++++++++++++++----- commonlibrary/toolchain/libc-test/Test.json | 2 +- .../toolchain/libc-test/src/toolchaintest.cpp | 4 +- 3 files changed, 50 insertions(+), 17 deletions(-) diff --git a/commonlibrary/toolchain/BUILD.gn b/commonlibrary/toolchain/BUILD.gn index a264d7ac7..be6736db5 100644 --- a/commonlibrary/toolchain/BUILD.gn +++ b/commonlibrary/toolchain/BUILD.gn @@ -71,20 +71,53 @@ action("tar_dllib") { script = rebase_path( "//test/xts/acts/commonlibrary/toolchain/libc-test/tar_files.py") - _outputs = [ "$target_out_dir/libc-test-lib.tar" ] - outputs = _outputs + if (target_cpu == "arm") { + _outputs = [ "$target_out_dir/libc-test-lib.tar" ] + outputs = _outputs - input_path = rebase_path("$dllib_path/musl/libc-test-lib") - output_path = - rebase_path("$dllib_path/suites/acts/testcases/libc-test-lib.tar") + input_path = rebase_path("$dllib_path/musl/libc-test-lib") + output_path = + rebase_path("$dllib_path/suites/acts/testcases/libc-test-lib.tar") - print("root_build_dir-49", root_build_dir) - args = [ - "--input_path", - input_path, - "--output_path", - output_path, - "--temp_path", - "./libc-test-lib", - ] + print("root_build_dir-49", root_build_dir) + args = [ + "--input_path", + input_path, + "--output_path", + output_path, + "--temp_path", + "./libc-test-lib", + ] + } else if (target_cpu == "arm64") { + _outputs = [ "$target_out_dir/libc-test-lib.tar" ] + outputs = _outputs + + input_path = rebase_path("$dllib_path/musl/libc-test-lib") + output_path = + rebase_path("$dllib_path/suites/acts/testcases/libc-test-lib.tar") + print("root_build_dir-49", root_build_dir) + args = [ + "--input_path", + input_path, + "--output_path", + output_path, + "--temp_path", + "./libc-test-lib", + ] + } else { + _outputs = [ "" ] + outputs = _outputs + + input_path = rebase_path("") + output_path = rebase_path("") + print("root_build_dir-49", root_build_dir) + args = [ + "--input_path", + input_path, + "--output_path", + output_path, + "--temp_path", + "./libc-test-lib", + ] + } } diff --git a/commonlibrary/toolchain/libc-test/Test.json b/commonlibrary/toolchain/libc-test/Test.json index ef7ff7f47..5cb7392de 100755 --- a/commonlibrary/toolchain/libc-test/Test.json +++ b/commonlibrary/toolchain/libc-test/Test.json @@ -23,7 +23,7 @@ "native-test-timeout": "120000", "type": "CppTest", "module-name": "ActToolChainTest", - "runtime-hint": "1s", + "runtime-hint": "100s", "native-test-device-path": "/data/local/tmp" }, "description": "Configuration for ActToolChainTest Tests" diff --git a/commonlibrary/toolchain/libc-test/src/toolchaintest.cpp b/commonlibrary/toolchain/libc-test/src/toolchaintest.cpp index d660bf042..abbc43adf 100644 --- a/commonlibrary/toolchain/libc-test/src/toolchaintest.cpp +++ b/commonlibrary/toolchain/libc-test/src/toolchaintest.cpp @@ -104,8 +104,8 @@ static int runTests(const char *argvs) return -1; } //Process state - if (WIFEXITED(status)) { - if (WEXITSTATUS(status) == 0) { + if (WIFEXITED(status)) { //The right exit + if (WEXITSTATUS(status) == 0) { //operate successfully return t_status; } printf("FAIL %s [status %d]\n", argvs, WEXITSTATUS(status)); -- GitLab