PHP
downloads | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

imap_8bit> <read_exif_data
Last updated: Sat, 17 Jul 2004

view this page in

XLIII. IMAP, POP3 그리고 NNTP 함수

이 함수를 작동시키려면, --with-imap 옵션으로 PHP를 컴파일해야 한다. 이 옵션은 c-client 라이브러리가 요구된다. ftp://ftp.cac.washington.edu/imap/으로부터 최신 버전을 내려받아 컴파일 하시오. 그리고 c-client/c-client.a파일을 /usr/local/lib/libc-client.a로,또는 다른 링크 경로에 복사하시오. c-client/rfc822.h, mail.hlinkage.h/usr/local/include이나 다른 include경로에 복사하시오.

이 함수는 그 이름에도 불구하고, IMAP 프로토콜에만 한정되어 있지 않다. 이함수의 기초를 이루는 c-client 라이브러리는 또한 NNTP, POP3 그리고 로컬 메일함 접근 메쏘드를 지원한다.

이 문서는 여기서 제공되는 함수에 관계된 모든 주제를 설명 할 수는 없다. 더 자세한 정보는 c-client 라이브러리 소스의 문서에 제공된다 (docs/internal.txt). 그리고 다음 RFC 문서들도 이와 관련된 정보를 제공한다:

  • RFC821: Simple Mail Transfer Protocol (SMTP).

  • RFC822: Standard for ARPA internet text messages.

  • RFC2060: Internet Message Access Protocol (IMAP) Version 4rev1.

  • RFC1939: Post Office Protocol Version 3 (POP3).

  • RFC977: Network News Transfer Protocol (NNTP).

  • RFC2076: Common Internet Message Headers.

  • RFC2045 , RFC2046 , RFC2047 , RFC2048 & RFC2049: Multipurpose Internet Mail Extensions (MIME).

더 자세한 사항은 David Wood씨가 저술한 Programming Internet Email 과 Dianna Mullet씨와 Kevin Mullet씨가 같이 저술한 Managing IMAP를 참고하시오.

