PHP mit Imap-Support kompilieren

"Oliver Marahrens" <[email protected]>
Newsgroups gmane.linux.suse.programming
Organization Universitätsbibliothek TU-Harburg
Message-ID <4177AC13.26050.BF612A@localhost>
Hallo Liste,

ich habe ein Problem, das zwar nicht mit Programmierung zu tun hat, 
aber mit Kompilierung und ich hoffe, da bin ich hier an einer ganz 
guten Adresse.
Ich versuche, in mein PHP-Modul für den Apachen die Imap-Funktionen 
einzukompilieren, aber das klappt nicht. PHP hab ich in den 4.3.9-
Sourcen und ohne Imap-Support lassen sie sich prima zusammenbauen. 
Imap hab ich in Version 2004a. Die Kompilierung von Imap an sich hat 
auch geklappt, aber ich bekomme kein .so-Modul aus Imap, sondern nur 
eine statische .a-Version. Nun brauche ich für PHP aber das .so-
Modul, ansonsten scheitert es, ein PHP-so-Modul zu bauen (und PHP 
brauch ich als shared object, weil es sich ansonsten nicht vom 
Apachen ansprechen lässt). 
Die entsprechende Warnung von make (configure läuft einwandfrei 
durch) sieht dann so aus:

*** Warning: linker path does not have real file for library -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
*** because I did check the linker path looking for a file starting
*** with libc-client and none of the candidates passed a file format 
test
*** using a file magic. Last file checked: /usr/lib/libc-client.a

*** Warning: libtool could not satisfy all declared inter-library
*** dependencies of module libphp4.  Therefore, libtool will create
*** a static module, that should work as long as the dlopening
*** application is linked with the -dlopen flag.

Ich habe schon versucht, mir rpm-Pakete mit libc-client.so zu 
organisieren (Version 2002e), aber die führen zu einer Fehlermeldung 
(unabhängig von der Imap-Version, ich hab es auch mit einer selbst 
gebauten Version 2002e versucht). Diese Fehlermeldung taucht manchmal 
schon beim configure auf (immer dann, wenn ich --with-imap=/usr 
angebe; da liegen die .so-Dateien aus dem rpm). Er meldet mir dann, 
dass Imap nicht funktioniert. Den gleichen Effekt hab ich 
interessanterweise, wenn ich die .so-Dateien in den Ordner kopiere, 
in dem ich Imap kompiliert habe. 
Wenn die .so-Libs nicht im angesprochenen Ordner, sondern nur im LD-
Pfad liegen, dann endet make mit folgender Fehlermeldung:

/usr/lib64/gcc-lib/x86_64-suse-linux/3.3.3/../../../../x86_64-suse-
linux/bin/ld: /usr/local/imap/lib/libc-client.a(osdep.o): relocation 
R_X86_64_32 can not be used when making a shared object; recompile 
with -fPIC
/usr/local/imap/lib/libc-client.a: could not read symbols: Bad value
collect2: ld returned 1 exit status
make: *** [libphp4.la] Error 1

Wie daraus ersichtlich ist, arbeite ich auf ner 64bit-Kiste. Als OS 
hab ich da SuSE 9.1 Pro laufen.

Ich bin inzwischen ziemlich ratlos, woran das liegen könnte, viel 
Gegoogel hat mir auch nicht weitergeholfen :-( Vielleicht weiss ja 
jemand von euch einen Tipp - wäre sehr schön, wenn mir jemand 
weiterhelfen könnte.

Vielen Dank schonmal und viele Grüße
	Oliver

-- 
Um die Liste abzubestellen, schicken Sie eine Mail an:
    [email protected]
Um eine Liste aller verfügbaren Kommandos zu bekommen, schicken
Sie eine Mail an: [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.