1#!/bin/sh -eux 2 3# Copyright (c) 2022 Yubico AB. All rights reserved. 4# Use of this source code is governed by a BSD-style 5# license that can be found in the LICENSE file. 6# SPDX-License-Identifier: BSD-2-Clause 7 8${CC} --version 9SCAN=scan-build${CC#clang} 10 11# Check exports. 12(cd src && ./diff_exports.sh) 13 14# Build, analyze, and install libfido2. 15for T in Debug Release; do 16 mkdir build-$T 17 (cd build-$T && ${SCAN} --use-cc="${CC}" cmake -DCMAKE_BUILD_TYPE=$T ..) 18 ${SCAN} --use-cc="${CC}" --status-bugs make -j"$(nproc)" -C build-$T 19 make -C build-$T regress 20 sudo make -C build-$T install 21done 22