Language Selection

English French German Italian Portuguese Spanish

Using Cscope and SilentBob to analyze source code

Filed under
HowTos

When you start learning the source code of an unfamiliar project, you don't have the knowledge of its structure or the meaning of specific functions, classes, and units in the project. You can use tags to browse for definitions, but it's hard to get an overall picture by just looking through every definition one by one. Cscope and SilentBob are two tools that can help you analyze unfamiliar source code. They help you find symbol definitions, determine where specific functions are used, determine which functions are called by other given functions, and search for strings and patterns throughout the code base. With them, you can save time by doing fast, targeted searches instead of grepping through source files by hand.

Using Cscope

Cscope is a popular utility, and most modern distributions include it. Although Cscope was originally intended only for use with C code, it actually works well with languages like C++ and Java. Cscope comes with an ncurses-based GUI, but it also supports a command-line interface to communicate with other application that can be used as front ends, including major editors such as Emacs and Vim.

SilentBob

SilentBob is another new tool for analyzing source code. It currently supports C/C++, Perl, and Python, but its plugin framework (which is not documented at the moment) enables users to add support for new languages and other features easily.

Full Story.

More in Tux Machines

PuppEX Linux Live CD Now Based on Puppy Xenial, Compatible with Ubuntu 16.04 LTS

Arne Exton informs us about the availability of a new stable build of its Puppy-derived PuppEX Linux Live CD distribution, version 160822, which is now using the latest kernel and software applications. Read more

KDevelop 5.0 Open-Source IDE Officially Released with New C/C++ Language Support

After being in development for the past two years, the open-source KDevelop IDE (Integrated Development Environment) software has finally reached the 5.0 milestone. Read more

Open source drone controller has an FPGA-enhanced brain

Aerotenna has launched an open source, $499 “OcPoc” drone flight controller that runs Linux on an Altera Cyclone V ARM/FPGA SoC. Lawrence, Kansas based Aerotenna, which bills itself as “the leading provider of innovative microwave sensors and flight control systems,” describes OcPoC (Octagonal Pilot on Chip) as a ready-to-fly, open source flight control platform. The system integrates an IMU, barometer, GPS, and a CSI-camera interface. Read more

Linux Kernel 3.16.37 LTS Is a Massive Update with Tons of Networking Changes

Immediately after announcing the release of Linux kernel 3.2.82 LTS, maintainer Ben Hutchings proudly informed the community about the availability of the thirty-seventh maintenance update to the Linux 3.16 LTS kernel series. Read more