  Semibounded symmetric operators have a distinguished self-adjoint extension,
the Friedrichs extension. The eigenvalues of the Friedrichs extension are given
by a variational principle that involves only the domain of the symmetric
operator. Although Dirac operators describing relativistic particles are not
semibounded, the Dirac operator with Coulomb potential is known to have a
distinguished extension. Similarly, for Dirac-type operators on manifolds with
a boundary a distinguished self-adjoint extension is characterised by the
Atiyah--Patodi--Singer boundary condition. In this paper we relate these
extensions to a generalisation of the Friedrichs extension to the setting of
operators satisfying a gap condition. In addition we prove, in the general
setting, that the eigenvalues of this extension are also given by a variational
principle that involves only the domain of the symmetric operator.
