[Writer][ELF] Use correct data types for sizes. Fixes integer overflow bug.

This only happens when the section header count is > 1024.
Fix (possible) MSVC miscompile in debug mode.
[Driver][GNU] Accept and ignore more options.