On 19/08/2016 15:39, kang joni wrote: > As the title suggest, I usually compile my linux code from old debian > squeeze to run for either centos 6 or debian wheezy and these distros > later version and adjusting some app rpath and clang libc++ runtime > libs to point local relative file path via origin method. Is there any > easy guideline to follow when working on bsd libc version? I feels do > not like on how libc emulation method as it seems complex > configuration fine tuning for starter BSD like me.
FreeBSD promises /forward/ ABI compatibility for the whole of one major version's lifetime. That means that if you want to run your application on a mixture of 10.1, 10.2 and 10.3 machines, then you should compile it under 10.1. This is modified by the use of versioned symbols in recent releases: effectively libc contains multiple copies of certain symbols where there have been ABI-breaking changes, so you can run something compiled for 10.1 on an 11.0 system and dynamically link against the same copy of libc. The use of versioned symbols applies to the most important shared libraries provided by the base system, but not all, and it doesn't apply to any shared libraries provided from the ports as far as I am aware. So while it will normally 'just work' for safeties' sake you'll still need to test cross compatibility and may still need to install compat libraries or compile code separately for each different major OS version. See: https://people.freebsd.org/~deischen/symver/freebsd_versioning.txt for a much fuller explanation of symbol versioning. Cheers, Matthew
signature.asc
Description: OpenPGP digital signature
