[Qbs] Using clang-tidy with Qbs
chgans at gmail.com
Mon Sep 25 08:33:41 CEST 2017
On 25/09/2017 6:44 pm, <timur.kristof at gmail.com> wrote:
> > > I've found this bugreport: https://bugreports.qt.io/browse/QBS-99
> > > 7
> > > However it's unclear to me whether this actually made it into Qbs
> > > yet.
> > >
> > > What's the right way to use clang-tidy with my Qbs-based project?
> > qbs generate -g clangdb
> > ls -l <profile>/compile_commands.json
> > clang-check -p <profile> path/to/source.cpp
> > clang-tidy -p <profile> path/to/source.cpp
> set -e
> qbs generate -g clangdb
> find . -name '*.cpp' | clang-check -p <some-default-qbs-profile>
> is somehow an unreal example of a git hook, server and/or client side
Thank you Chris!
I'm not accustomed to using Qbs on the command line. How do I set up a
Qbs profile? Is there a detailed documentation for that?
So far, I've looked at the Configuring and How-tos section in the docs
but they don't cover this. I'd like to set up an arm-none-eabi kit like
I have with Qt Creator.
Are you talking "bare metal" toolchain?
Anyway, look at qbs auxiliary programs such as qbs-setup-toolchain,
You might want to add /path/to/qt/sdk/Tools/QtCreator/bin to your path.
You can as well re-use qtc's own qbs profile. In CI I don't, but I would do
on a Dev machine.
Answering from my phone, please excuse my brievity.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Qbs