GD für bestehendes php aktivieren

D

derJosh

Mitglied
Thread Starter
Dabei seit
22.01.2005
Beiträge
86
Reaktionspunkte
0
Hallo zusammen,

habe einen Mac OS X Server (Tiger) hier stehen, auf welchem bereits ein apache und ein php rennt. Leider brauche ich zur Programmierung GD in php, was aber nicht konfiguriert ist. Libgd und der ganze Rest sind alle auf dem System vorhanden.

Wie bekomme ich PHP/Apache dazu, die GD Funktionen zu interpretieren?

Andernfalls bin ich für eine alternative Grafiklib offen.

Grüße,
derJosh
 
Das wird beim compilieren von PHP festgelegt. Entweder wird GD statisch mit eingebunden oder eine Anbindung an eine externe shared GD-Lib aktiviert. Ist beides nicht der Fall hast Du so keine Chance GD zu aktivieren.

Ich empfehle das PHP-Paket von entropy.ch das sehr umfassend ist ( nebenbei das komplette PEAR mitbringt) und sich als Entwicklerversion ganz hervorragend eignet.


EDIT: ich hab Dich mal zur Web-Programmierung verschoben.
 
Hier ist nicht die Bar! Bitte keine OT-Beiträge (habe 3 gelöscht!)
 
du brauchst php nicht komplett neu zu bauen, du kannst auch einfach die extension so bauen...
dazu musst du die sourcen haben, einfach das sub-dir gehen, das üblich phpize etc machen und dann make...
dann einfach die .so in das extension verzeichnis packen...

hi

da werde ich nicht so ganz schlau draus. ich habe mir die sourcen geladen, configure/make/make install gemacht, aber .so files liegen da nirgendwo rum, leider?

es wäre sehr nett, wenn du das nochmal genauer ausfuehren koenntest. danke!
 
wahrscheinlich hast du das ganze ding kompiliert.
zuerst musst du die passenden sourcen zu der os x version laden, die liefern nicht die aktuellste version mit...
dann einfach in das verzeichnis der gd extension wechseln:
cd php-4.4.x/ext/gd
phpize
configure
make

dann sollte die .so im gleichen verzeichnis sein oder in einem der unterverzeichnisse des verzeichnisses...
ggf. musst du auch die configure optionen entsprechend deiner gd installation anpassen...
 
danke - das hat licht ins dunkle gebracht :)

leider kommt bei make das hier :(

creating libtool
configure: creating ./config.status
config.status: creating config.h
config.status: config.h is unchanged

SIRIOS-TEST:/Users/php-4.4.8/ext/gd root# make

gcc -dynamic -flat_namespace -bundle -undefined suppress -DPHP_ATOM_INC -I/Users/php-4.4.8/ext/gd/include -I/Users/php-4.4.8/ext/gd/main -I/Users/php-4.4.8/ext/gd -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/local/include -DHAVE_CONFIG_H -g -O2 -o gd.so gd.lo gdttf.lo libgd/gd.lo libgd/gd_gd.lo libgd/gd_gd2.lo libgd/gd_io.lo libgd/gd_io_dp.lo libgd/gd_io_file.lo libgd/gd_ss.lo libgd/gd_io_ss.lo libgd/gd_png.lo libgd/gd_jpeg.lo libgd/gdxpm.lo libgd/gdfontt.lo libgd/gdfonts.lo libgd/gdfontmb.lo libgd/gdfontl.lo libgd/gdfontg.lo libgd/gdtables.lo libgd/gdft.lo libgd/gdcache.lo libgd/gdkanji.lo libgd/wbmp.lo libgd/gd_wbmp.lo libgd/gdhelpers.lo libgd/gd_topal.lo libgd/gd_gif_in.lo libgd/xbm.lo libgd/gd_gif_out.lo libgd/gd_security.lo -L/usr/local/lib -L/usr/local/lib -lpng -L/usr/local/lib -L/usr/local/lib -lz
/usr/bin/ld: truncated or malformed file: gd.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: gdttf.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_gd.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_gd2.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_io.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_io_dp.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_io_file.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_ss.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_io_ss.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_png.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_jpeg.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gdxpm.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gdfontt.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gdfonts.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gdfontmb.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gdfontl.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gdfontg.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gdtables.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gdft.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gdcache.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gdkanji.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/wbmp.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_wbmp.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gdhelpers.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_topal.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_gif_in.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/xbm.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_gif_out.lo (file size too small to be any kind of object or library)
/usr/bin/ld: truncated or malformed file: libgd/gd_security.lo (file size too small to be any kind of object or library)
collect2: ld returned 1 exit status
make: *** [gd.so] Error 1
 
ahh ich glaub ich weiss woran es liegt.
die sind beim kompilieren des php am freitag entstanden und sind irgendwie nu 1byte gross.. wenn ich die umbenenne werden die neu erstellt

komisch nur, dass der die nicht ueberschreibt
 
hmm, was sagte ich noch zur php version?
welche hat 10.4.11 denn? 4.4.7 oder?

abgesehen davon, welche configure optionen hast du verwendet?
der scheint ja das configure vor dem phpize verwendet zu haben, oder?
 
hmm, was sagte ich noch zur php version?
welche hat 10.4.11 denn? 4.4.7 oder?

abgesehen davon, welche configure optionen hast du verwendet?
der scheint ja das configure vor dem phpize verwendet zu haben, oder?


4.4.8 ist es bei mir.

./configure --with-zlib-dir=/usr/local/

das war das einzige ... najo das gd.so wurde auch erstellt, aber mit der einbindung klappt es irgendwie nicht so, wie ich mir das vorgestellt habt. also gd.so in /libexec/httpd/ kopiert und LoadModule gd_module libexec/httpd/gd.so in der httpd.conf führt dazu, dass httpd nicht wieder hochfaehrt nach einem stop

wahrscheinlich mach ich aber grade eh alles falsch :/
 
das ist ein php modul und kein apache modul ;)
d.h. du musst es zu den anderen php .so tun und über die php.ini einbinden...

warum nimmst denn eine zlib aus local?
die sollte doch auch onboard sein...
 
großartig. du bist mein held!

danke :)

edit: der hat zlib irgendwie nicht gefunden und da hab ichs halt angegeben
 
Zurück
Oben Unten