Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I found that if I build any binary on Ubuntu 10.10, then it doesn't execute on some older Linuxes. It is because Ubuntu uses a very new C library, called EGLIBC. Most of the desktop Linux systems use GLIBC.

I would like to know whether there is any standard method how to redistribute binary programs built on a modern Ubuntu so that they can be executed on any older Linux system ?

How to find all required dependencies (glibc version, dynamic libraries) ?

share|improve this question

1 Answer 1

up vote 3 down vote accepted

If you insist on doing that, then you can not use any shared libraries; you must link with -static.

To find out what it links to from the source, look at the linker command for -lfoo switches. To inspect a binary, run ldd on it.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.