I am creating a Perl script that, among other things, sets into a ClearCase view, sources an environment, and runs synthesis tools, and finally post-processes output reports
As I mention in the answer you saw "Python and ClearCase setview", using setview in a script is generally not a good idea.
The only solution I know is two make 2 scripts:
/vobs/xxx
refers to the right vob in the right view/vobs
.Trying to do all in one step will mostly fail due to the sub-shell launched by setview.