Thoughts on the age-old cyradm thingie
Jay Levitt
jay-cyrus at shopwatch.org
Sun Nov 17 23:52:25 EST 2002
I'm new to Cyrus imapd - and, for that matter, to autoconf, perl, Linux,
younameit. Building cyrus-imapd-2.1.10 on Mandrake 9.0, I ran into a
problem that people have been running into for years: perl wants to find
modules like Shell.pm under /usr/lib/perl5, but Shell.pm is actually getting
installed under /usr/local/lib/perl5.
It turns out that line 83 of perl/Makefile.in is set to pass @prefix@ to
perl/imap/Makefile.PL, the MakeMaker, er, maker. Reading the resulting
perl/imap/Makefile, I get the impression that on most platforms, variables
like INSTALLSITELIB are hardcoded to /usr/..., but on Mandrake, they are set
to $PREFIX/... instead. Manually running Makefile.PL with no arguments
fixes the problem; MakeMaker seems to know the "right" place to put things
by default.
A quick fix might be for perl/Makefile to only pass @prefix@ to
perl/imap/Makefile.PL if it is not equal to $ac_default_prefix from
configure. That way, default installs work, and explicit installs to
different places work too. (Or at least they work to the extent they work
today, which assumes that whatever your --prefix is, there are some
site_perl directories in your @INC@ path. I have no idea how valid an
assumption that really is, or if it's worth having configure warn you if you
change your prefix.)
An alternate fix would be for configure to go find perl, see where it's
installed, add a new --perl-prefix argument that defaults here, and then
pass THAT to Makefile.PL instead.
Cyrus folks, what do you think? I don't have the background to know which
of these two ideas is actually more portable or correct, but this problem
seems to pop up fairly consistently on info-cyrus and on newsgroups.. sure
would be nice to fix it.
Jay Levitt
More information about the Info-cyrus
mailing list