use BINARY_DIR for input and output files