On Thu, 2003-10-02 at 20:57, Tim Miller wrote:
First, thanks to Timo for solving my last issue. I got dovecot up and running on one of my machines, and it does exactly what I want. Now I'm trying to install dovecot on an older box (glibc 2.0.7 Linux kernel 2.0.36), and encountering some problems:
-- firstly autoconf/automake does not seem to correctly deal with the madvise function on this system. It detects that we don't have madvise, yet it's prototyped in /usr/include/sys/mman.h. This causes the compilation to fail when dovecot tries to redefine this function.
-- I attempted to solve this problem by renaming the function dovecot prototypes to dc_madvise and then changed all the calls in the code (and the implementation) from madvise to dc_madvise. This allows the code to compile correctly.
Well, I fixed it in a bit easier way :) diff -u -r1.4 -r1.5 --- mmap-util.h 28 Oct 2002 09:00:25 -0000 1.4 +++ mmap-util.h 3 Oct 2003 14:50:48 -0000 1.5 @@ -15,7 +15,8 @@ #endif #ifndef HAVE_MADVISE -int madvise(void *start, size_t length, int advice); +# define madvise my_madvise +int my_madvise(void *start, size_t length, int advice); # ifndef MADV_NORMAL # define MADV_NORMAL 0 # define MADV_RANDOM 0
-- However, once the server is installed, it does not appear to work correctly. I can login, but when I try to list my folders or select any folder (one that exists or one that doesn't exist) the connection times out and the following entry is written to the log file:
dovecot: Oct 03 05:38:56 Error: login: received another "not listening" notification (if you can't login at all, see src/lib/fdpass.c)
I tracked this message down in the source, but didn't see any obvious way to trace back the problem.
Linux 2.0.x kernels requires changes in the source to work. I didn't think anyone would really bother trying Dovecot with 2.0 kernels anymore so there was only a comment about it there. Apply the included patch and compile with -DLINUX20 and it should work.