#!/bin/sh set -e # Install development tools. dnf install \ --setopt=install_weak_deps=False \ --setopt=fastestmirror=True \ --setopt=max_parallel_downloads=10 \ -y \ $(grep '^[^#]\+$' /root/iwyu_packages.lst) cd /root git clone "https://github.com/include-what-you-use/include-what-you-use.git" cd include-what-you-use readonly llvm_full_version="$( clang --version | head -n1 | cut -d' ' -f3 )" readonly llvm_version="$( echo "$llvm_full_version" | cut -d. -f-1 )" git checkout "clang_$llvm_version" git apply <