I have the same error and I was searching for the solution for hours but I couldnt solve it.
Nay, you might wrote the solution, but I dont clearly understand what you said.
Could you explain me a little more?
I downloaded the files but where can I change the MYSQL_LIBRARY in Cmake? In the CMake.txt or in the Cmake program before generating the source?