Linux ports - determining the correct port to order

0 Likes

Problem:

When ordering ports for the Linux operating system it is necessary to know the glibc version that is installed on the target machine to avoid a port mismatch.

Resolution:

From the command line type the following command:

rpm -q glibc

This should return output similar to:

glibc-2.3.2-5

For ordering purposes, the glibc version in this example would be version 2.3.

Example command line syntax and output:

user@my_linux:~> rpm -q glibc

glibc-2.3.2-5

On recent Linux distributions, the version can be found by simply running

the library as if it were an executable:

    prompt% /lib/libc.so.6

    GNU C Library stable release version 2.2.5, by Roland McGrath et al.

    [...]

The first line of the output contains the version number.

Another way to determine the version is to see what version string is embedded in the library itself:

    prompt% strings /lib/libc.so.? | grep "GNU C Library"

    GNU C Library stable release version 2.1.3, by Roland McGrath et al.

If the above does not work, look in /lib and see what's there:

    prompt% ls -l /lib/libc.*

In the output, look for a file with a format similar to "libc-X.Y.Z.so" and/or "libc.so.W", where W, X, Y, and Z are digits.

    libc-1.Y.Z.so == libc-5

    libc-2.0.Z.so == glibc-2.0

    libc-2.1.Z.so == glibc-2.1

    libc-2.2.Z.so == glibc-2.2

These are likely symbolic links to the libc-X.Y.Z.so file:

    libc.so.5 == libc-5

    libc.so.6 == glibc-2.?

Old KB# 2666
Comment List
Anonymous
Related Discussions
Recommended