Problem arises on fresh build, where the destination file is not yet defined.
In that case Cwd::abs_path() returns empty string, which fatal later on.
}
use File::Basename;
use File::Path;
}
use File::Basename;
use File::Path;
use File::Copy "cp";
use File::Temp qw/ :POSIX /;
use lyxStatus;
use File::Copy "cp";
use File::Temp qw/ :POSIX /;
use lyxStatus;
&diestack("Destfilename not defined") if (! defined($dest));
&diestack("Format (e.g. pdf4) not defined") if (! defined($format));
&diestack("Destfilename not defined") if (! defined($dest));
&diestack("Format (e.g. pdf4) not defined") if (! defined($format));
-$source = &abs_path($source);
-$dest = &abs_path($dest);
+$source = File::Spec->rel2abs($source);
+$dest = File::Spec->rel2abs($dest);