clang-tidy install
Solution 1
You can use your package manager to find out which package clang-tidy
provides. For example on Fedora/CentOS:
dnf whatprovides '*/clang*tidy*'
On Debian/Ubuntu you can use an analogous apt-file search
command.
However, on Fedora 23 clang-tidy
just isn't packaged. No match is found.
There is even an open bug report: Missing clang-query and clang-tidy
For Ubuntu/Debian, the LLVM project maintains an llvm apt repostiory. This should be the easiest way to get the latest clang-tidy
. After configuring that repository and doing an apt-file update
and apt-file search
should return the package that provides clang-tidy
.
An alternative to building from source is to use the upstream llvm pre-built binaries - they are available for Fedora, CentOS etc. For example the one for Fedora 23 does contain clang-tidy:
clang+llvm-3.8.0-x86_64-fedora23/bin/clang-tidy
Solution 2
Fedora 29 includes clang-tidy
in the main Fedora repository. You can install it via:
dnf install clang-tools-extra
Related videos on Youtube
Sardathrion - against SE abuse
I am deeply saddened and worried by the abusing behaviour of stack exchange staff with regards to its users and have stopped all activities in this network. I urge you to do educate yourselves before it is too late. The final words… Firing mods and forced relicensing: is Stack Exchange still interested in cooperating with the community? Time line of events Sign the open letter, if you wish… I did. Nescire autem quid ante quam natus sis acciderit, id est semper esse puerum. Quid enim est aetas hominis, nisi ea memoria rerum veterum cum superiorum aetate contexitur? -- Cicero, Marcus Tullius (106-43BC)
Updated on September 18, 2022Comments
-
Sardathrion - against SE abuse over 1 year
I have clang installed from packages on both Ubuntu 14.07, Centos 7 and Fedoara 22. I would like to use
clang-tidy
but can neither find a package nor how to install it without installing clang from source. That's something I would rather not do.What am I missing?
I might be dense, if so please mock me.