CMake: allow appending a string to the library filename

This helps us install multiple versions of the library side-by-side.