FOAM_INST_DIR is the location of the OpenFOAM installation which defaults to the directory containing the etc/bashrc,cshrc file. If this default is not appropriate FOAM_INST_DIR can be set explicitly.
Patches provided by Bruno Santos Resolves bug-report http://www.openfoam.org/mantisbt/view.php?id=231