Skip to content

Commit 60bd836

Browse files
committed
PHP 5
1 parent 0e1821e commit 60bd836

14 files changed

+71
-70
lines changed

build.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,16 +21,16 @@ sudo apt-get install -y \
2121
libpspell-dev \
2222
libreadline-dev
2323

24-
sudo mkdir /usr/local/php7
24+
sudo mkdir /usr/local/php5
2525

2626
git clone https://github.com/php/php-src.git
2727
cd php-src
28-
git checkout PHP-7.0.11
28+
git checkout PHP-5.6.26
2929
git pull
3030
./buildconf --force
3131

32-
CONFIGURE_STRING="--prefix=/usr/local/php7 \
33-
--with-config-file-scan-dir=/usr/local/php7/etc/conf.d \
32+
CONFIGURE_STRING="--prefix=/usr/local/php5 \
33+
--with-config-file-scan-dir=/usr/local/php5/etc/conf.d \
3434
--with-pear \
3535
--enable-bcmath \
3636
--with-bz2 \

conf/php-fpm.conf

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[global]
22

3-
pid = /var/run/php7-fpm.pid
4-
error_log = /var/log/php7-fpm.log
3+
pid = /var/run/php5-fpm.pid
4+
error_log = /var/log/php5-fpm.log
55

6-
include=/usr/local/php7/etc/php-fpm.d/*.conf
6+
include=/usr/local/php5/etc/php-fpm.d/*.conf

conf/php7-fpm.init renamed to conf/php5-fpm.init

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,26 @@
11
#!/bin/sh
22
### BEGIN INIT INFO
3-
# Provides: php7-fpm
3+
# Provides: php5-fpm
44
# Required-Start: $remote_fs $network
55
# Required-Stop: $remote_fs $network
66
# Default-Start: 2 3 4 5
77
# Default-Stop: 0 1 6
8-
# Short-Description: starts php7-fpm
8+
# Short-Description: starts php5-fpm
99
# Description: Starts The PHP FastCGI Process Manager Daemon
1010
### END INIT INFO
1111

1212
# Author: Ondrej Sury <ondrej@debian.org>
1313
# Adjusted for PHP7 by Kaspars Dambis <hi@kaspars.net>
14+
# Adjusted for PHP5 by Jaroslav Hranička <hranicka@outlook.com>
1415

15-
PATH=/sbin:/usr/sbin:/bin:/usr/bin:/usr/local/php7/sbin
16-
DESC="PHP7 FastCGI Process Manager"
17-
NAME=php7-fpm
18-
DAEMON=/usr/local/php7/sbin/$NAME
19-
CONFFILE=/usr/local/php7/etc/php-fpm.conf
16+
PATH=/sbin:/usr/sbin:/bin:/usr/bin:/usr/local/php5/sbin
17+
DESC="PHP5 FastCGI Process Manager"
18+
NAME=php5-fpm
19+
DAEMON=/usr/local/php5/sbin/$NAME
20+
CONFFILE=/usr/local/php5/etc/php-fpm.conf
2021
DAEMON_ARGS="--daemonize --fpm-config $CONFFILE"
2122
CONF_PIDFILE=$(sed -n 's/^pid[ =]*//p' $CONFFILE)
22-
PIDFILE=${CONF_PIDFILE:-/var/run/php7-fpm.pid}
23+
PIDFILE=${CONF_PIDFILE:-/var/run/php5-fpm.pid}
2324
TIMEOUT=30
2425
SCRIPTNAME=/etc/init.d/$NAME
2526

conf/www.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
user = www-data
44
group = www-data
55

6-
listen = 127.0.0.1:9007
6+
listen = 127.0.0.1:9006
77

88
pm = dynamic
99
pm.max_children = 5

extensions/imagick-build.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@ sudo apt-get install -y \
99

1010
git clone https://github.com/mkoppanen/imagick.git
1111
cd imagick
12-
git checkout phpseven
12+
git checkout master
1313
git pull
1414

15-
/usr/local/php7/bin/phpize
16-
./configure --with-php-config=/usr/local/php7/bin/php-config
15+
/usr/local/php5/bin/phpize
16+
./configure --with-php-config=/usr/local/php5/bin/php-config
1717

1818
make
1919
sudo make install

extensions/imagick-install.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#!/bin/bash
22

33
# Add config files
4-
echo "extension=imagick.so" | sudo tee -a /usr/local/php7/etc/conf.d/modules.ini
4+
echo "extension=imagick.so" | sudo tee -a /usr/local/php5/etc/conf.d/modules.ini

extensions/memcached-build.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@ sudo apt-get install -y \
99

1010
git clone https://github.com/php-memcached-dev/php-memcached
1111
cd php-memcached
12-
git checkout php7
12+
git checkout master
1313
git pull
1414

15-
/usr/local/php7/bin/phpize
16-
./configure --with-php-config=/usr/local/php7/bin/php-config
15+
/usr/local/php5/bin/phpize
16+
./configure --with-php-config=/usr/local/php5/bin/php-config
1717

1818
make
1919
sudo make install

extensions/memcached-install.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#!/bin/bash
22

33
# Enable the module
4-
echo "extension=memcached.so" | sudo tee -a /usr/local/php7/etc/conf.d/modules.ini
4+
echo "extension=memcached.so" | sudo tee -a /usr/local/php5/etc/conf.d/modules.ini

extensions/redis-build.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,11 @@ sudo apt-get install -y \
88

99
git clone https://github.com/phpredis/phpredis.git
1010
cd phpredis
11-
git checkout php7
11+
git checkout master
1212
git pull
1313

14-
/usr/local/php7/bin/phpize
15-
./configure --with-php-config=/usr/local/php7/bin/php-config
14+
/usr/local/php5/bin/phpize
15+
./configure --with-php-config=/usr/local/php5/bin/php-config
1616

1717
make
1818
sudo make install

extensions/redis-install.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#!/bin/bash
22

33
# Enable the module
4-
echo "extension=redis.so" | sudo tee -a /usr/local/php7/etc/conf.d/modules.ini
4+
echo "extension=redis.so" | sudo tee -a /usr/local/php5/etc/conf.d/modules.ini

0 commit comments

Comments
 (0)