add tmp directory
change output directory