Symlink check.

The current test for existing shared library does not consider the possiblity the shared library is symlink. This change tests for both regular and symlinked files.