Conditionalize usage of dlvsym(), nanosleep(), usleep(); Conditionalize layout of struct sigaction and type of it's member sa_flags. Conditionalize glob_t members gl_closedir, gl_readdir, gl_opendir, gl_flags, gl_lstat, gl_stat. Check for availability of glob.h for use with above members. Check for availability of netrom/netrom.h, sys/ustat.h (for obsolete ustat() function), utime.h (for obsolete utime() function), wordexp.h. Determine size of sigset_t instead of hardcoding it. Determine size of struct statfs64, if available. Leave defaults to match what glibc expects but probe them for uClibc.
The patch is huge and has too many ifdefs.
It will have some time for us to review and will be very costly to maintain.
So, before we continue with review I would like to hear the motivation and
whether you are welling to help us maintain this code in future (= set up a public build bot)