Created
March 14, 2018 22:10
-
-
Save 0x15f/5a4c1aa0078549edbd9346e52825896e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
mkdir -p work | |
cd work | |
curl -fsSL https://downloads.php.net/~pollita/php-7.2.3.tar.xz | tar -xJf - --strip-components=1 | |
./configure \ | |
--disable-cgi \ | |
--enable-mbstring \ | |
--enable-bcmath \ | |
--enable-pdo \ | |
--enable-sockets \ | |
--enable-ftp \ | |
--with-curl \ | |
--with-libedit \ | |
--with-openssl \ | |
--with-zlib \ | |
--with-gmp \ | |
--with-gd \ | |
--with-jpeg-dir \ | |
--with-png-dir \ | |
--with-xpm-dir \ | |
--with-freetype-dir \ | |
--with-mysqli \ | |
--without-readline \ | |
--enable-pcntl \ | |
--enable-maintainer-zts \ | |
--prefix="${PREFIX}" | |
make -j`nproc` | |
$SUDO make install | |
$SUDO "${PREFIX}/bin/pecl" install channel://pecl.php.net/weakref-0.3.3 channel://pecl.php.net/yaml-2.0.2 channel://pecl.php.net/zip-1.15.1 | |
echo "phar.readonly = off | |
extension = yaml.so | |
extension = weakref.so | |
extension = zip.so | |
extension = redis.so | |
extension = ds.so | |
zend_extension = opcache.so | |
zend.assertions = -1 | |
" | $SUDO tee "${PREFIX}/lib/php.ini" > /dev/null | |
cd .. | |
rm -rf work |
sudo apt-get install libcurl4-openssl-dev pkg-config
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
sudo apt-get install php-pear build-essentials libxml2-dev