Adding the missing check to verify package is installed

The to verify package is installed or not is missing in R1.05 branch. The check is already present in master branch. 

This missing check has introduced bug 2737 in Ubuntu. Adding the check back.