  We prove that the generating series of special divisors in toroidal
compactifications of orthogonal Shimura varieties is a mixed mock modular form.
More precisely, we find an explicit completion using theta series associated to
rays in the cone decomposition. The proof relies on intersection theory at the
boundary of the Shimura variety.
