【问题标题】:Add coverity scan to Qt app将覆盖扫描添加到 Qt 应用程序
【发布时间】:2015-01-04 09:16:12
【问题描述】:

我正在尝试将 Coverity Scan static analysis 添加到我的 Qt 项目中,但我无法获得结果。

我下载了覆盖率扫描构建工具并使用以下命令行:

cov-build --dir cov-int make

这会产生以下日志:

...
my build log
...
[WARNING] No files were emitted. This may be due to a problem with your configuration
or because no files were actually compiled by your build command.
Please make sure you have configured the compilers actually used in the compilation.
For more details, please look at:
    /Users/martin/dev/builds/ConsoleTest01-Desktop_Qt_5_3_clang_64bit-Debug/cov-int/build-log.txt

我怎样才能走得更远?

我在 MacOS 10.9 下使用 Qt 5.3.2。

【问题讨论】:

  • 日志是怎么说的?
  • 结果是日志,我没有放所有的日志,是项目的标准构建日志
  • 你的意思是这个日志cov-int/build-log.txt是显示的那个?这不是很冗长:p

标签: qt coverity


【解决方案1】:

我没有仔细阅读文档:https://scan.coverity.com/download?tab=cxx 我必须首先通过运行来配置覆盖率:

cov-configure --comptype clangcxx --compiler clang++ --template

【讨论】:

    【解决方案2】:

    你需要先运行qmake,然后你可以用make运行cov-int命令。

    我发现在 Qt-Creator 创建的 build- 文件夹中运行 cov-int 最简单。

    【讨论】:

      猜你喜欢
      • 2020-11-07
      • 2011-07-29
      • 2013-07-19
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-10-02
      • 1970-01-01
      • 2022-11-08
      相关资源
      最近更新 更多