Notes on the libiberty.so file


Libiberty is part of the GNU compiler and debugger distributions. Amongst its other roles, debugging and execution/performance analysis tools use libiberty to demangle G++ function names (i.e., function names decorated/encoded by the G++ compiler). This package builds and includes libiberty as a shared library, making this functionality available to a wider range of tools without requiring them to explicitly link with any particular version of libiberty.

Here is the README file included in shared-libiberty.tar.gz.


This libiberty package has been configured to build libiberty.so on Solaris by modifying the Makefile to generate a shared library instead of libiberty.a. (Note that "configure" can be used to re-generate a Makefile for libiberty.a, but "configure --enable-shared" is still broken.)

You could also generate libiberty.so by configuring with --enable-shared and then generate the shared library using:

/usr/ccs/bin/ld -G -Bdynamic pic/*.o -o libiberty.so

Either copy libiberty.so to the directory where you wish to install it or use

make libdir=/my/install/dir install

As a shared library, libiberty.so can be dynamically loaded by any tool which wishes to use its functionality for C++ function name demangling, etc. Such tools will typically expect to locate libiberty.so via an environment variable such as LD_LIBRARY_PATH which should include the pathname of the directory where libiberty.so has been installed.

This version of libiberty from GCC 2.95.3 is expected to be compatible with earlier versions, but not necessarily with subsequent G++ releases.


The shared-libiberty.tar.gz file has been provided by Sun to include on sunfreeware.com. To install the file, copy it to a directory of your choice and then gunzip and untar it via

gunzip shared-libiberty.tar.gz
tar xvf shared-libiberty.tar

This will create a directory called shared-libiberty.

To download the file, click (or sometimes you may need to shift-click) on

shared-libiberty.tar.gz


Contact Information

© Copyright 2011 Steven M. Christensen and Associates, Inc.
This page was last updated on January 1, 2011.