Attempt to fix a problem that leads to repeated building of some ports
There are build dependencies, that were compiled again and again even
though the latest version was already installed.
This fix is based on a patch suggested by Tatsuki Makino, with a small
change to better comply with the existing style used in this program.
An extended patch has been provided by Walter Schwarzenfeld, but in my
tests it did not make a difference. If further testing shows a need for
the additional commands suggested by Walter, I'll add them (or a variation)
in a follow-up commit.
PR: 241227, 242086, 243432
Submitted by: Tatsuki Makino
Approved by: antoine (implicit)