HowTo Compile In Ubuntu

From AMule Project FAQ
Revision as of 20:45, 19 September 2009 by Sturedman (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Work in progress, stop reading NOW.


This page describes how to compile aMule and its required libraries CryptoPP and wxWidgets on Ubuntu 9.04. We will install everything in our home

Install packages

Use Synaptic Package Manager (if you use GNOME) or KPackageKit/Adept (if you use KDE) to install the following packages:

  • g++
  • libgd2-xpm-dev
  • libgeoip-dev
  • zlib1g-dev

Build CryptoPP

Make directory where you want to build and install aMule (we will use /home/me/amule). Download CryptoPP 5.6.0. Unzip it to /home/me/amule/cryptopp and run make. Then run ./cryptest.exe v to validate it (it must print All tests passed!).

Compile and install aMule

Info: What aMule release needs what wxwidgets release?

  • Debian Etch includes aMule 2.1.3 and wxwidgets 2.6.3
  • aMule 2.1.x needs wxwidgets 2.6. You cannot compile it with newer versions of wxwidgets.
  • aMule 2.2.x needs wxwidgets 2.8. You cannot compile it with older versions of wxwidgets.

What developement packages do I need for compiling?

For compiling aMule SVN you need the following packages installed:

  • libcrypto++-dev
  • libgd2-xpm-dev
  • libgeoip-dev
  • libglib2.0-dev
  • libpng12-dev
  • libreadline5-dev
  • libupnp3-dev
  • libwxgtk2.8-dev
  • wx2.8-i18n
  • zlib1g-dev
  • binutils-dev

Warning: 64 bit users need to install a libxcb >= 1.1.92 if they want long uptimes.

Preparing: Compiling and installing wxwidgets

This algorithm works for all Debian flavours.

Note: Recent versions of Ubuntu (Jaunty) have an (almost unpatched) libwxgtk good enough for use with aMule. Note that aMule developers require you compile your own wxWidgets.

To compile aMule, You need to have a current version of wxWidgets installed. To achieve that: Uninstall every possibly previously installed wxwidgets stuff (see How to uninstall wxWidgets and Check if wx is installed twice) You need the following packages installed:

  • flex
  • bison
  • gettext
  • libgtk2.0-dev
  • python-all-dev (>= 2.4.3)
  • python-all-dbg
  • zlib1g-dev
  • libjpeg62-dev
  • libpng12-dev
  • libtiff4-dev
  • libsm-dev
  • libgl1-mesa-dev or libgl-dev
  • libglu1-mesa-dev or libglu-dev
  • libesd0-dev
  • libgnomeprintui2.2-dev
  • libgconf2-dev
  • libgstreamer0.10-dev
  • libgstreamer-plugins-base0.10-dev
  • bc
  1. Download current wxwidgets wxGTK stable release source code tar ball from http://www.wxwidgets.org/downloads/
  2. $ tar xvzf wxgtk-version.tar.gz
  3. $ cd wxGTK-version
  4. $ ./configure --prefix=/usr --with-gtk --enable-unicode --disable-compat24 --enable-optimise
  5. $ make
  6. # make install
  7. # ldconfig

$ = command executed with normal user account
# = command executed with root account

Compiling and installing aMule

Now that You have installed current wxGTK, go on to compile aMule:

  1. Install the needed packages mentioned in "What developement packages do I need for compiling?"
  2. Download aMule source code tar ball from http://www.amule.org (note: For compiling aMule 2.1.3 you'll need a patch aviable HERE
  3. $ tar xvjf aMule-version.tar.bz2
  4. $ cd aMule-version
  5. To have a look what features of aMule You can enable or disable: $ ./configure --help
  6. You should be right with $ ./configure --disable-debug --enable-optimize
  7. $ make
  8. # make install

$ = command executed with normal user account
# = command executed with root account

That's it! Now You can start aMule with command "amule".


You're done...

That's it! Your own compiled aMule is installed on your system and ready to go.

To run aMule, just type "amule". You can check if everything worked by typing "amule -v" and check if the displayed version corresponds with the one you were compiling/installing.

If this HowTo didn't help, you have a rare problem on your system ;-) Take a look at http://www.amule.org (aMule Forums at http://forum.amule.org ) or visit us in #amule on irc.freenode.net and (don't doubt) we'll try to do our best to help you.