Import elf.h from glibc 2.17 for scripts/mod/.

This makes the build work out of the box on non-ELF hosts like Mac OS.

The header is slightly modified to not depend on __BEGIN_DECLS/__END_DECLS
or <features.h>.
Merge pull request #3 from jld/add-elf-h

Import elf.h from glibc 2.17 for scripts/mod/.