kevink619
Posts: 7
Joined: Tue Oct 11, 2016 3:02 am

Why is it so difficult to install PHP 7.2 in RPi3?!

Wed Oct 31, 2018 8:37 am

Can someone please tell me how to install PHP 7.2 on my Raspberry Pi 3?

I can never get it to install. And I don't have "buster" - whatever the heck that is.

User avatar
RaTTuS
Posts: 10381
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK

Re: Why is it so difficult to install PHP 7.2 in RPi3?!

Wed Oct 31, 2018 9:08 am

what have you tried ?
what instructions are you following
How To ask Questions :- http://www.catb.org/esr/faqs/smart-questions.html
WARNING - some parts of this post may be erroneous YMMV

1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX
Covfefe

klricks
Posts: 6509
Joined: Sat Jan 12, 2013 3:01 am
Location: Grants Pass, OR, USA
Contact: Website

Re: Why is it so difficult to install PHP 7.2 in RPi3?!

Wed Oct 31, 2018 1:08 pm

kevink619 wrote:
Wed Oct 31, 2018 8:37 am
Can someone please tell me how to install PHP 7.2 on my Raspberry Pi 3?

I can never get it to install. And I don't have "buster" - whatever the heck that is.
The current version of PHP in the Raspbian "Stretch" repository is 7.0
Why do you think you need 7.2?

Raspbian is based on the Debian Linux distribution.
The current version is Debian 9 which is code-named "Stretch"
Debian 8 was named "Wheezy"
The next release Debian 10 is named "Buster" (Approximate release in mid 2019)
The names are taken from characters in the Toy Story movies.
New releases come out about every 2 years and will have newer but not necessarily the latest versions of user software packages included.
Unless specified otherwise my response is based on the latest and fully updated Raspbian Buster w/ Desktop OS.

User avatar
allfox
Posts: 452
Joined: Sat Jun 22, 2013 1:36 pm
Location: Guang Dong, China

Re: Why is it so difficult to install PHP 7.2 in RPi3?!

Thu Nov 01, 2018 8:11 am

I see that they have a new version of Node.js in Raspberry Foundation's repository.

Don't know how they decide which package could get update in this way.

PHP is quite like Node.js, I think.

I believe Web is changing(advancing) too fast these days, reinventing too much wheels.

User avatar
DougieLawson
Posts: 35594
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: Why is it so difficult to install PHP 7.2 in RPi3?!

Thu Nov 01, 2018 11:27 am

kevink619 wrote:
Wed Oct 31, 2018 8:37 am
Can someone please tell me how to install PHP 7.2 on my Raspberry Pi 3?

I can never get it to install. And I don't have "buster" - whatever the heck that is.
You can build PHP7 from source code, but it's non-trivial task and it takes a long time (may be faster on a 3B+, it's been a while since I went through that pain with PHP5).

This script https://gist.github.com/matthiasbayer/2 ... 4793c527cc may help.
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

Heater
Posts: 12976
Joined: Tue Jul 17, 2012 3:02 pm

Re: Why is it so difficult to install PHP 7.2 in RPi3?!

Thu Nov 01, 2018 12:51 pm

allfox,
Don't know how they decide which package could get update in this way.
Most packages in Raspbian come from Debian from which it is derived. When Debian updates a package that eventually finds it's way into Raspbian. Packages get updated by their package maintainers who are generally volunteers. The maintainers build the package and test it before it goes into use. So it's understandable that the packages in Debian/Raspbian can lag behind the latest versions.
PHP is quite like Node.js, I think.
Only if you have only glanced sideways at some source for less than a minute.

Apart from both being interpreted language systems with some superficial C like syntax, they are vastly different. Built for different purposes. One can do a lot more, more easily, with node.js than PHP.
I believe Web is changing(advancing) too fast these days, reinventing too much wheels.
Perhaps but PHP and Javascript have been around since almost the beginning and both are much the same. Javascript especially has done an excellent job of maintaining backwards compatibility.

Moving from PHP 7.0 to 7.2 or updating node.js is not so much reinventing the wheels as polishing the old ones.

User avatar
DougieLawson
Posts: 35594
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: Why is it so difficult to install PHP 7.2 in RPi3?!

Thu Nov 01, 2018 12:58 pm

Heater wrote:
Thu Nov 01, 2018 12:51 pm
Moving from PHP 7.0 to 7.2 or updating node.js is not so much reinventing the wheels as polishing the old ones.
I don't think I can say what we're polishing with PHP7.2 in a public, family friendly forum. But we're using Kiwi's finest brown polish for it.
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

User avatar
allfox
Posts: 452
Joined: Sat Jun 22, 2013 1:36 pm
Location: Guang Dong, China

Re: Why is it so difficult to install PHP 7.2 in RPi3?!

Thu Nov 01, 2018 1:26 pm

Heater wrote:
Thu Nov 01, 2018 12:51 pm
Most packages in Raspbian come from Debian from which it is derived. When Debian updates a package that eventually finds it's way into Raspbian. Packages get updated by their package maintainers who are generally volunteers. The maintainers build the package and test it before it goes into use. So it's understandable that the packages in Debian/Raspbian can lag behind the latest versions.
But Debian Stable only have Node.js 4.8.2. The RPF have the version 8 for current Pi, which should be for Debian Testing.

It looks like PHP is not that lucky. (I didn't do a apt search for PHP)

I remember dnsmasq also had a newer version on Pi in RPF's repo.

It's good, but not that fair for other package.

dmausner
Posts: 3
Joined: Wed Feb 06, 2019 5:24 pm

Re: Why is it so difficult to install PHP 7.2 in RPi3?!

Mon Feb 18, 2019 3:56 pm

I will second the OP's implied request for a RPi3 compilation of PHP 7.2 (or 7.3).

One good reason for this request is that php.net issue library corrections in 7.1, 7.2, and 7.3, but many (or most) corrections are not back-ported to 7.0.

On other Linux platforms, in order to obtain library updates, I have upgraded from 7.0 to at least 7.2. This is not currently possible on Stretch, which leaves us with bugs known to be fixed in later versions, but not installable today. This presents reliability and security issues for production RPi3 maintainers.

Respect to all volunteer RPi3 code coordinators.

User avatar
rpdom
Posts: 14770
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: Why is it so difficult to install PHP 7.2 in RPi3?!

Mon Feb 18, 2019 4:05 pm

dmausner wrote:
Mon Feb 18, 2019 3:56 pm
I will second the OP's implied request for a RPi3 compilation of PHP 7.2 (or 7.3).
I guess you didn't read the stuff about Debian policy and what "Stable" means.

Never mind, in a few months time Stretch will be replaced by Buster and that will have newer versions of most packages.

serendipitus
Posts: 1
Joined: Fri May 31, 2019 7:40 am

Re: Why is it so difficult to install PHP 7.2 in RPi3?!

Fri May 31, 2019 7:43 am

On Ubuntu there is a solution which also seems to work on RPi3. I managed to install it successfully as there is a package for Stretch.

https://www.colinodell.com/blog/201711/ ... ing-php-72

Return to “General discussion”