1. 程式人生 > >ubuntu 16.04 編譯安裝 amule

ubuntu 16.04 編譯安裝 amule

安裝依賴

$ sudo apt-get install libcrypto++-utils binutils-dev libcrypto++-dev libgtk2.0-dev  libgeoip-dev  zlib1g-dev libupnp-dev libboost-all-dev libwxbase3.0-dev libwxgtk3.0-dev  build-essential autoconf automake gettext -y


下載libgd 編譯安裝

$ curl -L -O https://github.com/libgd/libgd/releases/download/gd-2.2.5/libgd-2.2.5.tar.gz
$ tar -zxf libgd-2.2.5.tar.gz && cd libgd-2.2.5 $ ./configure && make $ sudo make install


下載wxWidgets 編譯安裝

$ curl -L -O https://github.com/wxWidgets/wxWidgets/releases/download/v3.0.4/wxWidgets-3.0.4.tar.bz2
$ tar -jxf wxWidgets-3.0.4.tar.bz2 && cd wxWidgets-3.0.4
./configure --with-gtk --without-libtiff --without-subdirs --enable-unicode --enable-optimise
$ 
make


這裡wxWidgets 必須使用 3.0,不能使用 3.0 以上,比如 3.1,會報錯


extern/wxWidgets/listctrl.cpp:4864:23: error: ‘OnScroll’ is not a member of ‘wxScrolledWindow’


wxWidgets 執行make就可以,不必make install


編譯amule

先在這裡下載 amule

下載地址: https://sourceforge.net/projects/amule/files/aMule/

我選擇當前的最新版本:2.3.2

$ curl -L https://sourceforge.net/projects/amule/files/aMule/2.3.2/aMule-2.3.2.tar.bz2/download > aMule-2.3.2.tar.bz2
$ tar -jxf aMule-2.3.2.tar.bz2 && cd aMule-2.3.2

 

預編譯

 

$ sudo ./configure --prefix=/usr/local/amule/ \
--enable-debug \
--enable-dependency-tracking \
--enable-amule-daemon \
--enable-amulecmd \
--enable-webserver \
--enable-amule-gui \
--enable-cas \
--enable-wxcas \
--enable-profile \
--enable-optimize \
--enable-static-boost \
--enable-mmap \
--enable-upnp \
--enable-geoip \
--enable-nls \
--enable-alcc \
--enable-alc \
--with-boost \
--with-denoise-level=3 \
--with-wxdir=/path/wxWidgets-3.0.4 \
LIBS=-lX11

 

這裡 --with-wxdir 填原始碼地址

sudo make
sudo make install

 

參考連結

http://wiki.amule.org/wiki/HowTo_Compile_In_Ubuntu
https://github.com/amule-project/amule/issues/55
http://forum.amule.org/index.php?topic=21696.0