Isometry group of a compact Pseudo-Riemannian manifold

Here are the details for my comment above.

A matrix $A\in SL(2,{\mathbb Z})$ is called Anosov if its eigenvalues have absolute value different from $1$. Equivalently, $tr(A)\notin [-2,2]$. Given any two distinct 1-dimensional subspaces $L_1, L_2\subset {\mathbb R}^2$ there is a unique, up to scale, nondegenerate bilinear form $b$ on ${\mathbb R}^2$ which vanishes on both lines. (If $e_i$ is a generating vector of $L_i$ then the form $b$ is uniquely determined by $b(e_1,e_2)$. For instance, if $L_1, L_2$ are the coordinate axes then $b(x,y)=xy$.) This form defines a Lorenztian metric on ${\mathbb R}^2$. If $A\in SL(2, {\mathbb R})$ preserves both lines $L_1, L_2$ then it preserves the form $b$ as well. Now, given an Anosov matrix $A\in SL(2, {\mathbb Z})$ let $L_1, L_2$ be its eigenspaces (both eigenvalues have to be real and distinct) and $b$ be the corresponding bilinear form which has to be invariant under $A$. The linear transformation $A$ preserves the standard integer lattice ${\mathbb Z}^2$ in ${\mathbb R}^2$ and, hence, descends to an automorohism $f: T^2= {\mathbb R}^2/{\mathbb Z}^2$. The bilinear form descends to a flat Lorenzian metric $g$ on $T^2$ invariant under the automorphism $f$. Thus, $Isom(T^2, g)$ contains the infinite cyclic group $\Gamma$ generated by $f$. I claim that $\Gamma$ is not contained in any Lie group $G$ with finitely many component acting (topologically) on $T^2$. Indeed, $f$ induces an infinite order automorphism on the 1st homology group $H_1(T^2, {\mathbb Z})$, namely the one given by the matrix $A$, where we use projections of the standard coordinate vectors in ${\mathbb R}^2$ as the generators of the homology group. If $G$ is a subgroup of $Homeo(T^2)$ containing $\Gamma$ then the path connected component of identity $G^0$ of $G$ acts trivially on the 1-st homology group $H_1(T^2, {\mathbb Z})$. Hence, if $G$ has only finitely many connected components then the image of $G$ in $Aut(H_1(T^2, {\mathbb Z}))$ is finite. Thus, the automorphism $f$ as above cannot belong to such $G$. Since every compact group has only finitely many connected components, it follows that $f$ cannot belong to any compact Lie subgroup of $Homeo(T^2)$. Since the isometry group of any pseudo-Riemannian manifold is a Lie group, it follows that $Isom(T^2, g)$ is noncompact. qed