Howto: ArcEmu on Slackware

How to compile ArcEmu on Slackware

.

Step 1: Create a user [optional]

Run the following as root:
useradd -d /home/arcemu -s /bin/bash -p users -m arcemu
passwd arcemu -d
useradd explained:
  • -d /home/arcemu — This is where the home directory is located
  • -s /bin/bash — This the the shell the user will use (If you prefer another then use it.)
  • -p users — This is the primary group the user belongs to. In the case we don’t need anymore rights than this.
  • -m — This will create the home directory if it doesn’t exist
  • arcemu — The username we are creating.
passwd explained:
  • arcemu — The account we want to work with.
  • -d — This removes the password for the account – THIS IS A SECURITY RISK but it allows me to script it a little easier. You should change this password to something you can remember!
Why create an account for this? The nice thing is that all of arcemu will be packaged up in a single home directory. If we move to another box we only have to worry about one folder to archive. For me, this also makes the build environment clean and I don’t clutter the rest of my linux box with things that won’t be used globally. It should also make nightly or weekly builds easier.
.

Step 2: Install Pre-Requirements [required]

None

.

Step 3: Download and Build ArcEmu [required]

[optional] We can or are running everything as our normal user, arcemu in my case. ‘su – arcemu’
Get the latest sources of arcemu
LC_CTYPE=en_US.UTF-8
svn co https://arcemu.svn.sourceforge.net/svnroot/arcemu/trunk arcemu
Build ArcEmu
cd arcemu &&
mkdir buildarcemu &&
cd buildarcemu &&
cmake ../cmake
  -DCMAKE_INSTALL_PREFIX=$HOME/arcemu
  -DARCEMU_CONFIGSFILE_PATH=$HOME/arcemu/etc
  -DARCEMU_SCRIPTLIB_PATH=$HOME/arcemu/lib
  -DBUILD_EVENTSCRIPTS=1
  -DBUILD_INSTANCESCRIPTS=1  
  -DBUILD_EXTRASCRIPTS=1  
  -DBUILD_GOSSIPSCRIPTS=1  
  -DBUILD_QUESTSCRIPTS=1  
  -DBUILD_MISCSCRIPTS=1  
  -DBUILD_SERVERSTATUSPLUGIN=1  
  -DBUILD_LUABRIDGE=1
  -DBUILD_LUAENGINE=0
  -DCMAKE_CXX_FLAGS="-mmmx -msse -msse2 -msse4"
  -DCMAKE_C_FLAGS="-mmmx -msse -msse2 -msse4" &&
make -j 2 || make &&
make install
The flags to be concerned about are the LINKER_FLAGS. The C_FLAGS and CXX_FLAGS you can add extra compile optimizations that may or may not help. I was just experimenting and used MMX as most procs now days have that extension.
.
About “make -j 2″: Generally, you use “-j (number of processors + 1)” but there are a few other considerations… For example, my build machine only has 512Mb of RAM (a virtual machine) and if i go beyond “-j 2″, I run out of memory and it kills the make job… So adjust this to whatever you need. (the “|| make” part says, if the first command fails, then fail back to this simpler form of make (equiv to “make -j 1″).)
.
I’ve added ‘arcemu.SlackBuild’ script that creates a nice package to install. (Sometimes the build will fail due to source issues in source control.)
.

Step 4: Installing the Database and Beyond

This how-to won’t cover that as Slackware isn’t any different than Ubuntu, CentOS or (insert distribution here) in that respect. Please refer to the official article on the ArcEmu wiki.
.

SlackBuilds

These SlackBuilds are self contained. They download the needed files and build the package auto-matically and it’s done the Slackware way.
.
arcemu.SlackBuild – The server itself.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>