recode the environment setup perl script.