Chapter 1. Setting up a development workstation


Red Hat Enterprise Linux 8 supports the development of custom applications. To set up your system for development, install the required tools and utilities for the most common development use cases.

1.1. Enabling debug and source repositories

To access essential debugging data for system components, enable debug and source repositories. RHEL disables these by default to save space. Enable them to install debuginfo packages required for performance measurement and deep system troubleshooting.

Procedure

  • Enable the source and debug information package channels:

    1. Enable the BaseOS debug repository:

      # subscription-manager repos --enable rhel-8-for-$(uname -i)-baseos-debug-rpms
    2. Enable the BaseOS source repository:

      # subscription-manager repos --enable rhel-8-for-$(uname -i)-baseos-source-rpms
    3. Enable the AppStream debug repository:

      # subscription-manager repos --enable rhel-8-for-$(uname -i)-appstream-debug-rpms
    4. Enable the AppStream source repository:

      # subscription-manager repos --enable rhel-8-for-$(uname -i)-appstream-source-rpms

      The $(uname -i) part is automatically replaced with a matching value for architecture of your system:

Expand

Architecture name

Value

64-bit Intel and AMD

x86_64

64-bit ARM

aarch64

IBM POWER

ppc64le

64-bit IBM Z

s390x

1.2. Setting up to manage application versions

Effective version control is essential to all multi-developer projects. Red Hat Enterprise Linux includes Git, a distributed version control system.

Procedure

  1. Install the git package:

    # yum install git
  2. Optional: Set the full name associated with your Git commits:

    $ git config --global user.name "Full Name"
  3. Optional: Set the email address associated with your Git commits:

    $ git config --global user.email "email@example.com"

    Replace Full Name and email@example.com with your actual name and email address.

  4. Optional: To change the default text editor started by Git, set value of the core.editor configuration option:

    $ git config --global core.editor command

    Replace command with the command to be used to start the selected text editor.

To develop C and C++ applications on Red Hat Enterprise Linux, you can use the development tools provided by Red Hat Enterprise Linux. This procedure describes how to install the standard development tools, including the GCC and LLVM toolchains.

Prerequisites

  • The debug and source repositories must be enabled.

Procedure

  1. Install the Development Tools package group including GNU Compiler Collection (GCC), GNU Debugger (GDB), and other development tools:

    # yum group install "Development Tools"
  2. Install the LLVM-based toolchain including the clang compiler and lldb debugger:

    # yum install llvm-toolset
  3. Optional: For Fortran dependencies, install the GNU Fortran compiler:

    # yum install gcc-gfortran

1.4. Setting up to debug applications

To analyze and troubleshoot internal application behavior, Red Hat Enterprise Linux offers multiple debugging and instrumentation tools.

Prerequisites

  • The debug and source repositories must be enabled.

Procedure

  1. Install the tools useful for debugging:

    # yum install gdb valgrind systemtap ltrace strace
  2. Install the yum-utils package in order to use the debuginfo-install tool:

    # yum install yum-utils
  3. Run a SystemTap helper script for setting up the environment.

    # stap-prep

    Note that stap-prep installs packages relevant to the currently running kernel, which might not be the same as the actually installed kernel(s). To ensure stap-prep installs the correct kernel-debuginfo and kernel-headers packages, double-check the current kernel version by using the uname -r command and reboot your system if necessary.

  4. Make sure SELinux policies allow the relevant applications to run not only normally, but in the debugging situations, too. For more information, see Using SELinux.

To identify the causes of application performance loss, you can use the performance measurement tools provided by Red Hat Enterprise Linux. This procedure describes how to install tools such as perf, Valgrind, SystemTap, and Performance Co-Pilot (PCP).

Prerequisites

  • The debug and source repositories must be enabled.

Procedure

  1. Install the tools for performance measurement:

    # yum install perf papi pcp-zeroconf valgrind strace sysstat systemtap
  2. Run a SystemTap helper script for setting up the environment.

    # stap-prep

    Note that stap-prep installs packages relevant to the currently running kernel, which might not be the same as the actually installed kernel(s). To ensure stap-prep installs the correct kernel-debuginfo and kernel-headers packages, double-check the current kernel version by using the uname -r command and reboot your system if necessary.

  3. Enable the Performance Co-Pilot (PCP) collector service:

    # systemctl enable pmcd
  4. Start the Performance Co-Pilot (PCP) collector service:

    # systemctl start pmcd
Red Hat logoGithubredditYoutubeTwitter

Learn

Try, buy, & sell

Communities

About Red Hat Documentation

We help Red Hat users innovate and achieve their goals with our products and services with content they can trust. Explore our recent updates.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

Theme

© 2026 Red Hat
Back to top