차례
imap_8bit --  8비트 문자열을 quoted-printable 문자열로 변환한다
imap_alerts --  이 함수는 현재 페이지 요구(page request)동안이나,또는 경고 스택(alert stack)이 리셋(reset)된 이후에 발생한 경고(alert)메시지 (물론 있다면) 모두를 돌려준다
imap_append --  특정 메일박스에 문자열 메시지를 덧붙인다.
imap_base64 -- BASE64로 엔코딩된 텍스트를 디코딩한다
imap_binary --  8비트 문자열을 base64문자열로 변환한다
imap_body -- 메시지의 본문을 읽어온다
imap_bodystruct --  Read the structure of a specified body section of a specific message
imap_check -- 현재 메일 박스를 체크한다
imap_clearflag_full -- 메시지에서 플래그(flags)를 클리어(clear)한다
imap_close -- IMAP 스트림을 닫는다
imap_createmailbox -- 새 메일 박스를 만든다
imap_delete --  현재 메일 박스에서 삭제될 메시지를 표시한다
imap_deletemailbox -- 메일 박스를 지운다
imap_errors --  이 함수는 현재 페이지 요구(page request)동안에, 또는 에러 스택(error stack)이 리셋(reset)된 이후에 발생한 IMAP 에러(물론 있다면)를 모두 돌려준다
imap_expunge -- 지움 표시된 모든 메시지를 완전히 삭제한다
imap_fetch_overview --  주어진 메시지 헤더의 전체 정보를 읽어 온다
imap_fetchbody --  메시지의 본문중에서 특정 부분을 페치한다
imap_fetchheader -- 메시지에서 헤더를 돌려준다
imap_fetchstructure --  특별한 메시지의 구조체를 읽어온다
imap_get_quota --  Retrieve the quota level settings, and usage statics per mailbox
imap_get_quotaroot --  Retrieve the quota settings per user
imap_getacl --  Gets the ACL for a given mailbox
imap_getmailboxes --  메일박스의 목록을 읽어오고, 각 메일박스에 대한 상세한 정보를 돌려준다.
imap_getsubscribed -- subscribed된 모든 메일 박스의 목록을 보여준다.
imap_header -- Read the header of the message
imap_headerinfo -- 메시지의 머릿글을 읽어온다
imap_headers --  메일박스에서 모든 메시지의 헤더를 돌려준다
imap_last_error --  이 함수는 현재 페이지 요구(page request) 동안에 발생한 IMAP 에러(물론 있다면)의 가장 나중것을 돌려준다
imap_list -- Read the list of mailboxes
imap_listmailbox -- 메일박스의 목록을 읽어온다
imap_listscan --  Read the list of mailboxes, takes a string to search for in the text of the mailbox
imap_listsubscribed -- subscribed된 모든 메일박스의 목록을 보여준다
imap_lsub -- List all the subscribed mailboxes
imap_mail_compose --  주어진 envelope와 body 섹션으로 구성된 MIME메시지를 만든다
imap_mail_copy -- 메일박스에 특정 메시지를 복사한다
imap_mail_move -- 메일박스에 특정 메시지를 이동시킨다
imap_mail --  이메일 메시지를 보낸다
imap_mailboxmsginfo -- 현재 메일박스에 관한 정보를 가져온다
imap_mime_header_decode -- MIME 헤더 구성요소(element)를 디코딩한다
imap_msgno --  이 함수는 주어진 UID값에 대해 메시지 일련번호(sequence number)을 넘겨준다
imap_num_msg --  현재 메일박스의 메시지 갯수를 돌려준다
imap_num_recent -- 현재 메일박스의 새로운 메시지 갯수를 돌려준다
imap_open -- 메일박스에 IMAP 스트림(stream)을 연다
imap_ping -- IMAP 스트림(stream)이 아직 사용가능한지 체크한다
imap_qprint -- quoted-printable 문자열을 8비트 문자열로 변환한다
imap_renamemailbox -- 메일박스의 이름을 바꾼다
imap_reopen -- 새로운 메일박스에 IMAP 스트림(stream)을 다시 연다
imap_rfc822_parse_adrlist -- 주소 문자열을 해석한다
imap_rfc822_parse_headers -- 문자열에서 메일 헤더를 해석한다
imap_rfc822_write_address --  주어진 메일박스, 호스트, 개인 정보로 적절히 형식화된 이메일 주소를 돌려준다
imap_scanmailbox --  메일박스의 텍스트중에서 검색 문자열을 갖는 메일박스의 목록을 읽어 온다
imap_search --  이 함수는 주어진 검색 기준(criteria)에 부합되는 메시지의 배열을 돌려준다
imap_set_quota -- Sets a quota for a given mailbox
imap_setacl --  Sets the ACL for a giving mailbox
imap_setflag_full -- 메시지에서 플래그(flags)를 셋(set)한다
imap_sort -- 메시지 헤더의 배열을 정렬한다
imap_status --  이 함수는 현재 메일박스 이외의 다른 메일 박스의 상태 정보를 돌려준다
imap_subscribe -- 메일 박스에 Subscribe한다
imap_thread --  Return threaded by REFERENCES tree
imap_timeout --  Set or fetch imap timeout
imap_uid --  이 함수는 주어진 메시지의 일련번호(sequence number)에 대한 UID를 돌려준다
imap_undelete --  지움 표시된 메시지의 지움 표시를 제거한다
imap_unsubscribe -- 메일박스를 Unsubscribe한다
imap_utf7_decode --  modified UTF-7 인코딩된 문자열을 디코딩한다.
imap_utf7_encode --  8비트 데이터를 UTF-7 텍스트로 변환한다.
imap_utf8 --  텍스트를 UTF8로 변환한다


imap_8bit> <read_exif_data
Last updated: Sat, 17 Jul 2004
 
add a note add a note User Contributed Notes
IMAP, POP3 그리고 NNTP 함수
gpayne at galenaparkisd com
07-Aug-2007 12:48
You can also use the novalidate-cert flag and it won't bother you about the ssl stuff:

