Throw exception if library is not available.