compiling IMAP

Whether you are using Linux on the desktop or as a server, it's still good that you're using Linux. Linux related questions go here.

Moderator: General Moderators

Post Reply
Ree
Forum Regular
Posts: 592
Joined: Fri Jun 10, 2005 1:43 am
Location: LT

compiling IMAP

Post by Ree »

I'm trying to add IMAP support to PHP 5.1.4. For that I need to compile IMAP. So I downloaded IMAP-2004g and tried to compile it, but I get errors without any explanations.

Code: Select all

[root@admin imap-2004g]# make lrh
make build EXTRACFLAGS='' EXTRALDFLAGS='' EXTRADRIVERS='mbox' EXTRAAUTHENTICATORS='' PASSWDTYPE=std SSLTYPE=nopwd IP=4 EXTRASPECIALS='' BUILDTYPE=lnp \
SPECIALS="GSSDIR=/usr/kerberos SSLDIR=/usr/share/ssl SSLINCLUDE=/usr/include/openssl SSLLIB=/usr/lib LOCKPGM=/usr/sbin/mlock" \
EXTRACFLAGS=" -I/usr/kerberos/include"
make[1]: Entering directory `/usr/local/imap-2004g'
Building c-client for lnp...
echo `cat SPECIALS`  > c-client/SPECIALS
cd c-client;make lnp EXTRACFLAGS='-I/usr/kerberos/include'\
 EXTRALDFLAGS=''\
 EXTRADRIVERS='mbox'\
 EXTRAAUTHENTICATORS=''\
 PASSWDTYPE=std SSLTYPE=nopwd IP=4\
 GSSDIR=/usr/kerberos SSLDIR=/usr/share/ssl SSLINCLUDE=/usr/include/openssl SSLLIB=/usr/lib LOCKPGM=/usr/sbin/mlock
make[2]: Entering directory `/usr/local/imap-2004g/c-client'
make build EXTRACFLAGS='-I/usr/kerberos/include' EXTRALDFLAGS='' EXTRADRIVERS='mbox' EXTRAAUTHENTICATORS='' PASSWDTYPE=std SSLTYPE=nopwd IP=4 `cat SPECIALS` OS=lnx \
 SIGTYPE=psx CHECKPW=pam CRXTYPE=nfs \
 SPOOLDIR=/var/spool \
 ACTIVEFILE=/var/lib/news/active \
 RSHPATH=/usr/bin/rsh \
 BASECFLAGS="-g -fno-omit-frame-pointer -O2" \
 BASELDFLAGS="-lpam -ldl"
make[3]: Entering directory `/usr/local/imap-2004g/c-client'
sh -c 'rm -rf auths.c crexcl.c nfstest.c linkage.[ch] siglocal.c osdep*.[ch] *.o ARCHIVE *FLAGS *TYPE c-client.a || true'
Once-only environment setup...
echo cc > CCTYPE
echo -g -fno-omit-frame-pointer -O2 '-I/usr/kerberos/include' > CFLAGS
echo -DCREATEPROTO=unixproto -DEMPTYPROTO=unixproto \
 -DMAILSPOOL=\"/var/spool/mail\" \
 -DANONYMOUSHOME=\"/var/spool/mail/anonymous\" \
 -DACTIVEFILE=\"/var/lib/news/active\" -DNEWSSPOOL=\"/var/spool/news\" \
 -DRSHPATH=\"/usr/bin/rsh\" -DLOCKPGM=\"/usr/sbin/mlock\" > OSCFLAGS
echo -lpam -ldl  > LDFLAGS
echo "ar rc c-client.a osdep.o mail.o misc.o newsrc.o smanager.o utf8.o siglocal.o dummy.o pseudo.o netmsg.o flstring.o fdstring.o rfc822.o nntp.o smtp.o imap4r1.o pop3.o unix.o mbx.o mmdf.o tenex.o mtx.o news.o phile.o mh.o mx.o;ranlib c-client.a" > ARCHIVE
echo lnx > OSTYPE
./drivers mbox imap nntp pop3 mh mx mbx tenex mtx mmdf unix news phile dummy
./mkauths  md5 pla log
make[4]: Entering directory `/usr/local/imap-2004g/c-client'
echo -DMD5ENABLE=\"/etc/cram-md5.pwd\" >> OSCFLAGS
make[4]: Leaving directory `/usr/local/imap-2004g/c-client'
ln -s os_lnx.h osdep.h
ln -s os_lnx.c osdepbas.c
ln -s log_std.c osdeplog.c
ln -s sig_psx.c siglocal.c
ln -s crx_nfs.c crexcl.c
ln -s ip4_unix.c ip_unix.c
ln: `ip_unix.c': File exists
make[3]: *** [onceenv] Error 1
make[3]: Leaving directory `/usr/local/imap-2004g/c-client'
make[2]: *** [lnp] Error 2
make[2]: Leaving directory `/usr/local/imap-2004g/c-client'
make[1]: *** [OSTYPE] Error 2
make[1]: Leaving directory `/usr/local/imap-2004g'
make: *** [lrh] Error 2
I have no clue why it doesn't work. Also, I'm on Fedora.

Anyone could explain me why?

If someone can tell me a better way to enable IMAP support in PHP than the one described on php.net, please let me know.
Post Reply