PowerMail安装的几点记录

今天安装PowerMail,费了不少周折。
刚开始是找不到mysql的include
server2:/usr/soft/powermail-1.7# make
make  all-recursive
make[1]: Entering directory `/usr/soft/powermail-1.7'
Making all in codedocs
make[2]: Entering directory `/usr/soft/powermail-1.7/codedocs'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/usr/soft/powermail-1.7/codedocs'
Making all in userbases
make[2]: Entering directory `/usr/soft/powermail-1.7/userbases'
Making all in mysqlpdns
make[3]: Entering directory `/usr/soft/powermail-1.7/userbases/mysqlpdns'
source='mysqlpdns.cc' object='mysqlpdns.o' libtool=no \
depfile='.deps/mysqlpdns.Po' tmpdepfile='.deps/mysqlpdns.TPo' \
depmode=gcc3 /bin/sh ../../depcomp \
c++ -DHAVE_CONFIG_H -I. -I. -I../.. -I../..   -I/usr/local/mysql5/include/mysql  -Wall -pthread -O2 -c -o mysqlpdns.o `test -f mysqlpdns.cc || echo './'`mysqlpdns.cc
In file included from mysqlpdns.hh:29,
                from mysqlpdns.cc:20:
../../smysql.hh:24:25: mysql/mysql.h: No such file or directory
In file included from mysqlpdns.hh:29,
                from mysqlpdns.cc:20:
../../smysql.hh:40: error: 'MYSQL' is used as a type, but is not defined as a
  type.
make[3]: *** [mysqlpdns.o] Error 1
make[3]: Leaving directory `/usr/soft/powermail-1.7/userbases/mysqlpdns'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/usr/soft/powermail-1.7/userbases'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/soft/powermail-1.7'
make: *** [all] Error 2
估计跟我把mysql安装在特定目录有关。把路径在smysql.hh专门指定就行
#vi smysql.hh
#include
修改成
#include
重新编译通过。
然后是在make install的时候出现问题
mkdir -p /usr/local/etc
//usr/local/sbin/powersmtp: error while loading shared libraries: libmysqlclient.so.15: cannot open shared object file: No such file or directory
make[2]: *** [install-data-local] Error 127
make[2]: Leaving directory `/usr/soft/powermail-1.7'
make[1]: *** [install-am] Error 2
make[1]: Leaving directory `/usr/soft/powermail-1.7'
make: *** [install-recursive] Error 1
解决方法是
#vi /etc/ld.so.conf
添加
/usr/local/mysql5/lib/mysql
然后
#ldconfig -v
#make install
OK!