From d5c58ceec2aad7415bfb8d4cee1d98779535b615 Mon Sep 17 00:00:00 2001 From: "Yann E. MORIN" Date: Wed, 8 Feb 2017 21:15:25 +0100 Subject: support/test-pkg: store lines missing from resulting configuraiton When a build is skipped, store the lines from the config snippet, that are missing in the resulting configuration, in a file in the build directory, for the user to inspect. Signed-off-by: "Yann E. MORIN" Cc: Thomas Petazzoni Cc: Luca Ceresoli Cc: Thomas De Schampheleire Acked-by: Luca Ceresoli Tested-by: Luca Ceresoli Signed-off-by: Thomas Petazzoni --- support/scripts/test-pkg | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'support') diff --git a/support/scripts/test-pkg b/support/scripts/test-pkg index 008b32ca2..5eeaf63db 100755 --- a/support/scripts/test-pkg +++ b/support/scripts/test-pkg @@ -61,7 +61,7 @@ build_one() { local url="${2}" local cfg="${3}" local pkg="${4}" - local toolchain line + local toolchain line skip # Using basename(1) on a URL works nicely toolchain="$( basename "${url}" .config )" @@ -94,12 +94,19 @@ build_one() { # or not set) in the actual .config; if one of them is not, it means # some dependency from the toolchain or arch is not available, in # which case this config is untestable and we skip it. + skip=false while read line; do if ! grep "^${line}\$" "${dir}/.config" >/dev/null 2>&1; then - printf ", SKIPPED\n" - return + printf "%s\n" "${line}" + skip=true fi - done <"${cfg}" + done <"${cfg}" >"${dir}/missing.config" + if ${skip}; then + printf ", SKIPPED\n" + return + fi + # Remove file, it's empty anyway. + rm -f "${dir}/missing.config" if [ -n "${pkg}" ]; then printf ", dirclean" -- cgit v1.2.3