Maybe I should wear a hard hat to guard against falling asteroids.
They are working on solving that problem as well. Could be dicey. Scientists like Freeman Dyson, Nikolai Kardashev, etc, envisioned that an advanced "type II civilization" could not only save themselves from such an extinction event, they could also save themselves from a solar catastrophe on the order of a super nova. ie, Star Trek and the federation of planets