Remove O_LARGEFILE for open(), add '-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' for CPPFLAGS instead.
This should fix the compilation error reported by dcblack.