Don't use string.gsub to derive the library name

The pattern was an unsanitized path name which may contain special
characters (e.g. '-')
Merge pull request #1 from dushan42/master

Don't use string.gsub to derive the library name