Upgrade PHP from 5.5 to 5.6 (originally installed with portmaster)

Hello,

As PHP 5.5 is going to be deprecated soon, we need to upgrade PHP to version 5.6.
I't a straight forward 10.3-RELEASE-p9 with Apache 2.4 and MySQL.

All ports are installed using portmaster.
Someone told me to just run:

portmaster -o lang/php56 lang/php55

Could anything really be that easy?
Or are there any known "heads up"?

Using the following PHP Modules

Code:
bz2
Core
ctype
curl
date
dba
dom
ereg
exif
fileinfo
filter
ftp
gd
gettext
hash
iconv
intl
json
libxml
mbstring
mcrypt
mhash
mysql
mysqli
mysqlnd
openssl
pcre
PDFlib
PDO
pdo_mysql
pdo_sqlite
Phar
posix
pspell
readline
Reflection
session
SimpleXML
soap
SPL
sqlite3
standard
tokenizer
xml
xmlreader
xmlwriter
xsl
Zend OPcache
zip
zlib

[Zend Modules]
Zend OPcache
 
That should work, but I like to go with a less error prone solution, just remove everything PHP 5.5 related and install PHP 5.6 with the modules you need. There's less risk of running into a dependency hell if you remove the old stuff first. It's a bit more work though.
 
Perfect, as I thought! :)

If I may ask two more questions:
1. Should ports originally installed with portmaster, be uninstalled with cd /usr/ports/lang/php55 && make deinstall clean, or should we use portmaster for uninstalling?
2. Is there a way to deinstall all of php55 modules in one go, or do we need to deinstall them one by one?

Thanks,
 
1) Doesn't matter, it'll all end up doing a pkg-delete(8).

2) This should probably remove it all: pkg delete -R php55 && pkg autoremove
 
Other option is to compile PHP sources directly from php.net which I normally do and its easier to maintain.
Not recommended unless you really know what you are doing. I would advise against it and sticking to either ports or packages, use the ports if you're going to deviate from the standard settings.
 
Not recommended unless you really know what you are doing. I would advise against it and sticking to either ports or packages, use the ports if you're going to deviate from the standard settings.

Been doing it for 2 years and had no issues but you are correct that is not something for someone who knows nothing about manually compiling source codes. I did this because I have multiple PHP versions and to keep pkg list short as well.
 
Back
Top