diff --git a/build/build-vax-netbsd.sh b/build/build-vax-netbsd.sh index 3e17a19..5104a2e 100755 --- a/build/build-vax-netbsd.sh +++ b/build/build-vax-netbsd.sh @@ -107,8 +107,15 @@ popd # Package newly built compiler. gcc_name="gcc-${gcc_target}-${gcc_version}-${nb_actual_timestamp}" gcc_tarball="${workdir}/${gcc_name}.tar.xz" -[ -z "${forced_output_filename}" ] || gcc_tarball="${forced_output_filename}" -[ -d "${forced_output_filename}" ] || gcc_tarball="${forced_output_filename}/${gcc_tarball}" + +if [ -z "${forced_output_filename}" ]; then + gcc_tarball="${forced_output_filename}" +elif [ -d "${forced_output_filename}" ]; then + gcc_tarball="${forced_output_filename}/${gcc_name}.tar.xz" +else + gcc_tarball="${forced_output_filename}" +fi + gcc_destdir="${workdir}/${gcc_name}" gcc_destdir_sysroot="${gcc_destdir}/${gcc_target}-sysroot" mkdir -p "${gcc_destdir}"