简体   繁体   中英

Cppcheck into Jenkins with QT project

I have server with Jenkins and QT project. The server runs on CentOS 7. I installed " Cppcheck " into server also I installed " Cppcheck Plug-in " plugin into Jenkins.

The script for build project:

cd FlashClipboard;
/usr/lib64/qt5/bin/qmake FlashClipboard.pro;
make clean;
make;
cppcheck --enable=all --suppress=missingIncludeSystem . --xml --xml-version=2 . 2> ./tmp/cppcheck.xml;

Post-Build Actions:

在此处输入图片说明

But I have error:

[Cppcheck] Starting the cppcheck analysis.

[Cppcheck] Processing 1 files with the pattern 'tmp/cppcheck.xml'.

[Cppcheck] Parsing throws exceptions. javax.xml.bind.UnmarshalException - with linked exception:

[org.xml.sax.SAXParseException; systemId: file:/var/lib/jenkins/workspace/Flash%20Clipboard/tmp/cppcheck.xml; lineNumber: 1; columnNumber: 1; Premature end of file.]

Build step 'Publish Cppcheck results' changed build result to FAILURE

Build step 'Publish Cppcheck results' marked build as failure

What is my mistake?

sorry but are you sure the path is correct?

Shouldn't it be:

Cppcheck report XML:  FlashClipboard/tmp/cppcheck.xml

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM