Having trouble compiling latest eAthena Client SVN

Ask for help regarding any technical issue or report any bug or OS independent issues.
Post Reply
ZniL
Peon
Peon
Posts: 5
Joined: 12 Jun 2007, 21:50

Having trouble compiling latest eAthena Client SVN

Post by ZniL »

Thank you for your time!

I'm having some problems compiling the eAthena Client.

Here's what I did:


* downloaded the latest source (https://svn.sourceforge.net/svnroot/the ... /tmw/trunk) using TortoiseSVN. (HEAD revision)
* downloaded Dev C++ and installed it
* downloaded and installed the DevPak from http://themanaworld.org/files/tmw-svn.DevPak
* downloaded and installed Code::Blocks
* added the Dev C++ include directory (C:\Dev-Cpp\include) and the SDL directory (C:\Dev-Cpp\include\SDL) to the Compiler directories in Code::Blocks
* hit the compile button and it gave me some errors. (See log below)

I also have tried compiling it in Dev C++ but some errors occurred that were associated with time.h (Log uploaded http://pastebin.ca/565957)

I have been trying for a while, browsing the forum, but I can't find any solution. I apologize if there was a topic with the solution already existing. (If there is, I would like a link!) Also please note that I have limited C++ skills but I will try my best to understand.

Project : The Mana World
Compiler : GNU GCC Compiler (called directly)
Directory : C:\Documents and Settings\Lindsay.RIGHT\Desktop\The Mana World CVS\
--------------------------------------------------------------------------------
Switching to target: default
Compiling: src\channel.cpp
Compiling: src\channelmanager.cpp
Compiling: src\gui\quitdialog.cpp
Compiling: src\gui\unregisterdialog.cpp
Compiling: src\gui\viewport.cpp
Compiling: src\main.cpp
In file included from C:/Dev-Cpp/include/guichan/keyinput.hpp:60,
from C:/Dev-Cpp/include/guichan/sdl/sdlinput.hpp:65,
from src\main.cpp:38:
C:/Dev-Cpp/include/guichan/key.hpp:128: error: expected identifier before numeric constant
C:/Dev-Cpp/include/guichan/key.hpp:128: error: expected `}' before numeric constant
C:/Dev-Cpp/include/guichan/key.hpp:128: error: expected unqualified-id before numeric constant
C:/Dev-Cpp/include/guichan/key.hpp:160: error: expected unqualified-id before "protected"
C:/Dev-Cpp/include/guichan/key.hpp:160: error: expected `,' or `;' before "protected"
C:/Dev-Cpp/include/guichan/key.hpp:163: error: expected declaration before '}' token
In file included from C:/Dev-Cpp/include/guichan/keyinput.hpp:60,
from C:/Dev-Cpp/include/guichan/sdl/sdlinput.hpp:65,
from src\main.cpp:38:
C:/Dev-Cpp/include/guichan/key.hpp:57:1: unterminated #ifndef
In file included from C:/Dev-Cpp/include/guichan/sdl/sdlinput.hpp:65,
from src\main.cpp:38:
C:/Dev-Cpp/include/guichan/keyinput.hpp:57:1: unterminated #ifndef
In file included from src\main.cpp:38:
C:/Dev-Cpp/include/guichan/sdl/sdlinput.hpp:57:1: unterminated #ifndef
Process terminated with status 1 (0 minutes, 12 seconds)
9 errors, 0 warnings

Thank you again for reading!
User avatar
Crush
TMW Adviser
TMW Adviser
Posts: 8046
Joined: 25 Aug 2005, 16:08
Location: Germany

Post by Crush »

That error is a rare incompatiblity between the current guichan version and some versions of the winAPI caused by a unthoughtful #define in some windows header. Add the line

Code: Select all

#undef DELETE
in main.cpp before including the first guichan header.
  • former Manasource Programmer
  • former TMW Pixel artist
  • NOT a game master

Please do not send me any inquiries regarding player accounts on TMW.


You might have heard a certain rumor about me. This rumor is completely false. You might also have heard the other rumor about me. This rumor is 100% accurate.
ZniL
Peon
Peon
Posts: 5
Joined: 12 Jun 2007, 21:50

Post by ZniL »

Ah. I did see that in another topic. :roll:
I now have a different error, the full version is at http://pastebin.ca/566158

...
Compiling: src\tmw.rc
Compiling: src\utils\base64.cpp
Compiling: src\utils\xml.cpp
Linking executable: tmw.exe
C:\Program Files\CodeBlocks\bin\..\lib\gcc\mingw32\3.4.4\..\..\..\..\mingw32\bin\ld.exe: cannot find -lguichan
collect2: ld returned 1 exit status
Process terminated with status 1 (5 minutes, 40 seconds)
1 errors, 0 warnings

Thank you!
User avatar
Bjørn
Manasource
Manasource
Posts: 1438
Joined: 09 Dec 2004, 18:50
Location: North Rhine-Westphalia, Germany
Contact:

Post by Bjørn »

That is because you haven't managed to install Guichan properly. Probably you installed the headers but somehow not the libraries. This is strange, since they should be included with the DevPack. Please see if you can find the library yourself and try to find out why ld.exe can't find it.
ZniL
Peon
Peon
Posts: 5
Joined: 12 Jun 2007, 21:50

Post by ZniL »

Solved!

I needed to add the C:\Dev-Cpp\lib directory to the Settings -> Compiler -> Directories -> Linker.

Thank you Crush!
This can be closed now.

EDIT: Bjorn beat me to it! :P
User avatar
Bjørn
Manasource
Manasource
Posts: 1438
Joined: 09 Dec 2004, 18:50
Location: North Rhine-Westphalia, Germany
Contact:

Post by Bjørn »

But instead of adding "C:\Dev-Cpp\lib" to your Code::Blocks compiler library path, you probably just want to install the libs to the Code::Blocks lib directory, heh. And then you can get rid of Dev-C++.
Post Reply