How to solve problem “version `GLIBC_2.14′ not found”

Simpliest solution

There is a several ways how you can deal with this problem. I think the easiest (and solution I choose) is compile application on the most oldest version of OS you want support. Here is the reason:

For dynamic linking, Linux (and most other UNIXes) support backward compatibility: an old binary continues to work on newer systems. But they don’t support forward compatibility (a binary built on a newer system will generally not run on an older one).

External links:

Another solutions

Here is a nice list how can be this issue solved (source here):

  • You could copy (the target of /lib/ld-linux symlink) to the target system, and invoke it explicitly: /path/to/ –library-path /path/to/your/executable. This generally works, but can confuse an application that looks at argv[0], and breaks for applications that re-exec themselves.
  • You could build on an older system.
  • You could use appgcc.
  • You could set up a chroot environment matching the target system, and build inside that chroot.
  • You could build yourself a Linux-to-olderLinux crosscompiler

One more solution

You can also try following way, but I don’t test it

#include <limits.h>
#include <stdlib.h>
#include <stdio.h>

__asm__(".symver realpath,realpath@GLIBC_2.2.5");
int main()
   char* unresolved = "/lib64";
   char  resolved[PATH_MAX+1];

   if(!realpath(unresolved, resolved))
      { return 1; }

   printf("%s\n", resolved);

   return 0;

One comment

  1. For the first solution, I tested whether argv[0] is changed while the executable is invoked by explicitly, and the answer is no, argv[0] is still the executable itself.

Leave a Reply

Your email address will not be published. Required fields are marked *