I am encountering compiling falures as well. I am currently at 2/5 successful.
ActivePerl 5.10.1 Build 1008
Microsoft Visual C++ 2008 Express
MySQL Server 5.5.9
zlib 1.2.3
Ended up 1/4 success - they were failing because it could not find "zlib.lib"
I notice that a "zlib.lib" file was not included in my zlib download. Found this forum (
http://www.eqemulator.org/forums/showthread.php?t=28678) which confirms that the official zip file calls the lib "zdll.lib" instead of "zlib.lib". So I made a copy of "zdll.lib" named "zlib.lib" and the compiler can now find that file...
However, that brought me to 2/5 sucessful and the other 3 are all failing on the same issue.
The 3 build failures are identical for World, Zone, and ucs, and happens during the linking stage:
2>Linking...
2>mysqlclient.lib(inflate.obj) : error LNK2005: _inflateInit2_ already defined in zlib.lib(zlib1.dll)
2>mysqlclient.lib(inflate.obj) : error LNK2005: _inflate already defined in zlib.lib(zlib1.dll)
2>mysqlclient.lib(inflate.obj) : error LNK2005: _inflateEnd already defined in zlib.lib(zlib1.dll)
2>.\../build/World.exe : fatal error LNK1169: one or more multiply defined symbols found
2>World - 4 error(s), 2 warning(s)
The guide was going smoothly until it told me to add "C:\mysql\lib\opt" to the INCLUDE list in Visual Studio because that directory did not exist. So I just added "C:\mysql\lib\" and continued...
Not sure why that directory is missing because I installed all components of the MySQL server (confirmed by going into add/remove programs > change).
Downloaded this MySQL Connector C++ 1.1.0 which seems to actually contain a "mysql\lib\opt\" folder, but that did not have an affect either way...
Since I had a "mysql\lib\opt\" path now, i tried removing "c:\mysql\lib\" but then the linker fails with this reason:
LINK : fatal error LNK1104: cannot open file 'mysqlclient.lib'.
So it seems that I need to have "mysql\lib\" in the LIBRARY list, which puts me back to the previous error.
I believe my problem is somewhere between MySQL Server and zlib.
My thoughts are that with recent changes to MySQL there is no "opt" folder but just "lib" folder?
Also, in the zlib USAGE file and it states:
- If you wish, you may rename "zdll.exp" to "zlib1.exp", and/or
rename "zdll.lib" to "zlib1.lib".
It doesnt mention renaming it to "zlib.lib" possibly because it knows thats not compatible?
Either way, I tried naming the file to "zlib1.lib" and it brings me back to my first error: LINK : fatal error LNK1104: cannot open file 'zlib.lib'.
Now I feel strongly that perhaps recent updates with zlib and MySQL are conflicting with each calling their own "zlib.lib", and maybe zlib is recommending use zlib1.lib instead.
So what I think I need to do is somehow tell the Linker process to use zlib's "zlib1.lib" instead of "zlib.lib".
Any suggestions?
Thx