Compiling: Windows

From ArcEmu-Wiki
Revision as of 07:19, 17 August 2011 by Dfighter (Talk | contribs)
Jump to: navigation, search

ArcEmu currently ONLY supports: 3.3.5a 12340 June 29, 2010



NOTE:
The express(free) version of Visual Studio does not contain 64 bit tools, purchasing a version such as Visual Studio 2010 Professional allows you to then compile code in 64 bit without a problem See the end of the page


Please note that you don't NEED the 64bit version. The 32bit version binaries will run fine, even if you are on a 64bit system!

Contents




Requirements

You will need a C++ Compiler. The following explanations are based on Visual C++ Express 2010 which is freely available.

Please note that Visual C++ 2010 requires Windows XP SP2 at least and therefore that is Arcemu's minimum requirement as well!

Besides Visual Studio 2010, you will need CMake to generate the project files to allow you to build. Download CMake here. Install with a desktop icon (for simplicity of the guide).


The following explanations are also based on the trunk source. Please adapt if your Source differs.


Generating the build environment

Arcemu now uses the CMake cross platform build system, this means that before you can begin to build you will have to generate the build files. If you are having problems generating the solution files or you want to know what some of the options are when generating the project files, use one of the guides on this page.


Compiling

Browse to where you have generated the build files.

Then open

"Arcemu.sln"
  • (Includes Scripting Engines, Instance Scripts, Area Scripts)


Now we may move onto building.


Building

This will be written in sub steps to attempt to explain in more detail the steps to compiling.

None of these steps can be skipped if you are to produce a working server. Read carefully


Opening the Project File will take some time at first, the program will parse everything and get the interface set up for first use.


assuming you have not ran VS2010 before.

  • A box will come up asking what your target language will be. Click "Microsoft Visual Studio C++"

If you have done this step before move on.


1. (Building the Code)

  • Go to the previous menu in the toolbar or press F7 to "Build Solution"

Read: Sometimes the project will error out saying it could not "create a file", clean your build by accessing the "Build" menu, shutdown VC2010 and retry.

  • The program will do some work and compile the code and related link libraries, sit back for a bit.
  • If your build was successful(you followed this guide to a T) you will get an output similar to this.

201108170026.jpg

2. (Copying main files)

Now that you have a successful build of ArcEmu you need to install/copy the files. You can do that by selecting the INSTALL project in Visual Studio, right clicking on it, then selecting Project-Only -> Build only INSTALL.


201108170027.jpg


After doing this, you should see something similar to this

201108170028.jpg


BUT HALT!

There are extra things to be done now for first time builders! Your server will NOT have these libraries built in!

3.' (Copying Libraries)

  • Migrate to "trunk\dep\DLL"
  • Copy "Libmysql.dll" and "Libeay32.dll" to your Server Directory ex. C:\ArcEmu\"
  • Remember to use 32 or 64 bit DLLs matching whichever configuration you built ArcEmu in.

3½. (Extracting and Copying DBCs, maps, and vmaps.)

~ DBC Extraction ~

Ico info.png DBC & map Extraction is now on its OWN page. Please come back to THIS page when you are done extracting DBCs!


To extract DBCs, follow the guide on the page below.

Compiling:_DBC_Extraction

4 Vmaps

Vmaps are the advanced g3d engine ArcEmu supports, you will have to turn these on if you preform this step later on. Vmaps take up quite a bit of space and are extracted just as Maps are, but with an extra step.


Ico info.png It does not matter where you put the extractor, it operates on registry path. If you wanted to you can put it in the ArcEmu root directory and run it, and not have to move the vmaps folder anywhere after extracting.



  • Run makevmaps_SIMPLE.bat and wait for it to finish, it will take about 4 minutes depending on the performance of your system.
  • After it is finished extracting files, the new folder vmaps will have all information within it, copy this to the ArcEmu root directory.
Ico info.png Keep in mind that with each patch, the vmaps extractor will need to be downloaded again, and the new data assembled for the each new patch.



Arcemu CAN run without Maps or Vmaps, however functionality will be lost.

Anything that relies on maps internally will fail, that means; spells, line of sight, indoor dismounting checks, random waypoint generation, some waypoints, scripts that depend on maps, and possibly graveyards.


Arcemu CANNOT run without DBC files in the proper directory.

Additional Notes

Compiling for X64 target platform


Users finding it impossible to compile ArcEmu X64 target platform,

"x64 compilers are not available for the Visual Studio Express edition IDEs. Microsoft targets the Express IDEs at students and hobbyists." [1]

This means that the express(usually free) version of visual studio does not contain 64 bit compilers, purchasing a version such as Visual Studio 2010 Professional allows you to then compile code in 64 bit without a problem, however it has a significantly larger footprint on your system than the express version.


Please once again note, that you don't NEED the 64bit version, the 32bit version will run just fine on your 64bit system.




Conclusion

You have successfully compiled your server, you're now ready to move on to Database setup.


Additional help

Template:P2P IRC

Personal tools