$mailbox = imap_open("{localhost:143/imap/novalidate-cert}INBOX", "user","pw");
mleiv
26-Jul-2007 04:12
MAC OSX advice for those less experienced in UNIX.

I had a lot of trouble with all the advice here, but I finally got it working, so I thought I'd leave my steps.  If you know a decent amount about UNIX you can probably do better on you own.
#1) downloaded version listed by php.net above.
#2) ran "make opx" on it (the three-letter is your OS, opx is later osx versions)
#3) copied resulting c-client/ folder to where I wanted to leave my imap stuff, herafter referred to as IMAP_HOME.
#4) renamed IMAP_HOME/c-client/c-client.a to libc-client.a
#5) ran "configure" on php using --with-imap=IMAP_HOME --with-kerberos  --with-imap-ssl (my configure insisted that I use the last two)
#6) make, make install, and restarted Apache.  Voila!   

At this point you can delete the downloaded imap stuff, or move it to your sources/ folder or whatever.
bogdanderen at mail dot ru
07-Jul-2007 06:41
INSTALLING IMAP
   1. Log in as root:
      su -
   2. Download IMAP installation
   3. Untar the package:
      tar -zxf IMAP_PACKAGE_FILENAME
   4. Enter the source directory:
      cd IMAP_PACKAGE_DIRECTORY
   5. Build the package.
      # edit Makefile EXTRACFLAGS=-fPIC
      # make lrh
   6. Install the lib and include files:
      # mkdir /IMAP_DIR/lib
      # mkdir /IMAP_DIR/include
      # cp -r ./src/c-client/*.h /IMAP_DIR/include/
      # cp  ./c-client/linkage.h /IMAP_DIR/include/
      # cp ./src/osdep/unix/*.h /IMAP_DIR/include/
      # cp ./src/osdep/unix/*.c /IMAP_DIR/lib/
      # rm -rf all files and directories except /IMAP_DIR/include/ & /IMAP_DIR/lib/
   7. Create the osdep.h link:
      Linux:
      # ln -s ./include/c-client/os_slx.h \
      /IMAP_DIR/include/osdep.h

INSTALLING PHP (DO NOT --with-kerberos)
    --with-imap=/IMAP_DIR
eeescalona at yahoo dot com
20-Feb-2007 12:49
fyi.

I had an error during this process

*downloaded from ftp.cac.washington.edu  imap-2006e.tar.gz
*untarred it as /usr/local/src/imap-2006e.
*made lrh (make lrh)
*copied /usr...imap-2006e/c-client/c-client.a into ..../client/libc-client.a
*cd /usr/local/src/php-4.2.1/
*configured php using ... --with-imap=/usr/local/src/imap-2006e --with-ssl

*and during make the following error occurred.

