builder: properly communicate onbuild trigger information during subsequent builds.

closes #8078
fixes #8078

/cc @tianon @tiborvass