## (2)thinkphp5部署到linux下,验证码失效`500 server error`
~~~
> 访问验证码
Call to undefined function think\captcha\imagecreate()
~~~
#### 原因:未安装GD库
> 取消注释
~~~
vi /etc/php.ini
/php_gd2.dll #查找php_gd2.dll,将注释;去掉
~~~
`cd /usr/local/src/php-7.0.12/ext/gd
/usr/local/php/bin/phpize`
~~~
./configure -with-php-config=/usr/local/php/bin/php-config
--with-vpx-dir=/usr/local/src/
--with-jpeg-dir=/usr/local/src/
--with-png-dir=/usr/local/src/
--with-freetype-dir=/usr/local/src/
~~~
`make && make install`
> Installing shared extensions: /usr/local/php/lib/php/extensions/no-debug-zts-20151012/
> Installing header files: /usr/local/php/include/php/
> cd /usr/local/apache/bin/
> ./apachectl start
> 重启apache后成功