php_imap.c:71: error: conflicting types for 'utf8_mime2text'
/usr/local/src/imap-2006e//c-client/utf8aux.h:37: error: previous declaration of 'utf8_mime2text' was here
php_imap.c:71: error: conflicting types for 'utf8_mime2text'
/usr/local/src/imap-2006e//c-client/utf8aux.h:37: error: previous declaration of 'utf8_mime2text' was here
make[3]: *** [php_imap.lo] Error 1
make[3]: Leaving directory `/usr/local/src/php-4.2.1/ext/imap'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/usr/local/src/php-4.2.1/ext/imap'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/local/src/php-4.2.1/ext'
make: *** [all-recursive] Error 1

apparently, apache 4.2.1 and imap-2006e has the same declared function which creates a duplication problem. the utf8_mime2text function is both found on files:

php-4.2.1/imap/php_imap.c (2 occurences)
imap-2006e/c-client/utf8aux.h (1 occurences)
imap-2006e/c-client/utf8aux.c (1 occurrences)
imap-2006e/c-client/mail.c (5 occrences)

bug fixers says i have to upgrade my php, but I cant afford to change versions since i run some home grown developed php software which doesnt work on higher versions.

So I did this.

I replaced all utf8_mime2text texts with utf8_mime2text2 for the imap sources.

since my server is both web and mysql, i used a built in mysql command called 'replace'

$>replace utf8_mime2text utf8_mime2text2 -- /..../c-client/utf8aux.h
$>replace utf8_mime2text utf8_mime2text2 -- /..../c-client/utf8aux.c
$>replace utf8_mime2text utf8_mime2text2 -- /..../c-client/mail.c

then i continued make and make install, without the reported error.

caveats...i just did this to try it. i dunno if it will work later...
couplewith at interpakr dot co dot kr
12-Feb-2007 05:37
imap-install
  1. tar xvzf c-client.tgz
  2. cd imap-2006e
  3. make lrh    # install redhat linux
  4. cp c-client/c-client.a  /usr/local/lib/libc-client.a
      copy head files
      c-client/rfc822.h, mail.h 과 linkage.h
       /usr/local/include
       c-clinet/utf-8.h /usr/local/include
  5. if  U8T_CANONICAL undefined error
      edit php_src/ext/imap/php_imap.c

==add 53 line ==
#include <time.h>
#include <stdio.h>
#include <ctype.h>
#include <signal.h>
+#include "utf8.h"
   6. make php installatin step
Marplatense
23-Nov-2006 08:52
Compiling php with support for imap on a linux 64 bits server (tested with php 5.1.6, php 5.2.0, CentOS 4.4 64 bits and c-client snap 0611201609):

1- download the imap from ftp.
# tar -zxvf imap-2006d.DEV.tar.Z
# cd imap-2006d.DEV.SNAP-0611201609/
# vim MakeFile
2- Search for "EXTRACFLAGS=" and add -fPIC at then end:
    before EXTRACFLAGS=
    after   EXTRACFLAGS=-fPIC
3- save the file and quit
# make lrh
# cd c-client/
# cp /.../imap-2006d.DEV.SNAP-0611201609/c-client/c-client.a /.../imap-2006d.DEV.SNAP-0611201609/c-client/libc-client.a
4- navigate to your php directory and:
# ./configure ... lots of options here and ... --with-imap=/.../imap-2006d.DEV.SNAP-0611201609 --with-imap-ssl
# make
# make install

Additional notes:
a- I choose "lrh" in the make but you might check what's yours option.
b- I made it with ssl support and because of this I added the --with-imap-ssl in the php configure option. You might make it with no SSL
James Triplett <jm-php at vj8 dot net>
05-Apr-2006 07:50
Building Apache2, PHP and IMAP requires a shareable version
of the c-client library, but the standard UW code doesn't provide one.
I couldn't find any way to build with the libc-client.a without generating piles of relocation errors. (gcc on Solaris 10)

The IMAP c-client library can be built shareable with the following steps:
1. fix the Makefile in .../imap-2004/c-client to include:
BASECFLAGS="-fPIC -O3"
2. make
3. mkdir tmp
4. cd tmp
5. ar xv ../c-client.a  (to extract the .o files)
6. gcc -shared -o c-client.so *.o  (to create the .so library)
7. copy that c-client.so to /usr/local/imap/lib/libc-client.so
    (it may be necessary to hide the libc-client.a)
8. configure PHP ; make; make install
info at toyflish dot de
15-Dec-2005 02:26
if you are on SuSE9.3 64 and still compiling errors you have to add the -fPIC flag to the  EXTRACFLAGS in imap-Makefile.
BjarneDM macintosh at mathiesen dot info
20-Oct-2005 12:49
Mac OS X client install notes with DarwinPorts

The c-client.a isn't present on your system after you've installed the imap-uw package. !But! it's actually present at a specific time during the install phase as it's being complied from source - it's just deleted at the end of the compilation process. So, we'll have to break the install process down into it's component processes and get hold of what we need at the appropriate time:

sudo port fetch imap-uw
sudo port extract imap-uw
sudo port patch imap-uw
sudo port configure imap-uw
sudo port build imap-uw
imapLib=/darwinports/var/db/dports/distfiles/imap-uw/lib
imapIncludes=/darwinports/var/db/dports/distfiles/imap-uw/include
sudo mkdir ${imapLib} ${imapInclude}
cd /darwinports/var/db/dports/build/*/*/*/c-client
sudo cp *.c ${imapLib}
sudo cp *.h ${imapIncludes}
sudo cp c-client.a ${imapLib}/libc-client.a
cd ${imapLib}
ranlib - libc-client.a
sudo port install imap-uw

Now, you can just specify:
    --with-imap=/darwinports/var/db/dports/distfiles/imap-uw \
    --with-imap-ssl=/darwinports \
in your ./configure command.
php at got2get dot net
07-Sep-2005 08:04
Install note for FreeBSD:

If you get this:

/libexec/ld-elf.so.1: /usr/local/lib/php/20041030/imap.so: Undefined symbol "ssl_onceonlyinit"

...in your httpd-error.log.

It is because you compiled cclient without SSL support.

However. In order for me to get SquirrelMail woorking, I had to install ports/mail/imap-uw with WITHOUT_SSL=yes and same option for ports/mail/cclient. After doing this, I recompiled cclient w/o any options to get SSL support, and then installed posrt/mail/php5-imap.

This works. But if you just want SSL everywhere - install imap-uw normally, which will install cclient too. After that, install php5-imap normally as well - and you have a working system with SSL.

Hope this saves more people from wasting too much time like I just did ;)

 - Nicolai
sinasalek at gmail dot com
24-Jun-2005 07:35
if you want connect to Secure(SSL) POP3 server, enabling openssl isn't enough in windows,
take a look at this
http://archives.devshed.com/a/ng/557-23605/
v dot 0000000001 dot -0006398047 at vertabiz dot com
23-Jun-2005 09:01
Since this library at a whole is fairly poorly documented, and it doesn't help that there's 30-something functions, and many of the functions do the same things, I have gone through and categorized the functions.  Hopefully this will help somebody else, I know it will help me!! -Justin

CONNECTION, ERRORS & QUOTAS
===========================
imap_timeout
imap_ping
imap_open
imap_reopen
imap_close
imap_check **(fairly useless)
imap_alerts
imap_errors
imap_last_error
imap_get_quota
imap_get_quotaroot
imap_set_quota

MESSAGES - READING
==================
imap_uid
imap_msgno
imap_fetchbody
imap_fetchheader
imap_fetchstructure
imap_fetch_overview
imap_body
imap_rfc822_parse_adrlist
imap_rfc822_parse_headers

MESSAGES - WRITING
==================
imap_mail_compose
imap_mail
imap_append
imap_rfc822_write_address

MESSAGES - OPERATIONS
=====================
imap_undelete
imap_thread
imap_delete
imap_mail_copy
imap_mail_move
imap_expunge
imap_clearflag_full
imap_setflag_full

MESSAGES - DECODE/ENCODE
========================
imap_utf7_decode
imap_utf7_encode
imap_utf8
imap_8bit
imap_base64
imap_binary
imap_mime_header_decode
imap_qprint

FOLDERS
=======
imap_createmailbox
imap_deletemailbox
imap_getmailboxes
imap_mailboxmsginfo
imap_renamemailbox
imap_headers **(fairly useless)
imap_status
imap_sort
imap_search
imap_listscan

NNTP
====
imap_unsubscribe
imap_subscribe
imap_getsubscribed

Others
=============================
imap_num_msg - use imap_mailboxmsginfo()
imap_num_recent - use imap_mailboxmsginfo()
imap_header - alias of imap_headerinfo()
imap_scanmailbox - alias of imap_listscan()
imap_listsubscribed - alias of imap_lsub()
imap_listmailbox - alias of imap_list()
imap_lsub - use imap_getsubscribed()
imap_list - use imap_getmailboxes()
imap_bodystruct - not documented
imap_getacl - not documented
imap_setacl - not documented
imap_headerinfo - use imap_fetch_overview()
Anonymous
13-Apr-2005 12:13
If you are having difficulty compiling on netbsd from source and want imap support then you should know that the c-client library is compiled with kerberos support.  Unfortunately gssapi_krb5 and k5crypto is not on the system (or at least wasn't for me).  I didn't have administrative level access to add these libraries so I had to do the following.  I still have to test that it worked 100% but at least it compiled without complaining.

Comment the following segments from the configure script.

Segment 1 -- test for gssapi_krb5 library

  case gssapi_krb5 in
  c|c_r|pthread*) ;;
  *)
    if test "$ext_shared" = "yes"; then
        IMAP_SHARED_LIBADD="$IMAP_SHARED_LIBADD -lgssapi_krb5"
    else
 
 
  case gssapi_krb5 in
  c|c_r|pthread*) ;;
  *)
      LIBS="$LIBS -lgssapi_krb5"
   ;;
  esac

    fi
   ;;
  esac

Segment 2 -- test for k5crypto

  case k5crypto in
  c|c_r|pthread*) ;;
  *)
    if test "$ext_shared" = "yes"; then
        IMAP_SHARED_LIBADD="$IMAP_SHARED_LIBADD -lk5crypto"
    else

  case k5crypto in
  c|c_r|pthread*) ;;
  *)
      LIBS="$LIBS -lk5crypto"
   ;;
  esac

    fi
   ;;
  esac

BTW.  Since I was only compiling for the modules (they have suPHP so I compile all my own modules when I need them) I only dropped this in for the php configure script parameters

./configure --with-imap=shared,xxxxxx --with-kerberos=xxxxxx --with-imap-ssl

This is verified working via an imap test.  One excellent test that I located on the phpbuilder.com site.  Here it is.  Modify the address, port, protocol type, username, and password appropriately.  The post was 5 years old but the script still works fine.  The posters name was "Matthew"

<HTML>
<HEAD>
<TITLE>imap_check</TITLE>
</HEAD>
<BODY>
<?
         //check for new messages

         $mailbox = imap_open("{localhost/pop3:110}INBOX",
                 "#username#","#password#");

         // Check messages
         $check = imap_check($mailbox);
         print("<PRE>");
         print("Date most recent message : " . $check->Date);
         print("<BR>");
         print("Connection type : " . $check->Driver);
         print("<BR>");
         print("Name of the mailbox : " . $check->Mailbox);
         print("<BR>");
         print("Number of messages : " . $check->Nmsgs);
         print("<BR>");
         print("Number of recent messages : " . $check->Recent);
         print("<BR>");
         print("</PRE>");

         // show headers for messages

         $index=1;

         $header = imap_header($mailbox, $index);
         print("<PRE>");
         print("Header Date : " . $header->Date . "<BR>");
         print("Header To : " . $header->to) . "<BR>";
         print("Header From : " . $header->From . "<BR>");
         print("Header cc : " . $header->cc . "<BR>");
         print("Header ReplyTo : " . $header->ReplyTo . "<BR>");
         print("Header Subject : " . $header->Subject . "<BR></PRE>");

         print("<PRE>");
         print(imap_body($mailbox,$index));
         print("</PRE><HR>");

         imap_close($mailbox);
?>

</BODY></HTML>
seem dot iges at mail dot ee
15-Feb-2005 05:48
If you like me disvoer that "make slx" fails, but you're damn sure you've openssl installed then, it might be that the lib and include paths on your distro are different then the defaults provided in the imap-2004a (or imap-XXXXx). To modify go to dir ../imap-2004a/src/osdep/unix and edit the section (shown below) in the Makefile

# Extended flags needed for SSL.  You may need to modify.

#SSLDIR=/usr/local/ssl
SSLDIR=/etc/ssl
SSLCERTS=$(SSLDIR)/certs
SSLKEYS=$(SSLCERTS)
#SSLINCLUDE=$(SSLDIR)/include
SSLINCLUDE=/usr/include/openssl
#SSLLIB=$(SSLDIR)/lib
SSLLIB=/usr/lib

SSLCRYPTO=-lcrypto

Commented out SSLDIR, SSLINCLUDE and SSLIB are defaults and the uncommented are valid paths for Slackware (10.0/10.1).
You should also check your ld.so.conf for valid paths.
antivert
13-Jan-2005 08:55
Note that is not not necessary to disable SSL in the IMAP compile to make it work with PHP 5.0.3.

1. Compile IMAP with SSL support for your system:

cd /path/to/imap/source/
make <system type> (ldb, lnx, etc)
mkdir include
mkdir lib

2. Make links in IMAP source directory:

cd /path/to/imap/source/c-client
cp *.h ../include/
cp *.c ../lib/
cp c-client.a ../lib/libc-client.a

3. Compile PHP with SSL support,  --with-imap=/path/to/imap/source/ . If SSL support fails, you'll get a configure-time error that IMAP doesn't work. This is a lie, you just need to get SSL support working in PHP. On certain linux systems, with OpenSSL 0.9.7, this means adding --with-openssl=/usr (if the OpenSSL files are in /usr/include/openssl/) instead of the proper directory containing the OpenSSL files. For some reason, giving a parent directory makes PHP able to find the OpenSSL include files.

4. PHP should build.

Alternately, you can disable SSL during the IMAP build, as per the previous directions posted here.
amit dot gupta at prudence-india dot com
18-Nov-2004 12:44
I faced problem in compiling imap with php-5.0.2 release version. Then following commands on snapshot version solved my problem

# tar -zxvf imap-2004b.DEV.tar.Z
# cd imap-2004b.DEV.SNAP-0411051435/
# make lnp SSLTYPE=none
# cp -r /usr/local/imap-2004b.DEV.SNAP-0411051435/c-client/*.h /usr/local/imap-2004b.DEV.SNAP-0411051435/include/

# cp -r /usr/local/imap-2004b.DEV.SNAP-0411051435/c-client/*.c /usr/local/imap-2004b.DEV.SNAP-0411051435/lib/

# ln -s /usr/local/imap-2004b.DEV.SNAP-0411051435/c-client/c-client.a /usr/local/imap-2004b.DEV.SNAP-0411051435/lib/libc-client.a

# tar -zxvf php5-STABLE-200411180530.tar.gz

# cd php5-STABLE-200411180530

./configure  --with-apxs2=/usr/sbin/apxs --enable-shared --with-mod_charset --enable-force-cgi-redirect --enable-fastcgi --enable-magic-quotes --with-openssl  --with-zlib  --enable-bcmath  --enable-calendar --with-curl  --with-curlwrappers  --enable-dba   --with-gdbm --with-cdb  --with-inifile  --with-flatfile  --enable-dbase   --enable-dbx     --enable-dio --with-fam  --enable-filepro  --enable-ftp  --with-ldap  --enable-mbstring --with-mysql=/usr/include  --with-zlib-dir  --enable-shmop --enable-soap  --enable-sockets    --enable-sysvmsg   --enable-sysvsem  --enable-sysvshm  --enable-wddx --with-pic --enable-versioning  --with-pgsql --with-java=/usr/java/jdk1.5.0/  --with-imap=/usr/local/imap-2004b.DEV.SNAP-0411051435 --with-kerberos

# make

# make install

Thus, php compiled sucessufully with imap support on fedora core 1.
Pete Spicer, sleeping [at] myperch.org
17-Jul-2004 03:19
I have a pretty much stock set-up of SuSE 8.1 Personal (Apache, PHP et al built by me) and IMAP-2004 refused to build for me.

What I found was, using the make lsu (for SuSE) almost worked built I was getting odd build results, i.e. make failures.

The problem? GCC 3.2. If you don't have an older GCC available, please install one! I installed the gcc_old package from SuSE and built with the following command:

CC=gcc297 make lsu SSLTYPE=none

The result was a perfect build. So if you are getting errors, please try an earlier build of GCC.
Tomas V.V.Cox
11-May-2004 06:15
For compiling this extension without compiling imap from sources I did (this was mandrake):

Install the following rpms:
imap
imap-devel
openssl
openssl-devel
krb5
krb5-devel
pam
pam-devel

Do the trick:
# mkdir /usr/include/imap/lib
# cp /usr/lib/libc-client-PHP4.a /usr/include/imap/lib/libc-client.a

And the configure line:
./configure <options> --with-imap=/usr/include/imap --with-imap-ssl

(don't forget --enable-pear ;)

imap_8bit> <read_exif_data
Last updated: Sat, 17 Jul 2004
 
 
show source | credits | stats | sitemap | contact | advertising | mirror sites