Building libunwind - linux-on-ibm-z/docs GitHub Wiki
Building libunwind
Below versions of Libunwind are available in respective distributions at the time creation of these build instructions:
- RHEL (9.2, 9.4, 9.5) have
1.6.2
- SLES 15 SP6 has
1.5.0
The instructions provided below specify the steps to build libunwind v1.8.1 on Linux on IBM Z for following distributions:
- RHEL (8.8, 8.10, 9.2, 9.4, 9.5)
- SLES 15 SP6
- Ubuntu (20.04, 22.04, 24.04, 24.10)
General Notes:
- When following the steps below please use a standard permission user unless otherwise specified.
- A directory
/<source_root>/
will be referred to in these instructions, this is a temporary writable directory anywhere you'd like to place it.
Step 1: Building and installing libunwind
1.1) Install dependencies
- RHEL (8.8, 8.10, 9.2, 9.4, 9.5)
sudo yum install automake gcc git make libtool gcc-c++
- SLES 15 SP6
sudo zypper install automake gcc git make texinfo libtool pkg-config gcc-c++
- Ubuntu (20.04, 22.04, 24.04, 24.10)
sudo apt-get update
sudo apt-get install automake gcc g++ git make texinfo libtool libltdl-dev pkg-config
1.2) Build and install Libunwind
cd $SOURCE_ROOT
git clone -b v1.8.1 https://github.com/libunwind/libunwind
cd libunwind
export CFLAGS="-std=gnu99" #Only for ubuntu 24.04 and ubuntu 24.10
autoreconf -i
./configure
make
sudo make install
1.3) Run Unit and Performance Tests (Optional)
cd $SOURCE_ROOT/libunwind
make check
cd $SOURCE_ROOT/libunwind/tests
make perf