  The paper has two relatively distinct but connected goals; the first is to
define the notion of Pad\'e\ approximation of Weyl-Stiltjes transforms on an
arbitrary compact Riemann surface of higher genus. The data consists of a
contour in the Riemann surface and a measure on it, together with the
additional datum of a local coordinate near a point and a divisor of degree
$g$. The denominators of the resulting Pad\'e--like approximation also satisfy
an orthogonality relation and are sections of appropriate line bundles. A
Riemann--Hilbert problem for a square matrix of rank two is shown to
characterize these orthogonal sections, in a similar fashion to the ordinary
orthogonal polynomial case.
  The second part extends this idea to explore its connection to integrable
systems. The same data can be used to define a pairing between two sequences of
line bundles. The locus in the deformation space where the pairing becomes
degenerate for fixed degree coincides with the zeros of a "tau" function. We
show how this tau function satisfies the Kadomtsev--Petviashvili hierarchy with
respect to either deformation parameters, and a certain modification of the
2--Toda hierarchy when considering the whole sequence of tau functions. We also
show how this construction is related to the Krichever construction of
algebro--geometric solutions.
