Redmine#5463: do not use local_software_dir if it does not exist

(cherry picked from commit 057d7604f5bd5cff60837c0eb9bc48ec66615ada)