[Dovecot] configure: error: unrecognized option: --docdir=/usr/share/doc/dovecot-2.0.11
Hi,
I tried to use ATrpms (http://dl.atrpms.net/all/dovecot-2.0.11-1_126.src.rpm) to rebuild the rpms. It is shown the error message as following: configure: error: unrecognized option: --docdir=/usr/share/doc/dovecot-2.0.11 Try `./configure --help' for more information.
I checked `./configure --help', it did contain the '--docdir' option. I don't know how to fix it.
Then I tried to remove ' --docdir=%{_docdir}/%{name}-%{version} \' and rebuild it again. It is shown another error message as following: mv: cannot stat `/var/tmp/dovecot-2.0.11-1_126-root//usr/share/doc/dovecot-2.0.11': No such file or directory
I tried to modify dovecot.spec again, replace 'mv $RPM_BUILD_ROOT/%{_docdir}/%{name}-%{version} %{_builddir}/%{name}-%{version}/docinstall ' with 'mv $RPM_BUILD_ROOT/%{_docdir}/%{name} %{_builddir}/%{name}-%{version}/docinstall' and rebuild it again.
Antoher error shown 'File must begin with "/": %{_initddir}/dovecot', therefore I add '%define _initddir /etc/rc.d/init.d'
Finally, I can rebuild the RPMS, but it is shown error message again while I install RPMS:
[root@testmail SPECS]# rpm -ivh ../RPMS/x86_64/dovecot-2.0.11-1_126.x86_64.rpm
Preparing... ########################################### [100%]
1:dovecot ########################################### [100%]
/var/tmp/rpm-tmp.13056: line 3: syntax error near unexpected token fi' /var/tmp/rpm-tmp.13056: line 3:
fi'
error: %post(dovecot-2.0.11-1_126.x86_64) scriptlet failed, exit status 2
Please advise me how to fix the problem and thank you in advance.
Best Regards, Bruce
On Tue, 2011-04-05 at 16:11 +0800, Bruce Cheng wrote:
Hi,
I tried to use ATrpms (http://dl.atrpms.net/all/dovecot-2.0.11-1_126.src.rpm) to rebuild the rpms. It is shown the error message as following: configure: error: unrecognized option: --docdir=/usr/share/doc/dovecot-2.0.11 Try `./configure --help' for more information.
I checked `./configure --help', it did contain the '--docdir' option. I don't know how to fix it.
I guess your autoconf/automake is too old. Although I don't know why the rpm builder wants to regenerate configure.
Hi,
Thank you for your soon reply. I tried to build RPMS from source rpm file, due to I don't need to use some API such llike postgresql, sqlite and so on.
I tried to upgrade automake and autoconf, but they all are new enough.
# yum install automake autoconf Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile
- addons: centos.tt.co.kr
- base: mirror.yongbok.net
- extras: mirror.yongbok.net
- rpmforge: fr2.rpmfind.net
- updates: mirror.yongbok.net Setting up Install Process Package automake-1.9.6-2.3.el5.noarch already installed and latest version Package autoconf-2.59-12.noarch already installed and latest version Nothing to do
Please advise me how to fix this issue and thank you in advance.
2011/4/5 Timo Sirainen <tss@iki.fi>
On Tue, 2011-04-05 at 16:11 +0800, Bruce Cheng wrote:
Hi,
I tried to use ATrpms (http://dl.atrpms.net/all/dovecot-2.0.11-1_126.src.rpm) to rebuild the rpms. It is shown the error message as following: configure: error: unrecognized option: --docdir=/usr/share/doc/dovecot-2.0.11 Try `./configure --help' for more information.
I checked `./configure --help', it did contain the '--docdir' option. I don't know how to fix it.
I guess your autoconf/automake is too old. Although I don't know why the rpm builder wants to regenerate configure.
-- Best Regards, Bruce
On 6.4.2011, at 8.09, Bruce Cheng wrote:
I tried to upgrade automake and autoconf, but they all are new enough.
Package automake-1.9.6-2.3.el5.noarch already installed and latest version Package autoconf-2.59-12.noarch already installed and latest version
The --docdir option exists only if you have autoconf 2.60.
Dear Timo,
You are very top. I found the the newer version of autoconf via http://rpmfind.remotelan.net/linux/rpm2html/search.php?query=autoconf. After upgrading it, I can rebuild the rpms.
But when I install the rpms, it failed again.
[root@testmail SPECS]# rpm -ivh
/usr/src/redhat/RPMS/x86_64/dovecot-2.0.11-1_126.x86_64.rpm
/usr/src/redhat/RPMS/x86_64/dovecot-devel-2.0.11-1_126.x86_64.rpm
Preparing... ########################################### [100%]
1:dovecot ########################################### [ 50%]
/var/tmp/rpm-tmp.63117: line 3: syntax error near unexpected token fi' /var/tmp/rpm-tmp.63117: line 3:
fi'
error: %post(dovecot-2.0.11-1_126.x86_64) scriptlet failed, exit status 2
2:dovecot-devel ########################################### [100%]
Is there any one met the same problem like this ?
Please advise me and thank you in advance.
2011/4/6 Timo Sirainen <tss@iki.fi>:
On 6.4.2011, at 8.09, Bruce Cheng wrote:
I tried to upgrade automake and autoconf, but they all are new enough.
Package automake-1.9.6-2.3.el5.noarch already installed and latest version Package autoconf-2.59-12.noarch already installed and latest version
The --docdir option exists only if you have autoconf 2.60.
-- Best Regards, Bruce
participants (2)
-
Bruce Cheng
-
Timo Sirainen