Installs a number of wrapper headers around system headers that add functionality missing in various older OSX releases.
Installed headers use the include_next
pre-processor feature to add
the missing features and then forward include the original header.
So using these headers instead of the originals should be transparent.
Missing functions are compiled into a library that must also be linked into any builds using the wrapped headers. This is handled in MacPorts via the legacysupport PortGroup.
Wrapped headers are:
- cmath : Adds declaration of various
long long
methods missing in OSX10.6 and older. - stdio.h : Adds
getline
andgetdelim
functions missing in OSX10.6 and older. - stdlib.h : Adds
posix_memalign
functional replacement, missing in OSX10.5 and older. - string.h : Adds
strnlen
,strndup
andmemmem
functions missing in OSX10.6 and older. - time.h : Adds
clock_gettime
function missing in OSX10.11 and older. - wchar.h : Adds functions
wcsdup
,wcsnlen
,wcpcpy
,wcpncpy
,wcscasecmp
,wcsncasecmp
missing in OSX10.6 and older. - xlocale/_wchar.h : Adds functions
wcscasecmp_l
,wcsncasecmp_l
missing in OSX10.6 and older. - sys/fcntl.h : Adds missing
O_CLOEXEC
,AT_FDCWD
,AT_EACCESS
,AT_SYMLINK_NOFOLLOW
, :AT_SYMLINK_FOLLOW
, andAT_REMOVEDIR
definitions as required. - sys/fcntl.h : Adds
openat
function missing in OSX10.9 and older. - sys/mman.h : Adds missing
MAP_ANONYMOUS
definition as required. - sys/stdio.h : Adds
renameat
function missing in OSX10.9 and older. - sys/stat.h : Adds
fchmodat
,fstatat
, andmkdirat
functions missing in OSX10.9 and older. : Adds "lchmod", missing in OSX10.4. - sys/unistd.h : Adds
getattrlistat
,readlinkat
,faccessat
,fchownat
,linkat
,symlinkat
, : andunlinkat
functions missing in OSX10.9 and older.