Start here

Home
About Klocwork
What's new
Fixed issues
Release notes
Installation

Reference

C/C++ checkers
Java checkers
C# checkers
MISRA C 2004 checkers
MISRA C++ 2008 checkers
MISRA C 2012 checkers
MISRA C 2012 checkers with Amendment 1
Commands
Metrics
Troubleshooting
Reference

Product components

C/C++ Integration build analysis
Java Integration build analysis
Desktop analysis
Refactoring
Klocwork Static Code Analysis
Klocwork Code Review
Structure101
Tuning
Custom checkers

Coding environments

Visual Studio
Eclipse for C/C++
Eclipse for Java
IntelliJ IDEA
Other

Administration

Project configuration
Build configuration
Administration
Analysis performance
Server performance
Security/permissions
Licensing
Klocwork Static Code Analysis Web API
Klocwork Code Review Web API

Community

View help online
Visit RogueWave.com
Klocwork Support
Rogue Wave Videos

Legal

Legal information

Kwcollect

The kwcollect command (like Kwcscollect for C#) is a lightweight tool that you can use to collect C/C++ data and submit to Klocwork Support to receive additional help with build errors.

Usage

kwpython kwcollect.py [<options>] <tables_dir>

where

  • <options> is any of the kwcollect options listed below
  • <tables_dir> is the tables directory of the project you want to collect data for

Examples

If you want to add multiple files to an archive to collect data on, run the following:

kwpython kwcollect.py -f "file1" -a "file2" -o "myarchive" "C:\Klocwork\Server 18.1\My_tables"
Note: There must either be build errors in the project, or at least one source file must be specified with -f in order for kwcollect to pack any data. Any files specified with the ‘-a’ option will not pack anything unless there are build errors in the project.

If you want to collect data for your entire project, run the following:

kwpython kwcollect.py --all-sources "C:\Klocwork\Server 18.1\My_tables"

Options

Name (and short name) Description
<tables_dir> The location of your project's tables directory; this is a mandatory option and must be specified last
--help (-h) display help
-f <file> looks for build errors on specified source file
-l <file> looks for build errors on specified file list
-a <file> adds specified file to an archive
-o <file> specify the name of the archive you want to create
--lef packs all lef-related files
--all-sources packs all source files for the project, with the exception of lef-related files.
--debug enable debug output