#!/bin/bash

./configure –prefix=/srv/php7.2 –enable-fpm –enable-mysqlnd –with-mysqli –with-sqlite3 –with-pear –with-mcrypt –with-pdo-mysql=mysqlnd
–with-iconv-dir –with-freetype-dir –with-jpeg-dir –with-png-dir –with-zlib –with-libxml-dir=/usr –enable-xml
–disable-rpath –enable-magic-quotes –enable-safe-mode –enable-bcmath –enable-shmop –enable-sysvsem
–enable-inline-optimization –with-curl –enable-mbregex –enable-mbstring –with-mcrypt –enable-ftp –with-gd
–enable-gd-native-ttf –with-openssl –with-mhash –enable-pcntl –enable-sockets –with-xmlrpc –enable-zip
–enable-soap –with-gettext –with-ldap=/srv/openldap

同时摘录一下别人的:

./configure –prefix=/usr/local/php7
–with-curl
–with-freetype-dir
–with-gd
–with-gettext
–with-iconv-dir
–with-kerberos
–with-libdir=lib64
–with-libxml-dir
–with-mysqli
–with-mysql
–with-openssl
–with-pcre-regex
–with-pdo-mysql
–with-pdo-sqlite
–with-pear
–with-png-dir
–with-xmlrpc
–with-xsl
–with-zlib
–with-apxs2
–enable-fpm
–enable-bcmath
–enable-libxml
–enable-inline-optimization
–enable-gd-native-ttf
–enable-mbregex
–enable-mbstring
–enable-opcache
–enable-pcntl
–enable-shmop
–enable-soap
–enable-sockets
–enable-sysvsem
–enable-xml
–enable-zip
–enable-mysqlnd

作者:hellojammyPlus 链接:https://www.jianshu.com/p/4438ff8aa44a 來源:简书