Commit adds macros and #include in order to bring down the number of `warning:
implicit declaration of function 'X' [-Wimplicit-function-declaration]`
warnings.
'lib/ipmi_sdradd.c' ipmi_sdr_read_records() opens a file descriptor and never
closes it. Here is a patch in use by SGI for quite some time now. Suggested
patch attached.