
Big Sur: “Warning: PHP is not recommended” - neovive
https://twitter.com/GrahamJCampbell/status/1295111982924861442
======
spanhandler
What’s with the people in the twitter thread taking this as an insult to PHP
itself, or a sign that PHP will no longer run on macOS? It’s clearly neither.

~~~
stormcode
Seems to be more about Apple telling people what is and isn't recommended
software.

~~~
csande17
It's easier to understand this if you know that the `php` binary bring invoked
is the one _shipped with the operating system_. They've introduced similar
messages for other interpreter binaries. I think the intent here is to say
"relying on this copy of PHP is not recommended", or maybe "shipping a
standalone PHP script to end users is not recommended".

~~~
spanhandler
Yeah, like, pretend you're looking at a message in a FreeBSD base system's
documentation or something. They're just saying "don't write new shit that
relies on macOS system PHP, because it's going away"—it is... not recommended!

As pointed out in the thread, it says the same thing for Python2 (though only
if you run it bare for some reason, not with --version, and obviously only if
you're invoking the system Python2, not something from e.g. Homebrew) so it
seems to just be the message they use for anything that's deprecated and
expected to vanish from macOS installations in the future. I bet the same
message is used a bunch of other places.

I'd be kind of horrified if anyone's writing PHP on a mac that _is not_
targeting the system's PHP specifically, but is _using_ it. You want whatever
version's gonna be on your deployment target, not what happens to ship with
your OS installation. Included scripting languages are there so you can write
scripts targeting the OS, not develop with them generally. You could, but it's
not what most people are going to want.

------
schoolornot
What was the original intent of bundling php + ruby on rails in a workstation
OS?

~~~
skissane
I think it was a good idea in principle, but worked out poorly in practice.

Pro: You don't have to download it, it is already there

Con: It is always going to be an old and outdated version, since Apple can't
keep up with the open source developers, so you probably need to download it
anyway, and then deal with the confusion of having both the old and new
versions installed

They probably didn't foresee how it was going to work out in practice, in
hindsight they probably wish they'd made a different decision. You learn from
experience.

Also, Unix OS vendors have had a historical culture of bundling things. Back
in the old days, before widespread availability of the Internet, it made sense
to bundle as much with the OS as possible, since if it wasn't bundled it was
hard to get. Even after the Internet became widely available, back in the dark
ages of dial-up, downloads were so slow, it made sense to include as much as
possible out of the box. It is a different world now. But keep in mind that
Mac OS X Server 1.0 was released all the way back in 1999, and back then those
times were still the reality for many people, and a recent memory for many
more.

------
tdeck
Are people writing a lot of scripts in PHP? I'm surprised to see it came
preinstalled to begin with.

~~~
zeroimpl
Apache is also preinstalled. I use it to host some PHP scripts on my local
network. The annoying thing is that every OS upgrade causes all the
configuration files to get reset so I need to fix it every time. But it's just
small enough of an annoyance that I haven't migrated to installing my own.

------
ch_123
Same message is used for the bundled Python 2.7:

`WARNING: Python 2.7 is not recommended. This version is included in macOS for
compatibility with legacy software. Future versions of macOS will not include
Python 2.7. Instead, it is recommended that you transition to using 'python3'
from within Terminal.`

Similar message for Ruby, but without the "not recommended" part:

`WARNING: This version of ruby is included in macOS for compatibility with
legacy software. In future versions of macOS the ruby runtime will not be
available by default, and may require you to install an additional package.`

------
taylodl
Hmmm, I wonder if Apple is going to distribute _Homebrew_ as part of Mac OS or
are they planning on creating their own package manager?

