Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> Jak dokompilować do PHP biblioteke GD?
Kres
post
Post #1





Grupa: Zarejestrowani
Postów: 3
Pomógł: 0
Dołączył: 18.06.2004

Ostrzeżenie: (0%)
-----


Jak w temacie mam php 4.2.3 i chce dołożyć GD wersji 2.xx system linux, jak tego dokonać?(IMG:http://forum.php.pl/style_emoticons/default/questionmark.gif)

Ten post edytował Kres 18.06.2004, 20:28:34
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi (1 - 3)
hwao
post
Post #2


Developer


Grupa: Moderatorzy
Postów: 2 844
Pomógł: 20
Dołączył: 25.11.2003
Skąd: Olkusz




Prosze:
Click
Go to the top of the page
+Quote Post
Kres
post
Post #3





Grupa: Zarejestrowani
Postów: 3
Pomógł: 0
Dołączył: 18.06.2004

Ostrzeżenie: (0%)
-----


Duzo tego, a moze bardziej szczegolowo co zrobic?

Czy np. wystarczy path do php 4.2.3( którego uzywam)?


INSTRUCTIONS (Please Follow Carefully)
Step One: download and install gd 2.0.8 or better. See the gd manual if you have questions about this step.
Step Two: download the php 4.2.3 source distribution. You have probably done this already. (If you can use a newer version of php, then DON'T USE this patch at all. See the message at the top of this page.)
Step Three: download the patch file, php-4.2.3-gd-2.0.8.patch, and save it to the directory where you saved the php source distribution. I recommend right-clicking on the above link and selecting the "save target as" option.
Step Four: untar the php distribution, if you have not already done so, and cd to the php-4.2.3 directory.
Step Five: type this command:
patch -p1 < ../php-4.2.3-gd-2.0.8.patch

Step Six: type ./configure, make, make install, etc. as you would normally do for php. In my experience, you will probably have to specify --with-gd=/usr/local, --with-png-dir=/usr/local, and --with-zlib-dir=/usr/local at a minimum to get configure to notice that gd is available, but your mileage may vary.
Step Seven: enjoy! The new imagecopyrotated function is similar to imagecopyresized, except with slightly different arguments: dstImage, srcImage, dstX, dstY, srcX, srcY, srcWidth, srcHeight, angle. Note that the destination X and Y coordinates specify the center of the rotated version of the source rectangle. Also note that the angle is specified as an integer number of degrees (0-359).
Go to the top of the page
+Quote Post
Jojo
post
Post #4





Grupa: Zarejestrowani
Postów: 405
Pomógł: 1
Dołączył: 19.09.2003
Skąd: Lublin

Ostrzeżenie: (0%)
-----


Na stronie, którą podał Ci hwao masz wyraźnie napisane:
Cytat
To enable GD-support configure php --with-gd[=DIR], where DIR is the GD base install directory.

Czyli musisz napisać:
Kod
./configure --with-gd=/path/to/gd

Oczywiście musisz dodać również wszystkie inne opcje z którymi wcześniej kompilowałeś php.
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
2 Użytkowników czyta ten temat (2 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 23.08.2025 - 23:49