In my CMakeLists I have a statement:
target_link_libraries(mytarget somelib)
The problem is that I am working on Windows and somelib has a verbatim name - libsomelib.a. I cannot control that because the library is built by another person (who thinks it is a cool idea to name Windows libraries in a UNIX fashion) and installed somewhere.
Prior to the statement I have
set(CMAKE_STATIC_LIBRARY_PREFIX "lib")
set(CMAKE_STATIC_LIBRARY_SUFFIX ".a")
which seems to affect only libraries produced by a given CMakeLists, and, in the list of dependencies (of a generated VS project) it still appears as somelib.lib. My question is what can be done to get this dependent library properly named?