use proper directories for temp. files