Merge "Fix the computation of basefilename"