Add dependence on library if explicit path is provided