  We define intrinsic torsion in generalised geometry and use it to introduce a
new notion of generalised special holonomy. We then consider generic warped
supersymmetric flux compactifications of M theory and Type II of the form
$\mathbb{R}^{D-1,1}\times M$. Using the language of
$E_{d(d)}\times\mathbb{R}^+$ generalised geometry, we show that, for $D\geq 4$,
preserving minimal supersymmetry is equivalent to the manifold $M$ having
generalised special holonomy and list the relevant holonomy groups. We
conjecture that this result extends to backgrounds preserving any number of
supersymmetries. As a prime example, we consider $\mathcal{N}=1$ in $D=4$. The
corresponding generalised special holonomy group is $SU(7)$, giving the natural
M theory extension to the notion of a $G_2$ manifold, and, for Type II
backgrounds, reformulating the pure spinor $SU(3)\times SU(3)$ conditions as an
integrable structure.
