ike3 / mangosbot

This is a modification of MaNGOS (Zero, One, R2, Trinity) server which brings a number of bots online and available for any player. Also allows you to use your account/guild characters as bots.
http://ike3.github.io/mangosbot-docs/
GNU General Public License v2.0
185 stars 79 forks source link

Failure to compile - Debian 8.5 #71

Open skeezerbean opened 8 years ago

skeezerbean commented 8 years ago

Description: I installed a fresh Debian 8.5 install, added WebMin and vim packages, then added packages exactly as described in the TrinityCore guide. CMAKE runs fine, but make fails. Did I do something wrong?

Current behaviour: make output at the end, at 100% - http://pastebin.com/gHwgT51Q CMAKE output - http://pastebin.com/nGyYEC7s OpenSSL - OpenSSL 1.0.1t 3 May 2016

Branch(es): 335 https://github.com/ike3/mangosbot/commit/9fefd30dabd9d5e8be82651e288feeb9b5025c22 but also failed a week ago when trying previous commit on another fresh server (Tried Ubuntu 16.04 week ago)

skeezerbean commented 8 years ago

Note - this last attempt was with commit https://github.com/ike3/mangosbot/commit/95bcc36b4ef945443bc1bd2d6c8df62639821bf2 updated on 6-14-2016

The problem was linking order, far as I can tell, and I edited this file - mangosbot/build/src/server/worldserver/CMakeFiles/worldserver.dir/link.txt

I changed the linkage order, a small section, from this ../../plugins/libplugins.a ../scripts/libscripts.a ../game/libgame.a to this ../scripts/libscripts.a ../game/libgame.a ../../plugins/libplugins.a

At this point I was able to run make, make install. Linking CXX executable worldserver [100%] Built target worldserver

After this was fixed I got this error running the authserver

In mysql_stmt_prepare() id: 67, sql: "SELECT c.country FROM ip2nationCountries c, ip2nation i WHERE i.ip < ? AND c.code = i.country ORDER BY i.ip DESC LIMIT 0,1" Table 'auth.ip2nationCountries' doesn't exist

This was fixed by renaming the table ip2nationcountries to ip2nationCountries to match capitalization. After this the auth server started up. This may be an issue with exporting out the databases from a Windows machine where this was previously running.

When launching worldserver it complained about not finding the aiplayerbot.conf, no matter where I seemed to put it. This was because I was lauching ~/server/bin/worldserver rather than cd ~/server/bin and then launching with ./worldserver - I put the conf files in the bin directory for it to find them.

When initializing bots it crashed during the Initalizing quests... part, which I had forgotten about https://github.com/ike3/mangosbot/issues/58

I hope this helps someone out there.

LordPsyan commented 8 years ago

@sheexerbean in order to force cmake to make the change to that link.txt file, you would want to replace ( in /src/server/worldserver/CmakeLists.txt)

target_link_libraries(worldserver
  PUBLIC
  plugins
    scripts
    game
    gsoap
    readline)

with

target_link_libraries(worldserver
  PUBLIC
    scripts
    game
    plugins
    gsoap
    readline)

However, this didnt fix the problem for me. It did lower the number of linking errors after 100% but didn't remove them completely. I will come back here with updates when I figure it out.

LordPsyan commented 8 years ago

Sorry for second post, but my suipplied fix actually fixes the issue, but you have to do a fresh compile... aka make clean or delete build folder and start over.

ghost commented 8 years ago

@skeezerbean : Can you test what @LordPsyan suggested and close this issue if it works for you? :-)

Skua74 commented 7 years ago

I had the exact same problem as described by skeezerbean and tried LordPsyans fix. It worked for me! I also didn't have to make a fresh compile! Thx a lot!

timothystewart6 commented 5 years ago

@skeezerbean thank you so much! I moved from Windows MySQL to Linux and it was getting hung up on this.