[imp] compile PHP --with-imap, on OS X: progress, but...

Michael Geary listmail@gearyweb.com
Mon, 12 Aug 2002 08:56:35 -0600


Hi Brent,

First of all, can I just thank you for not simply saying,

"why don't you just use the PHP module or follow instructions at 
entropy.ch."

I can't tell you how many responses I've gotten to this effect. People 
don't seem to understand that I want to do this in order to increase my 
understanding, and not just to get the job done. Furthermore, Marc's 
version does not have support for some modules I need (gettext). 
Furthermore, Marc's version can only be used with Apple's Apache, and 
I'm using my own compiled version.

Anyway, it really does look like nobody on the lists is in a position to 
describe in exact detail what it takes to get IMP running on OS X from 
scratch. This being the case, I am retiring my cause and using 
SquirrelMail until either I can figure this out, or PHP.NET releases 
4.3.0 which supposedly 'officially' supports OS X, at which point I'll 
try everything again.

Thanks for your tips.

Michael

On Monday, August 12, 2002, at 05:29 AM, Brent J. Nordquist wrote:

> On Fri, 9 Aug 2002, Michael Geary <listmail@gearyweb.com> wrote:
>
>> I am desperately trying to get PHP (4.2.2) --with-imap running on OS X,
>> so I can run the IMP web-mail client.
>
> I feel your pain.  :-)  Chuck will attest to how much time I burned at
> OSCON (ultimately unsuccessfully) trying to get PHP compiled with IMAP
> (everything else is working).  I can get you a little farther than you
> are; the only way I found to get around this error:
>
>> *** Warning: This library needs some functionality provided by 
>> -lc-client.
>> *** I have the capability to make that library automatically link in 
>> when
>> *** you link to this library.  But I can only do this if you have a
>> *** shared version of the library, which you do not appear to have.
>
> was to compile c-client as a shared library.  I hacked up the patch that
> Debian uses to do this, and you can get it here:
>
> 	http://kepler.acns.bethel.edu/~bjn/imap-2001a-shlib.patch
>
> That gets me a .so file out of the PHP build process.  Where I'm stuck 
> is
> that Apache won't load it; it can't find the IMAP library callbacks.
>
>> I do still get a libphp4.dylib file, but when I rename this to
>> libphp4.so and place it in the appropriate apache directory,
>
> I have also learned that .dylib and .so are not the same thing; Mac OS X
> is apparently different from most Unix platforms, in that a loadable
> shared object and a dynamically-linked library are not the same thing.
> So just renaming it won't work.
>
> The site I found most helpful was Marc Liyanage's (I'm using his patch
> also):
>
> 	http://www.entropy.ch/software/macosx/php/
>
> I wrote to him (because his page implies that he got IMAP working); in 
> his
> response he said he didn't remember getting the error I did, and he sent
> me a new version of his patch (which I haven't had time to try yet).
>
> I hope this is a little helpful; I would love to see this all 
> working.  I
> know the PHP folks have stated that Mac OS X support will be in the next
> release, but I don't know if they've tried building IMAP yet.
>
> --
> Brent J. Nordquist <bjn@horde.org> N0BJN
> Other contact information: http://www.nordist.net/contact.html
>