Move local includes below system includes.
Remove all implicit definitions of compiler provided functions.
<strings.h> cause strncasecmp to be define.
Add out_BinaryFileSlice() definition to output.h.
Comment out unused variable dest.
Only define _MAX_PATH is it isn't already defined.
Remove GNU-specific <getopt.h>. getopt() is defined in <unistd.h> in POSIX, which adding #define _XOPEN_SOURCE 500 causes GCC to include.