Properly ignore target dirs.