Add trailing slash if necessary to target-dir