Today I just did a fresh rebuild of MySQL 5.1.19 on my Windows XP laptop using Visual Studio 2005. The build process is straight forward with few initial steps:
- I already have Visual Studio 2005 Professional edition installed.
- Installed cmake
- I also installed Windows Bison port, even though am not sure if I will change the parser code.
- Extracted the source files to a directory
- Ran win/configure WITH_INNOBASE_STORAGE_ENGINE from the top directory
- Once the configure completed; executed win\build-vs8.bat; which generated the project workspaces (sln and vcproj) without any problems.
Once I have the MySQL.sln project workspace file; loaded with Vistual Studio 2005 and started the debug build by making mysqld as the startup project. The build completed without any errors.
I started the mysqld debug server under debugger; and when I tried to connect and/or execute any query to this server; the server generates the error Run-Time Check Failure #3 – The variable ‘MYSQLlVal’ is being used without being initialized. I did not wanted to change the source code; so found a solution to turn off this run time checks by going to project settings -> mysqld properties -> Configuration properties -> C/C++ -> Code Generation and changed the Basic Runtime Checks value to “Stack Frames (/RTCs)” from “Both (/RTC1, equv. to /RTCsu)”. Once this this value is changed and did a complete rebuild of the mysqld project workspace; and the resulted debug server did not popup anymore runtime errors.
Thanks for this tip, Venu !
It worked like a champ for me
LTu
Changing the option does the trick, but the option is reset every time the project/solution is rebuilt.
To make the change persistent, just update CMake this way: replace “RTC1” by “RTCs” in file C:\Program Files\CMake\share\cmake-2.4\Modules\Platform.
Typo: the file to update is C:\Program Files\CMake\share\cmake-2.4\Modules\Platform\Windows-cl.cmake.