Hi Folks,
I've had a bit of hassle recently trying to compile VPopMail 5.2.1/5.3.8 with
the Oracle authentication module. Having had a bit of a poke about the
archives for this mailing list I see that a few other people have had the
same problems and no one has posted a solution yet.
First I want to give a little background so that if anyone wants to pick up
where I've left off it will be a little easier.
VPopMail uses a number of different authentication modules. Which one you're
going to use is defined when you run ./configure and the chosen file is
symlinked to auth.c (auth.h remains unchanged). In the case of the Oracle
module the authentication file is voracle.c which has been produced by
running Pro*C (oracle's precompiler) on voracle.pc.
Also, during ./configure, the file config.h is produced. This contains
various #define statements depending on which arguments you have passed to
configure. Many of these #defines are used by the c preprocessor to chose
which particular parts of the program(s) are to be compiled. Therefore the
arguments passed to ./configure are very important.
OK, on to the build.
Make sure that Oracle's precompiler (proc) is installed and working. You
have no chance of building vpopmail with oracle support without proc. Test
it out on it's demo files.
Unpack the archive with
gunzip < vpopmail-5.2.1.tar.gz | tar xvf -
and
cd vpopmail-5.2.1
You need to make 2 changes to voracle.pc so open it up in an editor and make
the following changes:
voracle.pc line 630, change MYSQL_DEFAULT_TABLE to ORACLE_DEFAULT_TABLE
voracle.pc line 334, change memset(pwent, 0, sizeof(pwent)); to
memset(&pwent, 0, sizeof(pwent));
save voracle.pc and run it through the oracle precompiler
proc voracle.pc
this will produce the voracle.c file.
Now you need to run configure. remember that the arguments passed to
configure are extrememly important and you may need to experiment a little.
The arguments that have worked for me are :-
./configure --enable-oracle=y
--enable-incdir=/opt/oracle/product/817/precomp/public
--enable-libdir=/opt/oracle/product/817/lib --enable-auth-logging=n
--enable-mysql=n --enable-many-domains=y --enable-file-locking=y
--enable-clear-passwd=n
You will have to adjust the path details for the include directory and
library directory to suit your system and there may be a little scope for
experimentation with the other options, but be careful. As I mentioned
above; many of the options set precompiler directives which determine exactly
which bits of code are/are not compiled. Many of the errors I was getting
and many of the errors listed on this list are due to the compiler trying to
build incorrect pieces of code.
Finally you need to add a #define macro to config.h so open it with an editor
and go to the end and add the following line:
#define SITE_SIZE 10000000
I've just picked 10000000 as an arbitary value. You will probably want to
experiment with this and find something suitable for your needs.
OK, we're done. type
make
and it should compile. Hope this works out for you and many thanks to Ken for
helping me out.
regards, dunch.