Answer the question
In order to leave comments, you need to log in
How to install PHP 5.3 on Debian 8.5?
Hello! Already asked a question about compiling PHP 5.3. The following question arose:
I realized that I can’t build PHP 5.3 normally, tell me where can I get already compiled PHP 5.3 sources? (it's important that they have --prefix=/opt/php53
when compiling
. Thanks in advance for your replies.
Answer the question
In order to leave comments, you need to log in
debian 9, maybe it will be useful for someone
apt-get update
apt-get install -y libfcgi-dev libfcgi0ldbl libjpeg62-dbg libmcrypt-dev libssl-dev libxml2-dev zlib1g-dev libcurl4-gnutls-dev libjpeg-turbo8-dev libbz2-dev libjpeg-dev libfreetype6-dev libmcrypt-dev libcurl4-gnutls-dev
ln -s /usr/include/x86_64-linux-gnu/curl curl
cd /usr/local/include
mkdir /opt/php-5.4.45
mkdir /usr/local/src/php5
cd /usr/local/src/php5
wget http://de2.php.net/get/php-5.4.45.tar.gz/from/this/mirror
mv mirror php-5.4.45.tar.gz
tar -xzvf php-5.4.45.tar.gz
cd php-5.4.45
./configure --prefix=/opt/php-5.4.45 --enable-fpm --with-fpm-user=www-data --with-fpm-group=www-data --enable-mbstring --enable-sockets --enable-exif --enable-bcmath --enable-calendar --enable-zip --enable-ftp --enable-gd-native-ttf --with-gd --with-jpeg-dir=/usr --with-png-dir=/usr --with-freetype-dir --with-zlib --with-zlib-dir --with-bz2 --with-mcrypt --with-mhash --with-pcre-regex --with-libxml-dir=/usr --with-xmlrpc --with-xsl --with-mysql --with-libdir=/lib/x86_64-linux-gnu --with-curl
make
make install
/opt/php-5.4.45/bin/php -v
PHP 5.4.45 (cli) (built: Mar 12 2019 20:05:50)
Copyright (c) 1997-2014 The PHP Group
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question