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

Using the demosthenes demo project (Linux or Solaris)

Prerequisites:

  • The Klocwork Server package must be installed.
  • The Klocwork servers must be running.
To test your Klocwork installation, you can use the sample project 'demosthenes' to quickly create and analyze a project. To set up the sample project:
  1. In the <klocwork_server_install>/samples directory, you can find the Demosthenes project, which is a C/C++ sample project.
  2. From <klocwork_server_install>/samples/demosthenes, run [<environment_variable_settings>] kwrun.sh [<output directory>]. If you are using an Ubuntu machine that uses the Dash shell, run: [<environment_variable_settings>] /bin/bash ./kwrun.sh [<output directory>] where <environment_variable settings> can include:
    • KW_LICENSE_HOST=<host> - specifies the License Server host (if you are not using a license file)
    • KW_LICENSE_PORT=<port> - specifies the License Server port (if you are not using a license file, and if the License Server is running on a non- default port. The default is 27000.)
    • KW_NO_KWINJECT=[yes|y] - generate build specification without kwinject
    <output_directory> is the directory where all analysis data is stored. The default output directory is demosthenes_build, in the current working directory. kwrun.sh creates a demosthenes project on the server and analyzes each revision of the source code.
  3. In your browser, enter the following URL: http://<klocwork_server_host>:<klocwork_server_port>.
  4. Select Klocwork Static Code Analysis and log in. A password is not required if you have not set up authentication.
  5. Choose demosthenes from the project list. From the issues list, you can investigate the issues and get familiar with all of the available features found in Klocwork Static Code Analysis.