MFC r365646, r365720:
r365646:
Enclose BRANCH_OVERRIDE in quotes in order to fix an issue with freebsd-update(8) builds, where BRANCH is suffixed with -p0 for builds.
r365720 (gordon):
Partially revert r346018 and use the if/then construct instead of shell.
Sponsored by: Rubicon Communications, LLC (netgate.com)