I am seeing the same thing, and been pulling my hair out on this (cuz just realize the php patch level was way behind).
Note the "Error:Can't add notification!" is more cosmetic. if you go to your cpanel web admin, click on the bell to display notifications, and remove them (or just the php related ones), that error will go away.
As for solving the problem, for the php-selector one so far I did find a work around, that is dumb, but whatever.
- Start the build process via the UI
- in a terminal window to the server, cd to /usr/local/src
- copy the php-rebuild.sh to some place else (don't delete, just cp)
- once the build process completes (and fails), on a terminal window
- cd /usr/local/src
- cp php-rebuild.sh to the /usr/local/src directory (since the UI build process removes it)
- now do a "sh php-rebuild.sh"
For some reason, if you run it that way, it works. But running from the UI it does not. I suspect the UI is not doing the "cd /usr/local/src" before running it.