[pre-install]
look for old installs
rpm -qa | grep -i apache
rpm -qa | grep -i httpd
rpm -qa | grep -i php
rpm -qa | grep -i mysql
uninstall these packages
rpm -e filename
#note:packages dependances
[install mysql]
my mysql tar: mysql-5.0.27.tar.gz
groupadd mysql
useradd -g mysql -d /usr/local/mysql/data -M mysql
tar zxvf mysql-5.0.27.tar.gz
cd mysql-5.0.27
./configure --prefix=/usr/local/mysql --sysconfdir=/etc/ --localstatedir=/usr/local/mysql/data --enable-assembler --with-mysqld-ldflags=-all-static --with-charset=utf8 --with-extra-charsets=all --with-mysqld-user=mysql
make&&make install
/usr/local/mysql/bin/mysql_install_db
chown -R mysql:mysql /usr/local/mysql/data
cp /usr/local/mysql/share/mysql/mysql.server /etc/rc.d/init.d/mysqld
chkconfig --add mysqld
cp /usr/local/mysql/share/mysql/my-medium.cnf /etc/my.cnf
cd /usr/local/mysql/bin
for file in *; do ln -s /usr/local/mysql/bin/$file /usr/bin/$file; done
mkdir /usr/include/mysql
cp /usr/local/mysql/include/mysql/* /usr/include/mysql/
cp -rf /usr/local/mysql/lib/mysql /usr/lib/
updatedb
ln -s /usr/lib/mysql/libmysqlclient_r* /usr/lib/ #no such files, why? only can copy from other systems
service mysqld start
mysqladmin -u root password "xxx"
mysql -u root -p #enter password
mysql>create database bn;
mysql>create database ghost;
mkdir /var/lib/mysql
ln -s /tmp/mysql.sock /var/lib/mysql/ #for ghost++ use
[install pvpgn]
#install mysql first
my pvpgn package: pvpgn-1.8.5.tar.gz, pvpgn-support-1.2.tar.gz
tar zxvf pvpgn-1.8.5.tar.gz
cd pvpgn-1.8.5/src
./configure --prefix=/usr/local/pvpgn --with-mysql
make&&make install
tar zxvf pvpgn-support-1.2.tar.gz
mv pvpgn-support-1.2/* /usr/local/pvpgn/var/files
rmdir pvpgn-support-1.2
vim /usr/local/pvpgn/etc/bnetd.conf #change storage mode
cp /usr/local/mysql/lib/mysql/libmysqlclient.so.15 /usr/lib/ #for next command
/usr/local/pvpgn/sbin/bnetd #maybe lack libmysqlclient.so.15
netstat -antl |grep 6200 #test
[install Apache]
my apache package: httpd-2.2.3.tar.bz2
tar jxvf httpd-2.2.3.tar.bz2
cd httpd-2.2.3
./configure --prefix=/usr/local/apache --enable-so
make&&make install
[install php5]
my php5 package: php-5.3.5.tar.bz2
tar jxvf php-5.3.5.tar.bz2
cd php-5.3.5
./configure --prefix=/usr/local/php --with-apxs2=/usr/local/apache/bin/apxs --with-mysql=/usr/local/mysql
make &&make install
[install boost]
my boost package: boost_1_45_0.tar.bz2
tar jxvf boost_1_45_0.tar.bz2
cd boost_1_45_0
./bootstrap.sh --with-libraries=all --prefix=/usr/local/boost --exec-prefix=/usr/local/boost
./bjam
./bjam install
rm -rf /usr/include/boost
cp -rf /usr/local/boost/include/boost /usr/include/
cp /usr/local/boost/lib/* /usr/lib/
[install ghost++]
unzip ghostplusplus_17.1.zip
cd ghost/bncsutil/src/bncsutil/ (may need install libgmp3-dev)
make&&make install
cd ghost/StormLib/stormlib/zlib
make && make install
cd ghost/StormLib/stormlib/bzip2
make && make install
cd ghost/StormLib/stormlib/
make&&make install
cd ghost/ghost
change this in Makefile:
-DBOOST_FILESYSTEM_VERSION=2
(install mysql_dev for ubuntu: sudo aptitude install libmysql++-dev)
(install mysql_dev for fedora: yum install mysql-devel)
make
mkdir /usr/local/ghost++
cd ..
cp -r maps/ mapcfgs/ replays/ savegames/ /usr/local/ghost++/
cp ghost/ghost++ default.cfg /usr/local/ghost++/
cp gameloaded.txt gameover.txt ipblacklist.txt ip-to-country.csv /usr/local/ghost++/
cp language.cfg mysql_create_tables_v2.sql /usr/local/ghost++/
cd /usr/local/ghost++
mysql -u root -p ghost
edit the default.cfg and copy game.dll Storm.dll war3.exe War3Patch.mpq from warcraft iii
./ghost++