Don't use PathV1.h in LTOCodeGenerator.cpp

This patch also adds a simpler version of sys::fs::remove and a tool_output_file
constructor for when we already have an open file.
Avoid using __SIZE_TYPE__ in a -std=c++98 -pedantic-errors test, because that
triggers an error on MS targets where __SIZE_TYPE__ expands to 'long long'.