When you execute configura, the following message is displayed: configure: error: freetype. hnotfound. freetype is installed using brew. You can also query this file stk-tianwen: freetype2hufeiyan $ lsusrlocal1_defreetype2freetype. husrlocal1_defreetype2freetype. hstk-tianwen.
When you execute configura, the following message is displayed: configure: error: freetype. h not found. freetype is installed using brew. You can also query this file stk-tianwen: freetype2 hufeiyan $ ls/usr/local/include/freetype2/freetype. h/usr/local/include/freetype2/freetype. h stk-tianwen
Prompt when configura is executed
Configure: error: freetype. h not found.
Freetype is installed using brew. You can also query this file.
Stk-tianwen: freetype2 hufeiyan $ ls/usr/local/include/freetype2/freetype. h
/Usr/local/include/freetype2/freetype. h
Stk-tianwen: freetype2 hufeiyan $
After a long time, it was impossible.
Then I searched for the configuration file.
Stk-tianwen: php-5.5.7 hufeiyan $ cat configure | grep freetype. h
If test-f "$ I/include/freetype2/freetype. h"; then
As_fn_error $? "Freetype. h not found." "$ LINENO" 5
If test-f "$ I/include/freetype2/freetype. h"; then
As_fn_error $? "Freetype. h not found." "$ LINENO" 5
Stk-tianwen: php-5.5.7 hufeiyan $
Their paths are different. After brew is installed, the header file path is/usr/local/include/freetype2/, and the path required by PHP is/include/freetype2/freetype/
PHP considers/usr/local/include/freetype2/to have a freetype directory.
Execute Command
Ln-s/usr/local/Cellar/freetype/2.5.2/include/freetype2 // usr/local/Cellar/freetype/2.5.2/include/freetype2/freetype
After creating a link, the configuration passes.
Command:
. /Configure -- with-apxs2 =/usr/local/apache2/bin/apxs -- with-freetype-dir =/usr/local/opt/freetype -- with-libxml-dir =/usr/ local/opt/libxml2/-- with-png-dir =/usr/local/opt/libpng/-- with-jpeg-dir =/usr/local/opt/jpeg --- gd =/usr/local/-- with-zlib-dir =/usr/local/zlib/-- with-mcrypt =/usr/local/opt/mcrypt/-- with-mysql = /usr/local/mysql -- enable-soap -- enable-mbstring = all -- enable-pdo -- with-pdo-mysql =/usr/local/mysql -- with-pgsql =/Applications /ipvs93.app/Contents/MacOS -- enable-opcache = no
I don't know who is wrong.