BugHunter Pro and the VeriLogger Simulators

10.2 Setting up gcc for Linux Machines

10.2 Setting up gcc for Linux Machines

Previous topic Next topic  

10.2 Setting up gcc for Linux Machines

Previous topic Next topic  

To use SystemC on Linux, you must have the gcc compiler installed.

Step 1: Install the gcc compiler

Most systems have a functioning gcc installed by default.  If yours doesn't, you can usually install one by running one of the following commands:

On RedHat, run "sudo yum install gcc-c++"

On Ubuntu, run "sudo apt-get install build-essential"

Step 2: Setup the PATH environment variable

By default, BugHunter will use the gcc compiler found via your PATH environment variable.  This is usually what you want, and your system will usually come pre-configured this way.

Step 3: Compile the SystemC Library Using gcc

Compile the systemc.lib static library that will be used whenever you compile a SystemC simulation. This only needs to be done once before you first try to run a SystemC project from within BugHunter.

Change directory to the lib/systemc subdirectory under the BugHunter distribution:

  cd synapticad-16.01y/lib/systemc

Configure and build the SystemC library:

  ./configure --prefix=`pwd`/install

  make

Install it. This step will place the compiled library in the directory synapticad-16.01y/lib/systemc/install, which is where the example projects shipped with BugHunter will expect to find it. It will not modify anything outside of the BugHunter distribution directory, and does not require root access.

  make install

Verify that it installed the library synapticad-16.01y/lib/systemc/install/lib-linux/libsystemc.a, and the header files synapticad-16.01y/lib/systemc/install/include/systemc.h.  Note: if you are building on a 64-bit system with a 64-bit compiler, the SystemC library will be built to the directory lib-linux64 instead of lib-linux.  If this is the case, you will need to modify the path in the "Library Directories" field in the Project Simulation Properties dialog to get the SystemC example projects to link correctly.