- # tar Xvzf zlib-1.2.3.tar.gz
- # CD zlib-1.2.3
- #./configure
- # Make && make install
Copy Code3, installation FreeType
- # tar Xvzf freetype-1.3.1.tar.gz
- # CD freetype-1.3.1
- #./configure--prefix=/usr/local/freetype
- # Make && make install
Copy CodeThere are multiple lines of errors similar to: ftdump.c:172:1: error:pasting "." and "Glyph_object" does not give a valid preprocessing token Workaround: Modify the code inside the TEST/FTDUMP.C: Change Print_mem (memory_footprint.# #field, String) to: Print_mem (Memory_footprint.field, String) Change #define footprint (field) save_memory (&memory_footprint.# #field) to: #define Footprint (field) Save_memo RY (&memory_footprint.field) reset && make install or modify makefile.in:
- 1. Remove the tttest from the All:ttlib tttest ttpo
- 2. Delete
- Install
- CD $ (FTLIBDIR); $ (make)-F $ (MAKEFILE) Install
- CD $ (FTTESTDIR); $ (make)-F $ (MAKEFILE) Install
- CD $ (FTPODIR); $ (make) Install
- In the CD $ (FTTESTDIR); $ (make)-F $ (MAKEFILE) Install
- #./configure--prefix=/usr/local/freetype
- # Make && make install
Copy Code4, installation libpng
- # tar Xvzf libpng-1.5.2.tar.gz
- # CD libpng-1.5.2
- #./configure--prefix=/usr/local/libpng
- # Make && make install
Copy Code5, Installation Jpegsrc
- # tar Xvzf jpegsrc.v6b.tar.gz
- # CD JPEGSRC.V6B
- #./configure--prefix=/usr/local/jpeg6–enable-shared–enable-static
- # Make && make install
Copy CodePossible error: The prompt folder does not exist, should be the program can not automatically create folders, according to the error of the prompt, hand-use mkdir create files on it. This time for example:
- # mkdir-p/usr/local/jpeg6/include/
- # mkdir-p/usr/local/jpeg6/lib/
- # mkdir-p/usr/local/jpeg6/bin/cjpeg
- # mkdir-p/usr/local/jpeg6/man/man1/
Copy Code6, install GetText (some directly have, you can install the GD library, error and then return to install)
- # tar Xvzf gettext-0.16.1.tar.gz
- # CD gettext-0.16.1
- #./configure--prefix=/usr/local/gettext
- # Make && make install
Copy Code7. Install GD Library
- # tar Xvzf gd-2.0.35.tar.gz
- # CD gd-2.0.35
- #./configure--prefix=/usr/local/gd--with-jpeg=/usr/local/jpeg6--with-png=/usr/local/libpng--with-freetype=/usr /local/freetype
- # make
- # make Install
Copy CodeConfigure ... Possible error in this step: configure.ac:64:error:possibly undefined macro:am_iconv, this must be installed GetText (in step 6) 8. Generate gd.so
- # CD: /php-5.2.17/ext/gd/
- #/usr/local/php5/bin/phpize
- #./configure--with-php-config=/usr/local/php5/bin/php-config--with-jpeg-dir=/usr/local/jpeg6/--with-png-dir=/ usr/local/libpng/--with-gd=/usr/local/gd/--with-freetype-dir=/usr/local/freetype/
- # Make && make install
Copy CodeAt the end of make install there will be the location of GD inventory, from that folder to copy gd.so to the extension library directory 9, modify php.ini in the php.ini add the following content
- Extension=gd.so
Copy Code10. End of installation, restart Apache Service
- # Service httpd Restart
Copy Code |