Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Linux distribution binary compatibility

Tags:

Any way to make a binary in a Linux distribution and run it on another distribution with same architecture? Or I should compile and build it on different distributions?

Is there any compatibility between Redhat, Debian based distributions for binary files? (I want to use my Ubuntu binary file on fedora!)

like image 679
Hosi Avatar asked Jan 08 '10 13:01

Hosi


People also ask

Is Linux binary compatible with Unix?

Binary compatibility is a major benefit when developing computer programs that are to be run on multiple OSes. Several Unix-based OSes, such as FreeBSD or NetBSD, offer binary compatibility with more popular OSes, such as Linux-derived ones, since most binary executables are not commonly distributed for such OSes.

Which of the following distributions is binary compatible with RHEL?

CentOS (Community ENTerprise Operating System) is binary compatible to RHEL (Red Hat Enterprise Linux).

Is Oracle Linux binary compatible with RHEL?

Does Oracle Linux offer Red Hat Enterprise Linux compatibility? Yes, Oracle has offered application binary compatibility with Red Hat Enterprise Linux since Oracle Linux was introduced in 2006, with no reported issues.

What is binary compatible and source compatible?

Source: Source compatibility concerns translating Java source code into class files. Binary: Binary compatibility is defined in The Java Language Specification as preserving the ability to link without error. Behavioral: Behavioral compatibility includes the semantics of the code that is executed at runtime.


2 Answers

Enter Linux Standard Base to reduce the differences between individual Linux distributions. See

  • http://www.linuxfoundation.org/collaborate/workgroups/lsb
  • http://en.wikipedia.org/wiki/Linux_Standard_Base
like image 60
Diego Torres Milano Avatar answered Dec 01 '22 23:12

Diego Torres Milano


Statically linking your binaries makes them LESS portable because some libraries won't then work correctly for that machine (differing authentication methods, etc).

If you statically link any "unusual" libraries and keep your set of supported distros to a minimum, you should be ok.

Don't statically link the C library (or the whole binary), that's a recipe for trouble :)

Look at what (e.g.) Google do with Chrome.

like image 26
MarkR Avatar answered Dec 01 '22 22:12

MarkR