소스 검색

be more strict when searching `scan-build-*`

clang-9 brings `scan-build-py-9` which matched the old pattern
Steffen Jaeckel 6 년 전
부모
커밋
4458e91151
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      .ci/meta_builds.sh

+ 2 - 2
.ci/meta_builds.sh

@@ -53,8 +53,8 @@ function run_clang() {
    # output version
    # output version
    bash .ci/printinfo.sh
    bash .ci/printinfo.sh
 
 
-   scan_build=$(which scan-build)
-   [ -z "$scan_build" ] && scan_build=$(find /usr/bin/ -name 'scan-build-*' | sort -nr | head -n1) || true
+   scan_build=$(which scan-build) || true
+   [ -z "$scan_build" ] && scan_build=$(find /usr/bin/ -name 'scan-build-[0-9]*' | sort -nr | head -n1) || true
    [ -z "$scan_build" ] && { echo "couldn't find clang scan-build"; exit 1; } || echo "run $scan_build"
    [ -z "$scan_build" ] && { echo "couldn't find clang scan-build"; exit 1; } || echo "run $scan_build"
    $scan_build --status-bugs make -j$MAKE_JOBS all CFLAGS="$2 $CFLAGS $4" EXTRALIBS="$5"
    $scan_build --status-bugs make -j$MAKE_JOBS all CFLAGS="$2 $CFLAGS $4" EXTRALIBS="$5"