Ubuntu: Do patching an installed PHP package have side-effects?


I used this recipe from DigitalOcean to install phpMyAdmin on a web server running Ubuntu 16.04 LTS.

However, the version of php-gettext that you get for Ubuntu 16.4 LTS by doing:

apt install php-gettext  

is from 2010, and it uses some depreciated class contructors (as pointed out in this answer).

My question is: If I go ahead and apply the suggested edits, will it have any (harmful) side effects. For instance will me patching the code stop it from being upgraded when the fine people officially maintaining Ubuntu 16.04 gets around to fixing this?

Or can I go ahead and patch it, and when the official upgrade comes along, it will be automatically installed as normal when I do the apt upgrade?


You can go ahead and patch it manually, but when the php-gettext package gets updated for any reason whatsoever, your changes will be overwritten. Apt will ask about changes to configuration files, but it simply doesn't care about any other changes (and files in /usr typically won't be marked as configuration files).

So, no, it won't affect upgrades, but you'll need to be re-apply the changes when upgrading if the new version doesn't fix the problem.

Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Next Post »