下载源码编译安装postfix,并让它支持mysql。而mysql也是用源码安装的,位置是/usr/local/mysql
按官方的文档用下面指令为编译作准备
make -f Makefile.init makefiles 'CCARGS=-DHAS_MYSQL -I/usr/local/mysql/include/mysql' 'AUXLIBS=-L/usr/local/mysql/lib/mysql -lmysqlclient -lz -lm'
却出错了:
/usr/bin/ld: cannot find -lmysqlclient
collect2: ld returned 1 exit status
make: *** [master] Error 1
make: *** [update] Error 1
后通过搜索得知是libmysqlclient的位置问题,将libmysqlclient.so.16复制到/usr/lib下解决~
我想将libmysqlclient文件所在的目录加入到path中,也应该可以
此时,本人创建一个postfix用户和postdrop组。却在创建postfix时自作聪明地将该用户的主目录给删除了,以致后来的make install一直出错,搞了两天。
Please specify the group for mail submission and for queue management commands. Specify a group name with a numerical group ID that is not shared with other accounts, not even with the Postfix mail_owner account. You can no longer specify "no" here. setgid_group: [postdrop] postdrop
postfix-install: Error: "y" should be "no" or an absolute
path name. make: *** [install] Error 1
无论用组名还是用GID都无法通过,郁闷了一天。后向一网友请教,经他一提醒,回来逐步检查测试才发现是postfix的主目录没有定义引起的~
按官方的文档用下面指令为编译作准备
make -f Makefile.init makefiles 'CCARGS=-DHAS_MYSQL -I/usr/local/mysql/include/mysql' 'AUXLIBS=-L/usr/local/mysql/lib/mysql -lmysqlclient -lz -lm'
却出错了:
/usr/bin/ld: cannot find -lmysqlclient
collect2: ld returned 1 exit status
make: *** [master] Error 1
make: *** [update] Error 1
后通过搜索得知是libmysqlclient的位置问题,将libmysqlclient.so.16复制到/usr/lib下解决~
我想将libmysqlclient文件所在的目录加入到path中,也应该可以
此时,本人创建一个postfix用户和postdrop组。却在创建postfix时自作聪明地将该用户的主目录给删除了,以致后来的make install一直出错,搞了两天。
Please specify the group for mail submission and for queue management commands. Specify a group name with a numerical group ID that is not shared with other accounts, not even with the Postfix mail_owner account. You can no longer specify "no" here. setgid_group: [postdrop] postdrop
postfix-install: Error: "y" should be "no" or an absolute
path name. make: *** [install] Error 1
无论用组名还是用GID都无法通过,郁闷了一天。后向一网友请教,经他一提醒,回来逐步检查测试才发现是postfix的主目录没有定义引起的~
转载于:https://blog.51cto.com/motus/110946