  We construct a large class of gauge theories with extended supersymmetry on
four-dimensional manifolds with a Killing vector field and isolated fixed
points. We extend previous results limited to super Yang-Mills theory to
general $\mathcal{N}=2$ gauge theories including hypermultiplets. We present a
general framework encompassing equivariant Donaldson-Witten theory and Pestun's
theory on $S^4$ as two particular cases. This is achieved by expressing fields
in cohomological variables, whose features are dictated by supersymmetry and
require a generalized notion of self-duality for two-forms and of chirality for
spinors. Finally, we implement localization techniques to compute the exact
partition function of the cohomological theories we built up and write the
explicit result for manifolds with diverse topologies.
