Tiny cross-platform file functions wrapper