vendredi 21 septembre 2007
courier-authlib 0.59.3 et auth_vchkpw_login
Par Mathieu Feulvarc'h, vendredi 21 septembre 2007 à 20:19 :: Qmail
Avec la version 0.59.3 de courier-authlib, il est possible de tomber sur une erreur du type:
authvchkpw.c: At top level: authvchkpw.c:103: error: static declaration of 'auth_vchkpw_login' follows non-static declaration authvchkpw.c:86: error: previous implicit declaration of 'auth_vchkpw_login' was here authvchkpw.c: In function 'auth_vchkpw_changepass': authvchkpw.c:184: warning: passing argument 1 of 'parse_email' discards qualifiers from pointer target type
Le probleme vient d'une liberte prise lors du developpement que GCC ne supporte pas. Pour le resoudre, il faut utiliser le patch suivant:
--- courier-authlib-0.59.3/authvchkpw.c 2007-04-22 20:53:30.000000000 +0200
+++ courier-authlib-0.59.3b/authvchkpw.c 2007-04-25 17:53:58.908980669 +0200
-55,16 +55,19
return (*i->callback_func)(a, i->callback_arg);
}
#if HAVE_HMACLIB
#include "libhmac/hmac.h"
#include "cramlib.h"
+static int auth_vchkpw_login(const char *service, char *authdata,
+ int (*callback_func)(struct authinfo *, void *), void *callback_arg);
+
static int auth_vchkpw_cram(const char *service,
const char *authtype, char *authdata,
int (*callback_func)(struct authinfo *, void *),
void *callback_arg)
{
struct cram_callback_info cci;
Vous creez alors un fichier, vous faite un "patch < nom_fichier" et la commande "make" devrait aller jusqu'au bout. (merci a broza pour avoir annonce mon erreur)
