Problems compiling 1.1.2 under FreeBSD 5.0-CURRENT:

c++  -O -pipe -march=pentiumpro    -o bincimapd  bincimapd.o broker.o depot.o 
exceptions.o initconfig.o  pendingupdates.o session.o liboperators_nonauth.a 
liboperators_auth.a liboperators_selected.a -Lparsers/imap -limapparser 
-Lparsers/imap/recursivedescent -lrecursivedescent -Lparsers/storage -lstorage 
-Lparsers/args -largs -Lmailbox/maildir -lmaildir -Lmailbox -lmailbox -Lparsers/mime 
-lmime -Lio -lio -Lutil -lutil source='authenticate.cc' object='authenticate.o' 
libtool=no depfile='.deps/authenticate.Po' tmpdepfile='.deps/authenticate.TPo' 
depmode=gcc3 /bin/sh ../depcomp  c++ -DHAVE_CONFIG_H -I. -I. -I..  -O -pipe 
-march=pentiumpro -c -o authenticate.o `test -f 'authenticate.cc' || echo 
'./'`authenticate.cc
authenticate.cc: In function `int Binc::authenticate(Binc::Depot&, const std::string&, 
const std::string&)':
authenticate.cc:225: `kill' undeclared (first use this function)
authenticate.cc:225: (Each undeclared identifier is reported only once for each 
function it appears in.)
*** Error code 1

kill() is declared in <signal.h> under FreeBSD, which is not included in
this file. Adding the include fixes the problem.

In addition to that, under FreeBSD 4.8-RC gid_t is defined in
<sys/types.h>, which needs to be included before <grp.h> in order for
src/authenticate.cc to compile successfully.

The following patch addresses both issues:

--- src/authenticate.cc.orig    Sat Mar 29 11:28:22 2003
+++ src/authenticate.cc Sun Mar 30 23:03:38 2003
@@ -34,6 +34,8 @@
 #include <string>
 #include <vector>
 
+#include <sys/types.h>
+#include <signal.h>
 #include <grp.h>
 #include <pwd.h>
 #include <sys/wait.h>

Sergei

Reply via email to