opentibia / server

An open source server for the MMORPG Tibia.
GNU General Public License v2.0
414 stars 149 forks source link

how to compile #42

Closed adahox closed 9 years ago

adahox commented 9 years ago

how can i compile the source?

iryont commented 9 years ago

What kind of operating system are you using?

You can use cmake to generate any project you like (e.g. msvc project) or simple use MinGW along with Unix Makefiles generator on Windows to get it compiled.

https://github.com/opentibia/server/wiki

adahox commented 9 years ago

ya. actualy i'm usying windows. will i need some lib? or just open the open tibia project and compile?

iryont commented 9 years ago

Unfortunately you will need several libraries to make it work. Please have a look:

https://github.com/opentibia/server/wiki/Compiling-OTServ-0.7.0-under-Windows-using-MinGW

adahox commented 9 years ago

alright. thanks iryont :D

adahox commented 9 years ago

sorry but i'm getting some error. i googled so hard but i dont find anything helpfull. someone already get this error: src\otpch.h [Error] libxml/xmlmemory.h: No such file or directory

i dont know here find this file. i downloaded all the libraries.

I'm following the tutorial but when i put the come cmake .....i got some error. i really need help :(

OsoSangre commented 9 years ago

My knowledge is a little dated, but it looks like the libxml2 library isn't being linked to properly.

adahox commented 9 years ago

I'm having several problems in the build. I'm giving up compile it. should be something easy. but when I solve one problem. another appears. put all the libraries in the correct place but now generates error in the code.

iryont commented 9 years ago

Do you have libxml in your include/ directory of MinGW or whatever are you using? Did cmake find libxml2? Can you copy the output of cmake generation?

adahox commented 9 years ago

ya. i've libxml and others libs. lock the error in this link:

http://imageshack.com/a/img538/5311/3sonCM.png

iryont commented 9 years ago

You should use cmake as generator for your build files. You can't really add files to Dev-C++ project and expect them to work.

adahox commented 9 years ago

omg iryont. sorry. i dont know how to use cmake :(

ivucica commented 9 years ago

This is not a bug with the OpenTibia Server. It's fairly inappropriate to use the GitHub bug system as a support board.

iryont commented 9 years ago

@ivucica is correct. However, I see no problem in a small support due to pretty much dead user base.

In any case you need to add MinGW to system path:

http://stackoverflow.com/questions/5733220/how-to-add-mingw-bin-directory-to-my-system-path

The next thing you have to do is to follow this tutorial:

https://github.com/opentibia/server/wiki/Compiling-OTServ-0.7.0-under-Windows-using-MinGW

assassina commented 9 years ago

I've noticed that the readme file doesn't include instructions about how to compile. Maybe we should include it in there, as well as a direct link for download of the latest version in trevis (for those who are too noob - or too lazy - to learn how to compile).

adahox commented 9 years ago

ya. do it man. i'm a noob. i dont know how to compile this source. really. it is so hard

iryont commented 9 years ago

I have to agree with @assassina, but in order to create automatic builds I had to implement static linking for the executable. It should be working now.

Travis is having some kind of issue with static linking (related to pthread) - I will have a look later on.